Other Parts Discussed in Thread: WL1837, MIO, WL1271
Tool/software: Linux
Hello.
I'm trying to integrate WL1837MODCOM8I module on AVNET UltraZed board.
My kernel version is 4.9.0-xilinx-v2017.2
I use petalinux 2017.2 tools to build and obtain image.ub and BOOT.BIN to load on the board.
In order to integrate WL1837MODCOM8I on the board i've done the following steps:
I've enabled all these features on the kernel
# Need for PLT calibration modes
CONFIG_NL80211_TESTMODE=y
# MAC 80211
CONFIG_WLAN=y
CONFIG_WIRELESS=y
CONFIG_WIRELESS_EXT=y
CONFIG_WL12XX_PLATFORM_DATA=y
CONFIG_KEYS=y
CONFIG_SECURITY=y
CONFIG_CRYPTO=y
CONFIG_CRYPTO_ARC4=y
CONFIG_CRYPTO_ECB=y
CONFIG_CRYPTO_AES=y
CONFIG_CRYPTO_MICHAEL_MIC=y
CONFIG_CRYPTO_RNG=y
CONFIG_CRYPTO_AEAD=y
CONFIG_CRYPTO_CCM=y
CONFIG_CRYPTO_GCM=y
I've modified the system-user.dtsi file, in order to add on global system-top.dts (main device-tree), the wifi entry. System-user.dtsi is
/include/ "system-conf.dtsi"
#include <dt-bindings/phy/phy.h>
/ {
model = "Avnet UltraZed-3EG";
chosen {
bootargs = "earlycon clk_ignore_unused earlyprintk uio_pdrv_genirq.of_id=xlnx,generic-uio cma=1024M";
};
//memory {
// device_type = "memory";
// reg = <0 0 0 0x80000000>, <0x8 0 0 0x80000000>;
//};
wlcore {
compatible = "ti,wl1837";
interrupt-parent = <0x4>;
irq = <0x0>;
platform-quirks = <0x1>;
board-ref-clock = <0x4>;
};
wlan_en: fixedregulator@1 {
compatible = "regulator-fixed";
regulator-name = "wlan-en-regulator";
regulator-min-microvolt = <0x325aa0>;
regulator-max-microvolt = <0x325aa0>;
gpio = <0x4 0x9 0x4>;
startup-delay-us = <0x11170>;
enable-active-high;
linux,phandle = <0x6>;
phandle = <0x6>;
};
};
/*
* from Avnet UZ3EG + IOCC
*/
/* production silicon */
&gem3 {
status = "okay";
local-mac-address = [00 0a 35 00 02 90];
phy-mode = "rgmii-id";
phy-handle = <&phy0>;
phy0: phy@9 {
reg = <0x9>;
ti,rx-internal-delay = <0x5>;
ti,tx-internal-delay = <0x5>;
ti,fifo-depth = <0x1>;
};
};
/* ES1 silicon */
//&gem3 {
// status = "okay";
// local-mac-address = [00 0a 35 00 02 90];
// phy-mode = "rgmii-id";
// phy-handle = <&phy0>;
// phy0: phy@5 {
// reg = <0x5>;
// ti,rx-internal-delay = <0x5>;
// ti,tx-internal-delay = <0x5>;
// ti,fifo-depth = <0x1>;
// };
//};
&i2c1 {
status = "okay";
clock-frequency = <400000>;
i2cswitch@70 { /* u7 */
compatible = "nxp,pca9543";
#address-cells = <1>;
#size-cells = <0>;
reg = <0x70>;
i2c@0 { /* i2c mw 70 0 1 */
#address-cells = <1>;
#size-cells = <0>;
reg = <0>;
eeprom: eeprom1@50 { /* 2048-bit (8-bit X 256) IIC_EEPROM - SOM U8 */
compatible = "at,24c02";
reg = <0x50>;
};
macid: eeprom2@51 { /* IIC_MAC_ID - IOCC U5 */
compatible = "at,24mac402";
reg = <0x51>;
};
idt5901: clock-generator@6a { /* IDT 5P49V5935 clock generator - IOCC U1 */
#clock-cells = <0>;
compatible = "idt,idt5901";
reg = <0x6a>;
input-freq = <25000000>;
clk-freq = <75000000>;
output-num = <4>;
};
};
i2c@1 { /* i2c mw 70 0 2 */
#address-cells = <1>;
#size-cells = <0>;
reg = <1>;
/* SMBUS */
};
};
};
&qspi {
#address-cells = <1>;
#size-cells = <0>;
status = "okay";
flash0: flash@0 {
compatible = "micron,n25q256a"; /* 32MB */
#address-cells = <1>;
#size-cells = <1>;
reg = <0x0>;
spi-tx-bus-width = <1>;
spi-rx-bus-width = <4>; /* FIXME also DUAL configuration possible */
spi-max-frequency = <108000000>; /* Based on DC1 spec */
partition@qspi-boot {
label = "qspi-boot";
reg = <0x0 0x780000>;
};
partition@qspi-bootenv {
label = "qspi-bootenv";
reg = <0x780000 0x80000>;
};
partition@qspi-linux {
label = "qspi-linux";
reg = <0x800000 0x3800000>;
};
};
};
/* SD0 eMMC, 8-bit wide data bus */
//&sdhci0 {
// status = "okay";
// bus-width = <8>;
// max-frequency = <50000000>;
//};
//&sdhci0 {
// status = "okay";
// bus-width = <8>;
// clock-frequency = <199998006>;
// max-frequency = <50000000>;
//};
/* SD1 with level shifter */
//&sdhci1 {
// status = "okay";
// max-frequency = <50000000>;
// no-1-8-v; /* for 1.0 silicon */
//};
&sdhci1 {
status = "okay";
no-1-8-v; /* for 1.0 silicon */
xlnx,mio_bank = <1>;
};
//&gpio0 {
// interrupt-controller;
// #interrupt-cells=<2>;
//};
&sdhci0 {
status = "okay";
vmmc-supply = <&wlan_en>;
bus-width = <4>;
ti,non-removable;
ti,needs-special-hs-handling;
cap-power-off-card;
keep-power-in-suspend;
#address-cells = <1>;
#size-cells = <0>;
wlcore: wlcore@0 {
compatible = "ti,wl1837";
interrupt-parent = <0x4>;
interrupts = <0 4>;
reg = <2>;
platform-quirks = <0x1>;
board-ref-clock = <0x4>;
};
};
/* ULPI SMSC USB3320 */
&usb0 {
status = "okay";
};
&dwc3_0 {
status = "okay";
dr_mode = "host";
phy-names = "usb3-phy";
};
/*
* Display Port Configuration
*/
&xilinx_drm {
status = "okay";
clocks = <&idt5901>;
xlnx,vid-clk-pl;
planes {
xlnx,pixel-format = "argb8888";
};
};
&xlnx_dp {
status = "okay";
phy-names = "dp-phy0", "dp-phy1";
phys = <&lane3 PHY_TYPE_DP 0 3 27000000>, <&lane2 PHY_TYPE_DP 1 3 27000000>;
};
&xlnx_dp_sub {
status = "okay";
xlnx,vid-clk-pl;
xlnx,gfx-fmt = "argb8888";
};
&xlnx_dp_snd_card {
status = "okay";
};
&xlnx_dp_snd_codec0 {
status = "okay";
};
&xlnx_dp_snd_pcm0 {
status = "okay";
};
&xlnx_dp_snd_pcm1 {
status = "okay";
};
&xlnx_dpdma {
status = "okay";
};
//&pss_ref_clk {
// clock-frequency = <33330000>;
//};
//&amba {
// ddr_qos@fd090000 {
// compatible = "xlnx,generic-uio";
// reg = <0 0xfd090000 0 0x1000>;
// };
//
// afifm@fd360000 {
// compatible = "xlnx,generic-uio";
// reg = <0 0xfd360000 0 0x1000>;
// };
//
// afifm@fd370000 {
// compatible = "xlnx,generic-uio";
// reg = <0 0xfd370000 0 0x1000>;
// };
//
// afifm@fd380000 {
// compatible = "xlnx,generic-uio";
// reg = <0 0xfd380000 0 0x1000>;
// };
//
// afifm@fd390000 {
// compatible = "xlnx,generic-uio";
// reg = <0 0xfd390000 0 0x1000>;
// };
//
// afifm@fd3a0000 {
// compatible = "xlnx,generic-uio";
// reg = <0 0xfd3a0000 0 0x1000>;
// };
//
// afifm@fd3b0000 {
// compatible = "xlnx,generic-uio";
// reg = <0 0xfd3b0000 0 0x1000>;
// };
//
// afifm@fd9b0000 {
// compatible = "xlnx,generic-uio";
// reg = <0 0xfd9b0000 0 0x1000>;
// };
//};
//&uart1 {
// status = "disabled";
//};
When the board starts doing ifconfig-a i'm not able to see wlan0 interface and obviously doing ifconfig wlan0 up kernel says "No such device"
On proc file /sys/firmware/devicetree/base/wlcore i see the following folder
board-ref-clock compatible interrupt-parent irq name platform-quirks
cat of compatible gives me ti,wl1837
So it seems that kernel recognize correctly wifi tree
What's wrong?, What's missing? Whi i'm not able to see interface wlan0
Do i need to integrate wlconf on my project or this was just for old kernel
Hope i receive your suggestions soon
Thanks in advance
Regards
Alessandro