From: Martin K. Petersen Date: Fri, 21 Sep 2012 16:44:12 +0000 (-0400) Subject: [SCSI] sd: Ensure we correctly disable devices with unknown protection type X-Git-Tag: omap-for-v3.7-rc1/fixes-cpufreq-signed~38^2^2~1 X-Git-Url: http://git.openpandora.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=fe542396da73b7e2b0848618c7e95855c1b75689;p=pandora-kernel.git [SCSI] sd: Ensure we correctly disable devices with unknown protection type We set the capacity to zero when we discovered a device formatted with an unknown DIF protection type. However, the read_capacity code would override the capacity and cause the device to be enabled regardless. Make sd_read_protection_type() return an error if the protection type is unknown. Also prevent duplicate printk lines when the device is being revalidated. Reported-by: Hannes Reinecke Signed-off-by: Martin K. Petersen Signed-off-by: James Bottomley --- Reading git-diff-tree failed