Re: [PATCH v9 17/17] scsi: ufs: Inform the block layer about write ordering

Bart Van Assche
2023-08-17T19:35:57Z

On 8/17/23 12:00, Bao D. Nguyen wrote:
> In legacy SDB mode with auto-hibernation enabled, the default setting for the
> driver_preserves_write_order = false.
>
> Using the default setting, it may be missing this check that is part of the ufshcd_auto_hibern8_update()->ufshcd_update_preserves_write_order().

If auto-hibernation is enabled by the host driver, driver_preserves_write_order
is set by the following code in ufshcd_slave_configure():

q->limits.driver_preserves_write_order =
!ufshcd_is_auto_hibern8_supported(hba) ||
FIELD_GET(UFSHCI_AHIBERN8_TIMER_MASK, hba->ahit) == 0;

Does this answer your question?

Thanks,

Bart.