Re: [Alsa-devel] 2.5.50: sleeping function called from illegal context

2002-12-06 Thread Duncan Sands
> > I guess another way of dealing with this kind of problem is to use a > > semaphore rather than a spinlock, and a workqueue: when the interrupt > > comes in, the call to snd_ctl_notify is put on the queue, where it will > > later be run in process context, and can safely take the semaphore. > >

Re: [Alsa-devel] 2.5.50: sleeping function called from illegal context

2002-12-04 Thread Takashi Iwai
At Tue, 3 Dec 2002 13:21:41 +0100, Duncan Sands wrote: > > On Tuesday 03 December 2002 19:34, Paul Davis wrote: > > >I guess another way of dealing with this kind of problem is to use a > > >semaphore rather than a spinlock, and a workqueue: when the interrupt > > >comes in, the call to snd_ctl_no

Re: [Alsa-devel] 2.5.50: sleeping function called from illegal context

2002-12-03 Thread Duncan Sands
On Tuesday 03 December 2002 19:34, Paul Davis wrote: > >I guess another way of dealing with this kind of problem is to use a > >semaphore rather than a spinlock, and a workqueue: when the interrupt > >comes in, the call to snd_ctl_notify is put on the queue, where it will > > later be run in proces

Re: [Alsa-devel] 2.5.50: sleeping function called from illegal context

2002-12-03 Thread Paul Davis
>I guess another way of dealing with this kind of problem is to use a >semaphore rather than a spinlock, and a workqueue: when the interrupt >comes in, the call to snd_ctl_notify is put on the queue, where it will later >be run in process context, and can safely take the semaphore. can i get a poi

Re: [Alsa-devel] 2.5.50: sleeping function called from illegal context

2002-12-03 Thread Duncan Sands
> yes, basically what snd_ctl_notify() does is the same. > it queues an event and wakes up the sleepers. > thus, it's ok to separate the stuff from the semaphore. > > the attached is a patch to rewrite the locks with rwsem. > please check whether it works for you. This is against alsa cvs and not

Re: [Alsa-devel] 2.5.50: sleeping function called from illegal context

2002-12-03 Thread Takashi Iwai
At Tue, 3 Dec 2002 06:57:45 +0100, Duncan Sands wrote: > > On Tuesday 03 December 2002 14:56, Takashi Iwai wrote: > > At Tue, 3 Dec 2002 04:55:15 +0100, > > > > Duncan Sands wrote: > > > On Tuesday 03 December 2002 13:01, Takashi Iwai wrote: > > > > At Tue, 3 Dec 2002 04:07:52 +0100, > > > > > > >

Re: [Alsa-devel] 2.5.50: sleeping function called from illegal context

2002-12-03 Thread Duncan Sands
On Tuesday 03 December 2002 14:56, Takashi Iwai wrote: > At Tue, 3 Dec 2002 04:55:15 +0100, > > Duncan Sands wrote: > > On Tuesday 03 December 2002 13:01, Takashi Iwai wrote: > > > At Tue, 3 Dec 2002 04:07:52 +0100, > > > > > > Duncan Sands wrote: > > > > Got this with today 2.5 BK tree: > > > > >

Re: [Alsa-devel] 2.5.50: sleeping function called from illegal context

2002-12-03 Thread Takashi Iwai
At Tue, 3 Dec 2002 04:55:15 +0100, Duncan Sands wrote: > > On Tuesday 03 December 2002 13:01, Takashi Iwai wrote: > > At Tue, 3 Dec 2002 04:07:52 +0100, > > > > Duncan Sands wrote: > > > Got this with today 2.5 BK tree: > > > > > > Debug: sleeping function called from illegal context at > > > incl

Re: [Alsa-devel] 2.5.50: sleeping function called from illegal context

2002-12-03 Thread Duncan Sands
On Tuesday 03 December 2002 13:01, Takashi Iwai wrote: > At Tue, 3 Dec 2002 04:07:52 +0100, > > Duncan Sands wrote: > > Got this with today 2.5 BK tree: > > > > Debug: sleeping function called from illegal context at > > include/asm/semaphore.h:119 Call Trace: > > [] __might_sleep+0x52/0x58 > > [

Re: [Alsa-devel] 2.5.50: sleeping function called from illegal context

2002-12-03 Thread Takashi Iwai
At Tue, 3 Dec 2002 04:07:52 +0100, Duncan Sands wrote: > > Got this with today 2.5 BK tree: > > Debug: sleeping function called from illegal context at include/asm/semaphore.h:119 > Call Trace: > [] __might_sleep+0x52/0x58 > [] snd_cs46xx_iec958_put+0x36/0xf8 > [] snd_ctl_elem_write+0xe0/0x1a4

[Alsa-devel] 2.5.50: sleeping function called from illegal context

2002-12-03 Thread Duncan Sands
Got this with today 2.5 BK tree: Debug: sleeping function called from illegal context at include/asm/semaphore.h:119 Call Trace: [] __might_sleep+0x52/0x58 [] snd_cs46xx_iec958_put+0x36/0xf8 [] snd_ctl_elem_write+0xe0/0x1a4 [] snd_ctl_ioctl+0x184/0x2c8 [] sys_ioctl+0x1fa/0x244 [] syscall_cal