<font size=2 face="sans-serif">Hi,</font>
<br><font size=2 face="sans-serif">we are using an AmbiCom CF card for
WLAN on an MX1 powered board with Kernel 2.6.36.3.</font>
<br>
<br><font size=2 face="sans-serif">In our PCMCIA driver we power down the
CF card 2 seconds after the eject request if the card is still powered
on.</font>
<br><font size=2 face="sans-serif">In this case we get an kernel panic.
We don't have the option to wait any longer for power down.</font>
<br><font size=2 face="sans-serif">Can someone tell me, why the driver
is still sending commands after we stopped the card?</font>
<br>
<br><font size=2 face="sans-serif">Here is the log of the kernel panic:</font>
<br><font size=2 face="sans-serif"> </font>
<br><font size=2 face="sans-serif">pcmcia_socket pcmcia_socket0: pccard:
PCMCIA card inserted into slot 0</font>
<br><font size=2 face="sans-serif">pcmcia 0.0: pcmcia: registering new
device pcmcia0.0 (IRQ: 82)</font>
<br><font size=2 face="sans-serif">libertas: 00:10:7a:74:39:b0, fw 5.0.16p0,
cap 0x00000393</font>
<br><font size=2 face="sans-serif">lbs_update_hw_spec: regioncode: 1040</font>
<br><font size=2 face="sans-serif">lbs_cfg_set_regulatory_hint: regioncode:
40</font>
<br><font size=2 face="sans-serif">cfg80211: Calling CRDA for country:
JP</font>
<br><font size=2 face="sans-serif">libertas: wlan0: Marvell WLAN 802.11
adapter</font>
<br><font size=2 face="sans-serif">pcmcia_socket pcmcia_socket0: pccard:
card ejected from slot 0</font>
<br><font size=2 face="sans-serif">libertas: PREP_CMD: command 0x0006 failed:
-2</font>
<br><font size=2 face="sans-serif">------------[ cut here ]------------</font>
<br><font size=2 face="sans-serif">WARNING: at net/wireless/core.c:638
wdev_cleanup_work+0x5c/0xf8()</font>
<br><font size=2 face="sans-serif">Modules linked in:</font>
<br><font size=2 face="sans-serif">Backtrace:</font>
<br><font size=2 face="sans-serif">[<c0025304>] (dump_backtrace+0x0/0x10c)
from [<c0271bb0>] (dump_stack+0x18/0x1c)</font>
<br><font size=2 face="sans-serif"> r7:00000000 r6:c02549d4 r5:c0307a19
r4:0000027e</font>
<br><font size=2 face="sans-serif">[<c0271b98>] (dump_stack+0x0/0x1c)
from [<c0032b68>] (warn_slowpath_common+0x54/0x6c)</font>
<br><font size=2 face="sans-serif">[<c0032b14>] (warn_slowpath_common+0x0/0x6c)
from [<c0032ba4>] (warn_slowpath_null+0x24/0x2c)</font>
<br><font size=2 face="sans-serif"> r8:c1847e00 r7:c194e628 r6:c198c0c0
r5:c198c000 r4:c198c00c</font>
<br><font size=2 face="sans-serif">[<c0032b80>] (warn_slowpath_null+0x0/0x2c)
from [<c02549d4>] (wdev_cleanup_work+0x5c/0xf8)</font>
<br><font size=2 face="sans-serif">[<c0254978>] (wdev_cleanup_work+0x0/0xf8)
from [<c0044414>] (process_one_work+0x250/0x3ac)</font>
<br><font size=2 face="sans-serif"> r7:0000001a r6:0000001b r5:c1802240
r4:c194e628</font>
<br><font size=2 face="sans-serif">[<c00441c4>] (process_one_work+0x0/0x3ac)
from [<c00450b8>] (worker_thread+0x210/0x424)</font>
<br><font size=2 face="sans-serif">[<c0044ea8>] (worker_thread+0x0/0x424)
from [<c0049a08>] (kthread+0x88/0x90)</font>
<br><font size=2 face="sans-serif">[<c0049980>] (kthread+0x0/0x90)
from [<c0035f1c>] (do_exit+0x0/0x5a0)</font>
<br><font size=2 face="sans-serif"> r7:00000013 r6:c0035f1c r5:c0049980
r4:c181bf04</font>
<br><font size=2 face="sans-serif">---[ end trace 657895c8dce08edd ]---</font>
<br><font size=2 face="sans-serif">libertas: Received CMD_RESP with invalid
sequence 9 (expected 0)</font>
<br><font size=2 face="sans-serif">Error while ejecting - force power off</font>
<br><font size=2 face="sans-serif">libertas_cs: card data buffer has invalid
# of bytes (0)</font>
<br><font size=2 face="sans-serif">Unhandled fault: external abort on non-linefetch
(0x80a) at 0xc287e000</font>
<br><font size=2 face="sans-serif">Internal error: : 80a [#1]</font>
<br><font size=2 face="sans-serif">last sysfs file: /sys/devices/platform/mx1_hbp_cf/cf_on</font>
<br><font size=2 face="sans-serif">Modules linked in:</font>
<br><font size=2 face="sans-serif">CPU: 0 Tainted: G
W (2.6.36.3 #59)</font>
<br><font size=2 face="sans-serif">PC is at if_cs_interrupt+0x22c/0x624</font>
<br><font size=2 face="sans-serif">LR is at release_console_sem+0x1b0/0x214</font>
<br><font size=2 face="sans-serif">pc : [<c01b26f4>] lr
: [<c0033518>] psr: 60000093</font>
<br><font size=2 face="sans-serif">sp : c19bfdb4 ip : c19bfcf4 fp
: c19bfde8</font>
<br><font size=2 face="sans-serif">r10: 00000552 r9 : c19783a0 r8
: c198c220</font>
<br><font size=2 face="sans-serif">r7 : 00000000 r6 : 00000000 r5
: 00000000 r4 : c1989280</font>
<br><font size=2 face="sans-serif">r3 : c287e000 r2 : 00000002 r1
: 00001e58 r0 : 0000003f</font>
<br><font size=2 face="sans-serif">Flags: nZCv IRQs off FIQs
on Mode SVC_32 ISA ARM Segment user</font>
<br><font size=2 face="sans-serif">Control: c000717f Table: 099c4000
DAC: 00000015</font>
<br><font size=2 face="sans-serif">Process sh (pid: 323, stack limit =
0xc19be270)</font>
<br><font size=2 face="sans-serif">Stack: (0xc19bfdb4 to 0xc19c0000)</font>
<br><font size=2 face="sans-serif">fda0:
ffffe1e4 c19bfde4 c19bfdc8</font>
<br><font size=2 face="sans-serif">fdc0: c1989280 00000000 00000000 00000052
00000040 c1989418 c19bff78 c19bfe08</font>
<br><font size=2 face="sans-serif">fde0: c19bfdec c005ef90 c01b24d8 c0329acc
00000052 c0324ef8 00040000 c19bfe20</font>
<br><font size=2 face="sans-serif">fe00: c19bfe0c c0060d30 c005ef74 00000052
00040000 c19bfe48 c19bfe24 c002c468</font>
<br><font size=2 face="sans-serif">fe20: c0060ca4 c03264a0 0000000b 00000000
000b0000 c0324d68 c0286d24 c19bfe60</font>
<br><font size=2 face="sans-serif">fe40: c19bfe4c c0021078 c002c368 ffffffff
f4023000 c19bfebc c19bfe64 c0021aac</font>
<br><font size=2 face="sans-serif">fe60: c0021010 00000001 0000001e 00000001
54400000 60000013 0000007e 00000001</font>
<br><font size=2 face="sans-serif">fe80: c0324d68 c0286d24 c1989418 c19bff78
c19bfebc f401c300 c19bfeac c0149908</font>
<br><font size=2 face="sans-serif">fea0: c002c144 60000013 ffffffff c032501c
c19bfedc c19bfec0 c0149908 c002c120</font>
<br><font size=2 face="sans-serif">fec0: c19bff04 00000014 c190a400 00000002
c19bff04 c19bfee0 c01bb974 c01498cc</font>
<br><font size=2 face="sans-serif">fee0: c1989418 00000000 c19bff04 c194c960
00000002 c1989400 c19bff14 c19bff08</font>
<br><font size=2 face="sans-serif">ff00: c0164620 c01bb8a4 c19bff44 c19bff18
c00c9aa4 c0164608 c0035cf0 c191ec00</font>
<br><font size=2 face="sans-serif">ff20: 00000002 401c47b4 c19bff78 c0021fc4
c19be000 00000000 c19bff74 c19bff48</font>
<br><font size=2 face="sans-serif">ff40: c0087b94 c00c99a4 c0035dcc c0046834
00000003 00000000 00000000 c191ec00</font>
<br><font size=2 face="sans-serif">ff60: 00000004 c0021fc4 c19bffa4 c19bff78
c0087ce8 c0087aec 00000000 00000000</font>
<br><font size=2 face="sans-serif">ff80: c0093e30 00000000 00000002 401c12f4
00000002 401c47b4 00000000 c19bffa8</font>
<br><font size=2 face="sans-serif">ffa0: c0021e40 c0087cac 401c12f4 00000002
00000001 401c47b4 00000002 401c47b6</font>
<br><font size=2 face="sans-serif">ffc0: 401c12f4 00000002 401c47b4 00000004
00000001 00081008 00000000 00081284</font>
<br><font size=2 face="sans-serif">ffe0: 0007ea0c bea1f6a8 4018fc44 4017efdc
20000010 00000001 00000000 00000000</font>
<br><font size=2 face="sans-serif">Backtrace:</font>
<br><font size=2 face="sans-serif">[<c01b24c8>] (if_cs_interrupt+0x0/0x624)
from [<c005ef90>] (handle_IRQ_event+0x2c/0xf8)</font>
<br><font size=2 face="sans-serif">[<c005ef64>] (handle_IRQ_event+0x0/0xf8)
from [<c0060d30>] (handle_level_irq+0x9c/0x108)</font>
<br><font size=2 face="sans-serif"> r7:00040000 r6:c0324ef8 r5:00000052
r4:c0329acc</font>
<br><font size=2 face="sans-serif">[<c0060c94>] (handle_level_irq+0x0/0x108)
from [<c002c468>] (mx3_gpio_irq_handler+0x110/0x124)</font>
<br><font size=2 face="sans-serif"> r5:00040000 r4:00000052</font>
<br><font size=2 face="sans-serif">[<c002c358>] (mx3_gpio_irq_handler+0x0/0x124)
from [<c0021078>] (asm_do_IRQ+0x78/0x9c)</font>
<br><font size=2 face="sans-serif"> r8:c0286d24 r7:c0324d68 r6:000b0000
r5:00000000 r4:0000000b</font>
<br><font size=2 face="sans-serif">[<c0021000>] (asm_do_IRQ+0x0/0x9c)
from [<c0021aac>] (__irq_svc+0x2c/0x60)</font>
<br><font size=2 face="sans-serif">Exception stack(0xc19bfe64 to 0xc19bfeac)</font>
<br><font size=2 face="sans-serif">fe60: 00000001
0000001e 00000001 54400000 60000013 0000007e 00000001</font>
<br><font size=2 face="sans-serif">fe80: c0324d68 c0286d24 c1989418 c19bff78
c19bfebc f401c300 c19bfeac c0149908</font>
<br><font size=2 face="sans-serif">fea0: c002c144 60000013 ffffffff</font>
<br><font size=2 face="sans-serif"> r5:f4023000 r4:ffffffff</font>
<br><font size=2 face="sans-serif">[<c002c110>] (mxc_gpio_set+0x0/0x38)
from [<c0149908>] (__gpio_set_value+0x4c/0x5c)</font>
<br><font size=2 face="sans-serif"> r4:c032501c</font>
<br><font size=2 face="sans-serif">[<c01498bc>] (__gpio_set_value+0x0/0x5c)
from [<c01bb974>] (mx1_hbp_cf_on_store+0xe0/0xfc)</font>
<br><font size=2 face="sans-serif"> r6:00000002 r5:c190a400 r4:00000014</font>
<br><font size=2 face="sans-serif">[<c01bb894>] (mx1_hbp_cf_on_store+0x0/0xfc)
from [<c0164620>] (dev_attr_store+0x28/0x2c)</font>
<br><font size=2 face="sans-serif"> r6:c1989400 r5:00000002 r4:c194c960</font>
<br><font size=2 face="sans-serif">[<c01645f8>] (dev_attr_store+0x0/0x2c)
from [<c00c9aa4>] (sysfs_write_file+0x110/0x148)</font>
<br><font size=2 face="sans-serif">[<c00c9994>] (sysfs_write_file+0x0/0x148)
from [<c0087b94>] (vfs_write+0xb8/0x144)</font>
<br><font size=2 face="sans-serif">[<c0087adc>] (vfs_write+0x0/0x144)
from [<c0087ce8>] (sys_write+0x4c/0x7c)</font>
<br><font size=2 face="sans-serif"> r8:c0021fc4 r7:00000004 r6:c191ec00
r5:00000000 r4:00000000</font>
<br><font size=2 face="sans-serif">[<c0087c9c>] (sys_write+0x0/0x7c)
from [<c0021e40>] (ret_fast_syscall+0x0/0x2c)</font>
<br><font size=2 face="sans-serif"> r6:401c47b4 r5:00000002 r4:401c12f4</font>
<br><font size=2 face="sans-serif">Code: 15423001 e59831b0 e3a02002 e5933008
(e1c320b0)</font>
<br><font size=2 face="sans-serif">---[ end trace dce08ededce08edd ]---</font>
<br><font size=2 face="sans-serif">Kernel panic - not syncing: Fatal exception
in interrupt</font>
<br><font size=2 face="sans-serif">Backtrace:</font>
<br><font size=2 face="sans-serif">[<c0025304>] (dump_backtrace+0x0/0x10c)
from [<c0271bb0>] (dump_stack+0x18/0x1c)</font>
<br><font size=2 face="sans-serif"> r7:c19bfd6c r6:c19be000 r5:c19508a0
r4:00000000</font>
<br><font size=2 face="sans-serif">[<c0271b98>] (dump_stack+0x0/0x1c)
from [<c0271c04>] (panic+0x50/0x188)</font>
<br><font size=2 face="sans-serif">[<c0271bb4>] (panic+0x0/0x188)
from [<c0025728>] (die+0x188/0x1c8)</font>
<br><font size=2 face="sans-serif"> r3:00010000 r2:c02e04b9 r1:00000000
r0:c02da0be</font>
<br><font size=2 face="sans-serif">[<c00255a0>] (die+0x0/0x1c8) from
[<c0025830>] (arm_notify_die+0x58/0x5c)</font>
<br><font size=2 face="sans-serif">[<c00257d8>] (arm_notify_die+0x0/0x5c)
from [<c0021314>] (do_DataAbort+0x88/0x9c)</font>
<br><font size=2 face="sans-serif">[<c002128c>] (do_DataAbort+0x0/0x9c)
from [<c0021a60>] (__dabt_svc+0x40/0x60)</font>
<br><font size=2 face="sans-serif">Exception stack(0xc19bfd6c to 0xc19bfdb4)</font>
<br><font size=2 face="sans-serif">fd60:
0000003f
00001e58 00000002 c287e000 c1989280</font>
<br><font size=2 face="sans-serif">fd80: 00000000 00000000 00000000 c198c220
c19783a0 00000552 c19bfde8 c19bfcf4</font>
<br><font size=2 face="sans-serif">fda0: c19bfdb4 c0033518 c01b26f4 60000093
ffffffff</font>
<br><font size=2 face="sans-serif"> r8:c198c220 r7:00000000 r6:00000000
r5:c19bfda0 r4:ffffffff</font>
<br><font size=2 face="sans-serif">[<c01b24c8>] (if_cs_interrupt+0x0/0x624)
from [<c005ef90>] (handle_IRQ_event+0x2c/0xf8)</font>
<br><font size=2 face="sans-serif">[<c005ef64>] (handle_IRQ_event+0x0/0xf8)
from [<c0060d30>] (handle_level_irq+0x9c/0x108)</font>
<br><font size=2 face="sans-serif"> r7:00040000 r6:c0324ef8 r5:00000052
r4:c0329acc</font>
<br><font size=2 face="sans-serif">[<c0060c94>] (handle_level_irq+0x0/0x108)
from [<c002c468>] (mx3_gpio_irq_handler+0x110/0x124)</font>
<br><font size=2 face="sans-serif"> r5:00040000 r4:00000052</font>
<br><font size=2 face="sans-serif">[<c002c358>] (mx3_gpio_irq_handler+0x0/0x124)
from [<c0021078>] (asm_do_IRQ+0x78/0x9c)</font>
<br><font size=2 face="sans-serif"> r8:c0286d24 r7:c0324d68 r6:000b0000
r5:00000000 r4:0000000b</font>
<br><font size=2 face="sans-serif">[<c0021000>] (asm_do_IRQ+0x0/0x9c)
from [<c0021aac>] (__irq_svc+0x2c/0x60)</font>
<br><font size=2 face="sans-serif">Exception stack(0xc19bfe64 to 0xc19bfeac)</font>
<br><font size=2 face="sans-serif">fe60: 00000001
0000001e 00000001 54400000 60000013 0000007e 00000001</font>
<br><font size=2 face="sans-serif">fe80: c0324d68 c0286d24 c1989418 c19bff78
c19bfebc f401c300 c19bfeac c0149908</font>
<br><font size=2 face="sans-serif">fea0: c002c144 60000013 ffffffff</font>
<br><font size=2 face="sans-serif"> r5:f4023000 r4:ffffffff</font>
<br><font size=2 face="sans-serif">[<c002c110>] (mxc_gpio_set+0x0/0x38)
from [<c0149908>] (__gpio_set_value+0x4c/0x5c)</font>
<br><font size=2 face="sans-serif"> r4:c032501c</font>
<br><font size=2 face="sans-serif">[<c01498bc>] (__gpio_set_value+0x0/0x5c)
from [<c01bb974>] (mx1_hbp_cf_on_store+0xe0/0xfc)</font>
<br><font size=2 face="sans-serif"> r6:00000002 r5:c190a400 r4:00000014</font>
<br><font size=2 face="sans-serif">[<c01bb894>] (mx1_hbp_cf_on_store+0x0/0xfc)
from [<c0164620>] (dev_attr_store+0x28/0x2c)</font>
<br><font size=2 face="sans-serif"> r6:c1989400 r5:00000002 r4:c194c960</font>
<br><font size=2 face="sans-serif">[<c01645f8>] (dev_attr_store+0x0/0x2c)
from [<c00c9aa4>] (sysfs_write_file+0x110/0x148)</font>
<br><font size=2 face="sans-serif">[<c00c9994>] (sysfs_write_file+0x0/0x148)
from [<c0087b94>] (vfs_write+0xb8/0x144)</font>
<br><font size=2 face="sans-serif">[<c0087adc>] (vfs_write+0x0/0x144)
from [<c0087ce8>] (sys_write+0x4c/0x7c)</font>
<br><font size=2 face="sans-serif"> r8:c0021fc4 r7:00000004 r6:c191ec00
r5:00000000 r4:00000000</font>
<br><font size=2 face="sans-serif">[<c0087c9c>] (sys_write+0x0/0x7c)
from [<c0021e40>] (ret_fast_syscall+0x0/0x2c)</font>
<br><font size=2 face="sans-serif"> r6:401c47b4 r5:00000002 r4:401c12f4</font>