Re: [RFC 09/10] scsi: sd: Avoid sending medium write commands if device is write protected

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On Mon, Aug 11, 2014 at 5:40 AM, Dolev Raviv <draviv@xxxxxxxxxxxxxx> wrote:
> From: Sujit Reddy Thumma <sthumma@xxxxxxxxxxxxxx>
>
> The SYNCHRONIZE_CACHE command is a medium write command and hence can
> fail when the device is write protected. Avoid sending such commands by
> making sure that write-cache-enable is disabled even though the device
> claim to support it.
>
> Signed-off-by: Sujit Reddy Thumma <sthumma@xxxxxxxxxxxxxx>
> Signed-off-by: Dolev Raviv <draviv@xxxxxxxxxxxxxx>

Looks good. Setting SWP is defined to flush caches; there is no other
reason I could imagine WP media would need a SYNCHRONIZE CACHE.

Reviewed-by: Venkatesh Srinivas <venkateshs@xxxxxxxxxx>

-- vs;
--
To unsubscribe from this list: send the line "unsubscribe linux-arm-msm" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html




[Index of Archives]     [Linux ARM Kernel]     [Linux ARM]     [Linux Omap]     [Fedora ARM]     [Linux for Sparc]     [IETF Annouce]     [Security]     [Bugtraq]     [Linux MIPS]     [ECOS]     [Asterisk Internet PBX]     [Linux API]

  Powered by Linux