mirror of
https://github.com/BobTheBlinker/android_kernel_motorola_sm6375.git
synced 2026-10-15 01:01:56 -04:00
qcacld-3.0: Set wdev for vendor event BEACON_REPORTING_INDEX
Currently host sends wdev as NULL to cfg80211_vendor_event_alloc, this allows userspace to process nl_cmd for QCA_NL80211_VENDOR_SUBCMD_BEACON_REPORTING_INDEX event with P2P interface instead of WLAN. Set wdev with proper value to avoid processing nl_cmd with P2P interface by userspace. Change-Id: If0b99efdc76c1f89b6b07ee72edc6c5e2994a90c CRs-Fixed: 2568776
This commit is contained in:
parent
a8ed32b5ed
commit
335074e703
3 changed files with 11 additions and 2 deletions
|
|
@ -126,15 +126,20 @@ static void hdd_send_bcn_recv_info(hdd_handle_t hdd_handle,
|
|||
struct hdd_context *hdd_ctx = hdd_handle_to_context(hdd_handle);
|
||||
uint32_t data_len;
|
||||
int flags = cds_get_gfp_flags();
|
||||
struct hdd_adapter *adapter;
|
||||
|
||||
if (wlan_hdd_validate_context(hdd_ctx))
|
||||
return;
|
||||
|
||||
data_len = get_beacon_report_data_len(beacon_report);
|
||||
|
||||
adapter = hdd_get_adapter_by_vdev(hdd_ctx, beacon_report->vdev_id);
|
||||
if (hdd_validate_adapter(adapter))
|
||||
return;
|
||||
|
||||
vendor_event =
|
||||
cfg80211_vendor_event_alloc(
|
||||
hdd_ctx->wiphy, NULL,
|
||||
hdd_ctx->wiphy, &(adapter->wdev),
|
||||
data_len,
|
||||
QCA_NL80211_VENDOR_SUBCMD_BEACON_REPORTING_INDEX,
|
||||
flags);
|
||||
|
|
@ -423,7 +428,7 @@ void hdd_beacon_recv_pause_indication(hdd_handle_t hdd_handle,
|
|||
|
||||
vendor_event =
|
||||
cfg80211_vendor_event_alloc(
|
||||
hdd_ctx->wiphy, NULL,
|
||||
hdd_ctx->wiphy, &(adapter->wdev),
|
||||
data_len,
|
||||
QCA_NL80211_VENDOR_SUBCMD_BEACON_REPORTING_INDEX,
|
||||
flags);
|
||||
|
|
|
|||
|
|
@ -193,6 +193,7 @@ struct rsn_caps {
|
|||
|
||||
/**
|
||||
* struct wlan_beacon_report - Beacon info to be send to userspace
|
||||
* @vdev_id: vdev id
|
||||
* @ssid: ssid present in beacon
|
||||
* @bssid: bssid present in beacon
|
||||
* @frequency: channel frequency in MHz
|
||||
|
|
@ -201,6 +202,7 @@ struct rsn_caps {
|
|||
* @boot_time: Boot time when beacon received
|
||||
*/
|
||||
struct wlan_beacon_report {
|
||||
uint8_t vdev_id;
|
||||
struct wlan_ssid ssid;
|
||||
struct qdf_mac_addr bssid;
|
||||
uint32_t frequency;
|
||||
|
|
|
|||
|
|
@ -1113,6 +1113,8 @@ void sch_send_beacon_report(struct mac_context *mac_ctx,
|
|||
qdf_do_div(qdf_get_monotonic_boottime(),
|
||||
QDF_MC_TIMER_TO_MS_UNIT);
|
||||
|
||||
beacon_report.vdev_id = session->vdev_id;
|
||||
|
||||
/* Send report to upper layer */
|
||||
mac_ctx->lim.sme_bcn_rcv_callback(mac_ctx->hdd_handle,
|
||||
&beacon_report);
|
||||
|
|
|
|||
Loading…
Reference in a new issue