Re: [PATCH v19 01/11] block: Support block drivers that preserve the order of write requests

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

 



On 7/2/25 3:57 AM, Damien Le Moal wrote:
On 7/1/25 07:29, Bart Van Assche wrote:
diff --git a/block/blk-settings.c b/block/blk-settings.c
index a000daafbfb4..bceb9a9cb5ba 100644
--- a/block/blk-settings.c
+++ b/block/blk-settings.c
@@ -814,6 +814,8 @@ int blk_stack_limits(struct queue_limits *t, struct queue_limits *b,
  	}
  	t->max_secure_erase_sectors = min_not_zero(t->max_secure_erase_sectors,
  						   b->max_secure_erase_sectors);
+	t->driver_preserves_write_order = t->driver_preserves_write_order &&
+		b->driver_preserves_write_order;

Why not use a feature instead ? Stacking of the features does exactly this, no ?
That would be less code and one less limit.

Not all device mapper drivers preserve the bio order. The above code
allows device mapper drivers to declare whether or not the bio order is
preserved. The suggested alternative implements a different behavior,
namely that the driver at the top of the stack inherits the behavior
from the bottommost driver. I prefer to keep the above code.

Thanks,

Bart.




[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