* snd-cs4236 (possibly all isa-pnp cards or all alsa isa-pnp cards) broken in 2.6.16-rc4
@ 2006-02-20 16:54 Rene Herman
0 siblings, 0 replies; 15+ messages in thread
From: Rene Herman @ 2006-02-20 16:54 UTC (permalink / raw)
To: Takashi Iwai; +Cc: Adam Belay, Andrew Morton, Linux Kernel
[-- Attachment #1: Type: text/plain, Size: 1940 bytes --]
Hi Takashi.
I noticed on 2.6.16-rc4 that my MPU-401 wasn't functional, due to a
simple copy & paste error in sound/isa/cs423x/cs4236.c:
Index: local/sound/isa/cs423x/cs4236.c
===================================================================
--- local.orig/sound/isa/cs423x/cs4236.c 2006-02-11
00:34:12.000000000 +0100
+++ local/sound/isa/cs423x/cs4236.c 2006-02-20 04:01:29.000000000 +0100
@@ -414,7 +414,7 @@ static int __devinit snd_card_cs423x_pnp
}
/* MPU initialization */
if (acard->mpu && mpu_port[dev] > 0) {
- if (snd_cs423x_pnp_init_mpu(dev, acard->ctrl, cfg) < 0)
+ if (snd_cs423x_pnp_init_mpu(dev, acard->mpu, cfg) < 0)
goto error;
}
kfree(cfg);
Please apply. However, when I tested it (mpu works fine again after
this) I noticed that modprobe -r snd-cs4236 didn't release things --
specifically that the fixed index=1 I have for the card failed on a
subsequent modprobe since ALSA believes that index is still taken.
I stuck a few printks in cs4236.c. From "snd_cs423x_unregister_all",
"pnp_unregister_card_driver(&cs423x_pnpc_driver)" is indeed being called
but the card driver's own remove method, snd_cs423x_pnpc_remove, is not.
I started looking, but ran into the next issue again -- when snd-cs4236
is not card1 but card0, modprobe -r oopses in snd_timer_free (attached)
meaning debugging this wants someone with more of an overview of recent
damage done^W^Wchanges made.
Given that calling pnp_unregister_card_driver() is not cs4236 specific,
I assume the problem is more general. Possibly all ALSA ISA-PnP drivers.
Or, given that pnp_unregister_card_driver is not an ALSA function, maybe
even all ISA-PnP drivers using the card_driver interface.
The more general this problem turns out, the more reason there would be
for fixing this pre 2.6.16, obviously. I can test patches...
Rene.
[-- Attachment #2: oops --]
[-- Type: text/plain, Size: 1692 bytes --]
pnp: Device 01:01.03 disabled.
pnp: Device 01:01.02 disabled.
ALSA sound/isa/cs423x/cs4231_lib.c:208: in: auto calibration time out - reg = 0x18
ALSA sound/isa/cs423x/cs4231_lib.c:187: out: auto calibration time out - reg = 0x10, value = 0x80
ALSA sound/isa/cs423x/cs4231_lib.c:149: outm: auto calibration time out - reg = 0x18, value = 0x0
pnp: Device 01:01.00 disabled.
pnp: the driver 'cs4236_isapnp' has been unregistered
ALSA sound/core/seq/seq_device.c:574: drivers not released (2)
Unable to handle kernel paging request at virtual address f09c6058
printing eip:
f09c6058
*pde = 016d6067
*pte = 00000000
Oops: 0000 [#1]
PREEMPT
Modules linked in: snd_timer snd soundcore snd_page_alloc mga amd_k7_agp drm agpgart nfsd exportfs lockd sunrpc nls_iso8859_1 nls_cp437 vfat fat nls_base
CPU: 0
EIP: 0060:[<f09c6058>] Not tainted VLI
EFLAGS: 00010282 (2.6.16-rc4-local #8)
EIP is at 0xf09c6058
eax: ec20f400 ebx: ec20f400 ecx: ec20f4e8 edx: f09c6058
esi: b7f0417c edi: 00000000 ebp: e627a000 esp: e627af54
ds: 007b es: 007b ss: 0068
Process modprobe (pid: 1359, threadinfo=e627a000 task=e8291ad0)
Stack: <0>f09b20f2 e62610e8 f09b3c20 f09b5bc0 c0126529 00000000 5f646e73 656d6974
c0130072 ffffffff e65d322c b7f14000 c0137f6c b7f13000 b7f14000 b7f14000
e65d33e4 ef12cae0 ef12cb10 ffff0001 0027a000 c0137fae 0805c3f8 b7f0417c
Call Trace:
[<f09b20f2>] snd_timer_free+0x3b/0x46 [snd_timer]
[<f09b3c20>] alsa_timer_exit+0x27/0x42 [snd_timer]
[<c0126529>] sys_delete_module+0x12b/0x155
[<c0130072>] __pdflush+0x196/0x1ac
[<c0137f6c>] do_munmap+0xe2/0xef
[<c0137fae>] sys_munmap+0x35/0x4d
[<c0102551>] syscall_call+0x7/0xb
Code: Bad EIP value.
^ permalink raw reply [flat|nested] 15+ messages in thread
* snd-cs4236 (possibly all isa-pnp cards or all alsa isa-pnp cards) broken in 2.6.16-rc4
@ 2006-02-20 17:18 Rene Herman
0 siblings, 0 replies; 15+ messages in thread
From: Rene Herman @ 2006-02-20 17:18 UTC (permalink / raw)
To: Takashi Iwai; +Cc: Adam Belay, Andrew Morton, Linux Kernel, alsa-devel
[-- Attachment #1: Type: text/plain, Size: 2071 bytes --]
Hi Takashi.
[ Takashi: Adam's wonderful provider is again not accepting mail from my
wonderful provider. Could you forward? Also added alsa-devel ]
I noticed on 2.6.16-rc4 that my MPU-401 wasn't functional, due to a
simple copy & paste error in sound/isa/cs423x/cs4236.c:
Index: local/sound/isa/cs423x/cs4236.c
===================================================================
--- local.orig/sound/isa/cs423x/cs4236.c 2006-02-11
00:34:12.000000000 +0100
+++ local/sound/isa/cs423x/cs4236.c 2006-02-20 04:01:29.000000000 +0100
@@ -414,7 +414,7 @@ static int __devinit snd_card_cs423x_pnp
}
/* MPU initialization */
if (acard->mpu && mpu_port[dev] > 0) {
- if (snd_cs423x_pnp_init_mpu(dev, acard->ctrl, cfg) < 0)
+ if (snd_cs423x_pnp_init_mpu(dev, acard->mpu, cfg) < 0)
goto error;
}
kfree(cfg);
Please apply. However, when I tested it (mpu works fine again after
this) I noticed that modprobe -r snd-cs4236 didn't release things --
specifically that the fixed index=1 I have for the card failed on a
subsequent modprobe since ALSA believes that index is still taken.
I stuck a few printks in cs4236.c. From "snd_cs423x_unregister_all",
"pnp_unregister_card_driver(&cs423x_pnpc_driver)" is indeed being called
but the card driver's own remove method, snd_cs423x_pnpc_remove, is not.
I started looking, but ran into the next issue again -- when snd-cs4236
is not card1 but card0, modprobe -r oopses in snd_timer_free (attached)
meaning debugging this wants someone with more of an overview of recent
damage done^W^Wchanges made.
Given that calling pnp_unregister_card_driver() is not cs4236 specific,
I assume the problem is more general. Possibly all ALSA ISA-PnP drivers.
Or, given that pnp_unregister_card_driver is not an ALSA function, maybe
even all ISA-PnP drivers using the card_driver interface.
The more general this problem turns out, the more reason there would be
for fixing this pre 2.6.16, obviously. I can test patches...
Rene.
[-- Attachment #2: oops --]
[-- Type: text/plain, Size: 1692 bytes --]
pnp: Device 01:01.03 disabled.
pnp: Device 01:01.02 disabled.
ALSA sound/isa/cs423x/cs4231_lib.c:208: in: auto calibration time out - reg = 0x18
ALSA sound/isa/cs423x/cs4231_lib.c:187: out: auto calibration time out - reg = 0x10, value = 0x80
ALSA sound/isa/cs423x/cs4231_lib.c:149: outm: auto calibration time out - reg = 0x18, value = 0x0
pnp: Device 01:01.00 disabled.
pnp: the driver 'cs4236_isapnp' has been unregistered
ALSA sound/core/seq/seq_device.c:574: drivers not released (2)
Unable to handle kernel paging request at virtual address f09c6058
printing eip:
f09c6058
*pde = 016d6067
*pte = 00000000
Oops: 0000 [#1]
PREEMPT
Modules linked in: snd_timer snd soundcore snd_page_alloc mga amd_k7_agp drm agpgart nfsd exportfs lockd sunrpc nls_iso8859_1 nls_cp437 vfat fat nls_base
CPU: 0
EIP: 0060:[<f09c6058>] Not tainted VLI
EFLAGS: 00010282 (2.6.16-rc4-local #8)
EIP is at 0xf09c6058
eax: ec20f400 ebx: ec20f400 ecx: ec20f4e8 edx: f09c6058
esi: b7f0417c edi: 00000000 ebp: e627a000 esp: e627af54
ds: 007b es: 007b ss: 0068
Process modprobe (pid: 1359, threadinfo=e627a000 task=e8291ad0)
Stack: <0>f09b20f2 e62610e8 f09b3c20 f09b5bc0 c0126529 00000000 5f646e73 656d6974
c0130072 ffffffff e65d322c b7f14000 c0137f6c b7f13000 b7f14000 b7f14000
e65d33e4 ef12cae0 ef12cb10 ffff0001 0027a000 c0137fae 0805c3f8 b7f0417c
Call Trace:
[<f09b20f2>] snd_timer_free+0x3b/0x46 [snd_timer]
[<f09b3c20>] alsa_timer_exit+0x27/0x42 [snd_timer]
[<c0126529>] sys_delete_module+0x12b/0x155
[<c0130072>] __pdflush+0x196/0x1ac
[<c0137f6c>] do_munmap+0xe2/0xef
[<c0137fae>] sys_munmap+0x35/0x4d
[<c0102551>] syscall_call+0x7/0xb
Code: Bad EIP value.
^ permalink raw reply [flat|nested] 15+ messages in thread
* snd-cs4236 (possibly all isa-pnp cards or all alsa isa-pnp cards) broken in 2.6.16-rc4
@ 2006-02-20 17:18 Rene Herman
2006-02-21 5:27 ` Adam Belay
` (3 more replies)
0 siblings, 4 replies; 15+ messages in thread
From: Rene Herman @ 2006-02-20 17:18 UTC (permalink / raw)
To: Takashi Iwai; +Cc: Adam Belay, Andrew Morton, Linux Kernel, alsa-devel
[-- Attachment #1: Type: text/plain, Size: 2071 bytes --]
Hi Takashi.
[ Takashi: Adam's wonderful provider is again not accepting mail from my
wonderful provider. Could you forward? Also added alsa-devel ]
I noticed on 2.6.16-rc4 that my MPU-401 wasn't functional, due to a
simple copy & paste error in sound/isa/cs423x/cs4236.c:
Index: local/sound/isa/cs423x/cs4236.c
===================================================================
--- local.orig/sound/isa/cs423x/cs4236.c 2006-02-11
00:34:12.000000000 +0100
+++ local/sound/isa/cs423x/cs4236.c 2006-02-20 04:01:29.000000000 +0100
@@ -414,7 +414,7 @@ static int __devinit snd_card_cs423x_pnp
}
/* MPU initialization */
if (acard->mpu && mpu_port[dev] > 0) {
- if (snd_cs423x_pnp_init_mpu(dev, acard->ctrl, cfg) < 0)
+ if (snd_cs423x_pnp_init_mpu(dev, acard->mpu, cfg) < 0)
goto error;
}
kfree(cfg);
Please apply. However, when I tested it (mpu works fine again after
this) I noticed that modprobe -r snd-cs4236 didn't release things --
specifically that the fixed index=1 I have for the card failed on a
subsequent modprobe since ALSA believes that index is still taken.
I stuck a few printks in cs4236.c. From "snd_cs423x_unregister_all",
"pnp_unregister_card_driver(&cs423x_pnpc_driver)" is indeed being called
but the card driver's own remove method, snd_cs423x_pnpc_remove, is not.
I started looking, but ran into the next issue again -- when snd-cs4236
is not card1 but card0, modprobe -r oopses in snd_timer_free (attached)
meaning debugging this wants someone with more of an overview of recent
damage done^W^Wchanges made.
Given that calling pnp_unregister_card_driver() is not cs4236 specific,
I assume the problem is more general. Possibly all ALSA ISA-PnP drivers.
Or, given that pnp_unregister_card_driver is not an ALSA function, maybe
even all ISA-PnP drivers using the card_driver interface.
The more general this problem turns out, the more reason there would be
for fixing this pre 2.6.16, obviously. I can test patches...
Rene.
[-- Attachment #2: oops --]
[-- Type: text/plain, Size: 1692 bytes --]
pnp: Device 01:01.03 disabled.
pnp: Device 01:01.02 disabled.
ALSA sound/isa/cs423x/cs4231_lib.c:208: in: auto calibration time out - reg = 0x18
ALSA sound/isa/cs423x/cs4231_lib.c:187: out: auto calibration time out - reg = 0x10, value = 0x80
ALSA sound/isa/cs423x/cs4231_lib.c:149: outm: auto calibration time out - reg = 0x18, value = 0x0
pnp: Device 01:01.00 disabled.
pnp: the driver 'cs4236_isapnp' has been unregistered
ALSA sound/core/seq/seq_device.c:574: drivers not released (2)
Unable to handle kernel paging request at virtual address f09c6058
printing eip:
f09c6058
*pde = 016d6067
*pte = 00000000
Oops: 0000 [#1]
PREEMPT
Modules linked in: snd_timer snd soundcore snd_page_alloc mga amd_k7_agp drm agpgart nfsd exportfs lockd sunrpc nls_iso8859_1 nls_cp437 vfat fat nls_base
CPU: 0
EIP: 0060:[<f09c6058>] Not tainted VLI
EFLAGS: 00010282 (2.6.16-rc4-local #8)
EIP is at 0xf09c6058
eax: ec20f400 ebx: ec20f400 ecx: ec20f4e8 edx: f09c6058
esi: b7f0417c edi: 00000000 ebp: e627a000 esp: e627af54
ds: 007b es: 007b ss: 0068
Process modprobe (pid: 1359, threadinfo=e627a000 task=e8291ad0)
Stack: <0>f09b20f2 e62610e8 f09b3c20 f09b5bc0 c0126529 00000000 5f646e73 656d6974
c0130072 ffffffff e65d322c b7f14000 c0137f6c b7f13000 b7f14000 b7f14000
e65d33e4 ef12cae0 ef12cb10 ffff0001 0027a000 c0137fae 0805c3f8 b7f0417c
Call Trace:
[<f09b20f2>] snd_timer_free+0x3b/0x46 [snd_timer]
[<f09b3c20>] alsa_timer_exit+0x27/0x42 [snd_timer]
[<c0126529>] sys_delete_module+0x12b/0x155
[<c0130072>] __pdflush+0x196/0x1ac
[<c0137f6c>] do_munmap+0xe2/0xef
[<c0137fae>] sys_munmap+0x35/0x4d
[<c0102551>] syscall_call+0x7/0xb
Code: Bad EIP value.
^ permalink raw reply [flat|nested] 15+ messages in thread
* Re: snd-cs4236 (possibly all isa-pnp cards or all alsa isa-pnp cards) broken in 2.6.16-rc4
2006-02-20 17:18 Rene Herman
2006-02-21 5:27 ` Adam Belay
@ 2006-02-21 5:27 ` Adam Belay
2006-02-21 14:18 ` Takashi Iwai
2006-02-21 14:18 ` Takashi Iwai
3 siblings, 0 replies; 15+ messages in thread
From: Adam Belay @ 2006-02-21 5:27 UTC (permalink / raw)
To: Rene Herman; +Cc: Takashi Iwai, Andrew Morton, Linux Kernel, alsa-devel
On Mon, 2006-02-20 at 18:18 +0100, Rene Herman wrote:
> I stuck a few printks in cs4236.c. From "snd_cs423x_unregister_all",
> "pnp_unregister_card_driver(&cs423x_pnpc_driver)" is indeed being called
> but the card driver's own remove method, snd_cs423x_pnpc_remove, is not.
>
> I started looking, but ran into the next issue again -- when snd-cs4236
> is not card1 but card0, modprobe -r oopses in snd_timer_free (attached)
> meaning debugging this wants someone with more of an overview of recent
> damage done^W^Wchanges made.
>
> Given that calling pnp_unregister_card_driver() is not cs4236 specific,
> I assume the problem is more general. Possibly all ALSA ISA-PnP drivers.
> Or, given that pnp_unregister_card_driver is not an ALSA function, maybe
> even all ISA-PnP drivers using the card_driver interface.
>
> The more general this problem turns out, the more reason there would be
> for fixing this pre 2.6.16, obviously. I can test patches...
>
> Rene.
Hi Rene,
Hopefully this email account will work better. In any case, thanks for
bringing this bug to my attention. I may have stumbled across it a
couple days ago, and would appreciate if you would try this patch:
(there may be some fuzz)
--- a/drivers/pnp/card.c 2006-01-02 22:21:10.000000000 -0500
+++ b/drivers/pnp/card.c 2006-02-17 00:45:37.123525896 -0500
@@ -302,13 +302,11 @@
down_write(&dev->dev.bus->subsys.rwsem);
dev->card_link = clink;
dev->dev.driver = &drv->link.driver;
- if (drv->link.driver.probe) {
- if (drv->link.driver.probe(&dev->dev)) {
- dev->dev.driver = NULL;
- dev->card_link = NULL;
- up_write(&dev->dev.bus->subsys.rwsem);
- return NULL;
- }
+ if (pnp_bus_type.probe(&dev->dev)) {
+ dev->dev.driver = NULL;
+ dev->card_link = NULL;
+ up_write(&dev->dev.bus->subsys.rwsem);
+ return NULL;
}
device_bind_driver(&dev->dev);
up_write(&dev->dev.bus->subsys.rwsem);
It's possible that the attach mechanism isn't working correctly because
of recent driver model changes. If this is the case, it would also
explain the detach-not-called issues.
Thanks,
Adam
-------------------------------------------------------
This SF.net email is sponsored by: Splunk Inc. Do you grep through log files
for problems? Stop! Download the new AJAX search engine that makes
searching your log files as easy as surfing the web. DOWNLOAD SPLUNK!
http://sel.as-us.falkag.net/sel?cmd=lnk&kid=103432&bid=230486&dat=121642
^ permalink raw reply [flat|nested] 15+ messages in thread
* Re: snd-cs4236 (possibly all isa-pnp cards or all alsa isa-pnp cards) broken in 2.6.16-rc4
2006-02-20 17:18 Rene Herman
@ 2006-02-21 5:27 ` Adam Belay
2006-02-21 15:37 ` Rene Herman
2006-02-21 15:37 ` Rene Herman
2006-02-21 5:27 ` Adam Belay
` (2 subsequent siblings)
3 siblings, 2 replies; 15+ messages in thread
From: Adam Belay @ 2006-02-21 5:27 UTC (permalink / raw)
To: Rene Herman; +Cc: Takashi Iwai, Andrew Morton, Linux Kernel, alsa-devel
On Mon, 2006-02-20 at 18:18 +0100, Rene Herman wrote:
> I stuck a few printks in cs4236.c. From "snd_cs423x_unregister_all",
> "pnp_unregister_card_driver(&cs423x_pnpc_driver)" is indeed being called
> but the card driver's own remove method, snd_cs423x_pnpc_remove, is not.
>
> I started looking, but ran into the next issue again -- when snd-cs4236
> is not card1 but card0, modprobe -r oopses in snd_timer_free (attached)
> meaning debugging this wants someone with more of an overview of recent
> damage done^W^Wchanges made.
>
> Given that calling pnp_unregister_card_driver() is not cs4236 specific,
> I assume the problem is more general. Possibly all ALSA ISA-PnP drivers.
> Or, given that pnp_unregister_card_driver is not an ALSA function, maybe
> even all ISA-PnP drivers using the card_driver interface.
>
> The more general this problem turns out, the more reason there would be
> for fixing this pre 2.6.16, obviously. I can test patches...
>
> Rene.
Hi Rene,
Hopefully this email account will work better. In any case, thanks for
bringing this bug to my attention. I may have stumbled across it a
couple days ago, and would appreciate if you would try this patch:
(there may be some fuzz)
--- a/drivers/pnp/card.c 2006-01-02 22:21:10.000000000 -0500
+++ b/drivers/pnp/card.c 2006-02-17 00:45:37.123525896 -0500
@@ -302,13 +302,11 @@
down_write(&dev->dev.bus->subsys.rwsem);
dev->card_link = clink;
dev->dev.driver = &drv->link.driver;
- if (drv->link.driver.probe) {
- if (drv->link.driver.probe(&dev->dev)) {
- dev->dev.driver = NULL;
- dev->card_link = NULL;
- up_write(&dev->dev.bus->subsys.rwsem);
- return NULL;
- }
+ if (pnp_bus_type.probe(&dev->dev)) {
+ dev->dev.driver = NULL;
+ dev->card_link = NULL;
+ up_write(&dev->dev.bus->subsys.rwsem);
+ return NULL;
}
device_bind_driver(&dev->dev);
up_write(&dev->dev.bus->subsys.rwsem);
It's possible that the attach mechanism isn't working correctly because
of recent driver model changes. If this is the case, it would also
explain the detach-not-called issues.
Thanks,
Adam
^ permalink raw reply [flat|nested] 15+ messages in thread
* Re: snd-cs4236 (possibly all isa-pnp cards or all alsa isa-pnp cards) broken in 2.6.16-rc4
2006-02-20 17:18 Rene Herman
2006-02-21 5:27 ` Adam Belay
2006-02-21 5:27 ` Adam Belay
@ 2006-02-21 14:18 ` Takashi Iwai
2006-02-21 14:18 ` Takashi Iwai
3 siblings, 0 replies; 15+ messages in thread
From: Takashi Iwai @ 2006-02-21 14:18 UTC (permalink / raw)
To: Rene Herman; +Cc: Adam Belay, Andrew Morton, Linux Kernel, alsa-devel
At Mon, 20 Feb 2006 18:18:42 +0100,
Rene Herman wrote:
>
> I noticed on 2.6.16-rc4 that my MPU-401 wasn't functional, due to a
> simple copy & paste error in sound/isa/cs423x/cs4236.c:
Thanks, I applied it to ALSA CVS tree, too.
Takashi
-------------------------------------------------------
This SF.net email is sponsored by: Splunk Inc. Do you grep through log files
for problems? Stop! Download the new AJAX search engine that makes
searching your log files as easy as surfing the web. DOWNLOAD SPLUNK!
http://sel.as-us.falkag.net/sel?cmd=lnk&kid=103432&bid=230486&dat=121642
^ permalink raw reply [flat|nested] 15+ messages in thread
* Re: snd-cs4236 (possibly all isa-pnp cards or all alsa isa-pnp cards) broken in 2.6.16-rc4
2006-02-20 17:18 Rene Herman
` (2 preceding siblings ...)
2006-02-21 14:18 ` Takashi Iwai
@ 2006-02-21 14:18 ` Takashi Iwai
2006-02-21 15:51 ` Rene Herman
2006-02-21 15:51 ` Rene Herman
3 siblings, 2 replies; 15+ messages in thread
From: Takashi Iwai @ 2006-02-21 14:18 UTC (permalink / raw)
To: Rene Herman; +Cc: Adam Belay, Andrew Morton, Linux Kernel, alsa-devel
At Mon, 20 Feb 2006 18:18:42 +0100,
Rene Herman wrote:
>
> I noticed on 2.6.16-rc4 that my MPU-401 wasn't functional, due to a
> simple copy & paste error in sound/isa/cs423x/cs4236.c:
Thanks, I applied it to ALSA CVS tree, too.
Takashi
^ permalink raw reply [flat|nested] 15+ messages in thread
* Re: snd-cs4236 (possibly all isa-pnp cards or all alsa isa-pnp cards) broken in 2.6.16-rc4
2006-02-21 5:27 ` Adam Belay
2006-02-21 15:37 ` Rene Herman
@ 2006-02-21 15:37 ` Rene Herman
1 sibling, 0 replies; 15+ messages in thread
From: Rene Herman @ 2006-02-21 15:37 UTC (permalink / raw)
To: Adam Belay; +Cc: Takashi Iwai, Andrew Morton, Linux Kernel, alsa-devel
[-- Attachment #1: Type: text/plain, Size: 939 bytes --]
Adam Belay wrote:
[ pnp_card_driver.remove() not called ]
> Hopefully this email account will work better. In any case, thanks
> for bringing this bug to my attention. I may have stumbled across it
> a couple days ago, and would appreciate if you would try this patch:
> (there may be some fuzz)
Reject even. I've attached this patch regenerated against 2.6.16-rc4.
> - if (drv->link.driver.probe) {
> - if (drv->link.driver.probe(&dev->dev)) {
> + if (pnp_bus_type.probe(&dev->dev)) {
Yes, this works, thanks. If it's also the correct fix, I guess this
should go into 2.6.16?
I by the way also tested with a driver that uses pnp_driver instead of
pnp_card_driver, and that also works.
> It's possible that the attach mechanism isn't working correctly
> because of recent driver model changes. If this is the case, it
> would also explain the detach-not-called issues.
The bustype stuff...
Rene.
[-- Attachment #2: pnp_bus_type_adam.diff --]
[-- Type: text/plain, Size: 796 bytes --]
Index: local/drivers/pnp/card.c
===================================================================
--- local.orig/drivers/pnp/card.c 2006-02-11 00:34:01.000000000 +0100
+++ local/drivers/pnp/card.c 2006-02-21 14:06:21.000000000 +0100
@@ -303,13 +303,11 @@ found:
down_write(&dev->dev.bus->subsys.rwsem);
dev->card_link = clink;
dev->dev.driver = &drv->link.driver;
- if (drv->link.driver.probe) {
- if (drv->link.driver.probe(&dev->dev)) {
- dev->dev.driver = NULL;
- dev->card_link = NULL;
- up_write(&dev->dev.bus->subsys.rwsem);
- return NULL;
- }
+ if (pnp_bus_type.probe(&dev->dev)) {
+ dev->dev.driver = NULL;
+ dev->card_link = NULL;
+ up_write(&dev->dev.bus->subsys.rwsem);
+ return NULL;
}
device_bind_driver(&dev->dev);
up_write(&dev->dev.bus->subsys.rwsem);
^ permalink raw reply [flat|nested] 15+ messages in thread
* Re: snd-cs4236 (possibly all isa-pnp cards or all alsa isa-pnp cards) broken in 2.6.16-rc4
2006-02-21 5:27 ` Adam Belay
@ 2006-02-21 15:37 ` Rene Herman
2006-02-21 15:37 ` Rene Herman
1 sibling, 0 replies; 15+ messages in thread
From: Rene Herman @ 2006-02-21 15:37 UTC (permalink / raw)
To: Adam Belay; +Cc: Takashi Iwai, Andrew Morton, Linux Kernel, alsa-devel
[-- Attachment #1: Type: text/plain, Size: 939 bytes --]
Adam Belay wrote:
[ pnp_card_driver.remove() not called ]
> Hopefully this email account will work better. In any case, thanks
> for bringing this bug to my attention. I may have stumbled across it
> a couple days ago, and would appreciate if you would try this patch:
> (there may be some fuzz)
Reject even. I've attached this patch regenerated against 2.6.16-rc4.
> - if (drv->link.driver.probe) {
> - if (drv->link.driver.probe(&dev->dev)) {
> + if (pnp_bus_type.probe(&dev->dev)) {
Yes, this works, thanks. If it's also the correct fix, I guess this
should go into 2.6.16?
I by the way also tested with a driver that uses pnp_driver instead of
pnp_card_driver, and that also works.
> It's possible that the attach mechanism isn't working correctly
> because of recent driver model changes. If this is the case, it
> would also explain the detach-not-called issues.
The bustype stuff...
Rene.
[-- Attachment #2: pnp_bus_type_adam.diff --]
[-- Type: text/plain, Size: 796 bytes --]
Index: local/drivers/pnp/card.c
===================================================================
--- local.orig/drivers/pnp/card.c 2006-02-11 00:34:01.000000000 +0100
+++ local/drivers/pnp/card.c 2006-02-21 14:06:21.000000000 +0100
@@ -303,13 +303,11 @@ found:
down_write(&dev->dev.bus->subsys.rwsem);
dev->card_link = clink;
dev->dev.driver = &drv->link.driver;
- if (drv->link.driver.probe) {
- if (drv->link.driver.probe(&dev->dev)) {
- dev->dev.driver = NULL;
- dev->card_link = NULL;
- up_write(&dev->dev.bus->subsys.rwsem);
- return NULL;
- }
+ if (pnp_bus_type.probe(&dev->dev)) {
+ dev->dev.driver = NULL;
+ dev->card_link = NULL;
+ up_write(&dev->dev.bus->subsys.rwsem);
+ return NULL;
}
device_bind_driver(&dev->dev);
up_write(&dev->dev.bus->subsys.rwsem);
^ permalink raw reply [flat|nested] 15+ messages in thread
* Re: snd-cs4236 (possibly all isa-pnp cards or all alsa isa-pnp cards) broken in 2.6.16-rc4
2006-02-21 14:18 ` Takashi Iwai
@ 2006-02-21 15:51 ` Rene Herman
2006-02-21 15:51 ` Rene Herman
1 sibling, 0 replies; 15+ messages in thread
From: Rene Herman @ 2006-02-21 15:51 UTC (permalink / raw)
To: Takashi Iwai; +Cc: Adam Belay, Andrew Morton, Linux Kernel, alsa-devel
Takashi Iwai wrote:
> Rene Herman wrote:
>> I noticed on 2.6.16-rc4 that my MPU-401 wasn't functional, due to a
>> simple copy & paste error in sound/isa/cs423x/cs4236.c:
>
> Thanks, I applied it to ALSA CVS tree, too.
The patch Adam sent fixes the ".remove not called" issue. It _also_
fixes the OOPS in snd_timer_free() I sent along, so that one wasn't
independent. During testing, I uncovered one more bug though.
After using aplaymidi (to test cs4236 mpu401), which pulls in
snd-seq-oss, modprobe -r snd-cs4236 tells me:
"ALSA sound/core/device.c:106: device free eee4e000 (from f099153d), not
found"
That then stays until reboot, with a different device address each time.
f099153d is snd_opl3_free_seq_oss() here. For now I've stuck a
dump_stack() in there, which treats me to:
===
[<f099152e>] snd_opl3_free_seq_oss+0x8/0x20 [snd_opl3_synth]
[<f099044f>] snd_opl3_seq_delete_device+0x17/0x3c [snd_opl3_synth]
[<f08f06ec>] free_device+0x4b/0x8e [snd_seq_device]
[<f08f02da>] snd_seq_device_free+0x88/0xa9 [snd_seq_device]
[<f09579a2>] snd_device_free+0x8b/0xf0 [snd]
[<f0957ccd>] snd_device_free_all+0x67/0x7a [snd]
[<f0953d01>] snd_card_free+0x111/0x1f3 [snd]
[<c0134464>] zap_pte_range+0x1cf/0x1ec
[<c026a76e>] wait_for_completion+0xc4/0xdf
[<c010ea9b>] complete+0x2e/0x5c
[<c010eaa9>] complete+0x3c/0x5c
[<f096b7f9>] snd_cs423x_pnpc_remove+0xb/0x14 [snd_cs4236]
[<c01c148b>] card_remove_first+0x2f/0x4a
[<c01c1e3d>] pnp_device_remove+0x18/0x2d
[<c01e149d>] __device_release_driver+0x53/0x6b
[<c01e156a>] driver_detach+0x91/0xbf
[<c01e0fac>] bus_remove_driver+0x27/0x41
[<c01e181b>] driver_unregister+0xb/0x13
[<c01c1f46>] pnp_unregister_driver+0xb/0x1b
[<f096b826>] snd_cs423x_unregister_all+0x14/0x36 [snd_cs4236]
[<c0126529>] sys_delete_module+0x12b/0x155
[<c0137f6c>] do_munmap+0xe2/0xef
[<c0137fae>] sys_munmap+0x35/0x4d
[<c0102551>] syscall_call+0x7/0xb
ALSA sound/core/device.c:106: device free eee4e000 (from f099153d), not
found
pnp: Device 01:01.03 disabled.
pnp: Device 01:01.02 disabled.
pnp: Device 01:01.00 disabled.
pnp: the driver 'cs4236_isapnp' has been unregistered
===
I'll try and see if I can find anything later, but if you could, please
beat me to it. I'm not even quite sure what that oss sequencer thing is...
Rene.
-------------------------------------------------------
This SF.net email is sponsored by: Splunk Inc. Do you grep through log files
for problems? Stop! Download the new AJAX search engine that makes
searching your log files as easy as surfing the web. DOWNLOAD SPLUNK!
http://sel.as-us.falkag.net/sel?cmd=lnk&kid=103432&bid=230486&dat=121642
^ permalink raw reply [flat|nested] 15+ messages in thread
* Re: snd-cs4236 (possibly all isa-pnp cards or all alsa isa-pnp cards) broken in 2.6.16-rc4
2006-02-21 14:18 ` Takashi Iwai
2006-02-21 15:51 ` Rene Herman
@ 2006-02-21 15:51 ` Rene Herman
2006-02-21 17:43 ` Takashi Iwai
2006-02-21 17:43 ` Takashi Iwai
1 sibling, 2 replies; 15+ messages in thread
From: Rene Herman @ 2006-02-21 15:51 UTC (permalink / raw)
To: Takashi Iwai; +Cc: Adam Belay, Andrew Morton, Linux Kernel, alsa-devel
Takashi Iwai wrote:
> Rene Herman wrote:
>> I noticed on 2.6.16-rc4 that my MPU-401 wasn't functional, due to a
>> simple copy & paste error in sound/isa/cs423x/cs4236.c:
>
> Thanks, I applied it to ALSA CVS tree, too.
The patch Adam sent fixes the ".remove not called" issue. It _also_
fixes the OOPS in snd_timer_free() I sent along, so that one wasn't
independent. During testing, I uncovered one more bug though.
After using aplaymidi (to test cs4236 mpu401), which pulls in
snd-seq-oss, modprobe -r snd-cs4236 tells me:
"ALSA sound/core/device.c:106: device free eee4e000 (from f099153d), not
found"
That then stays until reboot, with a different device address each time.
f099153d is snd_opl3_free_seq_oss() here. For now I've stuck a
dump_stack() in there, which treats me to:
===
[<f099152e>] snd_opl3_free_seq_oss+0x8/0x20 [snd_opl3_synth]
[<f099044f>] snd_opl3_seq_delete_device+0x17/0x3c [snd_opl3_synth]
[<f08f06ec>] free_device+0x4b/0x8e [snd_seq_device]
[<f08f02da>] snd_seq_device_free+0x88/0xa9 [snd_seq_device]
[<f09579a2>] snd_device_free+0x8b/0xf0 [snd]
[<f0957ccd>] snd_device_free_all+0x67/0x7a [snd]
[<f0953d01>] snd_card_free+0x111/0x1f3 [snd]
[<c0134464>] zap_pte_range+0x1cf/0x1ec
[<c026a76e>] wait_for_completion+0xc4/0xdf
[<c010ea9b>] complete+0x2e/0x5c
[<c010eaa9>] complete+0x3c/0x5c
[<f096b7f9>] snd_cs423x_pnpc_remove+0xb/0x14 [snd_cs4236]
[<c01c148b>] card_remove_first+0x2f/0x4a
[<c01c1e3d>] pnp_device_remove+0x18/0x2d
[<c01e149d>] __device_release_driver+0x53/0x6b
[<c01e156a>] driver_detach+0x91/0xbf
[<c01e0fac>] bus_remove_driver+0x27/0x41
[<c01e181b>] driver_unregister+0xb/0x13
[<c01c1f46>] pnp_unregister_driver+0xb/0x1b
[<f096b826>] snd_cs423x_unregister_all+0x14/0x36 [snd_cs4236]
[<c0126529>] sys_delete_module+0x12b/0x155
[<c0137f6c>] do_munmap+0xe2/0xef
[<c0137fae>] sys_munmap+0x35/0x4d
[<c0102551>] syscall_call+0x7/0xb
ALSA sound/core/device.c:106: device free eee4e000 (from f099153d), not
found
pnp: Device 01:01.03 disabled.
pnp: Device 01:01.02 disabled.
pnp: Device 01:01.00 disabled.
pnp: the driver 'cs4236_isapnp' has been unregistered
===
I'll try and see if I can find anything later, but if you could, please
beat me to it. I'm not even quite sure what that oss sequencer thing is...
Rene.
^ permalink raw reply [flat|nested] 15+ messages in thread
* Re: snd-cs4236 (possibly all isa-pnp cards or all alsa isa-pnp cards) broken in 2.6.16-rc4
2006-02-21 15:51 ` Rene Herman
2006-02-21 17:43 ` Takashi Iwai
@ 2006-02-21 17:43 ` Takashi Iwai
1 sibling, 0 replies; 15+ messages in thread
From: Takashi Iwai @ 2006-02-21 17:43 UTC (permalink / raw)
To: Rene Herman; +Cc: Adam Belay, Andrew Morton, Linux Kernel, alsa-devel
At Tue, 21 Feb 2006 16:51:52 +0100,
Rene Herman wrote:
>
> Takashi Iwai wrote:
>
> > Rene Herman wrote:
>
> >> I noticed on 2.6.16-rc4 that my MPU-401 wasn't functional, due to a
> >> simple copy & paste error in sound/isa/cs423x/cs4236.c:
> >
> > Thanks, I applied it to ALSA CVS tree, too.
>
> The patch Adam sent fixes the ".remove not called" issue. It _also_
> fixes the OOPS in snd_timer_free() I sent along, so that one wasn't
> independent. During testing, I uncovered one more bug though.
>
> After using aplaymidi (to test cs4236 mpu401), which pulls in
> snd-seq-oss, modprobe -r snd-cs4236 tells me:
>
> "ALSA sound/core/device.c:106: device free eee4e000 (from f099153d), not
> found"
>
> That then stays until reboot, with a different device address each time.
This is harmless. The opl3-oss instance was already freed but the
driver tries to release it again just to be sure.
The patch below should fix this annoyance.
Takashi
===
[PATCH] Fix bogus snd_device_free() in opl3-oss.c
Remove snd_device_free() for an opl3-oss instance which should have
been released.
Signed-off-by: Takashi Iwai <tiwai@suse.de>
---
diff -u -r1.14 opl3_oss.c
--- linux/sound/drivers/opl3/opl3_oss.c 17 Nov 2005 14:11:29 -0000 1.14
+++ linux/sound/drivers/opl3/opl3_oss.c 21 Feb 2006 17:38:41 -0000
@@ -146,7 +146,7 @@
void snd_opl3_free_seq_oss(struct snd_opl3 *opl3)
{
if (opl3->oss_seq_dev) {
- snd_device_free(opl3->card, opl3->oss_seq_dev);
+ /* The instance should have been released in prior */
opl3->oss_seq_dev = NULL;
}
}
-------------------------------------------------------
This SF.net email is sponsored by: Splunk Inc. Do you grep through log files
for problems? Stop! Download the new AJAX search engine that makes
searching your log files as easy as surfing the web. DOWNLOAD SPLUNK!
http://sel.as-us.falkag.net/sel?cmd=lnk&kid=103432&bid=230486&dat=121642
^ permalink raw reply [flat|nested] 15+ messages in thread
* Re: snd-cs4236 (possibly all isa-pnp cards or all alsa isa-pnp cards) broken in 2.6.16-rc4
2006-02-21 15:51 ` Rene Herman
@ 2006-02-21 17:43 ` Takashi Iwai
2006-02-21 19:35 ` Rene Herman
2006-02-21 19:35 ` Rene Herman
2006-02-21 17:43 ` Takashi Iwai
1 sibling, 2 replies; 15+ messages in thread
From: Takashi Iwai @ 2006-02-21 17:43 UTC (permalink / raw)
To: Rene Herman; +Cc: Adam Belay, Andrew Morton, Linux Kernel, alsa-devel
At Tue, 21 Feb 2006 16:51:52 +0100,
Rene Herman wrote:
>
> Takashi Iwai wrote:
>
> > Rene Herman wrote:
>
> >> I noticed on 2.6.16-rc4 that my MPU-401 wasn't functional, due to a
> >> simple copy & paste error in sound/isa/cs423x/cs4236.c:
> >
> > Thanks, I applied it to ALSA CVS tree, too.
>
> The patch Adam sent fixes the ".remove not called" issue. It _also_
> fixes the OOPS in snd_timer_free() I sent along, so that one wasn't
> independent. During testing, I uncovered one more bug though.
>
> After using aplaymidi (to test cs4236 mpu401), which pulls in
> snd-seq-oss, modprobe -r snd-cs4236 tells me:
>
> "ALSA sound/core/device.c:106: device free eee4e000 (from f099153d), not
> found"
>
> That then stays until reboot, with a different device address each time.
This is harmless. The opl3-oss instance was already freed but the
driver tries to release it again just to be sure.
The patch below should fix this annoyance.
Takashi
===
[PATCH] Fix bogus snd_device_free() in opl3-oss.c
Remove snd_device_free() for an opl3-oss instance which should have
been released.
Signed-off-by: Takashi Iwai <tiwai@suse.de>
---
diff -u -r1.14 opl3_oss.c
--- linux/sound/drivers/opl3/opl3_oss.c 17 Nov 2005 14:11:29 -0000 1.14
+++ linux/sound/drivers/opl3/opl3_oss.c 21 Feb 2006 17:38:41 -0000
@@ -146,7 +146,7 @@
void snd_opl3_free_seq_oss(struct snd_opl3 *opl3)
{
if (opl3->oss_seq_dev) {
- snd_device_free(opl3->card, opl3->oss_seq_dev);
+ /* The instance should have been released in prior */
opl3->oss_seq_dev = NULL;
}
}
^ permalink raw reply [flat|nested] 15+ messages in thread
* Re: snd-cs4236 (possibly all isa-pnp cards or all alsa isa-pnp cards) broken in 2.6.16-rc4
2006-02-21 17:43 ` Takashi Iwai
@ 2006-02-21 19:35 ` Rene Herman
2006-02-21 19:35 ` Rene Herman
1 sibling, 0 replies; 15+ messages in thread
From: Rene Herman @ 2006-02-21 19:35 UTC (permalink / raw)
To: Takashi Iwai; +Cc: Adam Belay, Andrew Morton, Linux Kernel, alsa-devel
Takashi Iwai wrote:
> Rene Herman wrote:
>> "ALSA sound/core/device.c:106: device free eee4e000 (from f099153d), not
>> found"
> This is harmless. The opl3-oss instance was already freed but the
> driver tries to release it again just to be sure.
>
> The patch below should fix this annoyance.
Ah, good. Yes, it ofcourse does. Thanks. So, only the isapnp/bustype one
was in fact a problem, it seems...
Rene.
-------------------------------------------------------
This SF.net email is sponsored by: Splunk Inc. Do you grep through log files
for problems? Stop! Download the new AJAX search engine that makes
searching your log files as easy as surfing the web. DOWNLOAD SPLUNK!
http://sel.as-us.falkag.net/sel?cmd=lnk&kid=103432&bid=230486&dat=121642
^ permalink raw reply [flat|nested] 15+ messages in thread
* Re: snd-cs4236 (possibly all isa-pnp cards or all alsa isa-pnp cards) broken in 2.6.16-rc4
2006-02-21 17:43 ` Takashi Iwai
2006-02-21 19:35 ` Rene Herman
@ 2006-02-21 19:35 ` Rene Herman
1 sibling, 0 replies; 15+ messages in thread
From: Rene Herman @ 2006-02-21 19:35 UTC (permalink / raw)
To: Takashi Iwai; +Cc: Adam Belay, Andrew Morton, Linux Kernel, alsa-devel
Takashi Iwai wrote:
> Rene Herman wrote:
>> "ALSA sound/core/device.c:106: device free eee4e000 (from f099153d), not
>> found"
> This is harmless. The opl3-oss instance was already freed but the
> driver tries to release it again just to be sure.
>
> The patch below should fix this annoyance.
Ah, good. Yes, it ofcourse does. Thanks. So, only the isapnp/bustype one
was in fact a problem, it seems...
Rene.
^ permalink raw reply [flat|nested] 15+ messages in thread
end of thread, other threads:[~2006-02-21 19:35 UTC | newest]
Thread overview: 15+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2006-02-20 16:54 snd-cs4236 (possibly all isa-pnp cards or all alsa isa-pnp cards) broken in 2.6.16-rc4 Rene Herman
-- strict thread matches above, loose matches on Subject: below --
2006-02-20 17:18 Rene Herman
2006-02-20 17:18 Rene Herman
2006-02-21 5:27 ` Adam Belay
2006-02-21 15:37 ` Rene Herman
2006-02-21 15:37 ` Rene Herman
2006-02-21 5:27 ` Adam Belay
2006-02-21 14:18 ` Takashi Iwai
2006-02-21 14:18 ` Takashi Iwai
2006-02-21 15:51 ` Rene Herman
2006-02-21 15:51 ` Rene Herman
2006-02-21 17:43 ` Takashi Iwai
2006-02-21 19:35 ` Rene Herman
2006-02-21 19:35 ` Rene Herman
2006-02-21 17:43 ` Takashi Iwai
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.