Skip to content

Conversation

ArsenPodoba
Copy link

Reason for change: To be able start WPS session from OVSDB

Test procedure:
1) Verify successful build.
2) Change wps_pbc value in Wifi_VIF_Config
3) Confirm that callback executes correctly and updates runtime/OVSDB state.

Risks: Low. Scoped to WPS feature with guarded code paths.

Priority: P1

@ArsenPodoba ArsenPodoba requested a review from a team as a code owner October 13, 2025 12:09
@CLAassistant
Copy link

CLAassistant commented Oct 13, 2025

CLA assistant check
All committers have signed the CLA.

@ArsenPodoba
Copy link
Author

I have read the CLA Document and I hereby sign the CLA

Reason for change: To be able start WPS session from OVSDB

Test procedure:
    1) Verify successful build.
    2) Change wps_pbc value in Wifi_VIF_Config
    3) Confirm that callback executes correctly and updates runtime/OVSDB state.

Risks: Low. Scoped to WPS feature with guarded code paths.

Priority: P1

Signed-off-by: Arsen Podoba <[email protected]>
return;
}

int wps_event_callback(int apIndex, wifi_wps_ev_t event)
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

please add "static"


int wps_event_callback(int apIndex, wifi_wps_ev_t event)
{
wifi_wps_event_t wps_event;
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

initialize to 0, wifi_wps_event_t wps_event = {};

wps_event.vap_index = apIndex;
wps_event.event = event;

push_event_to_ctrl_queue((wifi_wps_event_t *)&wps_event, sizeof(wifi_wps_event_t), wifi_event_type_hal_ind, wifi_event_hal_wps_results, NULL);
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

code style: more than 100 chars in line, please format with clang-format

}
}

void process_wps_results_event(wifi_wps_event_t *wps_event)
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

please add "static"

wifi_util_info_print(WIFI_CTRL, "%s:%d wps event[%d] is received\n", __func__, __LINE__, wps_event->event);

switch(wps_event->event) {
case wifi_wps_ev_pbc_active:
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

code style: please format the function with clang-format, switch-case on the same level

wifi_vap_info_t *vap_info = NULL;
rdk_wifi_vap_info_t *rdk_vap_info = NULL;
unsigned int vap_index = wps_event->vap_index;
bool wpsPushButton = false;
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

lowercase naming wps_push_button

unsigned int vap_index = wps_event->vap_index;
bool wpsPushButton = false;

wifi_util_info_print(WIFI_CTRL, "%s:%d wps event[%d] is received\n", __func__, __LINE__, wps_event->event);
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

more than 100 chars in line


wifi_util_info_print(WIFI_CTRL, "%s:%d wps event[%d] is received\n", __func__, __LINE__, wps_event->event);

switch(wps_event->event) {
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

missing space after switch before (


wifi_util_dbg_print(WIFI_CTRL,"%s:%d: Comparing VAP [%s] with [%s]. \n",__func__, __LINE__,mgr_vap_info->vap_name,vap_info->vap_name);
if (is_vap_param_config_changed(mgr_vap_info, vap_info, mgr_rdk_vap_info, rdk_vap_info,
if (is_vap_param_config_changed_except_wpsPushButton(mgr_vap_info, vap_info, mgr_rdk_vap_info, rdk_vap_info,
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

please implement in different way:
similar to webconfig_send_sta_bssid_change_event add send_wps_change_event function
inside function send event and overwrite value mgr_vap_info->u.bss_info.wpsPushButton = rdk_vap_info->->u.bss_info.wpsPushButton to avoid change detection in is_vap_param_config_changed

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants