Re: [PATCH RFC 4/7] md/raid10: convert read/write to use bio_submit_split()

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

 



Hi,

在 2025/08/25 18:59, Christoph Hellwig 写道:
  		allow_barrier(conf);
+		bio = bio_submit_split(bio, max_sectors, &conf->bio_split);
  		wait_barrier(conf, false);
+
+		if (!bio) {
+			set_bit(R10BIO_Returned, &r10_bio->state);
+			goto err_handle;
+		}

The NULL return should only happen for REQ_NOWAIT here, so maybe
give R10BIO_Returned a more descriptive name?  Also please document
the flag in the header.

And also atomic write here, if bio has to split due to badblocks here.
The flag is refer to raid1. I can add cocument for both raid1 and raid10
in this case.


Any maybe yhe code wants a splitting helper instead of open coding
setting this flag in multiple places?
.

Yes.

Thanks,
Kuai





[Index of Archives]     [Linux RAID Wiki]     [ATA RAID]     [Linux SCSI Target Infrastructure]     [Linux Block]     [Linux IDE]     [Linux SCSI]     [Linux Hams]     [Device Mapper]     [Device Mapper Cryptographics]     [Kernel]     [Linux Admin]     [Linux Net]     [GFS]     [RPM]     [git]     [Yosemite Forum]


  Powered by Linux