qcacmn: handle MBSSID IE for critical update
With the MBSSID IE, it has to generate the corresponding beacon and probe response frames. Then handle the generated frames per critical update feature. Change-Id: Iff3fdb3a335a98d9ed7e51957885e2f161069807 CRs-Fixed: 3376521
This commit is contained in:

committed by
Madan Koyyalamudi

orang tua
a3d8c8606d
melakukan
f453c827cb
@@ -1728,6 +1728,22 @@ void scm_filter_valid_channel(struct wlan_objmgr_pdev *pdev,
|
||||
}
|
||||
}
|
||||
|
||||
QDF_STATUS scm_scan_register_mbssid_cb(struct wlan_objmgr_psoc *psoc,
|
||||
update_mbssid_bcn_prb_rsp cb)
|
||||
{
|
||||
struct wlan_scan_obj *scan_obj;
|
||||
|
||||
scan_obj = wlan_psoc_get_scan_obj(psoc);
|
||||
if (!scan_obj) {
|
||||
scm_err("scan obj is NULL");
|
||||
return QDF_STATUS_E_INVAL;
|
||||
}
|
||||
|
||||
scan_obj->cb.inform_mbssid_bcn_prb_rsp = cb;
|
||||
|
||||
return QDF_STATUS_SUCCESS;
|
||||
}
|
||||
|
||||
QDF_STATUS scm_scan_register_bcn_cb(struct wlan_objmgr_psoc *psoc,
|
||||
update_beacon_cb cb, enum scan_cb_type type)
|
||||
{
|
||||
|
@@ -182,6 +182,17 @@ scm_iterate_scan_db(struct wlan_objmgr_pdev *pdev,
|
||||
QDF_STATUS scm_scan_register_bcn_cb(struct wlan_objmgr_psoc *psoc,
|
||||
update_beacon_cb cb, enum scan_cb_type type);
|
||||
|
||||
/**
|
||||
* scm_scan_register_mbssid_cb() - API to register api to handle bcn/probe
|
||||
* as soon as they are generated
|
||||
* @psoc: psoc object
|
||||
* @cb: callback to be registered
|
||||
*
|
||||
* Return: QDF_STATUS
|
||||
*/
|
||||
QDF_STATUS scm_scan_register_mbssid_cb(struct wlan_objmgr_psoc *psoc,
|
||||
update_mbssid_bcn_prb_rsp cb);
|
||||
|
||||
/**
|
||||
* scm_db_init() - API to init scan db
|
||||
* @psoc: psoc
|
||||
|
@@ -508,11 +508,13 @@ struct scan_default_params {
|
||||
* @inform_beacon: cb to indicate frame to OS
|
||||
* @update_beacon: cb to indicate frame to MLME
|
||||
* @unlink_bss: cb to unlink bss from kernel cache
|
||||
* @inform_mbssid_bcn_prb_rsp: cb to indicate frames with mbssid
|
||||
*/
|
||||
struct scan_cb {
|
||||
update_beacon_cb inform_beacon;
|
||||
update_beacon_cb update_beacon;
|
||||
update_beacon_cb unlink_bss;
|
||||
update_mbssid_bcn_prb_rsp inform_mbssid_bcn_prb_rsp;
|
||||
/* Define nif/sif function callbacks here */
|
||||
};
|
||||
|
||||
|
@@ -478,6 +478,16 @@ wlan_scan_unregister_requester(struct wlan_objmgr_psoc *psoc,
|
||||
bool wlan_scan_cfg_skip_6g_and_indoor_freq(
|
||||
struct wlan_objmgr_psoc *psoc);
|
||||
|
||||
/**
|
||||
* wlan_scan_register_mbssid_cb() - register api to inform bcn/probe rsp
|
||||
* @psoc: psoc object
|
||||
* @cb: callback to be registered
|
||||
*
|
||||
* Return: QDF_STATUS
|
||||
*/
|
||||
QDF_STATUS wlan_scan_register_mbssid_cb(struct wlan_objmgr_psoc *psoc,
|
||||
update_mbssid_bcn_prb_rsp cb);
|
||||
|
||||
/**
|
||||
* wlan_scan_get_entry_by_mac_addr() - Get bcn/probe rsp from scan db
|
||||
* @pdev: pdev info
|
||||
|
@@ -1520,6 +1520,20 @@ struct scan_user_cfg {
|
||||
uint32_t sta_miracast_mcc_rest_time;
|
||||
};
|
||||
|
||||
/**
|
||||
* typedef update_mbssid_bcn_prb_rsp() - cb to inform mbssid beacon or prob resp
|
||||
* @frame: the pointer of frame data
|
||||
* @frame_len: the length of frame data
|
||||
* @frm_subtype: frame type
|
||||
* @bssid: the pointer of bssid
|
||||
*
|
||||
* Return: QDF_STATUS
|
||||
*/
|
||||
typedef QDF_STATUS (*update_mbssid_bcn_prb_rsp)(uint8_t *frame,
|
||||
uint32_t frame_len,
|
||||
uint8_t frm_subtype,
|
||||
char *bssid);
|
||||
|
||||
/**
|
||||
* typedef update_beacon_cb() - cb to inform/update beacon
|
||||
* @pdev: pdev pointer
|
||||
|
@@ -864,6 +864,12 @@ wlan_scan_get_entry_by_mac_addr(struct wlan_objmgr_pdev *pdev,
|
||||
return scm_scan_get_entry_by_mac_addr(pdev, bssid, frame);
|
||||
}
|
||||
|
||||
QDF_STATUS wlan_scan_register_mbssid_cb(struct wlan_objmgr_psoc *psoc,
|
||||
update_mbssid_bcn_prb_rsp cb)
|
||||
{
|
||||
return scm_scan_register_mbssid_cb(psoc, cb);
|
||||
}
|
||||
|
||||
struct scan_cache_entry *
|
||||
wlan_scan_get_entry_by_bssid(struct wlan_objmgr_pdev *pdev,
|
||||
struct qdf_mac_addr *bssid)
|
||||
|
@@ -3206,6 +3206,7 @@ static QDF_STATUS util_scan_parse_mbssid(struct wlan_objmgr_pdev *pdev,
|
||||
struct mgmt_rx_event_params *rx_param,
|
||||
qdf_list_t *scan_list)
|
||||
{
|
||||
struct wlan_scan_obj *scan_obj;
|
||||
struct wlan_bcn_frame *bcn;
|
||||
struct wlan_frame_hdr *hdr;
|
||||
struct scan_mbssid_info mbssid_info = {0};
|
||||
@@ -3221,6 +3222,10 @@ static QDF_STATUS util_scan_parse_mbssid(struct wlan_objmgr_pdev *pdev,
|
||||
enum nontx_profile_reasoncode retval;
|
||||
uint8_t *nontx_profile = NULL;
|
||||
|
||||
scan_obj = wlan_pdev_get_scan_obj(pdev);
|
||||
if (!scan_obj)
|
||||
return QDF_STATUS_E_INVAL;
|
||||
|
||||
hdr = (struct wlan_frame_hdr *)frame;
|
||||
bcn = (struct wlan_bcn_frame *)(frame + sizeof(struct wlan_frame_hdr));
|
||||
ie = (uint8_t *)&bcn->ie;
|
||||
@@ -3488,6 +3493,11 @@ static QDF_STATUS util_scan_parse_mbssid(struct wlan_objmgr_pdev *pdev,
|
||||
offsetof(struct wlan_bcn_frame, ie) +
|
||||
sizeof(struct wlan_frame_hdr),
|
||||
new_ie, new_ie_len);
|
||||
if (scan_obj->cb.inform_mbssid_bcn_prb_rsp)
|
||||
scan_obj->cb.inform_mbssid_bcn_prb_rsp(
|
||||
new_frame, new_frame_len,
|
||||
frm_subtype, new_bssid);
|
||||
|
||||
status = util_scan_gen_scan_entry(pdev, new_frame,
|
||||
new_frame_len,
|
||||
frm_subtype,
|
||||
|
Reference in New Issue
Block a user