Skip to content

Commit 0e56c19

Browse files
rado17krish2718
authored andcommitted
[noup] zephyr: Add changes for P2P discovery
Register probe request frames. Needed by RPU to send the frames up to supplicant. Send probe response frame down to driver. This facilitates P2P discovery. Signed-off-by: Ravi Dondaputi <ravi.dondaputi@nordicsemi.no>
1 parent 816d80d commit 0e56c19

File tree

1 file changed

+23
-0
lines changed

1 file changed

+23
-0
lines changed

src/drivers/driver_zephyr.c

Lines changed: 23 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2765,6 +2765,28 @@ int wpa_drv_zep_cancel_remain_on_channel(void *priv)
27652765
return ret;
27662766
}
27672767

2768+
int wpa_drv_zep_probe_req_report(void *priv, int report)
2769+
{
2770+
struct zep_drv_if_ctx *if_ctx = NULL;
2771+
int ret = -1;
2772+
2773+
if (!priv) {
2774+
wpa_printf(MSG_ERROR, "%s: Invalid handle", __func__);
2775+
goto out;
2776+
}
2777+
2778+
if_ctx = priv;
2779+
ret = wpa_drv_register_frame(priv, WLAN_FC_STYPE_PROBE_REQ << 4,
2780+
NULL, 0, 0);
2781+
if (ret) {
2782+
wpa_printf(MSG_ERROR, "%s: register probe req report failed", __func__);
2783+
goto out;
2784+
}
2785+
2786+
out:
2787+
return ret;
2788+
}
2789+
27682790
void wpa_drv_zep_send_action_cancel_wait(void *priv)
27692791
{
27702792
struct zep_drv_if_ctx *if_ctx = NULL;
@@ -2837,5 +2859,6 @@ const struct wpa_driver_ops wpa_driver_zep_ops = {
28372859
.dpp_listen = wpa_drv_zep_dpp_listen,
28382860
.remain_on_channel = wpa_drv_zep_remain_on_channel,
28392861
.cancel_remain_on_channel = wpa_drv_zep_cancel_remain_on_channel,
2862+
.probe_req_report = wpa_drv_zep_probe_req_report,
28402863
.send_action_cancel_wait = wpa_drv_zep_send_action_cancel_wait,
28412864
};

0 commit comments

Comments
 (0)