lkml.org 
[lkml]   [2001]   [Dec]   [20]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
Date
From
SubjectRe: 2.4.17-rc2 BUG at slab.c:1110
Andrew Morton writes:
> Paul Mackerras wrote:
> >
> > So, is this devfs's fault for not allowing devfs_unregister to be
> > called from interrupt context, or is it ide-cs's fault for calling
> > ide_unregister from interrupt context?
> >
>
> ide-cs, I'd say.

Definately. It's always been illegal to call into the devfs API from
interrupt context, and in fact given that devfs_register() always
called kmalloc() with GFP_KERNEL, it should have caught any interrupt
context callers of devfs.

It just happened that in the old devfs core, you could often get away
with a call to devfs_unregister(), since it didn't do any allocations.
However, doing so was unsafe due to races (no locking/irq disabling),
even on UP systems. So it was always a driver bug to do this.

> The way hotplug generally avoids this problem is via schedule_task()
> - that was why it was written in the first place, I think.
>
> And given that we need to bump the event up to process context, we may
> as well do it at the earliest stage. Looks like the fix it to kill
> off the timer altogether, replace it with a tqueue and ask keventd
> to run ide_release.

Sounds good to me. I look forward to seeing your patch in -rc3 :-)

Regards,

Richard....
Permanent: rgooch@atnf.csiro.au
Current: rgooch@ras.ucalgary.ca
-
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/

\
 
 \ /
  Last update: 2005-03-22 13:14    [W:0.066 / U:1.952 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site