lkml.org 
[lkml]   [2003]   [Mar]   [19]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
Date
From
SubjectRe: Sleeping in illegal context with 2.5.65-mm2
On Wed, 19 Mar 2003, Greg KH wrote:

> > Debug: sleeping function called from illegal context at mm/slab.c:1723
> > Call Trace:
> > [<c0119d92>] __might_sleep+0x5f/0x65
> > [<c013a097>] kmalloc+0x88/0x8f
> > [<c0238111>] usb_alloc_urb+0x21/0x51
> > [<f09180bc>] hci_usb_enable_intr+0x20/0xf8 [hci_usb]
>
> The call to usb_alloc_urb() here is being done with the GFP_ATOMIC flag,
> which is correct. Do we need to fix up the warning message to prevent
> false positives like this from happening?

Not in my tree: (drivers/bluetooth/hci_sb.c)

if (!(urb = usb_alloc_urb(0, GFP_KERNEL)))
return -ENOMEM;

And the function is called in a write_lock_irqsave(), so the complaint is
justified. (Also, I think __might_sleep() deliberately doesn't get
triggered for GFP_ATOMIC already, as you suggested).

--Kai

-
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:34    [W:0.033 / U:0.792 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site