Re: A new ide warning message

From: Jens Axboe (axboe@suse.de)
Date: Fri Aug 02 2002 - 09:20:37 EST


On Fri, Aug 02 2002, Bartlomiej Zolnierkiewicz wrote:
>
> On Fri, 2 Aug 2002, Jens Axboe wrote:
>
> > On Fri, Aug 02 2002, Jens Axboe wrote:
> > > On Fri, Aug 02 2002, Marcin Dalecki wrote:
> > > > U?ytkownik Stephen Lord napisa?:
> > > > >In 2.5.30 I started getting these warning messages out ide during
> > > > >the mount of an XFS filesystem:
> > > > >
> > > > >ide-dma: received 1 phys segments, build 2
> > > > >
> > > > >Can anyone translate that into English please.
> > > >
> > > > It can be found in pcidma.c.
> > > > It is repoting that we have one physical segment needed by
> > > > the request in question but the sctter gather list allocation
> > > > needed to break it up for mapping in two.
> > >
> > > You don't seem to realise that this is a BUG (somewhere, could even be
> > > in the generic mapping functions)! blk_rq_map_sg() must never map a
> > > request to more entries that rq->nr_segments, that's just very wrong.
> > >
> > > That's why I'm suspecting the recent pcidma changes. Just a feeling, I
> > > have not looked at them.
> >
> > I'll take that back. Having looked at Adam's changes there are perfectly
> > fine. I'm now putting my money on IDE breakage somewhere instead. It
>
> Look again Jens. Adam's changes made IDE queue handling inconsistent.
> hint: 2 * 127 != 255
>
> But noticed warning deals with design of ll_rw_blk.c. ;-)
> (right now max_segment_size have to be max bv->bv_len aligned)

Yeah that's true, actually was just saying that on linux-scsi
yesterday/today.

> Jens, please look at segment checking/counting code, it does it on
> bv->bv_len (4kb most likely) not sector granuality...
>
> So for not 4kb aligned max_segment_size we will get new segment...
>
> Best fix will be to make block layer count sectors not bv->bv_len...

Well I'm inclined to just make that page size granularity. It's like
that in 2.4 as well (no guarentees that we will honor anything less than
that granularity).

> btw. I like Adam's patch but it was draft not to include in mainline (?).

The concept is sound, so it has a bug... I can say the same for other
stuff in the kernel as well :-)

I probably just wanted more review (my 1 minute review surely wasn't
enough).

-- 
Jens Axboe

- To unsubscribe from this list: send the line "unsubscribe linux-kernel" in the body of a message to majordomo@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html Please read the FAQ at http://www.tux.org/lkml/



This archive was generated by hypermail 2b29 : Wed Aug 07 2002 - 22:00:19 EST