ramips: fixes for Keenetic KN-1613,1711,1713,1910
authorAnton Yu. Ivanusev <ivanusevanton@yandex.ru>
Wed, 12 Feb 2025 05:59:50 +0000 (10:59 +0500)
committerHauke Mehrtens <hauke@hauke-m.de>
Sun, 16 Feb 2025 21:37:27 +0000 (22:37 +0100)
Fixed the 5G mac address on KN-1910, rolled back the image size to stock
(there are no errors with loading large images in version 24.10.0),
minor spelling errors.

Signed-off-by: Anton Yu. Ivanusev <ivanusevanton@yandex.ru>
Link: https://github.com/openwrt/openwrt/pull/17946
Signed-off-by: Hauke Mehrtens <hauke@hauke-m.de>
target/linux/ramips/dts/mt7628an_keenetic_kn-1711.dts
target/linux/ramips/dts/mt7628an_keenetic_kn-1713.dts
target/linux/ramips/image/mt7621.mk
target/linux/ramips/image/mt76x8.mk
target/linux/ramips/mt7621/base-files/etc/hotplug.d/ieee80211/10_fix_wifi_mac

index c0350eb49428fbb5e2018e9a34931f4716b6327a..80326a96288fd189501c4da9aecb1140a68f4adf 100644 (file)
                        gpios = <&gpio 38 GPIO_ACTIVE_LOW>;
                };
 
-               wifi2 {
+               fn {
                        function = LED_FUNCTION_WLAN_2GHZ;
                        color = <LED_COLOR_ID_GREEN>;
                        gpios = <&gpio 3 GPIO_ACTIVE_LOW>;
                        linux,default-trigger = "phy0tpt";
                };
 
-               wifi5 {
+               wifi {
                        function = LED_FUNCTION_WLAN_5GHZ;
                        color = <LED_COLOR_ID_GREEN>;
                        gpios = <&gpio 4 GPIO_ACTIVE_LOW>;
@@ -95,7 +95,7 @@
                        partition@0 {
                                compatible = "denx,uimage";
                                label = "firmware";
-                               reg = <0x0 0x1CC0000>;
+                               reg = <0x0 0x1cc0000>;
                        };
                };
        };
                                reg = <0x1050000 0xe60000>;
                        };
                        
-                       partition@1EB0000 {
+                       partition@1eb0000 {
                                label = "Config_2";
                                reg = <0x1eb0000 0x40000>;
                                read-only;
index 84127a88e042185d963d9dc658dc99d479df4394..52c5338345c9a2cf08c77494ee2c2e8f76f9a1fa 100644 (file)
                        gpios = <&gpio 38 GPIO_ACTIVE_LOW>;
                };
 
-               wifi2 {
+               fn {
                        function = LED_FUNCTION_WLAN_2GHZ;
                        color = <LED_COLOR_ID_GREEN>;
                        gpios = <&gpio 3 GPIO_ACTIVE_LOW>;
                        linux,default-trigger = "phy0tpt";
                };
 
-               wifi5 {
+               wifi {
                        function = LED_FUNCTION_WLAN_5GHZ;
                        color = <LED_COLOR_ID_GREEN>;
                        gpios = <&gpio 4 GPIO_ACTIVE_LOW>;
index a4e490cd196856de6081c6969f02374a0b4ada2e..d887374e260040dbd0f162bb449ff2dd4e3e0f5c 100755 (executable)
@@ -1804,7 +1804,7 @@ define Device/keenetic_kn-1910
   $(Device/uimage-lzma-loader)
   BLOCKSIZE := 128k
   PAGESIZE := 2048
-  IMAGE_SIZE := 20368588
+  IMAGE_SIZE := 29097984
   DEVICE_VENDOR := Keenetic
   DEVICE_MODEL := KN-1910
   DEVICE_PACKAGES := kmod-mt7615-firmware kmod-usb3
index a0dd48b8a670f9f01f4d8fc472aab31c1fc2b29e..9c1d4d6298854fcc14a02015dd2cda8f81edfdef 100644 (file)
@@ -356,7 +356,7 @@ endef
 TARGET_DEVICES += jotale_js76x8-32m
 
 define Device/keenetic_kn-1613
-  IMAGE_SIZE := 31488k
+  IMAGE_SIZE := 15073280
   DEVICE_VENDOR := Keenetic
   DEVICE_MODEL := KN-1613
   DEVICE_PACKAGES := kmod-mt7615e kmod-mt7663-firmware-ap
@@ -368,7 +368,7 @@ TARGET_DEVICES += keenetic_kn-1613
 
 define Device/keenetic_kn-1711
   BLOCKSIZE := 64k
-  IMAGE_SIZE := 10551296
+  IMAGE_SIZE := 15073280
   DEVICE_VENDOR := Keenetic
   DEVICE_MODEL := KN-1711
   DEVICE_PACKAGES := kmod-mt7615e kmod-mt7663-firmware-ap kmod-usb2
@@ -380,7 +380,7 @@ TARGET_DEVICES += keenetic_kn-1711
 
 define Device/keenetic_kn-1713
   BLOCKSIZE := 64k
-  IMAGE_SIZE := 10551296
+  IMAGE_SIZE := 15073280
   DEVICE_VENDOR := Keenetic
   DEVICE_MODEL := KN-1713
   DEVICE_PACKAGES := kmod-mt7615e kmod-mt7663-firmware-ap kmod-usb2
index 4a056623abc021b006413bbd0ad1abb501c5b677..16c5dfc09bd5d8cd75230227b7af93edcc7de271 100644 (file)
@@ -126,6 +126,11 @@ case "$board" in
                [ "$PHYNBR" = "1" ] && \
                        macaddr_setbit_la "$(mtd_get_mac_binary Factory 0x4)" > /sys${DEVPATH}/macaddress
                ;;
+       keenetic,kn-1910)
+               lan_mac_addr="$(mtd_get_mac_binary RF-EEPROM 0x4)"
+               [ "$PHYNBR" = "1" ] && \
+                       macaddr_add $lan_mac_addr 2 > /sys${DEVPATH}/macaddress
+               ;;
        keenetic,kn-3510)
                [ "$PHYNBR" = "1" ] && \
                        macaddr_setbit_la "$(mtd_get_mac_binary rf-eeprom 0x4)" > /sys${DEVPATH}/macaddress