ath79: convert Araknis AN-300-AP-I-N WiFis to nvmem-cells
authorNick Hainke <vincent@systemli.org>
Thu, 15 Dec 2022 08:20:22 +0000 (09:20 +0100)
committerChristian Lamparter <chunkeey@gmail.com>
Thu, 15 Dec 2022 14:08:08 +0000 (15:08 +0100)
Pull the calibration data from the nvmem subsystem. This allows us to
move userspace caldata extraction into the device-tree definition.

Signed-off-by: Nick Hainke <vincent@systemli.org>
target/linux/ath79/dts/ar9344_araknis_an-300-ap-i-n.dts
target/linux/ath79/generic/base-files/etc/hotplug.d/firmware/10-ath9k-eeprom

index a886b4c0010f69e770a4d62687d88e6047cacc21..07dc8da506313c29657be6b462d756bc3907b3be 100644 (file)
        ath9k: wifi@0,0,0 {
                compatible = "pci168c,0030";
                reg = <0x0 0 0 0 0>;
-               nvmem-cells = <&macaddr_art_0>;
-               nvmem-cell-names = "mac-address";
+               nvmem-cells = <&macaddr_art_0>, <&calibration_art_5000>;
+               nvmem-cell-names = "mac-address", "calibration";
                mac-address-increment = <1>;
                qca,disable-5ghz;
-               qca,no-eeprom;
                #gpio-cells = <2>;
                gpio-controller;
        };
 
        qca,disable-2ghz;
 
-       mtd-cal-data = <&art 0x1000>;
-
-       nvmem-cells = <&macaddr_art_0>;
-       nvmem-cell-names = "mac-address";
+       nvmem-cells = <&macaddr_art_0>, <&calibration_art_1000>;
+       nvmem-cell-names = "mac-address", "calibration";
        mac-address-increment = <2>;
 };
 
        macaddr_art_0: macaddr@0 {
                reg = <0x0 0x6>;
        };
+
+       calibration_art_1000: calibration@1000 {
+               reg = <0x1000 0x440>;
+       };
+
+       calibration_art_5000: calibration@5000 {
+               reg = <0x5000 0x440>;
+       };
 };
index d6d5b257ffeb1bdb53a90f21d40d921aaa9934df..52f015ed5fd9e14be1c6349287f45f192b36d1b3 100644 (file)
@@ -83,7 +83,6 @@ case "$FIRMWARE" in
        ;;
 "ath9k-eeprom-pci-0000:00:00.0.bin")
        case $board in
-       araknis,an-300-ap-i-n|\
        atheros,db120|\
        engenius,eap600|\
        engenius,ecb600|\