[lkml]   [2003]   [May]   [13]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
Messages in this thread
SubjectRe: 2.5.69+bk: "sleeping function called from illegal context" on card release while shutting down
On Tue, 2003-05-13 at 12:21, Alex Riesen wrote:
> Paul Fulghum, Tue, May 13, 2003 17:31:01 +0200:
> > Similar to this patch for synclink_cs.c:
> ...
> > - mod_timer(&link->release, jiffies + HZ/20);
> > + mgslpc_release((u_long)link);
> Tried that. This time the trace looks different:
> Debug: sleeping function called from illegal context at include/asm/semaphore.h:119
> Call Trace:
> [<c0118bc8>] __might_sleep+0x58/0x70
> [<c6a31eb6>] +0x82/0x58c [pcmcia_core]
> [<c6a2d193>] undo_irq+0x23/0x90 [pcmcia_core]
> [<c6a31eb6>] +0x82/0x58c [pcmcia_core]
> [<c6a302f8>] pcmcia_release_irq+0xb8/0xe0 [pcmcia_core]
> [<c6a25e00>] pcnet_release+0x0/0x80 [pcnet_cs]
> [<c6a312d5>] CardServices+0x155/0x260 [pcmcia_core]
> [<c6a312c9>] CardServices+0x149/0x260 [pcmcia_core]
> [<c6a25e56>] pcnet_release+0x56/0x80 [pcnet_cs]
> [<c01224a4>] run_timer_softirq+0xc4/0x1a0
> [<c010a8b3>] handle_IRQ_event+0x33/0xf0
> [<c011e889>] do_softirq+0xa9/0xb0
> [<c010abb5>] do_IRQ+0x125/0x150
> [<c01093a8>] common_interrupt+0x18/0x20

Hmmm... the pcnet_release() function is still being called
from a timer context.

Looking at pcnet_cs.c I see that in function pcnet_close()
that the release function is being being run from
a timer. Try changing that instance to calling pcnet_release()
directly as you did in the CS_EVENT handler.

Paul Fulghum,
Microgate Corporation,

To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to
More majordomo info at
Please read the FAQ at

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