scsi: ufs: don't power cycle device if power on write protected
UFS device specification allows LUs to be write protected, either permanently or power on write protected. If any LU is power on write protected and if the card is power cycled (by powering off VCCQ and/or VCC rails), LU's write protect status would be lost. So this means those LUs can be written now. This patch ensures that UFS device is allowed to be power cycled only if the power on protect is not set for any of the LUs. If power on write protect is set and if device is in sleep/power-off state & link in inactive state (Hibern8 or OFF state), along with powering off VCC rail, put the VCCQ and VCCQ2 rails in low power mode. Change-Id: Ice10e1cc1b35b14f0a92605f39282275e64c736e Signed-off-by:Subhash Jadavani <subhashj@codeaurora.org> Signed-off-by:
Sujit Reddy Thumma <sthumma@codeaurora.org>
Loading
Please register or sign in to comment