This thread has been locked.

If you have a related question, please click the "Ask a related question" button in the top right corner. The newly created question will be automatically linked to this question.

M2-CC3351: cc33xx: ERROR Device info command failure

Part Number: M2-CC3351
Other Parts Discussed in Thread: CC3300

Tool/software:

Hello there,

I'm trying to get an m2-CC3351 working with an frdm-imx93 board. The modification on the board were made to get an functional M2 slot working, I've also swapped R7 and R10 on the M2 board to route the IRQ on a correct imx93 pin.

Using a linux mainline kernel v6.12.9, with the following node for the device tree:

&usdhc3 {
    pinctrl-names = "default";
    pinctrl-0 = <&pinctrl_usdhc3>, <&pinctrl_usdhc3_wlan>;
    mmc-pwrseq = <&usdhc3_pwrseq>;
    vmmc-supply = <&reg_usdhc3_vmmc>;
    bus-width = <4>;
    keep-power-in-suspend;
    cap-power-off-card;
    non-removable;
    max-frequency = <10000000>;
    status = "okay";
    #address-cells = <1>;
    #size-cells = <0>;

    wifi: wifi@2 {
        compatible = "ti,cc3300";
        reg = <2>;
        interrupt-parent = <&pcal6524>;
        interrupts = <10 IRQ_TYPE_EDGE_RISING>;
    };

    // TI-BLE-SDIO interface
    btti: btti@1 {
        compatible = "ti,cc33xxbt";
        reg = <1>;
    };
}

Now, using patch found on kernel's mailing list and firmware v1.7.0.120 (upper version were not compatible).

I can get the device probed successfully, and starting in main.c. Thus, it gets stuck on firmware download with the following message:

[ 0.889279] cc33xx: Set BLKsize to 128
[ 0.889925] cc33xx: HINT_STATUS: 0x8, TSF: 0x4402a, rx status: 0x1fff0000
[ 2.915544] cc33xx: Command T.O
[ 2.915565] cc33xx: ERROR Device info command failure
[ 2.922133] cc33xx: ERROR FW download failed
[ 2.922208] cc33xx: cc33xx_nvs_cb complete

What is the issue there?

  • Small update, I've removed the irq definition so it can use the "in-band" irq, just to check if it was an routing issue.

    Now I've got following messages:

    [ 13.036867] cc33xx_sdio mmc2:0001:2: sdio read 53 addr 0xbffc, 256 bytes
    [ 13.041536] WARNING: CPU: 0 PID: 46 at /drivers/net/wireless/ti/cc33xx/sdio.c:81 0xffff800080855a8c
    [ 13.200690] cc33xx_sdio mmc2:0001:2: sdio read failed (-110)
    [ 13.200767] cc33xx: ERROR IO error during core status read
    [ 13.204353] cc33xx_sdio_raw_read
    [ 23.268593] cc33xx_sdio mmc2:0001:2: sdio read 53 addr 0xbffc, 256 bytes
    [ 23.273247] WARNING: CPU: 1 PID: 24 at /drivers/net/wireless/ti/cc33xx/sdio.c:81 0xffff800080855a8c
    [ 23.425240] cc33xx_sdio mmc2:0001:2: sdio read failed (-110)
    [ 23.425252] cc33xx: ERROR IO error during core status read
    [ 25.444339] cc33xx: ERROR boot IRQ timeout
    [ 25.444362] cc33xx_sdio_disable_irq
    [ 35.560084] cc33xx_sdio_power_off
    [ 45.799909] cc33xx: ERROR FW download failed

    Any idea?

  • After some work I've got the interface working for.. a few minutes.

    I have three different behaviors:

    # behavior 1:

    Nothing is probed and the mmc controller fails:

    [ 102.882200] mmc2: Timeout waiting for hardware cmd interrupt.
    [ 102.882222] mmc2: sdhci: ============ SDHCI REGISTER DUMP ===========
    [ 102.882228] mmc2: sdhci: Sys addr: 0x00000000 | Version: 0x00000002
    [ 102.882236] mmc2: sdhci: Blk size: 0x00000000 | Blk cnt: 0x00000001
    [ 102.882242] mmc2: sdhci: Argument: 0x00000000 | Trn mode: 0x00000000
    [ 102.882248] mmc2: sdhci: Present: 0x01fd8009 | Host ctl: 0x00000000
    [ 102.882253] mmc2: sdhci: Power: 0x00000000 | Blk gap: 0x00000080
    [ 102.882258] mmc2: sdhci: Wake-up: 0x00000008 | Clock: 0x000020ff
    [ 102.882263] mmc2: sdhci: Timeout: 0x00000080 | Int stat: 0x00000000
    [ 102.882268] mmc2: sdhci: Int enab: 0x007f1003 | Sig enab: 0x007f1003
    [ 102.882273] mmc2: sdhci: ACmd stat: 0x00000000 | Slot int: 0x00000502
    [ 102.882278] mmc2: sdhci: Caps: 0x07eb0000 | Caps_1: 0x0000b400
    [ 102.882283] mmc2: sdhci: Cmd: 0x0000371a | Max curr: 0x00ffffff
    [ 102.882288] mmc2: sdhci: Resp[0]: 0x00000000 | Resp[1]: 0x00000000
    [ 102.882293] mmc2: sdhci: Resp[2]: 0x00000000 | Resp[3]: 0x00000000
    [ 102.882298] mmc2: sdhci: Host ctl2: 0x00000000
    [ 102.882302] mmc2: sdhci: ADMA Err: 0x00000000 | ADMA Ptr: 0x00000000
    [ 102.882308] mmc2: sdhci-esdhc-imx: ========= ESDHC IMX DEBUG STATUS DUMP =========
    [ 102.882312] mmc2: sdhci-esdhc-imx: cmd debug status: 0x3180
    [ 102.882317] mmc2: sdhci-esdhc-imx: data debug status: 0x3200
    [ 102.882322] mmc2: sdhci-esdhc-imx: trans debug status: 0x3300
    [ 102.882326] mmc2: sdhci-esdhc-imx: dma debug status: 0x3400
    [ 102.882331] mmc2: sdhci-esdhc-imx: adma debug status: 0x3500
    [ 102.882336] mmc2: sdhci-esdhc-imx: fifo debug status: 0x3680
    [ 102.882340] mmc2: sdhci-esdhc-imx: async fifo debug status: 0x3750
    [ 102.882345] mmc2: sdhci: ============================================

    # Behavior 2:

    device is probed but not responding

    [ 0.541262] device: 'mmc2': device_add
    [ 0.584548] mmc2: SDHCI controller on 428b0000.mmc [428b0000.mmc] using ADMA
    [ 1.251679] mmc2: error -16 whilst initialising SDIO card
    [ 1.944173] mmc2: error -16 whilst initialising SDIO card
    [ 2.632275] mmc2: error -16 whilst initialising SDIO card
    [ 3.328927] mmc2: error -16 whilst initialising SDIO card
    [ 3.338604] mmc2: Failed to initialize a non-removable card

    # behavior 3:

    interface is available to linux and can connect, thus, crashes after a few egabytes of traffic

    [ 333.721664] WARNING: CPU: 0 PID: 54 at /drivers/net/wireless/ti/cc33xx/sdio.c:79 0xffff8000808463a0
    [ 333.872727] cc33xx_sdio mmc2:0001:2: sdio read failed (-110)
    [ 333.872739] cc33xx: ERROR IO error during core status read
    [ 333.872783] cc33xx: ERROR IO error during core status read
    [ 333.872794] cc33xx: ERROR IO error during core status read
    [ 333.872803] cc33xx: ERROR IO error during core status read
    [ 333.872811] cc33xx: ERROR IO error during core status read
    [ 333.872820] cc33xx: ERROR IO error during core status read
    [ 333.872828] cc33xx: ERROR IO error during core status read
    [ 333.872836] cc33xx: ERROR IO error during core status read
    [ 333.872844] cc33xx: ERROR IO error during core status read
    [ 333.872852] cc33xx: ERROR IO error during core status read
    [ 333.872860] cc33xx: ERROR IO error during core status read
    [ 333.872868] cc33xx: ERROR IO error during core status read
    [ 333.872876] cc33xx: ERROR IO error during core status read
    [ 333.873062] cc33xx: CC33xx driver attempting recovery
    [ 333.903873] cc33xx: mac80211 sta 0 state=4->3
    [ 333.931944] cc33xx: mac80211 sta 0 state=3->2
    [ 333.931951] cc33xx: mac80211 sta 0 state=2->1
    [ 333.931956] cc33xx: mac80211 sta 0 state=1->0
    [ 333.932080] cc33xx: mac80211 conf tx 0
    [ 333.932089] cc33xx: mac80211 conf tx 1
    [ 333.932093] cc33xx: mac80211 conf tx 2
    [ 333.932097] cc33xx: mac80211 conf tx 3
    [ 333.932110] cc33xx: mac80211 remove chanctx 6 (type 1)
    [ 333.932148] cc33xx: mac80211 config psm off power 0 idle changed 0x100
    [ 334.939312] cc33xx: Set BLKsize to 128
    [ 345.015349] cc33xx_sdio mmc2:0001:2: sdio read 53 addr 0xbffc, 256 bytes
    [ 345.020019] WARNING: CPU: 1 PID: 11 at /drivers/net/wireless/ti/cc33xx/sdio.c:79 0xffff8000808463a0
    [ 345.168728] cc33xx_sdio mmc2:0001:2: sdio read failed (-110)
    [ 345.168741] cc33xx: ERROR IO error during core status read
    [ 347.190244] cc33xx: ERROR boot IRQ timeout
    [ 355.252187] cc33xx_sdio mmc2:0001:2: sdio read 53 addr 0xbffc, 256 bytes
    [ 355.256844] WARNING: CPU: 0 PID: 54 at /drivers/net/wireless/ti/cc33xx/sdio.c:79 0xffff8000808463a0
    [ 355.409122] cc33xx_sdio mmc2:0001:2: sdio read failed (-110)
    [ 355.409140] cc33xx: ERROR IO error during core status read
    [ 365.490116] cc33xx_sdio mmc2:0001:2: sdio read 53 addr 0xbffc, 256 bytes
    [ 365.495965] WARNING: CPU: 0 PID: 54 at /drivers/net/wireless/ti/cc33xx/sdio.c:79 0xffff8000808463a0
    [ 365.647949] cc33xx_sdio mmc2:0001:2: sdio read failed (-110)
    [ 365.647961] cc33xx: ERROR IO error during core status read
    [ 375.727969] cc33xx_sdio mmc2:0001:2: sdio read 53 addr 0xbffc, 256 bytes
    [ 375.732631] WARNING: CPU: 0 PID: 54 at /drivers/net/wireless/ti/cc33xx/sdio.c:79 0xffff8000808463a0
    [ 375.884569] cc33xx_sdio mmc2:0001:2: sdio read failed (-110)
    [ 375.884581] cc33xx: ERROR IO error during core status read
    [ 396.205408] cc33xx: using pre-allocated hw queue base 0
    [ 406.447621] WARNING: CPU: 0 PID: 54 at /drivers/net/wireless/ti/cc33xx/sdio.c:105 0xffff80008084619c
    [ 406.606713] cc33xx_sdio mmc2:0001:2: sdio write failed (-110)
    [ 406.606730] cc33xx: ERROR failed to initiate cmd role enable

    Now, i've asked myself quite a lot of questions, and i finally swapped the M2-CC3351 module for a PA9019A M2 module just to check my board was still OK. It worked like a charm at first try. Despite many efforts, I can't find a deterministic sequence to reproduce these errors.

  • If it were me, I'd be suspecting SDIO bus signal integrity issues...

  • Indeed, but it only happens with this kind of module. When I'm using a PA9019A M.2 module, there's no problem with similar device tree and system.

  • Hello John,

    I noticed in your devicetree that you are using the pcal6524. This is a I2C-based GPIO expander, correct?
    I have previous experience with developing on the imx93-QSB board that also used a GPIO expander for the IRQ pin. The CC33xx uses the IRQ very quickly, so I believe the I2C-based GPIO expander is simply too slow (or handles incorrectly timing-wise) to handle the CC33xx's IRQ. 

    For now I would recommend to comment OUT 2 interrupt lines as such:

        wifi: wifi@2 {
            compatible = "ti,cc3300";
            reg = <2>;
            //interrupt-parent = <&pcal6524>;
            //interrupts = <10 IRQ_TYPE_EDGE_RISING>;
        };

  • Hello Sabeeh,

    Yeah the PCAL6524 is a GPIO expander . On the FRDM-IMX93 board, the default SDIO_WAKE for the the IRQ on the board is wired to an incompatible PIN on the imx93, so we used the second optional PIN which is wired to this GPIO expander.

    I've also suspected this timing issue. I did try it without the IRQ as I saw in the driver code that it can support the in-band IRQ (first response to my initial thread). It didn't helped. The three errors shown appends with a device tree without IRQ declaration.

    I've also been suspecting some potential problems while setting up the M.2 port which is deactivated by default with non-provisioned 0R. But cross checking with another SDIO-based M.2 module made me confident in the board.

    Tested with three FRDM-IMX93 boards and two M2-CC3351 modules so far.

  • Hi John,

    Could you please share a schematic for the FRDM-IMX93 board? Could you also post the definitions of  "mmc-pwrseq = <&usdhc3_pwrseq>;" and "vmmc-supply = <&reg_usdhc3_vmmc>; " ?

  • Hi Sabeeh,

    Here are the defs for the device tree and the schematics. Regarding the schematics, the 0R marked as DNP have been provisioned, and the other one removed to disable the default soldered module to enable the M.2 one.

    reg_usdhc3_vmmc: regulator-usdhc3 {
        compatible = "regulator-fixed";
        regulator-name = "WLAN_EN";
        regulator-min-microvolt = <3300000>;
        regulator-max-microvolt = <3300000>;
        gpio = <&pcal6524 13 GPIO_ACTIVE_HIGH>;
        startup-delay-us = <20000>;
        enable-active-high;
        regulator-always-on;
    };

    usdhc3_pwrseq: usdhc3_pwrseq {
        compatible = "mmc-pwrseq-simple";
        reset-gpios = <&pcal6524 20 GPIO_ACTIVE_LOW>;
        post-power-on-delay-ms = <10>;
        power-off-delay-us = <80>;
    };

    SPF-94611_B1.pdf

  • Hi John,

    Which 0R are you describing? Can you please provide the identifier (R2861, R2822, etc.)...

  • In order to use the M.2 slot we had to rework a few resistor as described in the board user manual (see below). As mentioned earlier we've tested this rework with another M.2 module using SDIO, UART and SPI with success. 

    Resistors rework for M.2 slot usage
    Resistors DNP Resistors install

    R2808, R2809, R2812, R2819, R2820, R2821

    R2824, R2825, R2826, R2827, R2828, R2829

    R3023, R3024, R2958, R3028

    R2960, R2860

    R2854, R2855

    R2851, R2853

    R3038, R2870, R2871

    R3037, R2866, R2867

    R2796, R2798, R2800, R2802

    R2788, R2791, R2792, R2794

    R2797, R2799, R2801, R2805

    R2789, R2790, R2793, R2795

    R2832, R2834, R2836, R2838

    R2833, R2835, R2837, R2839

  • Hi Sabeeh,

    We've tried with a brand new module, on which we didn't swapped R7 and R10. It worked using the newest driver (1.0.0.9) with the in-band irq. But the two previous ones are not functioning anymore and seems to have been damaged.

    We've made few changes on the kernel driver so it can compile on LTS 6.12, we've put it altogether in a patch i'm attaching in case you want to reproduce. 0004-Added-TI-cc33xx-driver-for-wifi-and-bluetooth-v1.0.0.patch.txt

    Regarding Bluetooth, I understand that we need to have debugFS in order to enable the interface? (hciconfig command doesn't return anything)

    0004-Added-TI-cc33xx-driver-for-wifi-and-bluetooth-v1.0.0.patch.txt

  • Hi John,

    Good to hear you were able to get it working.

    For bluetooth, you must first send the ble_enable command. This is done as such:

    ehco 1 > /sys/kernel/debug/ieee80211/phy0/cc33xx/ble_enable

    Then assuming the devicetree and BT_TI kernel modules are set correctly, then you would see an hci interface (via hciconfig -a).

  • Hi Sabeeh,

    So the two previous modules that don't work anymore could have been broken just because of the IRQ misconfiguration?

    Also, I find it odd to use debugFS to enable the Bluetooth interface, is there a more regular way ? I don't have support of debugfs in my kernel and I'd like to keep it lightweight and secure. 

  • Hi John,

    So the two previous modules that don't work anymore could have been broken just because of the IRQ misconfiguration?

    This is likely the issue, but it is difficult to say since i have not made this configuration change myself nor do I have your board. I would suggest to move back to the original resistors for the IRQ configuration. Perhaps you accidentally put 3.3V on this line from the M.2 card, which would cause damage.

    Also, I find it odd to use debugFS to enable the Bluetooth interface, is there a more regular way ?

    This is the way we enable BLE on the CC33xx. There is no other option.