Skip to content

Commit

Permalink
Merge pull request #730 from Telecominfraproject/main
Browse files Browse the repository at this point in the history
RC2 changes
  • Loading branch information
jaspreetsachdev authored Sep 30, 2024
2 parents 81e38de + d2b6fc7 commit cb5b8a2
Show file tree
Hide file tree
Showing 148 changed files with 1,637 additions and 81 deletions.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
30 changes: 23 additions & 7 deletions feeds/ipq807x_v5.4/hostapd/files/mpskd
Original file line number Diff line number Diff line change
Expand Up @@ -9,8 +9,7 @@ let ubus = libubus.connect();
let interfaces = {};
let ssids = {};
let cache = {};
let sub_6g = [];
let sub_6g_obj;
let subs_hapd = [];
let reload_timer;
let gc_timer;

Expand Down Expand Up @@ -66,10 +65,9 @@ function event_cb(req) {
}

function create_6g_subscriber() {
for (let cur_sub in sub_6g)
for (let cur_sub in subs_hapd)
cur_sub.remove();
sub_6g = [];

subs_hapd = [];
for (let ifname, iface in interfaces) {
let obj = 'hostapd.' + ifname;
let cur_sub;
Expand All @@ -78,7 +76,7 @@ function create_6g_subscriber() {
else
cur_sub = ubus.subscriber((req) => event_cb(req));
cur_sub.subscribe(obj);
push(sub_6g, cur_sub);
push(subs_hapd, cur_sub);
printf(`subscribe ${ifname}\n`);
ubus.call(obj, 'notify_response', { notify_response: 1 });
}
Expand Down Expand Up @@ -314,12 +312,30 @@ let ubus_methods = {
return {
interfaces,
ssids,
cache
cache,
};
},
args: {
}
},
flush: {
call: function() {
for (let ssid, data in ssids) {
let band = '6g';
let iface = data.bands[band];
if (!iface)
continue;
let clients = ubus.call('hostapd.' + iface, 'get_clients');
for (let addr, client in clients.clients) {
if (!cache[ssid])
continue;
delete cache[ssid][addr];
ubus.call('hostapd.' + iface, 'del_client', { addr });
}
}
},
args: {}
},
};

reload_timer = uloop.timer(-1, () => { netifd_reload(); });
Expand Down
4 changes: 4 additions & 0 deletions feeds/ipq807x_v5.4/ipq50xx/base-files/etc/board.d/01_leds
Original file line number Diff line number Diff line change
Expand Up @@ -24,6 +24,10 @@ cybertan,eww631-a1|\
cybertan,eww631-b1)
ucidef_set_led_default "power" "POWER" "sys:blue" "on"
;;
sonicfi,rap630c-311g|\
sonicfi,rap630w-311g)
ucidef_set_led_default "power" "POWER" "pwm:blue" "on"
;;
edgecore,oap101|\
edgecore,oap101-6e|\
edgecore,oap101e|\
Expand Down
1 change: 1 addition & 0 deletions feeds/ipq807x_v5.4/ipq50xx/config-5.4
100644 → 100755
Original file line number Diff line number Diff line change
Expand Up @@ -1264,3 +1264,4 @@ CONFIG_PSTORE_PMSG=y
CONFIG_PSTORE_RAM=y
CONFIG_LEDS_TRIGGER_PATTERN=y
CONFIG_RTL8367C_PHY=y
CONFIG_LEDS_PWM=y
85 changes: 42 additions & 43 deletions feeds/ipq807x_v5.4/ipq50xx/files/arch/arm64/boot/dts/qcom/qcom-ipq5018-rap630c-311g.dts
100644 → 100755
Original file line number Diff line number Diff line change
Expand Up @@ -31,6 +31,8 @@
serial1 = &blsp1_uart2;
ethernet0 = "/soc/dp1";
ethernet1 = "/soc/dp2";

/* led-boot = &led_blue; */
};

chosen {
Expand Down Expand Up @@ -577,29 +579,59 @@
bias-pull-down;
};
};
leds_pins: leds_pinmux {
sys_blue {
pwm_pins: pwm_pinmux {
mux_1 {
pins = "gpio30";
function = "gpio";
function = "pwm3";
drive-strength = <8>;
bias-pull-up;
};
sys_red {
mux_2 {
pins = "gpio36";
function = "gpio";
function = "pwm1";
drive-strength = <8>;
bias-disable;
};
sys_green {
mux_3 {
pins = "gpio37";
function = "gpio";
function = "pwm2";
drive-strength = <8>;
bias-disable;
};
};
};

&soc {
pwm: pwm@0x1941010 {
used-pwm-indices = <0>, <1>, <1>, <1>;
pinctrl-0 = <&pwm_pins>;
pinctrl-names = "default";
#pwm-cells = <2>;
status = "ok";
};

/* Use PWM LED driver to control LED through PWM, make sure CONFIG_LEDS_PWM is enabled */
pwmleds {
compatible = "pwm-leds";

red {
label = "pwm:red";
pwms = <&pwm 1 1250000>;
max-brightness = <1>;
linux,default-trigger = "none";
};

green {
label = "pwm:green";
pwms = <&pwm 2 1250000>;
max-brightness = <1>;
linux,default-trigger = "none";
};

led_blue: blue {
label = "pwm:blue";
pwms = <&pwm 3 1250000>;
max-brightness = <1>;
linux,default-trigger = "timer";
};
};
gpio_keys {
compatible = "gpio-keys";
pinctrl-0 = <&button_pins>;
Expand All @@ -613,39 +645,6 @@
debounce-interval = <60>;
};
};
gpio_leds {
compatible = "gpio-leds";
pinctrl-0 = <&leds_pins>;
pinctrl-names = "default";

led@30 {
label = "sys:blue";
gpios = <&tlmm 30 GPIO_ACTIVE_HIGH>; /* GPIO_30 */
default-state="on";
/* linux,default-trigger = "timer";
active-delay = <700>;
inactive-delay = <700>;
default-state="on"; */
};
led@36 {
label = "sys:red";
gpios = <&tlmm 36 GPIO_ACTIVE_HIGH>; /* GPIO_36 */
default-state="off";
/* linux,default-trigger = "timer";
active-delay = <700>;
inactive-delay = <700>;
default-state="on"; */
};
led@37 {
label = "sys:green";
gpios = <&tlmm 37 GPIO_ACTIVE_HIGH>; /* GPIO_37 */
default-state="off";
/* linux,default-trigger = "timer";
active-delay = <700>;
inactive-delay = <700>;
default-state="on"; */
};
};

};

Expand Down
61 changes: 36 additions & 25 deletions feeds/ipq807x_v5.4/ipq50xx/files/arch/arm64/boot/dts/qcom/qcom-ipq5018-rap630w-311g.dts
100644 → 100755
Original file line number Diff line number Diff line change
Expand Up @@ -31,6 +31,8 @@
serial1 = &blsp1_uart2;
ethernet0 = "/soc/dp1";
ethernet1 = "/soc/dp2";

/* led-boot = &led_blue; */
};

chosen {
Expand Down Expand Up @@ -656,24 +658,21 @@
};
};

leds_pins: leds_pinmux {
sys_green {
pwm_pins: pwm_pinmux {
mux_1 {
pins = "gpio1";
function = "gpio";
function = "pwm1";
drive-strength = <8>;
bias-disable;
};
sys_blue {
mux_2 {
pins = "gpio30";
function = "gpio";
function = "pwm3";
drive-strength = <8>;
bias-pull-up;
};
sys_red {
mux_3 {
pins = "gpio46";
function = "gpio";
function = "pwm0";
drive-strength = <8>;
bias-disable;
};
};
};
Expand All @@ -693,25 +692,37 @@
};
};

gpio_leds {
compatible = "gpio-leds";
pinctrl-0 = <&leds_pins>;
pwm: pwm@0x1941010 {
pinctrl-0 = <&pwm_pins>;
pinctrl-names = "default";
used-pwm-indices = <1>, <1>, <0>, <1>;
#pwm-cells = <2>;
status = "ok";
};

led@1 {
label = "sys:green";
gpios = <&tlmm 1 GPIO_ACTIVE_HIGH>; /* GPIO_1/ATST_QP0 */
default-state="off";
/* Use PWM LED driver to control LED through PWM, make sure CONFIG_LEDS_PWM is enabled */
pwmleds {
compatible = "pwm-leds";

led_blue: blue {
label = "pwm:blue";
pwms = <&pwm 3 1250000>;
max-brightness = <1>;
linux,default-trigger = "timer";
};
led@30 {
label = "sys:blue";
gpios = <&tlmm 30 GPIO_ACTIVE_HIGH>; /* GPIO_30 */
default-state="on";

red {
label = "pwm:red";
pwms = <&pwm 0 1250000>;
max-brightness = <1>;
linux,default-trigger = "none";
};
led@46 {
label = "sys:red";
gpios = <&tlmm 46 GPIO_ACTIVE_HIGH>; /* GPIO_46 */
default-state="off";

green {
label = "pwm:green";
pwms = <&pwm 1 1250000>;
max-brightness = <1>;
linux,default-trigger = "none";
};
};
};
Expand Down
Original file line number Diff line number Diff line change
@@ -0,0 +1,69 @@
diff -Naur linux-5.4.164-qsdk-26349818b464f8c7b52d59ce73579d9f3dd6bd5d.orig/drivers/pinctrl/qcom/pinctrl-ipq5018.c linux-5.4.164-qsdk-26349818b464f8c7b52d59ce73579d9f3dd6bd5d/drivers/pinctrl/qcom/pinctrl-ipq5018.c
--- linux-5.4.164-qsdk-26349818b464f8c7b52d59ce73579d9f3dd6bd5d.orig/drivers/pinctrl/qcom/pinctrl-ipq5018.c 2022-10-04 01:02:19.000000000 +0800
+++ linux-5.4.164-qsdk-26349818b464f8c7b52d59ce73579d9f3dd6bd5d/drivers/pinctrl/qcom/pinctrl-ipq5018.c 2024-08-13 15:20:14.419427000 +0800
@@ -485,25 +485,25 @@
"gpio40",
};
static const char * const pwm0_groups[] = {
- "gpio42",
+ "gpio42", "gpio46",
};
static const char * const qdss_cti_trig_out_b0_groups[] = {
"gpio42",
};
static const char * const pwm1_groups[] = {
- "gpio43",
+ "gpio43", "gpio36", "gpio1",
};
static const char * const qdss_cti_trig_in_b0_groups[] = {
"gpio43",
};
static const char * const pwm2_groups[] = {
- "gpio44",
+ "gpio44", "gpio37",
};
static const char * const qdss_cti_trig_out_b1_groups[] = {
"gpio44",
};
static const char * const pwm3_groups[] = {
- "gpio45",
+ "gpio45", "gpio30",
};
static const char * const qdss_cti_trig_in_b1_groups[] = {
"gpio45",
@@ -613,7 +613,7 @@
};
static const struct msm_pingroup ipq5018_groups[] = {
PINGROUP(0, atest_char, _, qdss_cti_trig_out_a0, wci_txd, wci_rxd, xfem, _, _, _),
- PINGROUP(1, atest_char, _, qdss_cti_trig_in_a0, wci_txd, wci_rxd, xfem, _, _, _),
+ PINGROUP(1, atest_char, pwm1, qdss_cti_trig_in_a0, wci_txd, wci_rxd, xfem, _, _, _),
PINGROUP(2, atest_char, _, qdss_cti_trig_out_a1, wci_txd, wci_rxd, xfem, _, _, _),
PINGROUP(3, atest_char, _, qdss_cti_trig_in_a1, wci_txd, wci_rxd, xfem, _, _, _),
PINGROUP(4, sdc1_data, qspi_data, blsp1_spi1, btss, dbg_out, qdss_traceclk_a, _, burn0, _),
@@ -642,14 +642,14 @@
PINGROUP(27, audio_txmclk, wsa_swrm, audio_txmclk, blsp2_spi, btss, _, qdss_tracedata_b, _, _),
PINGROUP(28, audio_txbclk, wsa_swrm, blsp0_uart1, btss, qdss_tracedata_b, _, _, _, _),
PINGROUP(29, audio_txfsync, _, blsp0_uart1, _, qdss_tracedata_b, _, _, _, _),
- PINGROUP(30, audio_txd, led2, led0, _, _, _, _, _, _),
+ PINGROUP(30, audio_txd, led2, led0, pwm3, _, _, _, _, _),
PINGROUP(31, blsp2_spi0, blsp1_uart1, _, qdss_tracedata_b, eud_gpio, _, _, _, _),
PINGROUP(32, blsp2_spi0, blsp1_uart1, _, qdss_tracedata_b, eud_gpio, _, _, _, _),
PINGROUP(33, blsp2_i2c0, blsp2_spi0, blsp1_uart1, _, qdss_tracedata_b, eud_gpio, _, _, _),
PINGROUP(34, blsp2_i2c0, blsp2_spi0, blsp1_uart1, _, qdss_tracedata_b, eud_gpio, _, _, _),
PINGROUP(35, _, qdss_tracedata_b, eud_gpio, _, _, _, _, _, _),
- PINGROUP(36, mdc, qdss_tracedata_b, _, wsi_clk3, _, _, _, _, _),
- PINGROUP(37, mdio, atest_char, qdss_tracedata_b, _, wsi_data3, _, _, _, _),
+ PINGROUP(36, mdc, qdss_tracedata_b, pwm1, wsi_clk3, _, _, _, _, _),
+ PINGROUP(37, mdio, atest_char, qdss_tracedata_b, pwm2, wsi_data3, _, _, _, _),
PINGROUP(38, qdss_tracedata_b, _, _, _, _, _, _, _, _),
PINGROUP(39, qdss_traceclk_b, _, _, _, _, _, _, _, _),
PINGROUP(40, reset_out, qdss_tracectl_b, _, _, _, _, _, _, _),
@@ -658,7 +658,7 @@
PINGROUP(43, pwm1, qdss_cti_trig_in_b0, wci_txd, wci_rxd, xfem, _, _, _, _),
PINGROUP(44, pwm2, qdss_cti_trig_out_b1, wci_txd, wci_rxd, xfem, _, _, _, _),
PINGROUP(45, pwm3, qdss_cti_trig_in_b1, wci_txd, wci_rxd, xfem, _, _, _, _),
- PINGROUP(46, led0, _, _, _, _, _, _, _, _),
+ PINGROUP(46, led0, pwm0, _, _, _, _, _, _, _),
};

static const struct msm_pinctrl_soc_data ipq5018_pinctrl = {
2 changes: 1 addition & 1 deletion feeds/ipq807x_v5.4/wireguard/Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@ PKG_VERSION:=1.0.20211208
PKG_RELEASE:=1

PKG_SOURCE:=wireguard-linux-compat-$(PKG_VERSION).tar.xz
PKG_SOURCE_URL:=https://git.zx2c4.com/wireguard-linux-compat/snapshot/
PKG_SOURCE_URL:=https://ucentral.io/
PKG_HASH:=c0e607138a17daac656f508d8e63ea3737b5221fa5d9288191ddeb099f5a3b92

PKG_LICENSE:=GPL-2.0
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -152,7 +152,7 @@
bias-pull-down;
};
};*/

spi_2_pins: spi-2-pins {
pins = "gpio33", "gpio34", "gpio35", "gpio36";
function = "blsp2_spi0";
Expand Down Expand Up @@ -349,15 +349,15 @@
pinctrl-names = "default";
status = "ok";
};

spi@78b5000 {
pinctrl-0 = <&spi_0_pins>;
pinctrl-names = "default";
cs-select = <0>;
status = "ok";

m25p80@0 {
compatible = "mx25u12835f";
compatible = "n25q128a11";
#address-cells = <1>;
#size-cells = <1>;
reg = <0>;
Expand Down
Loading

0 comments on commit cb5b8a2

Please sign in to comment.