Skip to content

Commit

Permalink
lantiq: use nvmem for tplink tdw89x0
Browse files Browse the repository at this point in the history
These two devices use different wifi chips and as a result, different
calibration sizes. Move the differences out of dtsi.

Signed-off-by: Rosen Penev <[email protected]>
Link: openwrt/openwrt#16555
Signed-off-by: Robert Marko <[email protected]>
  • Loading branch information
neheb authored and robimarko committed Dec 27, 2024
1 parent 54cb64c commit 4348ed9
Show file tree
Hide file tree
Showing 4 changed files with 27 additions and 30 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -4,3 +4,15 @@
compatible = "tplink,tdw8970", "tplink,tdw89x0", "lantiq,xway", "lantiq,vr9";
model = "TP-LINK TD-W8970";
};

&boardconfig {
cal_boardconfig_21000: calibration@21000 {
reg = <0x21000 0x440>;
};
};

&ath9k {
compatible = "pci168c,0030";
nvmem-cells = <&macaddr_ath9k_cal_f100 2>, <&cal_boardconfig_21000>;
nvmem-cell-names = "mac-address", "calibration";
};
Original file line number Diff line number Diff line change
Expand Up @@ -27,3 +27,15 @@

reset-gpios = <&gpio 21 GPIO_ACTIVE_LOW>;
};

&boardconfig {
cal_boardconfig_21000: calibration@21000 {
reg = <0x21000 0x3d8>;
};
};

&ath9k {
compatible = "pci168c,002e";
nvmem-cells = <&macaddr_ath9k_cal_f100 2>, <&cal_boardconfig_21000>;
nvmem-cell-names = "mac-address", "calibration";
};
Original file line number Diff line number Diff line change
Expand Up @@ -200,15 +200,11 @@
#address-cells = <3>;
device_type = "pci";

ath9k: wifi@168c,002e {
compatible = "pci168c,002e";
ath9k: wifi@0,0 {
reg = <0 0 0 0 0>;
#gpio-cells = <2>;
gpio-controller;
qca,no-eeprom;
ieee80211-freq-limit = <2402000 2482000>;
nvmem-cells = <&macaddr_ath9k_cal_f100 2>;
nvmem-cell-names = "mac-address";
};
};
};
Expand Down Expand Up @@ -244,12 +240,12 @@
read-only;
};

ath9k_cal: partition@7d0000 {
partition@7d0000 {
reg = <0x7d0000 0x30000>;
label = "boardconfig";
read-only;

nvmem-layout {
boardconfig: nvmem-layout {
compatible = "fixed-layout";
#address-cells = <1>;
#size-cells = <1>;
Expand Down

This file was deleted.

0 comments on commit 4348ed9

Please sign in to comment.