qcacld-3.0: Add policy attribute to SUBCMD_NUD_STATS_SET
According to new changes in kernel 5.4 version onwards, driver has to provide the policy for a NL command to be verified against while registering wiphy to the kernel. To satisfy kernel 5.4 requirement add policy to following vendor command as part of this change: QCA_NL80211_VENDOR_SUBCMD_NUD_STATS_SET Change-Id: I1023872146d398252cd8dbde8431cd8c5e839a31 CRs-Fixed: 2631294
This commit is contained in:
parent
61206f13d3
commit
1c570b38f4
@ -12621,7 +12621,7 @@ static int wlan_hdd_cfg80211_set_fast_roaming(struct wiphy *wiphy,
|
||||
QCA_ATTR_NUD_STATS_SET_MAX
|
||||
|
||||
const struct nla_policy
|
||||
qca_wlan_vendor_set_nud_stats[STATS_SET_MAX + 1] = {
|
||||
qca_wlan_vendor_set_nud_stats_policy[STATS_SET_MAX + 1] = {
|
||||
[STATS_SET_START] = {.type = NLA_FLAG },
|
||||
[STATS_GW_IPV4] = {.type = NLA_U32 },
|
||||
[STATS_SET_DATA_PKT_INFO] = {.type = NLA_U32 },
|
||||
@ -13073,7 +13073,7 @@ static int __wlan_hdd_cfg80211_set_nud_stats(struct wiphy *wiphy,
|
||||
}
|
||||
|
||||
err = wlan_cfg80211_nla_parse(tb, STATS_SET_MAX, data, data_len,
|
||||
qca_wlan_vendor_set_nud_stats);
|
||||
qca_wlan_vendor_set_nud_stats_policy);
|
||||
if (err) {
|
||||
hdd_err("STATS_SET_START ATTR");
|
||||
return err;
|
||||
@ -14943,14 +14943,7 @@ const struct wiphy_vendor_command hdd_wiphy_vendor_commands[] = {
|
||||
WIPHY_VENDOR_CMD_NEED_RUNNING,
|
||||
.doit = wlan_hdd_cfg80211_ll_stats_ext_set_param
|
||||
},
|
||||
{
|
||||
.info.vendor_id = QCA_NL80211_VENDOR_ID,
|
||||
.info.subcmd = QCA_NL80211_VENDOR_SUBCMD_NUD_STATS_SET,
|
||||
.flags = WIPHY_VENDOR_CMD_NEED_WDEV |
|
||||
WIPHY_VENDOR_CMD_NEED_NETDEV |
|
||||
WIPHY_VENDOR_CMD_NEED_RUNNING,
|
||||
.doit = wlan_hdd_cfg80211_set_nud_stats
|
||||
},
|
||||
FEATURE_VENDOR_SUBCMD_NUD_STATS_SET
|
||||
{
|
||||
.info.vendor_id = QCA_NL80211_VENDOR_ID,
|
||||
.info.subcmd = QCA_NL80211_VENDOR_SUBCMD_NUD_STATS_GET,
|
||||
|
@ -279,6 +279,22 @@ wlan_hdd_cfg80211_roam_metrics_handover(struct hdd_adapter *adapter,
|
||||
struct csr_roam_info *roam_info);
|
||||
#endif
|
||||
|
||||
extern const struct nla_policy
|
||||
qca_wlan_vendor_set_nud_stats_policy
|
||||
[QCA_ATTR_NUD_STATS_SET_MAX + 1];
|
||||
|
||||
#define FEATURE_VENDOR_SUBCMD_NUD_STATS_SET \
|
||||
{ \
|
||||
.info.vendor_id = QCA_NL80211_VENDOR_ID, \
|
||||
.info.subcmd = QCA_NL80211_VENDOR_SUBCMD_NUD_STATS_SET, \
|
||||
.flags = WIPHY_VENDOR_CMD_NEED_WDEV | \
|
||||
WIPHY_VENDOR_CMD_NEED_NETDEV | \
|
||||
WIPHY_VENDOR_CMD_NEED_RUNNING, \
|
||||
.doit = wlan_hdd_cfg80211_set_nud_stats, \
|
||||
vendor_command_policy(qca_wlan_vendor_set_nud_stats_policy, \
|
||||
QCA_ATTR_NUD_STATS_SET_MAX) \
|
||||
},
|
||||
|
||||
/**
|
||||
* hdd_cfg80211_wiphy_alloc() - Allocate wiphy
|
||||
*
|
||||
|
Loading…
Reference in New Issue
Block a user