Re: [PATCH] md/raid5: remove an incorect assert in in_chunk_boundary

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

 



On Wed, May 19, 2021 at 4:36 AM wp1083705-spam02 wp1083705-spam02
<spam02@xxxxxxxxxxxx> wrote:
>
>
> > Christoph Hellwig <hch@xxxxxx> hat am 19.05.2021 08:22 geschrieben:
> >
> >
> > Now that the original bdev is stored in the bio this assert is incorrect
> > and will trigge for any partitioned raid5 device.
> >
> > Reported-by:  Florian D. <spam02@xxxxxxxxxxxx>
> > Fixes: 309dca309fc3 ("block: store a block_device pointer in struct bio"),
> > Signed-off-by: Christoph Hellwig <hch@xxxxxx>
> > ---
> >  drivers/md/raid5.c | 2 --
> >  1 file changed, 2 deletions(-)
> >
> > diff --git a/drivers/md/raid5.c b/drivers/md/raid5.c
> > index 841e1c1aa5e6..7d4ff8a5c55e 100644
> > --- a/drivers/md/raid5.c
> > +++ b/drivers/md/raid5.c
> > @@ -5311,8 +5311,6 @@ static int in_chunk_boundary(struct mddev *mddev, struct bio *bio)
> >       unsigned int chunk_sectors;
> >       unsigned int bio_sectors = bio_sectors(bio);
> >
> > -     WARN_ON_ONCE(bio->bi_bdev->bd_partno);
> > -
> >       chunk_sectors = min(conf->chunk_sectors, conf->prev_chunk_sectors);
> >       return  chunk_sectors >=
> >               ((sector & (chunk_sectors - 1)) + bio_sectors);
> > --
> > 2.30.2
>
> yes, this solves it, I can confirm with this patch the error/warning message when booting linux-5.12 is gone!

Applied to md-fixes. Thanks all.

@ Florian, would you like to update the Reported-by tag (with your
full name and/or
different email)?

Thanks,
Song



[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