Re: [blktests] zbd/012: Test requeuing of zoned writes and queue freezing

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

 



On 11/28/24 01:58, Christoph Hellwig wrote:
> On Wed, Nov 27, 2024 at 08:31:43PM +0900, Damien Le Moal wrote:
>>> We should not issue a report zones to a frozen queue, as that would
>>> bypass the freezing protection.  I suspect the right thing is to
>>> simply defer the error recovery action until after the queue is
>>> unfrozen.
>>
>> But that is the issue: if we defer the report zones, we cannot make progress
>> with BIOs still plugged in the zone write plug BIO list. These hold a queue
>> usage reference that the queue freeze wait is waiting for. We have to somehow
>> allow that report zones to execute to make progress and empty the zone write
>> plugs of all plugged BIOs.
> 
> Or just fail all the bios.
> 
>> Note that if we were talking about regular writes only, we would not need to
>> care about error recovery as we would simply need to abort all these plugged
>> BIOs (as we know they will fail anyway). But for a correct zone append
>> emulation, we need to recover the zone write pointer to resume the
>> execution of the plugged BIOs. Otherwise, the user would see failed zone
>> append commands that are not suppose to fail unless the drive (or the
>> zone) is dead...
> 
> Maybe I'm thick, but what error could we recover from here?

The BIO that failed is not recovered. The user will see the failure. The error
recovery report zones is all about avoiding more failures of plugged zone append
BIOs behind that failed BIO. These can succeed with the error recovery.

So sure, we can fail all BIOs. The user will see more failures. If that is OK,
that's easy to do. But in the end, that is not a solution because we still need
to get an updated zone write pointer to be able to restart zone append
emulation. Otherwise, we are in the dark and will not know where to send the
regular writes emulating zone append. That means that we still need to issue a
zone report and that is racing with queue freeze and reception of a new BIO. We
cannot have new BIOs "wait" for the zone report as that would create a hang
situation again if a queue freeze is started between reception of the new BIO
and the zone report. Do we fail these new BIOs too ? That seems extreme.

-- 
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