How to enable sdhci3 for wifi module(TI wl1837) on Nano

When I connect wifi/bt device to my custom Nano SOM carrier board I am porting TI wl1837.
( [Nano product module SDIO] ---- [WL1837] )
I added below device tree sources.

sdhci@700b0400 { /* SDMMC3 for TI wifi */
	status = "okay";
	wlcore: wlcore@0 {
		compatible = "ti,wl1837";
		reg = <2>;
		interrupt-parent = <&gpio>;
		interrupts = <TEGRA_GPIO(Z, 0) IRQ_TYPE_LEVEL_HIGH>; /* GPIO_PZ0 */
		ref-clock-frequency = <32000>;
	};
};

and loaded device driver modules.

#modprobe wlcore_sdio
#modprobe wlcore
#modprobe wl18xx

But there is no wlan devices.

root@localhost:~# iwconfig
l4tbr0    no wireless extensions.

rndis0    no wireless extensions.

lo        no wireless extensions.

usb0      no wireless extensions.

eth0      no wireless extensions.

dummy0    no wireless extensions.

How to enable sdhci3 for wifi module(TI wl1837) on Nano?

@ksypassion

pls share the whole dmesg here. before that pls recompile the kernel with CONFIG_MMC_DEBUG=y.
and
remove the quiet from /boot/exlinux/extlinux.conf of the nano board.

Let’s check the sdio setup fist.

Thanks for your replay.

After recompiling the kernel with CONFIG_MMC_DEBUG=y, I flashed a new kernel.

There are a lot of messages, so I couldn’t save dmesg .

Too many logs ware output and couldn’t be saved.
So, only kernel log output through debug serial is attached.

---------------------------------------kernel log start-------------------------------------------------
Starting kernel …
[ 1.043186] tegradc tegradc.1: dpd enable lookup fail:-19
[ 1.554475] Host read timeout at address 545c00c4
[ 1.752525] imx219 7-0010: imx219_board_setup: error during i2c read probe (-121)
[ 1.760084] imx219 7-0010: board setup failed
[ 1.788424] imx219 8-0010: imx219_board_setup: error during i2c read probe (-121)
[ 1.795958] imx219 8-0010: board setup failed
[ 1.822006] sdhci: =========== REGISTER DUMP (mmc0)===========
[ 1.824024] sdhci: =========== REGISTER DUMP (mmc1)===========
[ 1.824033] sdhci: Sys addr: 0x00000000 | Version: 0x00000303
[ 1.824039] sdhci: Blk size: 0x00000000 | Blk cnt: 0x00000000
[ 1.824046] sdhci: Argument: 0x00000000 | Trn mode: 0x00000000
[ 1.824053] sdhci: Present: 0x01fb00f0 | Host ctl: 0x00000000
[ 1.824059] sdhci: Power: 0x00000000 | Blk gap: 0x00000000
[ 1.824065] sdhci: Wake-up: 0x00000000 | Clock: 0x00000000
[ 1.824072] sdhci: Timeout: 0x00000000 | Int stat: 0x00000000
[ 1.824078] sdhci: Int enab: 0x00ff1003 | Sig enab: 0x00fc1003
[ 1.824085] sdhci: AC12 err: 0x00000000 | Slot int: 0x00000000
[ 1.824091] sdhci: Caps: 0x376cd08c | Caps_1: 0x10006f77
[ 1.824098] sdhci: Cmd: 0x00000000 | Max curr: 0x00000000
[ 1.824101] sdhci: Host ctl2: 0x00003000
[ 1.824110] sdhci: ADMA Err: 0x00000000 | ADMA Ptr: 0x0000000000000000
[ 1.824244] sdhci: ===========================================
[ 1.915806] sdhci: Sys addr: 0x00000000 | Version: 0x00000303
[ 1.921740] sdhci: Blk size: 0x00000000 | Blk cnt: 0x00000000
[ 1.927608] sdhci: Argument: 0x00000000 | Trn mode: 0x00000000
[ 1.933463] sdhci: Present: 0x01fb00f0 | Host ctl: 0x00000000
[ 1.939323] sdhci: Power: 0x00000000 | Blk gap: 0x00000000
[ 1.945192] sdhci: Wake-up: 0x00000000 | Clock: 0x00000000
[ 1.951044] sdhci: Timeout: 0x00000000 | Int stat: 0x00000000
[ 1.956935] sdhci: Int enab: 0x00ff1003 | Sig enab: 0x00fc1003
[ 1.962869] sdhci: AC12 err: 0x00000000 | Slot int: 0x00000000
[ 1.968845] sdhci: Caps: 0x376cd08c | Caps_1: 0x10006f77
[ 1.974824] sdhci: Cmd: 0x00000000 | Max curr: 0x00000000
[ 1.980777] sdhci: Host ctl2: 0x00003000
[ 1.984845] sdhci: ADMA Err: 0x00000000 | ADMA Ptr: 0x0000000000000000
[ 1.985138] sdhci: ===========================================
[ 2.664646] cgroup: cgroup2: unknown option “nsdelegate”
[ 4.308508] using random self ethernet address
[ 4.329680] using random host ethernet address
[ 4.596886] random: crng init done
[ 4.600293] random: 7 urandom warning(s) missed due to ratelimiting
[ 5.036879] using random self ethernet address
[ 5.069505] using random host ethernet address

Ubuntu 18.04.4 LTS localhost ttyS0

---------------------------------------kernel log end-------------------------------------------------

You can try reboot the system without sdio card insert.

Then keep capturing the log and insert the sdio card. then share again.

or you can save all the logs captured from the uart.

In the same time you may find the familiar device tree node from the jetpack and compared with the spec from your card vendor.

I can’t remove sdio card(= wifi/bt module).

It’s on PCB so it’s impossible to insert/remove sdio card.

I attached kernel log.
(kernel_20200619.log (123.2 KB)

And I compared with the spec from wl1837.

Please review kernel log which I attached.

@alanz

Please review kernel log whtish I attached.

There is no update from you for a period, assuming this is not an issue any more.
Hence we are closing this topic. If need further support, please open a new one.
Thanks

@ksypassion

sorry to response late.

From the log, we can see they are all the information about the emmc(mmc0), Could you capture the log from uart from the begining? let’s see what happened during the sdio setup.