SIlabs WF200 Wifi SoC driver port

Hi, I'm busy with a Driver port of the WFX-linux-driver of the WF200 to Openwrt .
its a new-ish SPI / MMC Wifi Co-Processor ( similar to ath9k-htc ) from SiliconLabs
Info page : WF200

WF111 or another one in the family with BLE and Wifi is also of interest but I only Have WF200 devices at the moment...

I have managed to compile the kernel module (wfx.ko) and install it and the firmware files ( ...pds and ...sec ) to a OpenWRT device ( based on Beaglebone Black ( AM335x ) )

When it loads it reports errors / warnings on unknown symbols.

logread | grep wfx
Sat Jan  1 00:01:19 2000 kern.warn kernel: [   78.105416] wfx: Unknown symbol cfg80211_find_ie_match (err 0)
Sat Jan  1 00:01:19 2000 kern.warn kernel: [   78.111885] wfx: Unknown symbol ieee80211_bss_get_ie (err 0)
Sat Jan  1 00:01:19 2000 kern.warn kernel: [   78.130204] wfx: Unknown symbol cfg80211_find_ie_match (err 0)
Sat Jan  1 00:01:19 2000 kern.warn kernel: [   78.136819] wfx: Unknown symbol ieee80211_bss_get_ie (err 0)
Sat Jan  1 00:01:19 2000 user.err kernel: [   78.152982] kmodloader: - wfx - 0

There were a LOT more of them until I added a dependency rule for Openwrt's build to mac80211, these are the last 2 remaining and I'm not sure which call to the mac80211 / nl80211 functions is causing it ( could it be a version mismatch between the Openwrt and Linux Trunk nl80211 / mac80211 ? )

Here is my Github repo with the modified makefiles ( to be compatible with Openwrt's build system )

in my build system I have :
wf200 placed under "openwrt/package/firmware/"
wfx placed under "openwrt/package/kernel/"

Openwrt Master

  • Linux OpenWrt 4.14.151 armv7l GNU/Linux
  • Target System (TI OMAP3/4/AM33xx)
  • Target Profile (Texas Instruments AM335x BeagleBone Black)

relevant DTS entry for the spi device :

spi@481a0000 {
			compatible = "ti,omap4-mcspi";
			#address-cells = < 0x01 >;
			#size-cells = < 0x00 >;
			reg = < 0x481a0000 0x400 >;
			interrupts = < 0x7d >;
			ti,spi-num-cs = < 0x02 >;
			ti,hwmods = "spi1";
			dmas = < 0x2b 0x2a 0x00 0x2b 0x2b 0x00 0x2b 0x2c 0x00 0x2b 0x2d 0x00 >;
			dma-names = "tx0\0rx0\0tx1\0rx1";
			status = "okay";
			pinctrl-names = "default";
			pinctrl-0 = <&wfx_spi1_pins>;
			//ti,pio_mode; /*disable DMA  when used in overlay, DMA gets stuck at 160 bits...*/

	     		wfx: spidev@0 {
				reg = <0>;
				status = "okay";
				spi-max-frequency = <20000000>; /* BBB max is 48MHz*/
				
				// "silabs,wfx-spi" is mandatory.
				// Append "spidev" to be able to also use spidev driver

				compatible = "silabs,wfx-spi","linux,spidev";
				pinctrl-names = "default";
				pinctrl-0 = <&wfx_irq &wfx_gpios>;

				interrupts-extended = <0x20 19 1>;
				wakeup-gpios = <0x37 17 0>;
				reset-gpios = <0x20 21 0>;
				local-mac-address = [de ad be ef ed 01];
	    		};
		};

Does anyone have any ideas ?

-Daniel

I'm on a mobile device at the moment and can't really check the packaging right now. But based on your error messages, it looks that you either built against the in-kernel cfg80211/ nl80211 subsystem (while OpenWrt uses an backported mac80211 stack instead) or forgot to load some required kernel modules. Have a look at the packaging fir ath10k-ct, mwlwifi or mt76 for examples of how to integrate with the mac80211 backport package.

2 Likes

Hi @slh,
That did the trick , Thank you for the suggestion ( using backports ).
It works now :slight_smile:
Getting it into simultaneous AP /STA mode is tricky ( set up STA first , then create AP ) and interfaces MUST be called wlan0 and wlan1 ( driver doesn't seem to like wlan0 and wlan0-1 ) - might be me or the driver..

wlan0     Link encap:Ethernet  HWaddr 08:xx:xx:xx:xx:xx
          inet addr:192.168.0.74  Bcast:192.168.0.255  Mask:255.255.255.0
          inet6 addr: fe80::0000:0000:0000:0000/64 Scope:Link
          UP BROADCAST RUNNING MULTICAST  MTU:1500  Metric:1
          RX packets:209 errors:0 dropped:1 overruns:0 frame:0
          TX packets:11 errors:0 dropped:0 overruns:0 carrier:0
          collisions:0 txqueuelen:1000
          RX bytes:50936 (49.7 KiB)  TX bytes:1901 (1.8 KiB)

wlan1     Link encap:Ethernet  HWaddr 08:xx:xx:xx:xx:xx
          inet6 addr:  fe80::0000:0000:0000:0000/64 Scope:Link
          UP BROADCAST RUNNING MULTICAST  MTU:1500  Metric:1
          RX packets:334 errors:0 dropped:0 overruns:0 frame:0
          TX packets:624 errors:0 dropped:0 overruns:0 carrier:0
          collisions:0 txqueuelen:1000
          RX bytes:31972 (31.2 KiB)  TX bytes:150214 (146.6 KiB)

1 Like

This topic was automatically closed 10 days after the last reply. New replies are no longer allowed.