lkml.org 
[lkml]   [2001]   [Nov]   [8]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
Patch in this message
/
Date
From
Subject[patch] cciss dequeue race fix (was Re: preempt-patch cleared of blame)
On Thu, Nov 08 2001, Jens Axboe wrote:
> On Thu, Nov 08 2001, Ingo Molnar wrote:
> >
> > On Thu, 8 Nov 2001, Jens Axboe wrote:
> >
> > > On Wed, Nov 07 2001, J Sloan wrote:
> > > > I think there may be a problem with the
> > > > compaq smart/2p raid drivers, since
> > > > the "do_ida_intr" code keeps showing
> > > > up in the oops, and I have not seen a
> > > > problem with 2.4.14 on any other system.
> > >
> > > Does this fix it?
> >
> > it did the trick on my system, which used to oops in/around do_ida_intr as
> > well.
>
> Good, so it was a dequeue race. Thanks Ingo.

BTW, cciss has a similar race.

--
Jens Axboe

--- linux/drivers/block/cciss.c~ Thu Nov 8 11:36:24 2001
+++ linux/drivers/block/cciss.c Thu Nov 8 11:37:03 2001
@@ -1307,6 +1307,8 @@
if (( c = cmd_alloc(h, 1)) == NULL)
goto startio;

+ blkdev_dequeue_request(creq);
+
spin_unlock_irq(&io_request_lock);

c->cmd_type = CMD_RWREQ;
@@ -1386,12 +1388,6 @@

spin_lock_irq(&io_request_lock);

- blkdev_dequeue_request(creq);
-
- /*
- * ehh, we can't really end the request here since it's not
- * even started yet. for now it shouldn't hurt though
- */
addQ(&(h->reqQ),c);
h->Qdepth++;
if(h->Qdepth > h->maxQsinceinit)
\
 
 \ /
  Last update: 2005-03-22 13:13    [from the cache]
©2003-2014 Jasper Spaans. Advertise on this site