Kernel crash issue with manufacturing test firmware

Tip / Sign in to post questions, reply, level up, and achieve exciting badges. Know more

cross mob
lock attach
Attachments are accessible only for community members.
PrBa_4645631
Level 1
Level 1

Dear all,

We are facing Kernel crash issue when using the manufacturing test firmware (fw_bcmdhd_mfgtest.bin) on a NXP i.MX 6ULL with Murata LBEE5KL1DX-883 wifi module.

The kernel module loads fine, but when we try to bring the wireless interface up (ifconfig wlan0 up) we get a kernel crash.

we are at kernel version 4.1.15

I am attaching logs here for crash.

0 Likes
1 Solution

ok, I just find one modification,  need your help to test this modification in file linux_osl.c

your version has no this modification:

/* Convert a native(OS) packet to driver packet.

* In the process, native packet is destroyed, there is no copying

* Also, a packettag is zeroed out

*/

#ifdef BCMDBG_CTRACE

void * BCMFASTPATH

osl_pkt_frmnative(osl_t *osh, void *pkt, int line, char *file)

#else

void * BCMFASTPATH

osl_pkt_frmnative(osl_t *osh, void *pkt)

#endif /* BCMDBG_CTRACE */

{

    struct sk_buff *cskb;

    struct sk_buff *nskb;

    unsigned long pktalloced = 0;

    if (osh->pub.pkttag)

        OSL_PKTTAG_CLEAR(pkt);

    /* walk the PKTCLINK() list */

    for (cskb = (struct sk_buff *)pkt;

         cskb != NULL;

         cskb = PKTISCHAINED(cskb) ? PKTCLINK(cskb) : NULL) {

        /* walk the pkt buffer list */

        for (nskb = cskb; nskb; nskb = nskb->next) {

            /* Increment the packet counter */

            pktalloced++;

            /* clean the 'prev' pointer

             * Kernel 3.18 is leaving skb->prev pointer set to skb

             * to indicate a non-fragmented skb

             */

#if (LINUX_VERSION_CODE >= KERNEL_VERSION(3, 18, 0))

            nskb->prev = NULL;

#endif /* LINUX_VERSION_CODE >= KERNEL_VERSION(3, 18, 0) */

#ifdef BCMDBG_CTRACE

            ADD_CTRACE(osh, nskb, file, line);

#endif /* BCMDBG_CTRACE */

        }

    }

    /* Increment the packet counter */

    atomic_add(pktalloced, &osh->cmn->pktalloced);

    return (void *)pkt;

}

View solution in original post

22 Replies
Zhengbao_Zhang
Moderator
Moderator
Moderator
250 sign-ins First comment on KBA 10 questions asked

hello

    So did you get the default release from imx platfrom ?  I think they should have fine tuned firmware released from their sdk.    and by the way the normal firmware of the same version didn't have this issue , right ?

0 Likes

Hello

Actually I did some more research and found  brcmfmac43430-sdio.1DX.clm_blob file from https://github.com/murata-wireless/cyw-fmac-fw but I don't know  how to proceed with this file.

Can you explain me the steps regarding how to apply this clm_blob file?

And the normal firmware of the same version didn't have this issue, only fw_bcmdhd_mfgtest.bin have this issue.

Regards,

Pratik

0 Likes

hello:

You can change the name to brcmfmac43430-sdio.clm_blob when bringing up the chip,  and do you mean normal firmware have no clm_blob file ,but the function is ok ?

0 Likes

Yes I Don't have clm_blob file but the function is ok.

0 Likes
lock attach
Attachments are accessible only for community members.

try this one for the test.

I had copy brcmfmac43430-sdio-mfgtest.bin to fw_bcmdhd.bin and then tried to up wlan0 with "ifconfig wlan0 up" command but still same issue happening.

If is there any other steps I need then please tell me.

0 Likes
lock attach
Attachments are accessible only for community members.

I missed one thing, seems you are not using fmac driver, try this one from official wiced release.

Tried, but same crash issue is happening

Steps followed :

-> cp 43438A1-mfgtest.bin fw_bcmdhd.bin

-> ifconfig wlan0 up

0 Likes

hello:

  I just find one similar issue inside,  I think you can disable auto-start of wpa_supplicant before "ifconfig wlan0 up" ,  need a try.   Because MFG firmware is used for the test,  wpa_supplicant is not needed when running.

0 Likes

Hello,

I have checked regarding wpa_supplicant  service using "ps" and it is not running, it is already disabled.

Then tried "ifconfig wlan0 up" but still same issue is happening.

Regards,

Pratik

0 Likes

Thanks for the test, another suggestion,  imx6ull should have dhd released by default,  the dhd should have passed the mfg test, I think maybe you can try a different dhd,  maybe the version of the default one is older than your 1.141 , if no issue, I think you can have a compare about the critical setting between two versions in your environment.   for supplicant, please run "killall wpa_supplicant " before the ifconfig up.

0 Likes

Hello,

In our IMX6ULL  dhd version is 1.141.92. Can we run compliance testing with this dhd? We need to have control of channel selection i.e. low, mid and high along with transmit power in all three mode i.e. b/g/n. Please share the command for the same if it can be doable in existing dhd version.

0 Likes

Yes, it can be run with 1.141.92  , so the crash didn't happen in verion 92 .

0 Likes

Can you share the steps for compliance testing ? We need to have control of channel selection i.e. low, mid and high along with transmit power in all three mode i.e. b/g/n. Please share the command for the same

0 Likes
lock attach
Attachments are accessible only for community members.

the attached is from our Iot test scripts , I think you only need to replace the prefix with string "wl"  .

Thanks, but I found that some commands like "wl country ALL" gives me "wl: Bad Argument"  error with normal binary So I found that I need mfgtest binary for that but as I described previous it gives me kernel crash.

Regards,

Pratik

0 Likes

Yes, I knew that,   so I am asking if you can try another DHD release , not the 1.141.78 one , where you got the driver ?  I think you can ask if an older one can avoid this crash.

Ok, Can you please provide me older one?  I have 1.141.92 as a current version.

0 Likes

ok, I just find one modification,  need your help to test this modification in file linux_osl.c

your version has no this modification:

/* Convert a native(OS) packet to driver packet.

* In the process, native packet is destroyed, there is no copying

* Also, a packettag is zeroed out

*/

#ifdef BCMDBG_CTRACE

void * BCMFASTPATH

osl_pkt_frmnative(osl_t *osh, void *pkt, int line, char *file)

#else

void * BCMFASTPATH

osl_pkt_frmnative(osl_t *osh, void *pkt)

#endif /* BCMDBG_CTRACE */

{

    struct sk_buff *cskb;

    struct sk_buff *nskb;

    unsigned long pktalloced = 0;

    if (osh->pub.pkttag)

        OSL_PKTTAG_CLEAR(pkt);

    /* walk the PKTCLINK() list */

    for (cskb = (struct sk_buff *)pkt;

         cskb != NULL;

         cskb = PKTISCHAINED(cskb) ? PKTCLINK(cskb) : NULL) {

        /* walk the pkt buffer list */

        for (nskb = cskb; nskb; nskb = nskb->next) {

            /* Increment the packet counter */

            pktalloced++;

            /* clean the 'prev' pointer

             * Kernel 3.18 is leaving skb->prev pointer set to skb

             * to indicate a non-fragmented skb

             */

#if (LINUX_VERSION_CODE >= KERNEL_VERSION(3, 18, 0))

            nskb->prev = NULL;

#endif /* LINUX_VERSION_CODE >= KERNEL_VERSION(3, 18, 0) */

#ifdef BCMDBG_CTRACE

            ADD_CTRACE(osh, nskb, file, line);

#endif /* BCMDBG_CTRACE */

        }

    }

    /* Increment the packet counter */

    atomic_add(pktalloced, &osh->cmn->pktalloced);

    return (void *)pkt;

}

Thanks a lot for this patch, Now crash issue is resolved after applying above patch in linux_osl.c

but i am running FCC test script for Tx on mfgtest firmware (43438A1-mfgtest.bin) and some commands are not  working proper.

wl down

wl mpc 0

wl phy_watchdog 0

wl country ALL

wl band b

wl 2g_rate -r 11 -b 20

wl txcore -s 1 -c 1 -o 1 -k 1

wl: Unsupported

wl channel 11

wl scansuppress 1

wl phy_txpwrctrl 1

wl: No clock

wl txpwr1 -1

wl txpwr1 -o -d 10

wl up

wl phy_forcecal 1

wl pkteng_start 00:11:22:33:44:55 tx 100 1024 0

sleep 10

Please provide me solution for "wl txcore -s 1 -c 1 -o 1 -k 1" and "wl phy_txpwrctrl 1".

Regards,

Pratik

0 Likes

hello:

You can skip these two commands for 43438.  then see if the power can transmit to the antenna point.

Hello,

Yes power can transmit to the antenna point.

you can close the issue.

Thanks & Regards,

Pratik

0 Likes