From: Sabrina Dubroca Date: Tue, 26 Aug 2014 14:14:02 +0000 (+0200) Subject: block: fix error handling in sg_io X-Git-Tag: omap-fixes-against-v3.17-rc3~30^2~2 X-Git-Url: http://git.openpandora.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=d19d744685f47f1bb3d39b3ec51eb50afe5ff47d;p=pandora-kernel.git block: fix error handling in sg_io Before commit 2cada584b200 ("block: cleanup error handling in sg_io"), we had ret = 0 before entering the last big if block of sg_io. Since 2cada584b200, ret = -EFAULT, which breaks hdparm: /dev/sda: setting Advanced Power Management level to 0xc8 (200) HDIO_DRIVE_CMD failed: Bad address APM_level = 128 Signed-off-by: Sabrina Dubroca Fixes: 2cada584b200 ("block: cleanup error handling in sg_io") Reviewed-by: Christoph Hellwig Signed-off-by: Jens Axboe --- Reading git-diff-tree failed