4 Replies Latest reply on Apr 10, 2018 6:34 AM by mifo

    bcmdhd crash while rmmod

    samuel_2522106

      Hello,

       

      On our custom board that integrates iMX6UL + LBEH5DU1BW, we observe unexpected and random behaviour while rmmod bcmdhd. It has been reproduce on several boards but it is not systematic, most of time the rmmod goes successfully.

       

      This failure in rmmod implies a failure on next modprobe. Finally only way to be able to modprobe successfully after such a failure is to reboot completely the board.

       

      We are using NXP official release : imx_4.1.15_2.0.0_ga (linux-imx.git)

       

      Any clue or fix to suggest?

       

      Thank you

       

      Sam

       

       

      bcmdhd crash during rmmod (log kernel)

       

      2016-12-07T22:51:08.934+0000 kernel: dhd_prot_ioctl : bus is down. we have nothing to do

       

      2016-12-07T22:51:08.934+0000 kernel: dhd_wlfc_deinit():3271, ampdu_hostreorder get failed Err = -1

      2016-12-07T22:51:08.935+0000 kernel: dhd_prot_ioctl : bus is down. we have nothing to do

      2016-12-07T22:51:08.942+0000 kernel: dhd_wlfc_deinit():3294 failed to enable/disable bdcv2 tlv signaling Err = -1

      2016-12-07T22:51:09.075+0000 kernel: CFGP2P-ERROR) wl_cfgp2p_del_p2p_disc_if : P2P interface unregistered

      2016-12-07T22:51:09.075+0000 kernel: dhd_detach(): thread:dhd_watchdog_thread:b9 terminated OK

      2016-12-07T22:51:09.086+0000 kernel: dhd_dpc_thread: Unexpected up_cnt 0

      2016-12-07T22:51:09.086+0000 kernel: dhd_detach(): thread:dhd_dpc:ba terminated OK

      2016-12-07T22:51:09.098+0000 kernel: CFG80211-ERROR) wl_event_handler : was terminated

      2016-12-07T22:51:09.098+0000 kernel: wl_destroy_event_handler(): thread:wl_event_handler:b8 terminated OK

      2016-12-07T22:51:09.133+0000 kernel: unregister wifi platform drivers

      2016-12-07T22:51:09.133+0000 kernel: wifi_platform_bus_enumerate device present 0

      2016-12-07T22:51:09.133+0000 kernel: mmc0: card 0001 removed

       

       

      Failure on next modprobe (log kernel)

       

      2016-12-08T06:45:44.965+0000 kernel: dhd_module_init in

       

      2016-12-08T06:45:44.965+0000 kernel: Power-up adapter 'DHD generic adapter'

      2016-12-08T06:45:44.972+0000 kernel: wifi_platform_bus_enumerate device present 1

      2016-12-08T06:45:45.065+0000 kernel: mmc0: queuing unknown CIS tuple 0x80 (7 bytes)

      2016-12-08T06:45:45.066+0000 kernel: mmc0: queuing unknown CIS tuple 0x80 (6 bytes)

      2016-12-08T06:45:45.146+0000 kernel: mmc0: queuing unknown CIS tuple 0x91 (3 bytes)

      2016-12-08T06:45:45.146+0000 kernel: mmc0: new high speed SDIO card at address 0001

      2016-12-08T06:45:45.185+0000 kernel: F1 signature OK, socitype:0x1 chip:0xa94c rev:0x2 pkg:0x0

      2016-12-08T06:45:45.185+0000 kernel: DHD: dongle ram size is set to 524288(orig 524288) at 0x0

      2016-12-08T06:45:45.204+0000 kernel: wifi_platform_get_mac_addr

      2016-12-08T06:45:45.204+0000 kernel: modprobe: page allocation failure: order:5, mode:0xc0d0

      2016-12-08T06:45:45.204+0000 kernel: CPU: 0 PID: 26113 Comm: modprobe Not tainted 4.1.15 #1

      2016-12-08T06:45:45.217+0000 kernel: Hardware name: Freescale i.MX6 Ultralite (Device Tree)

      2016-12-08T06:45:45.217+0000 kernel: [<800144a8>] (unwind_backtrace) from [<800121b0>] (show_stack+0x10/0x14)

      2016-12-08T06:45:45.232+0000 kernel: [<800121b0>] (show_stack) from [<8009dfb4>] (warn_alloc_failed+0xe4/0x120)

      2016-12-08T06:45:45.232+0000 kernel: [<8009dfb4>] (warn_alloc_failed) from [<800a07a4>] (__alloc_pages_nodemask+0x538/0x838)

      2016-12-08T06:45:45.247+0000 kernel: [<800a07a4>] (__alloc_pages_nodemask) from [<800b3758>] (kmalloc_order+0x10/0x20)

      2016-12-08T06:45:45.247+0000 kernel: [<800b3758>] (kmalloc_order) from [<805f8694>] (wiphy_new_nm+0x100/0x444)

      2016-12-08T06:45:45.265+0000 kernel: [<805f8694>] (wiphy_new_nm) from [<7f1839c0>] (wl_cfg80211_attach+0x80/0xccc [bcmdhd])

      2016-12-08T06:45:45.265+0000 kernel: [<7f1839c0>] (wl_cfg80211_attach [bcmdhd]) from [<7f15e5b8>] (dhd_attach+0x2f4/0x7c8 [bcmdhd])

      2016-12-08T06:45:45.283+0000 kernel: [<7f15e5b8>] (dhd_attach [bcmdhd]) from [<7f1a5fdc>] (dhdsdio_probe+0x194/0x69c [bcmdhd])

      2016-12-08T06:45:45.283+0000 kernel: [<7f1a5fdc>] (dhdsdio_probe [bcmdhd]) from [<7f199240>] (bcmsdh_probe+0xd0/0x134 [bcmdhd])

      2016-12-08T06:45:45.308+0000 kernel: [<7f199240>] (bcmsdh_probe [bcmdhd]) from [<7f19a9e4>] (bcmsdh_sdmmc_probe+0xcc/0x104 [bcmdhd])

      2016-12-08T06:45:45.308+0000 kernel: [<7f19a9e4>] (bcmsdh_sdmmc_probe [bcmdhd]) from [<8044141c>] (sdio_bus_probe+0xfc/0x114)

      2016-12-08T06:45:45.309+0000 kernel: [<8044141c>] (sdio_bus_probe) from [<8031c240>] (driver_probe_device+0x174/0x27c)

      2016-12-08T06:45:45.323+0000 kernel: [<8031c240>] (driver_probe_device) from [<8031c418>] (__driver_attach+0x8c/0x90)

      2016-12-08T06:45:45.324+0000 kernel: [<8031c418>] (__driver_attach) from [<8031a814>] (bus_for_each_dev+0x60/0x94)

      2016-12-08T06:45:45.338+0000 kernel: [<8031a814>] (bus_for_each_dev) from [<8031b9e0>] (bus_add_driver+0x148/0x1f0)

      2016-12-08T06:45:45.339+0000 kernel: [<8031b9e0>] (bus_add_driver) from [<8031ca50>] (driver_register+0x78/0xf8)

      2016-12-08T06:45:45.358+0000 kernel: [<8031ca50>] (driver_register) from [<7f197a08>] (wifi_plat_dev_drv_remove+0x2b0/0x454 [bcmdhd])

      2016-12-08T06:45:45.359+0000 kernel: [<7f197a08>] (wifi_plat_dev_drv_remove [bcmdhd]) from [<7f197c50>] (wifi_plat_dev_drv_probe+0xa4/0x128 [bcmdhd])

      2016-12-08T06:45:45.376+0000 kernel: [<7f197c50>] (wifi_plat_dev_drv_probe [bcmdhd]) from [<8031da70>] (platform_drv_probe+0x44/0xa4)

      2016-12-08T06:45:45.376+0000 kernel: [<8031da70>] (platform_drv_probe) from [<8031c240>] (driver_probe_device+0x174/0x27c)

      2016-12-08T06:45:45.398+0000 kernel: [<8031c240>] (driver_probe_device) from [<8031c418>] (__driver_attach+0x8c/0x90)

      2016-12-08T06:45:45.399+0000 kernel: [<8031c418>] (__driver_attach) from [<8031a814>] (bus_for_each_dev+0x60/0x94)

      2016-12-08T06:45:45.399+0000 kernel: [<8031a814>] (bus_for_each_dev) from [<8031b9e0>] (bus_add_driver+0x148/0x1f0)

      2016-12-08T06:45:45.416+0000 kernel: [<8031b9e0>] (bus_add_driver) from [<8031ca50>] (driver_register+0x78/0xf8)

      2016-12-08T06:45:45.416+0000 kernel: [<8031ca50>] (driver_register) from [<7f1980a0>] (dhd_wifi_platform_register_drv+0x1d4/0x218 [bcmdhd])

      2016-12-08T06:45:45.433+0000 kernel: [<7f1980a0>] (dhd_wifi_platform_register_drv [bcmdhd]) from [<80009678>] (do_one_initcall+0x8c/0x1d4)

      2016-12-08T06:45:45.433+0000 kernel: [<80009678>] (do_one_initcall) from [<8065a614>] (do_init_module+0x5c/0x1a8)

      2016-12-08T06:45:45.447+0000 kernel: [<8065a614>] (do_init_module) from [<800817fc>] (load_module+0x18b0/0x1c78)

      2016-12-08T06:45:45.447+0000 kernel: [<800817fc>] (load_module) from [<80081c94>] (SyS_init_module+0xd0/0x124)

      2016-12-08T06:45:45.481+0000 kernel: [<80081c94>] (SyS_init_module) from [<8000f260>] (ret_fast_syscall+0x0/0x3c)

        • 1. Re: bcmdhd crash while rmmod
          skerr_1713761

          Hi Samuel,

           

          Sorry for the delay in response. We are pushing an updated patch release to "My Murata".  I will reach out directly to share the patch file with you now.

           

          Best Regards,

           

          Scott

          1 of 1 people found this helpful
          • 2. Re: bcmdhd crash while rmmod
            dhvanil

            Hi skerr_1713761

             

            Can you please share patch with us, We are also facing the same issue with bcmdhd module. We are using 1DX modulle on i.mx6ul board.

            • 3. Re: bcmdhd crash while rmmod
              lambertarthur22_2221641

              Hi skerr_1713761

               

              We have a similar issue on imx6ull with bcmdhd on rmmod. Not sure that its exactly the same issue

              but I will be happy to get your patch to test it.

               

              Our issue :

               

              # sh /etc/init.d/S02modprobe stop

              dhd_prot_ioctl : bus is down. we have nothing to do

              dhd_wlfc_deinit():3271, ampdu_hostreorder get failed Err = -1

              dhd_prot_ioctl : bus is down. we have nothing to do

              dhd_wlfc_deinit():3294 failed to enable/disable bdcv2 tlv signaling Err = -1

              dhd_detach(): thread:dhd_watchdog_thread:8d terminated OK

              dhd_dpc_thread: Unexpected up_cnt 0

              dhd_detach(): thread:dhd_dpc:8e terminated OK

              Unable to handle kernel paging request at virtual address 00200200

              CFGP2P-ERROR) wl_cfgp2p_del_p2p_disc_if :

              pgd = 8669c000

              P2P interface unregistered

              [00200200] *pgd=00000000

              Internal error: Oops: 805 [#1] PREEMPT ARM

              Modules linked in: bcmdhd(-)

              CPU: 0 PID: 460 Comm: rmmod Not tainted 4.1.15 #2

              Hardware name: Freescale i.MX6 Ultralite (Device Tree)

              task: 8656c880 ti: 866fe000 task.ti: 866fe000

              PC is at cfg80211_unregister_wdev+0x40/0xd8

              LR is at cfg80211_unregister_wdev+0x18/0xd8

              pc : [<805fe39c>]    lr : [<805fe374>]    psr: 60000013

              sp : 866ffe70  ip : 00000019  fp : 00000000

              r10: 8649f914  r9 : 7f0782d8  r8 : 8649c000

              r7 : 86511518  r6 : 86500380  r5 : 86500140  r4 : 8655f6c0

              r3 : 00200200  r2 : 00200200  r1 : 8650003c  r0 : 00000001

              Flags: nZCv  IRQs on  FIQs on  Mode SVC_32  ISA ARM  Segment user

              Control: 10c53c7d  Table: 8669c059  DAC: 00000015

              Process rmmod (pid: 460, stack limit = 0x866fe208)

              Stack: (0x866ffe70 to 0x86700000)

              fe60:                                     809590f8 7f0785bc 8655f6c0 7f04354c

              fe80: 86500380 7f07bd0c 00011254 7f032a24 000002ee 00003880 8649c000 8649f880

              fea0: 7f07c44c 7f00c1a0 86453800 7f0782d8 86636dc0 00000000 8000f424 866fe000

              fec0: 00000000 7f0535dc 8649c000 7f0782d8 86453800 00000000 866fe000 7f054eb0

              fee0: 7f054e74 86636e40 86636e80 7f0478ac 86480800 86636dc0 7f07a294 7f0490f0

              ff00: 7f0490a8 86456208 86456200 80445a6c 86456208 7f07a294 7f07a294 8031e14c

              ff20: 7f07a294 86456208 8645623c 8031e8d8 8656c880 7f07a294 7ea4eb58 00006468

              ff40: 00000081 8031deac 7f07a2f4 7f05e1d4 7f05e1a8 80082100 7ea4ec14 646d6362

              ff60: 00006468 00000003 7ea4ec14 8642fcc0 8642fcc0 00005401 7ea4e9e4 00000001

              ff80: 866fe000 00000000 7ea4ec14 800e8dd4 00005401 00a4e9e4 00087630 0002769c

              ffa0: 646d6362 8000f2a0 0002769c 646d6362 7ea4eb58 00000880 7ea4eb58 00000880

              ffc0: 0002769c 646d6362 00006468 00000081 000c5634 00000000 76fbef70 00000000

              ffe0: 7ea4eb50 7ea4eb40 00027584 76f26a20 20000010 7ea4eb58 89fce821 89fcec21

              [<805fe39c>] (cfg80211_unregister_wdev) from [<7f04354c>] (wl_cfgp2p_del_p2p_disc_if+0x38/0xc0 [bcmdhd])

              [<7f04354c>] (wl_cfgp2p_del_p2p_disc_if [bcmdhd]) from [<7f032a24>] (wl_cfg80211_detach+0xf0/0x1b8 [bcmdhd])

              [<7f032a24>] (wl_cfg80211_detach [bcmdhd]) from [<7f00c1a0>] (dhd_detach+0x288/0x448 [bcmdhd])

              [<7f00c1a0>] (dhd_detach [bcmdhd]) from [<7f0535dc>] (dhdsdio_release+0x4c/0x1d0 [bcmdhd])

              [<7f0535dc>] (dhdsdio_release [bcmdhd]) from [<7f054eb0>] (dhdsdio_disconnect+0x3c/0x94 [bcmdhd])

              [<7f054eb0>] (dhdsdio_disconnect [bcmdhd]) from [<7f0478ac>] (bcmsdh_remove+0x3c/0x60 [bcmdhd])

              [<7f0478ac>] (bcmsdh_remove [bcmdhd]) from [<7f0490f0>] (bcmsdh_sdmmc_remove+0x48/0x60 [bcmdhd])

              [<7f0490f0>] (bcmsdh_sdmmc_remove [bcmdhd]) from [<80445a6c>] (sdio_bus_remove+0x30/0xf8)

              [<80445a6c>] (sdio_bus_remove) from [<8031e14c>] (__device_release_driver+0x70/0xe4)

              [<8031e14c>] (__device_release_driver) from [<8031e8d8>] (driver_detach+0xe4/0xfc)

              [<8031e8d8>] (driver_detach) from [<8031deac>] (bus_remove_driver+0x4c/0xa0)

              [<8031deac>] (bus_remove_driver) from [<7f05e1d4>] (dhd_module_cleanup+0x2c/0x3c [bcmdhd])

              [<7f05e1d4>] (dhd_module_cleanup [bcmdhd]) from [<80082100>] (SyS_delete_module+0x10c/0x1a8)

              [<80082100>] (SyS_delete_module) from [<8000f2a0>] (ret_fast_syscall+0x0/0x3c)

              Code: e3a03c02 e5941008 e3403020 e5812004 (e5821000)

              ---[ end trace 45910dd49527e969 ]---

              Kernel panic - not syncing: Fatal exception

               

              Thanks & Regards,

              Arthur.