mirror of
https://github.com/Telecominfraproject/wlan-ap.git
synced 2025-12-21 19:31:55 +00:00
Some checks failed
Build OpenWrt/uCentral images / build (cig_wf186h) (push) Has been cancelled
Build OpenWrt/uCentral images / build (cig_wf186w) (push) Has been cancelled
Build OpenWrt/uCentral images / build (cig_wf188n) (push) Has been cancelled
Build OpenWrt/uCentral images / build (cig_wf189) (push) Has been cancelled
Build OpenWrt/uCentral images / build (cig_wf196) (push) Has been cancelled
Build OpenWrt/uCentral images / build (cybertan_eww631-a1) (push) Has been cancelled
Build OpenWrt/uCentral images / build (cybertan_eww631-b1) (push) Has been cancelled
Build OpenWrt/uCentral images / build (edgecore_eap101) (push) Has been cancelled
Build OpenWrt/uCentral images / build (edgecore_eap102) (push) Has been cancelled
Build OpenWrt/uCentral images / build (edgecore_eap104) (push) Has been cancelled
Build OpenWrt/uCentral images / build (edgecore_eap105) (push) Has been cancelled
Build OpenWrt/uCentral images / build (edgecore_eap111) (push) Has been cancelled
Build OpenWrt/uCentral images / build (edgecore_eap112) (push) Has been cancelled
Build OpenWrt/uCentral images / build (edgecore_oap101) (push) Has been cancelled
Build OpenWrt/uCentral images / build (edgecore_oap101-6e) (push) Has been cancelled
Build OpenWrt/uCentral images / build (edgecore_oap101e) (push) Has been cancelled
Build OpenWrt/uCentral images / build (edgecore_oap101e-6e) (push) Has been cancelled
Build OpenWrt/uCentral images / build (hfcl_ion4x) (push) Has been cancelled
Build OpenWrt/uCentral images / build (hfcl_ion4x_2) (push) Has been cancelled
Build OpenWrt/uCentral images / build (hfcl_ion4x_3) (push) Has been cancelled
Build OpenWrt/uCentral images / build (hfcl_ion4x_w) (push) Has been cancelled
Build OpenWrt/uCentral images / build (hfcl_ion4xe) (push) Has been cancelled
Build OpenWrt/uCentral images / build (hfcl_ion4xi) (push) Has been cancelled
Build OpenWrt/uCentral images / build (hfcl_ion4xi_w) (push) Has been cancelled
Build OpenWrt/uCentral images / build (indio_um-305ax) (push) Has been cancelled
Build OpenWrt/uCentral images / build (sercomm_ap72tip) (push) Has been cancelled
Build OpenWrt/uCentral images / build (sonicfi_rap630c-311g) (push) Has been cancelled
Build OpenWrt/uCentral images / build (sonicfi_rap630w-211g) (push) Has been cancelled
Build OpenWrt/uCentral images / build (sonicfi_rap630w-311g) (push) Has been cancelled
Build OpenWrt/uCentral images / build (udaya_a6-id2) (push) Has been cancelled
Build OpenWrt/uCentral images / build (udaya_a6-od2) (push) Has been cancelled
Build OpenWrt/uCentral images / build (wallys_dr5018) (push) Has been cancelled
Build OpenWrt/uCentral images / build (wallys_dr6018) (push) Has been cancelled
Build OpenWrt/uCentral images / build (wallys_dr6018-v4) (push) Has been cancelled
Build OpenWrt/uCentral images / build (yuncore_ax820) (push) Has been cancelled
Build OpenWrt/uCentral images / build (yuncore_ax840) (push) Has been cancelled
Build OpenWrt/uCentral images / build (yuncore_fap640) (push) Has been cancelled
Build OpenWrt/uCentral images / build (yuncore_fap650) (push) Has been cancelled
Build OpenWrt/uCentral images / build (yuncore_fap655) (push) Has been cancelled
Build OpenWrt/uCentral images / trigger-testing (push) Has been cancelled
Build OpenWrt/uCentral images / create-x64_vm-ami (push) Has been cancelled
Signed-off-by: John Crispin <john@phrozen.org>
88 lines
2.5 KiB
Diff
Executable File
88 lines
2.5 KiB
Diff
Executable File
From 9401af4506decfb133e0cb947dba07c1da6f3b01 Mon Sep 17 00:00:00 2001
|
|
From: Ramanathan Choodamani <quic_rchoodam@quicinc.com>
|
|
Date: Mon, 17 Apr 2023 21:40:55 -0700
|
|
Subject: [PATCH] hostapd: Add config support for updating bridge connections
|
|
|
|
Add config support for updating bridge connections during
|
|
bringup.
|
|
This function will be called when all the interfaces
|
|
are up.
|
|
|
|
Signed-off-by: Ramanathan Choodamani <quic_rchoodam@quicinc.com>
|
|
---
|
|
hostapd/config_file.c | 2 ++
|
|
hostapd/main.c | 2 ++
|
|
src/ap/ap_config.h | 1 +
|
|
src/ap/drv_callbacks.c | 26 ++++++++++++++++++++++++++
|
|
src/ap/hostapd.h | 1 +
|
|
5 files changed, 32 insertions(+)
|
|
|
|
--- a/hostapd/config_file.c
|
|
+++ b/hostapd/config_file.c
|
|
@@ -4812,7 +4812,8 @@ static int hostapd_config_fill(struct ho
|
|
line);
|
|
return 1;
|
|
}
|
|
-
|
|
+ } else if (os_strcmp(buf, "bonded") == 0) {
|
|
+ bss->is_bonded_iface_enabled = true;
|
|
#endif /* CONFIG_IEEE80211BE */
|
|
} else if (os_strcmp(buf, "disable_csa_dfs") == 0) {
|
|
conf->disable_csa_dfs = atoi(pos);
|
|
--- a/hostapd/main.c
|
|
+++ b/hostapd/main.c
|
|
@@ -271,6 +271,8 @@ static int hostapd_driver_init(struct ho
|
|
params.own_addr = hapd->own_addr;
|
|
|
|
hapd->drv_priv = hapd->driver->hapd_init(hapd, ¶ms);
|
|
+ if (hapd->conf->is_bonded_iface_enabled)
|
|
+ hostapd_mld_update_bridge_conn(hapd->conf->bridge, hapd->conf->iface);
|
|
os_free(params.bridge);
|
|
if (hapd->drv_priv == NULL) {
|
|
wpa_printf(MSG_ERROR, "%s driver initialization failed.",
|
|
--- a/src/ap/ap_config.h
|
|
+++ b/src/ap/ap_config.h
|
|
@@ -953,6 +953,7 @@ struct hostapd_bss_config {
|
|
|
|
/* The MLD ID to which the AP MLD is affiliated with */
|
|
u8 mld_id;
|
|
+ bool is_bonded_iface_enabled;
|
|
#endif /* CONFIG_IEEE80211BE */
|
|
enum {
|
|
FILS_UBPR_USER_DISABLED,
|
|
--- a/src/ap/drv_callbacks.c
|
|
+++ b/src/ap/drv_callbacks.c
|
|
@@ -2040,6 +2040,32 @@ err:
|
|
}
|
|
#endif /* CONFIG_OWE */
|
|
|
|
+int hostapd_mld_update_bridge_conn(char *brname,
|
|
+ char *ifname)
|
|
+{
|
|
+ char bonded_ifname[IFNAMSIZ + 3];
|
|
+ char buf[128];
|
|
+ int res = 0;
|
|
+
|
|
+ os_snprintf(bonded_ifname, sizeof(bonded_ifname), "%s_b", ifname);
|
|
+ os_snprintf(buf, sizeof(buf), "brctl delif %s %s",
|
|
+ brname, ifname);
|
|
+ res = system(buf);
|
|
+ if (res)
|
|
+ return -1;
|
|
+ os_memset(buf, 0, sizeof(buf));
|
|
+ os_snprintf(buf, sizeof(buf), "brctl addif %s %s",
|
|
+ brname, bonded_ifname);
|
|
+ res = system(buf);
|
|
+ os_memset(buf, 0, sizeof(buf));
|
|
+ os_snprintf(buf, sizeof(buf), "ifconfig %s up",
|
|
+ bonded_ifname);
|
|
+ res = system(buf);
|
|
+ if (res)
|
|
+ return -1;
|
|
+
|
|
+ return 0;
|
|
+}
|
|
|
|
void hostapd_wpa_event(void *ctx, enum wpa_event_type event,
|
|
union wpa_event_data *data)
|