[openwrt/openwrt] lantiq: xrx200: convert FritzBox 7360v2's wifi to nvmem
LEDE Commits
lede-commits at lists.infradead.org
Sun Mar 26 07:43:17 PDT 2023
chunkeey pushed a commit to openwrt/openwrt.git, branch master:
https://git.openwrt.org/c2d1c32d1ef7f2797aa424a6c94d143e9ddaddc8
commit c2d1c32d1ef7f2797aa424a6c94d143e9ddaddc8
Author: Christian Lamparter <chunkeey at gmail.com>
AuthorDate: Mon Mar 13 22:49:50 2023 +0100
lantiq: xrx200: convert FritzBox 7360v2's wifi to nvmem
this was thoroughly tested (warm and cold boots). on a
real 7360v2. This is because there have been documented
hick-ups with other lantiq devices that need the
owl-loader too.
It's likely that the 7360(sl) could be converted in the
same way as well. However the 7362sl uses a reversed
caldata format, so the "qca,no-eeprom" stays in place.
The patch also moves the urloader nvmem partition
definition into the partition section.
Signed-off-by: Christian Lamparter <chunkeey at gmail.com>
---
.../mips/boot/dts/lantiq/vr9_avm_fritz7360-v2.dts | 24 ++++++++++++++--------
.../mips/boot/dts/lantiq/vr9_avm_fritz736x.dtsi | 2 +-
.../etc/hotplug.d/firmware/12-ath9k-eeprom | 3 +--
3 files changed, 18 insertions(+), 11 deletions(-)
diff --git a/target/linux/lantiq/files/arch/mips/boot/dts/lantiq/vr9_avm_fritz7360-v2.dts b/target/linux/lantiq/files/arch/mips/boot/dts/lantiq/vr9_avm_fritz7360-v2.dts
index 063d6dca5e..a30746cde2 100644
--- a/target/linux/lantiq/files/arch/mips/boot/dts/lantiq/vr9_avm_fritz7360-v2.dts
+++ b/target/linux/lantiq/files/arch/mips/boot/dts/lantiq/vr9_avm_fritz7360-v2.dts
@@ -42,6 +42,18 @@
label = "urlader";
reg = <0x00000 0x20000>;
read-only;
+
+ compatible = "nvmem-cells";
+ #address-cells = <1>;
+ #size-cells = <1>;
+
+ cal_urlader_985: cal at 985 {
+ reg = <0x985 0x440>;
+ };
+
+ macaddr_urlader_a91: macaddr at a91 {
+ reg = <0xa91 0x6>;
+ };
};
partition at 20000 {
@@ -78,12 +90,8 @@
reset-gpios = <&gpio 44 GPIO_ACTIVE_LOW>;
};
-&urlader {
- compatible = "nvmem-cells";
- #address-cells = <1>;
- #size-cells = <1>;
-
- macaddr_urlader_a91: macaddr at a91 {
- reg = <0xa91 0x6>;
- };
+&wifi {
+ /delete-property/ qca,no-eeprom;
+ nvmem-cells = <&cal_urlader_985>;
+ nvmem-cell-names = "calibration";
};
diff --git a/target/linux/lantiq/files/arch/mips/boot/dts/lantiq/vr9_avm_fritz736x.dtsi b/target/linux/lantiq/files/arch/mips/boot/dts/lantiq/vr9_avm_fritz736x.dtsi
index 73f6e152bf..7324127d2a 100644
--- a/target/linux/lantiq/files/arch/mips/boot/dts/lantiq/vr9_avm_fritz736x.dtsi
+++ b/target/linux/lantiq/files/arch/mips/boot/dts/lantiq/vr9_avm_fritz736x.dtsi
@@ -151,7 +151,7 @@
#address-cells = <2>;
device_type = "pci";
- wifi at 168c,002e {
+ wifi: wifi at 168c,002e {
compatible = "pci168c,002e";
reg = <0 0 0 0 0>;
qca,no-eeprom; /* load from ath9k-eeprom-pci-0000:01:00.0.bin */
diff --git a/target/linux/lantiq/xrx200/base-files/etc/hotplug.d/firmware/12-ath9k-eeprom b/target/linux/lantiq/xrx200/base-files/etc/hotplug.d/firmware/12-ath9k-eeprom
index c6bacb8d3c..eefc39b30b 100644
--- a/target/linux/lantiq/xrx200/base-files/etc/hotplug.d/firmware/12-ath9k-eeprom
+++ b/target/linux/lantiq/xrx200/base-files/etc/hotplug.d/firmware/12-ath9k-eeprom
@@ -19,8 +19,7 @@ case "$FIRMWARE" in
avm,fritz3390)
caldata_extract_reverse "urlader" 0x2546 0x440
;;
- avm,fritz7360sl|\
- avm,fritz7360-v2)
+ avm,fritz7360sl)
caldata_extract "urlader" 0x985 0x1000
;;
avm,fritz7412|\
More information about the lede-commits
mailing list