Re: [PATCH 2/2] block: Split and submit bios in LBA order

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

 



On 3/24/23 01:27, Bart Van Assche wrote:
> On 3/23/23 03:28, Damien Le Moal wrote:
>> For the zone append emulation, the write locking is done by sd.c and the upper
>> layer does not restrict to one append per zone. So we actually could envision a
>> UFS version of the sd write locking calls that is optimized for the device
>> capabilities and we can keep a common upper layer (which is preferable in my
>> opinion).
> 
> I see a blk_req_zone_write_trylock() call in 
> sd_zbc_prepare_zone_append() and a blk_req_zone_write_unlock() call in 
> sd_zbc_complete() for REQ_OP_ZONE_APPEND operations. Does this mean that 
> the sd_zbc.c code restricts the queue depth to one per zone for 
> REQ_OP_ZONE_APPEND operations?

Yes, since the append becomes a regular write and HBAs are often happy to
reorder these commands, even for SMR, we need the locking.

But if I understand your use case correctly, given that UFS gives guarantees on
the command dispatching order, you could probably relax this locking for zone
append requests. But you cannot for regular writes as the locking is up in the
block layer and needed to avoid block layer level reordering.

> 
> Thanks,
> 
> Bart.

-- 
Damien Le Moal
Western Digital Research




[Index of Archives]     [Linux RAID]     [Linux SCSI]     [Linux ATA RAID]     [IDE]     [Linux Wireless]     [Linux Kernel]     [ATH6KL]     [Linux Bluetooth]     [Linux Netdev]     [Kernel Newbies]     [Security]     [Git]     [Netfilter]     [Bugtraq]     [Yosemite News]     [MIPS Linux]     [ARM Linux]     [Linux Security]     [Device Mapper]

  Powered by Linux