fixed leds, fixed few other integration related stuff

This commit is contained in:
mooleshacat 2026-07-08 00:24:35 -04:00
parent 20441025f0
commit 5bb170a056
Signed by: mooleshacat
GPG Key ID: 6F42FE1A481818C2
3 changed files with 87 additions and 72 deletions

View File

@ -133,6 +133,12 @@ sony,ncp-hg100-cellular)
ucidef_set_led_netdev "wan" "WAN" "green:wan" "wan"
ucidef_set_led_netdev "wwan" "WWAN" "green:wan-4" "wwan0"
;;
trendnet,tew829dru)
ucidef_set_led_wlan "wlan5g1" "WLAN5G1" "ath10k-phy0" "phy0tpt"
ucidef_set_led_wlan "wlan2g4" "WLAN2G4" "tew829dru:blue:2g4" "phy1tpt"
ucidef_set_led_wlan "wlan5g2" "WLAN5G2" "tew829dru:blue:5g2" "phy2tpt"
ucidef_set_led_default "wps" "WPS" "tew829dru:blue:wps" "0"
;;
zyxel,nbg6617|\
zyxel,wre6606)
ucidef_set_led_wlan "wlan2g" "WLAN2G" "green:wlan2g" "phy0tpt"

View File

@ -125,9 +125,6 @@ ipq40xx_setup_interfaces()
plasmacloud,pa2200)
ucidef_set_interfaces_lan_wan "ethernet1" "ethernet2"
;;
trendnet,tew-829dru)
ucidef_set_interfaces_lan_wan "lan1 lan2 lan3 lan4 lan5 lan6 lan7 lan8" "wan1 wan2"
;;
qxwlan,e2600ac-c1)
ucidef_set_interfaces_lan_wan "sw-eth1" "sw-eth2"
;;
@ -137,6 +134,9 @@ ipq40xx_setup_interfaces()
skspruce,wia3300-20)
ucidef_set_interfaces_lan_wan "ETH2" "ETH1"
;;
trendnet,tew-829dru)
ucidef_set_interfaces_lan_wan "lan1 lan2 lan3 lan4 lan5 lan6 lan7 lan8" "wan1 wan2"
;;
zte,mf286d)
ucidef_set_interfaces_lan_wan "lan2 lan3 lan4" "wan"
;;

View File

@ -4,7 +4,7 @@
/*
* What is working?
*
*
* - UART
* - CPU
* - RAM
@ -13,15 +13,13 @@
* - 128MB nand (Micron MT29F1G08ABADA NAND 128MB // 2x kernel, 2x rootfs, 1x rootfs_data)
* - wifi (QCA9984, QCA4019)
* - switches (QCA8075, QCA8337)
* - LEDs (will resolve last :P)
*
* What is NOT working?
*
* - LEDs (will resolve last :P)
*
* - possible reset button
* - proper install/sysupgrade integration
*
* WARNING: ENSURE BOARD.BIN AND CALDATA IS NOT COMMITTED TO GIT REPOSITORY (INTELLECTUAL PROPERTY CONCERNS)
*
* NOTICE: THIS DTS DESCRIBES THE OPTIMAL CONFIGURATION FOR MAXIMUM HARDWARE FREEDOM :3
*
*/
@ -50,8 +48,68 @@
mtd7 = &art_part;
mtd8 = &rootfs_part;
};
gpio-keys {
compatible = "gpio-keys";
reset {
label = "reset";
gpios = <&tlmm 18 GPIO_ACTIVE_LOW>;
linux,code = <KEY_RESTART>;
};
};
regulators {
compatible = "simple-bus";
usb_power: usb-power-enable {
compatible = "regulator-fixed";
regulator-name = "usb-power-enable";
gpio = <&tlmm 48 GPIO_ACTIVE_HIGH>;
enable-active-high;
regulator-always-on;
regulator-boot-on;
};
};
leds {
compatible = "gpio-leds";
led_2g4: led-2g4 {
label = "tew829dru:blue:2g4";
gpios = <&tlmm 49 GPIO_ACTIVE_LOW>;
linux,default-trigger = "phy0tpt";
default-state = "off";
};
/* MISSING - claimed by qca8k, dont need it */
/*led_5g1: led-5g1 {
label = "tew829dru:blue:5g1";
gpios = <&tlmm ??? GPIO_ACTIVE_LOW>; //temporary - FILL IN GPIO WHEN FOUND!
default-state = "off";
};*/
led_5g2: led-5g2 {
label = "tew829dru:blue:5g2";
gpios = <&tlmm 45 GPIO_ACTIVE_LOW>;
linux,default-trigger = "phy1tpt";
default-state = "off";
};
led_wps: led-wps {
label = "tew829dru:blue:wps";
gpios = <&tlmm 50 GPIO_ACTIVE_LOW>;
default-state = "off";
};
}; /* end of leds */
}; /* end of root block */
/* ============================================================
* EDMA — dual conduit netdev for side-by-side DSA.
* eth0 (netdev) -> QCA8075 DSA tree 0
@ -77,6 +135,8 @@
};
/* ============================================================
* TOP SWITCH: QCA8075 (internal ESS, PSGMII, at 0xc000000)
* compatible = "qca,ipq4019-qca8337n" — confirmed by extracted DTS.
@ -154,6 +214,8 @@
}; /* end of &switch */
/* ============================================================
* MDIO bus — QCA8075 PHY package + QCA8337 external switch.
* gpio52 = MDC, gpio53 = MDIO — confirmed by extracted DTS.
@ -265,6 +327,9 @@
};
}; /* end of &mdio */
/* 8MB FLASH CHIP (Macronix MX25L6433F SPI NOR 8MB) */
&blsp1_spi1 {
@ -341,6 +406,9 @@
};
/* end of &blsp1_spi1 (Macronix MX25L6433F SPI NOR 8MB) */
/* start of &qpic_bam (for Micron MT29F1G08ABADA NAND 128MB) */
&qpic_bam {
status = "okay";
@ -424,14 +492,6 @@
function = "qpic";
};
/* Add GPIO Hog for USB Power */
usb_power_en: usb-power-en {
gpio-hog;
gpios = <48 GPIO_ACTIVE_HIGH>;
output-high;
line-name = "usb-power-enable";
};
mdio_pins: mdio_pinmux {
pinmux_1 {
pins = "gpio53";
@ -463,20 +523,6 @@
bias-disable;
};
led0_pins: led0_pinmux {
mux_1 {
pins = "gpio36";
function = "led0";
bias-pull-down;
};
mux_2 {
pins = "gpio40";
function = "led4";
bias-pull-down;
};
};
uart1_pins: uart1_pinmux {
mux {
pins = "gpio8", "gpio9", "gpio10", "gpio11";
@ -493,6 +539,7 @@
};
};
/* needed for ath10k / PCIe WiFi */
i2c_0_pinmux: i2c_0_pinmux {
mux {
pins = "gpio20", "gpio21";
@ -549,8 +596,6 @@
/* QCA4019 2GHZ */
&wifi0 {
status = "okay";
@ -580,6 +625,7 @@
ranges;
wifi@0,0 {
status = "okay";
compatible = "qcom,ath10k";
reg = <0x00010000 0 0 0 0>;
nvmem-cells = <&caldata_art_9000>;
@ -588,6 +634,9 @@
};
};
/* ART data / caldata for wifi */
&art_part {
compatible = "nvmem-cells";
@ -613,43 +662,3 @@
reg = <0x9000 0x2f20>;
};
};
/*
LED TODO:
- Probe GPIOs
- Add DTS config for LEDs
*/