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.

WL18XX Writing Magic Address Gives "Configuration Binary File Magic Number Mismatch"

Other Parts Discussed in Thread: WL1831

I have a clean wl18xx-conf.bin file in /lib/firmware/ti-connectivity/ that works great with my wl1831 module. I can associate with my router, download files from the internet, and everything works.

I am now trying to change the MAC address on the wlan0 device.

Reading the TI wiki, I should be able to unload the wl18xx / wlcore drivers and then do this:

/usr/bin/calibrator set nvs_mac /lib/firmware/ti-connectivity/wl18xx-conf.bin "$WIFI_MAC"

That command succeeds, and I can subsequently read back my new value with this command:

/usr/bin/calibrator get nvs_mac /lib/firmware/ti-connectivity/wl18xx-conf.bin

However, when I try to re-load the wireless modules to get a wlan0 device, it fails to load with this error:

wlcore: ERROR configuration binary file magic number mismatch, expected 0x10e100ca got 0xffe100ca

I traced the driver code down to this bit:

if (conf_file->header.magic != cpu_to_le32(WL18XX_CONF_MAGIC)) {
		wl1271_error("configuration binary file magic number mismatch, "
			     "expected 0x%0x got 0x%0x", WL18XX_CONF_MAGIC,
			     conf_file->header.magic);
		ret = -EINVAL;
		goto out;
	}

Why is this happening? How can I set the mac address and ensure the magic number is OK?

Thank you,

Phil

  • Hi Phil,

    Which wiki do you refer to? The correct page is: processors.wiki.ti.com/.../WL18xx_Writing_MAC_address
    The mac address needs to be written to "wl1271-nvs.bin" (and not wl18xx-conf.bin)

    Please use the below steps and let me know if it works.

    (1) ifconfig wlan0 down
    (2) rmmod wlcore_sdio
    (3) touch /lib/firmware/ti-connectivity/wl1271-nvs.bin
    (4) /usr/bin/calibrator set nvs_mac /lib/firmware/ti-connectivity/wl1271-nvs.bin 00:11:22:33:44:55
    [Writing mac address 00:11:22:33:44:55 to file /lib/firmware/ti-connectivity/wl1271-nvs.bin]
    (5) /usr/bin/calibrator get nvs_mac /lib/firmware/ti-connectivity/wl1271-nvs.bin
    [MAC addr from NVS: 00:11:22:33:44:55]
    (6) insmod /lib/modules/3.14.26-g2489c02/updates/drivers/net/wireless/ti/wlcore/wlcore_sdio.ko
    [
    wlcore: wl18xx HW: 183x or 180x, PG 2.2 (ROM 0x11)
    wlcore: loaded
    wlcore: driver version: ol_r8.a9.14
    wlcore: compilation time: Fri Apr 10 15:04:38 2015
    ]
    (7) ifconfig wlan0 up
    [
    wlcore: PHY firmware version: Rev 8.2.0.0.224
    wlcore: firmware booted (Rev 8.9.0.0.31)
    ]
    (8) ifconfig wlan0
    [
    wlan0 Link encap:Ethernet HWaddr 00:11:22:33:44:55
    UP BROADCAST MULTICAST MTU:1500 Metric:1
    RX packets:0 errors:0 dropped:0 overruns:0 frame:0
    TX packets:0 errors:0 dropped:0 overruns:0 carrier:0
    collisions:0 txqueuelen:1000
    RX bytes:0 (0.0 B) TX bytes:0 (0.0 B)
    ]

    Regards,
    Gigi Joseph.
  • Thanks for the clarification - this works.