P2P: Make group operating channel available
Provide local GO channel to the P2P module so that it can be used in messages that indicate the current operating channel. Signed-hostap: Jouni Malinen <jouni@qca.qualcomm.com>
This commit is contained in:
parent
9f7cd9ae8a
commit
ea43ad960b
4 changed files with 13 additions and 0 deletions
|
@ -1371,6 +1371,11 @@ struct p2p_group_config {
|
||||||
*/
|
*/
|
||||||
size_t ssid_len;
|
size_t ssid_len;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* freq - Operating channel of the group
|
||||||
|
*/
|
||||||
|
int freq;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* cb_ctx - Context to use with callback functions
|
* cb_ctx - Context to use with callback functions
|
||||||
*/
|
*/
|
||||||
|
|
|
@ -999,3 +999,9 @@ void p2p_group_force_beacon_update_ies(struct p2p_group *group)
|
||||||
group->beacon_update = 1;
|
group->beacon_update = 1;
|
||||||
p2p_group_update_ies(group);
|
p2p_group_update_ies(group);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
int p2p_group_get_freq(struct p2p_group *group)
|
||||||
|
{
|
||||||
|
return group->cfg->freq;
|
||||||
|
}
|
||||||
|
|
|
@ -604,6 +604,7 @@ void p2p_group_force_beacon_update_ies(struct p2p_group *group);
|
||||||
struct wpabuf * p2p_group_get_wfd_ie(struct p2p_group *g);
|
struct wpabuf * p2p_group_get_wfd_ie(struct p2p_group *g);
|
||||||
void p2p_buf_add_group_info(struct p2p_group *group, struct wpabuf *buf,
|
void p2p_buf_add_group_info(struct p2p_group *group, struct wpabuf *buf,
|
||||||
int max_clients);
|
int max_clients);
|
||||||
|
int p2p_group_get_freq(struct p2p_group *group);
|
||||||
|
|
||||||
|
|
||||||
void p2p_buf_add_action_hdr(struct wpabuf *buf, u8 subtype, u8 dialog_token);
|
void p2p_buf_add_action_hdr(struct wpabuf *buf, u8 subtype, u8 dialog_token);
|
||||||
|
|
|
@ -5235,6 +5235,7 @@ struct p2p_group * wpas_p2p_group_init(struct wpa_supplicant *wpa_s,
|
||||||
cfg->max_clients = wpa_s->conf->max_num_sta;
|
cfg->max_clients = wpa_s->conf->max_num_sta;
|
||||||
os_memcpy(cfg->ssid, ssid->ssid, ssid->ssid_len);
|
os_memcpy(cfg->ssid, ssid->ssid, ssid->ssid_len);
|
||||||
cfg->ssid_len = ssid->ssid_len;
|
cfg->ssid_len = ssid->ssid_len;
|
||||||
|
cfg->freq = ssid->frequency;
|
||||||
cfg->cb_ctx = wpa_s;
|
cfg->cb_ctx = wpa_s;
|
||||||
cfg->ie_update = wpas_p2p_ie_update;
|
cfg->ie_update = wpas_p2p_ie_update;
|
||||||
cfg->idle_update = wpas_p2p_idle_update;
|
cfg->idle_update = wpas_p2p_idle_update;
|
||||||
|
|
Loading…
Reference in a new issue