P2P find phase offload
Subsystems (5)
v10 cover P2P find phase offload
Following discussion input, I added 'flags' attribute for cfg80211_rx_mgmt(), as separate commit since it is... separate
Now, policy for P2P device is clear - it replies probe-requests if it can, then if driver receives probe (if FW replies to the probe, it may be not reported to the driver), it reports via cfg80211_rx_mgmt() indicating whether frame was replied. wpa_s now can determine whether it need to reply on its own.
Vladimir Kondratiev (2):
cfg80211: add flags to cfg80211_rx_mgmt
cfg80211: P2P find phase offload
drivers/net/wireless/ath/ath6kl/wmi.c | 7 +- drivers/net/wireless/ath/wil6210/wmi.c | 2 +- drivers/net/wireless/brcm80211/brcmfmac/p2p.c | 4 +- drivers/net/wireless/mwifiex/util.c | 4 +- include/net/cfg80211.h | 80 ++++++++++- include/uapi/linux/nl80211.h | 32 +++++ net/mac80211/rx.c | 3 +- net/wireless/mlme.c | 4 +- net/wireless/nl80211.c | 187 +++++++++++++++++++++++++- net/wireless/nl80211.h | 2 +- net/wireless/rdev-ops.h | 19 +++ net/wireless/trace.h | 42 ++++++ 12 files changed, 369 insertions(+), 17 deletions(-)
Signature · 1 line
1.8.1.2
PATCH v10 1/2 cfg80211: add flags to cfg80211_rx_mgmt
Flags intended to report various auxiliary information. Introduced flag NL80211_RXMGMT_FLAG_REPLIED to report whether frame was replied by the device/driver.
--- drivers/net/wireless/ath/ath6kl/wmi.c | 7 +++---- drivers/net/wireless/ath/wil6210/wmi.c | 2 +- drivers/net/wireless/brcm80211/brcmfmac/p2p.c | 4 ++-- drivers/net/wireless/mwifiex/util.c | 4 ++-- include/net/cfg80211.h | 4 +++- include/uapi/linux/nl80211.h | 16 ++++++++++++++++ net/mac80211/rx.c | 3 +-- net/wireless/mlme.c | 4 ++-- net/wireless/nl80211.c | 6 ++++-- net/wireless/nl80211.h | 2 +- 10 files changed, 35 insertions(+), 17 deletions(-)
drivers/net/wireless/ath/ath6kl/wmi.c +3 -4
@@ -568,8 +568,8 @@ static int ath6kl_wmi_rx_probe_req_event_rx(struct wmi *wmi, u8 *datap, int len, dlen, freq, vif->probe_req_report);if (vif->probe_req_report || vif->nw_type ==AP_NETWORK ) -cfg80211_rx_mgmt (&vif->wdev, freq,0 , - ev->data, dlen,GFP_ATOMIC ); +cfg80211_rx_mgmt (&vif->wdev, freq,0 , ev->data, dlen,0 , +GFP_ATOMIC );return 0 ; }
@@ -608,8 +608,7 @@ static int ath6kl_wmi_rx_action_event_rx(struct wmi *wmi, u8 *datap, int len,return -EINVAL ; }ath6kl_dbg (ATH6KL_DBG_WMI ,"rx_action: len=%u freq=%u\n" , dlen, freq); -cfg80211_rx_mgmt (&vif->wdev, freq,0 , - ev->data, dlen,GFP_ATOMIC ); +cfg80211_rx_mgmt (&vif->wdev, freq,0 , ev->data, dlen,0 ,GFP_ATOMIC );return 0 ; }
drivers/net/wireless/ath/wil6210/wmi.c +1 -1
@@ -339,7 +339,7 @@ static void wmi_evt_rx_mgmt(struct wil6210_priv *wil, int id, void *d, int len) } }else {cfg80211_rx_mgmt (wil->wdev, freq, signal, - (void *)rx_mgmt_frame, d_len,GFP_KERNEL ); + (void *)rx_mgmt_frame, d_len,0 ,GFP_KERNEL ); } }
drivers/net/wireless/brcm80211/brcmfmac/p2p.c +2 -2
@@ -1430,7 +1430,7 @@ int brcmf_p2p_notify_action_frame_rx(struct brcmf_if *ifp, IEEE80211_BAND_5GHZ); wdev = &ifp->vif->wdev; -cfg80211_rx_mgmt (wdev, freq,0 , (u8 *)mgmt_frame, mgmt_frame_len, +cfg80211_rx_mgmt (wdev, freq,0 , (u8 *)mgmt_frame, mgmt_frame_len,0 ,GFP_ATOMIC );kfree (mgmt_frame);
@@ -1895,7 +1895,7 @@ s32 brcmf_p2p_notify_rx_mgmt_p2p_probereq(struct brcmf_if *ifp, IEEE80211_BAND_2GHZ : IEEE80211_BAND_5GHZ); -cfg80211_rx_mgmt (&vif->wdev, freq,0 , mgmt_frame, mgmt_frame_len, +cfg80211_rx_mgmt (&vif->wdev, freq,0 , mgmt_frame, mgmt_frame_len,0 ,GFP_ATOMIC ); brcmf_dbg(INFO, "mgmt_frame_len (%d) , e->datalen (%d), chanspec (%04x), freq (%d)\n",
drivers/net/wireless/mwifiex/util.c +2 -2
@@ -171,8 +171,8 @@ mwifiex_process_mgmt_packet(struct mwifiex_private *priv, rx_pd->rx_pkt_length =cpu_to_le16 (pkt_len);cfg80211_rx_mgmt (priv->wdev, priv->roc_cfg.chan.center_freq, -CAL_RSSI (rx_pd->snr, rx_pd->nf), - skb->data, pkt_len,GFP_ATOMIC ); +CAL_RSSI (rx_pd->snr, rx_pd->nf), skb->data, pkt_len, +0 ,GFP_ATOMIC );return 0 ; }
include/net/cfg80211.h +3 -1
@@ -3856,6 +3856,8 @@ void cfg80211_conn_failed(struct net_device *dev, const u8 *mac_addr,* @sig_dbm: signal strength in mBm, or 0 if unknown * @buf: Management frame (header + body) * @len: length of the frame data +* @flags: various flags, see NL80211_RXMGMT_FLAG_xxx defined in +* enum nl80211_rxmgmt_flags * @gfp: context flags * * This function is called whenever an Action frame is received for a station
@@ -3867,7 +3869,7 @@ void cfg80211_conn_failed(struct net_device *dev, const u8 *mac_addr,* driver is responsible for rejecting the frame. */ bool cfg80211_rx_mgmt (struct wireless_dev *wdev,int freq,int sig_dbm, -const u8 *buf,size_t len,gfp_t gfp); +const u8 *buf,size_t len,u32 flags,gfp_t gfp);/** * cfg80211_mgmt_tx_status - notification of TX status for management frame
include/uapi/linux/nl80211.h +16 -0
@@ -1436,6 +1436,8 @@ enum nl80211_commands {* allowed to be used with the first @NL80211_CMD_SET_STATION command to * update a TDLS peer STA entry. * +* @NL80211_ATTR_RXMGMT_FLAGS: flags for cfg80211_rx_mgmt, u32 +* * @NL80211_ATTR_MAX: highest attribute number currently defined * @__NL80211_ATTR_AFTER_LAST: internal use */
@@ -1736,6 +1738,8 @@ enum nl80211_attrs {NL80211_ATTR_PEER_AID , +NL80211_ATTR_RXMGMT_FLAGS , +/* add attributes here, update the policy in nl80211.c */ __NL80211_ATTR_AFTER_LAST,
@@ -3754,4 +3758,16 @@ enum nl80211_crit_proto_id {/* maximum duration for critical protocol measures */ #define NL80211_CRIT_PROTO_MAX_DURATION 5000/* msec */ +/** +* enum nl80211_rxmgmt_flags - flags for cfg80211_rx_mgmt +* +* Defined are bits, to be used in form like +* BIT(NL80211_RXMGMT_FLAG_xxx) +* +* @NL80211_RXMGMT_FLAG_REPLIED: frame was replied by device/driver. +*/ +enum nl80211_rxmgmt_flags { +NL80211_RXMGMT_FLAG_REPLIED , +}; +#endif /* __LINUX_NL80211_H */
net/mac80211/rx.c +1 -2
@@ -2635,8 +2635,7 @@ ieee80211_rx_h_userspace_mgmt(struct ieee80211_rx_data *rx) sig = status->signal;if (cfg80211_rx_mgmt (&rx->sdata->wdev, status->freq, sig, - rx->skb->data, rx->skb->len, -GFP_ATOMIC )) { + rx->skb->data, rx->skb->len,0 ,GFP_ATOMIC )) {if (rx->sta) rx->sta->rx_packets++;dev_kfree_skb (rx->skb);
net/wireless/mlme.c +2 -2
@@ -615,7 +615,7 @@ int cfg80211_mlme_mgmt_tx(struct cfg80211_registered_device *rdev, }bool cfg80211_rx_mgmt (struct wireless_dev *wdev,int freq,int sig_mbm, -const u8 *buf,size_t len,gfp_t gfp) +const u8 *buf,size_t len,u32 flags,gfp_t gfp) {struct wiphy *wiphy = wdev->wiphy;struct cfg80211_registered_device *rdev =wiphy_to_dev (wiphy);
@@ -658,7 +658,7 @@ bool cfg80211_rx_mgmt(struct wireless_dev *wdev, int freq, int sig_mbm,/* Indicate the received Action frame to user space */ if (nl80211_send_mgmt (rdev, wdev, reg->nlportid, freq, sig_mbm, - buf, len, gfp)) + buf, len, flags, gfp))continue ; result = true;
net/wireless/nl80211.c +4 -2
@@ -9962,7 +9962,7 @@ EXPORT_SYMBOL(cfg80211_rx_unexpected_4addr_frame);int nl80211_send_mgmt (struct cfg80211_registered_device *rdev,struct wireless_dev *wdev,u32 nlportid,int freq,int sig_dbm, -const u8 *buf,size_t len,gfp_t gfp) +const u8 *buf,size_t len,u32 flags,gfp_t gfp) {struct net_device *netdev = wdev->netdev;struct sk_buff *msg;
@@ -9985,7 +9985,9 @@ int nl80211_send_mgmt(struct cfg80211_registered_device *rdev,nla_put_u32 (msg,NL80211_ATTR_WIPHY_FREQ , freq) || (sig_dbm &&nla_put_u32 (msg,NL80211_ATTR_RX_SIGNAL_DBM , sig_dbm)) || - nla_put(msg, NL80211_ATTR_FRAME, len, buf)) +nla_put (msg,NL80211_ATTR_FRAME , len, buf) || + (flags && + nla_put_u32(msg, NL80211_ATTR_RXMGMT_FLAGS, flags))) goto nla_put_failure;genlmsg_end (msg, hdr);
net/wireless/nl80211.h +1 -1
@@ -66,7 +66,7 @@ void nl80211_send_ibss_bssid(struct cfg80211_registered_device *rdev,int nl80211_send_mgmt (struct cfg80211_registered_device *rdev,struct wireless_dev *wdev,u32 nlpid,int freq,int sig_dbm, -const u8 *buf,size_t len,gfp_t gfp); +const u8 *buf,size_t len,u32 flags,gfp_t gfp); void nl80211_radar_notify(struct cfg80211_registered_device *rdev,
Signature · 1 line
1.8.1.2
Re: [PATCH v10 1/2] cfg80211: add flags to cfg80211_rx_mgmt
include/net/cfg80211.h void cfg80211_conn_failed(struct net_device *dev, const u8 *mac_addr, · line 3860
Quoted 10 lines · Vladimir Kondratiev
include/net/cfg80211.h +2
-0@@ -3856,6 +3856,8 @@ void cfg80211_conn_failed(struct net_device *dev, const u8 *mac_addr,* @sig_dbm: signal strength in mBm, or 0 if unknown * @buf: Management frame (header + body) * @len: length of the frame data +* @flags: various flags, see NL80211_RXMGMT_FLAG_xxx defined in +* enum nl80211_rxmgmt_flags
It seems sufficient to say:
@flags: flags as defined in enum nl80211_rxmgmt_flags
Regards,
Arend
Quoted 1 line
include/net/cfg80211.h +0
-0* @gfp: context flags
Johannes Berg
maintainerRe: [PATCH v10 1/2] cfg80211: add flags to cfg80211_rx_mgmt
In reply to Vladimir Kondratievinclude/uapi/linux/nl80211.h enum nl80211_crit_proto_id { · line 3771
Quoted 11 lines · Vladimir Kondratiev
include/uapi/linux/nl80211.h +11
-0+/** +* enum nl80211_rxmgmt_flags - flags for cfg80211_rx_mgmt +* +* Defined are bits, to be used in form like +* BIT(NL80211_RXMGMT_FLAG_xxx) +* +* @NL80211_RXMGMT_FLAG_REPLIED: frame was replied by device/driver. +*/ +enum nl80211_rxmgmt_flags { +NL80211_RXMGMT_FLAG_REPLIED , +};
I think you should define the bitmasks, i.e. use
NL80211_RXMGMT_FLAG_REPLIED = 1<<0,
I think that'd be clearer, and userspace doesn't even always have a BIT() macro.
johannes
PATCH v10 2/2 cfg80211: P2P find phase offload
In reply to Vladimir KondratievAllow to implement P2P find phase in the driver/firmware.
Offload scheme designed as follows:
- Driver provide methods start_p2p_find and stop_p2p_find in the cfg80211_ops;
- Driver indicate firmware or driver responds to the probe requests by setting feature NL80211_FEATURE_P2P_PROBE_RESP_OFFLOAD
- wpa_supplicant analyses methods supported to discover p2p offload support;
- wpa_supplicant analyses feature flags to discover p2p probe response offload support;
to perform p2p scan, wpa_supplicant:
- perform legacy scan, through driver's cfg80211_ops 'scan' method
- configure rx management filter to get probe-request and probe-response frames
- start p2p find via driver's cfg80211_ops start_p2p_find method
- driver start p2p find with hardware and notify wpa_supplicant with cfg80211_p2p_find_notify_start()
- driver/firmware toggle search/listen states. Received probe-request and probe-response frames passed to the wpa_supplicant via cfg80211_rx_mgmt
- when wpa_supplicant wants to stop p2p find, it calls driver's cfg80211_ops stop_p2p_find method. Alternatively, driver/firmware may decide to stop p2p find. In all cases, driver notifies wpa_supplicant using cfg80211_p2p_find_notify_end()
All driver to user space communication done through nl80211 layer.
Offloaded P2P find does not support variations like progressive scan.
--- include/net/cfg80211.h | 76 ++++++++++++++++++ include/uapi/linux/nl80211.h | 16 ++++ net/wireless/nl80211.c | 181 +++++++++++++++++++++++++++++++++++++++++++ net/wireless/rdev-ops.h | 19 +++++ net/wireless/trace.h | 42 ++++++++++ 5 files changed, 334 insertions(+)
include/net/cfg80211.h +76 -0
@@ -1805,6 +1805,38 @@ struct cfg80211_update_ft_ies_params { };/** +* struct cfg80211_p2p_find_params - parameters for P2P find +* @probe_ie: extra IE's for probe frames +* @probe_ie_len: length, bytes, of @probe_ie +* @probe_resp_ie: extra IE's for probe response frames +* @probe_resp_ie_len: length, bytes, of @probe_resp_ie +* Driver/firmware may add additional IE's as well as modify +* provided ones; typical IE's to be added are +* WLAN_EID_EXT_SUPP_RATES, WLAN_EID_DS_PARAMS, +* WLAN_EID_HT_CAPABILITY. +* @min_discoverable_interval: and +* @max_discoverable_interval: min/max for random multiplier of 100TU's +* for the listen state duration +* @listen_channel: channels to listen on; not NULL +* @n_channels: number of channels to operate on +* @channels: channels to operate on +* may be NULL, in this case driver suppose to scan for all social +* channels; or channel set should be non-empty (n_channels > 0) +*/ +struct cfg80211_p2p_find_params { +const u8 *probe_ie; +size_t probe_ie_len; +const u8 *probe_resp_ie; +size_t probe_resp_ie_len; +u32 min_discoverable_interval; +u32 max_discoverable_interval; +struct ieee80211_channel *listen_channel; + +int n_channels; +struct ieee80211_channel **channels; +}; + +/** * struct cfg80211_ops - backend description for wireless configuration * * This struct is registered by fullmac card drivers and/or wireless stacks
@@ -2043,6 +2075,24 @@ struct cfg80211_update_ft_ies_params {* driver can take the most appropriate actions. * @crit_proto_stop: Indicates critical protocol no longer needs increased link * reliability. This operation can not fail. +* +* @start_p2p_find: start P2P find phase +* Parameters include IEs for probe/probe-resp frames; +* and channels to operate on. +* Parameters are not retained after call, driver need to copy data if +* it need it later. +* P2P find can't run concurrently with ROC or scan, +* conflict with scan detected by cfg80211 and -EBUSY returned; +* and driver should check for ROC and return -EBUSY to indicate conflict. +* While performing P2P discovery, driver should report received +* probe-request and probe-response frames via cfg80211_rx_mgmt +* accordingly to the rx mgmt filter, as set by mgmt_frame_register(). +* If device indicates NL80211_FEATURE_P2P_PROBE_RESP_OFFLOAD, it may +* reply some matching probes and replied probes may be not reported to +* the upper layers; otherwise it must not reply any probe. +* @stop_p2p_find: stop P2P find phase +* After stopping p2p find, driver should call +* cfg80211_p2p_find_notify_end() to inform upper layers */ struct cfg80211_ops {int (*suspend)(struct wiphy *wiphy,struct cfg80211_wowlan *wow);
@@ -2278,6 +2328,12 @@ struct cfg80211_ops { u16 duration);void (*crit_proto_stop)(struct wiphy *wiphy,struct wireless_dev *wdev); + +int (*start_p2p_find)(struct wiphy *wiphy, +struct wireless_dev *wdev, +struct cfg80211_p2p_find_params *params); +void (*stop_p2p_find)(struct wiphy *wiphy, +struct wireless_dev *wdev); };/*
@@ -4178,6 +4234,26 @@ void cfg80211_report_wowlan_wakeup(struct wireless_dev *wdev,*/ void cfg80211_crit_proto_stopped (struct wireless_dev *wdev,gfp_t gfp); +/** +* cfg80211_p2p_find_notify_start - report p2p find phase started +* @wdev: the wireless device reporting the event +* @gfp: allocation flags +*/ +void cfg80211_p2p_find_notify_start (struct wireless_dev *wdev,gfp_t gfp); + +/** +* cfg80211_p2p_find_notify_end - report p2p find phase ended +* @wdev: the wireless device reporting the event +* @gfp: allocation flags +* +* p2p find phase may be ended either unsolicited or in response to +* ops->stop_p2p_find +* +* In any case, if @start_p2p_find from driver's struct cfg80211_ops called, +* @cfg80211_p2p_find_notify_end should be eventually called +*/ +void cfg80211_p2p_find_notify_end (struct wireless_dev *wdev,gfp_t gfp); +/* Logging, debugging and troubleshooting/diagnostic helpers. */ /* wiphy_printk helpers, similar to dev_printk */
include/uapi/linux/nl80211.h +16 -0
@@ -810,6 +810,9 @@ enum nl80211_commands {NL80211_CMD_CRIT_PROTOCOL_START ,NL80211_CMD_CRIT_PROTOCOL_STOP , +NL80211_CMD_START_P2P_FIND , + NL80211_CMD_STOP_P2P_FIND, +/* add new commands above here */ /* used to define NL80211_CMD_MAX below */
@@ -1438,6 +1441,11 @@ enum nl80211_commands {* * @NL80211_ATTR_RXMGMT_FLAGS: flags for cfg80211_rx_mgmt, u32 * +* @NL80211_ATTR_MIN_DISCOVERABLE_INTERVAL: +* @NL80211_ATTR_MAX_DISCOVERABLE_INTERVAL: min/max discoverable interval +* for the p2p find, multiple of 100 TUs, represented as u32 +* @NL80211_ATTR_LISTEN_FREQ: Listen channel frequency, represented as u32 +* * @NL80211_ATTR_MAX: highest attribute number currently defined * @__NL80211_ATTR_AFTER_LAST: internal use */
@@ -1740,6 +1748,10 @@ enum nl80211_attrs {NL80211_ATTR_RXMGMT_FLAGS , +NL80211_ATTR_MIN_DISCOVERABLE_INTERVAL , +NL80211_ATTR_MAX_DISCOVERABLE_INTERVAL , +NL80211_ATTR_LISTEN_FREQ , +/* add attributes here, update the policy in nl80211.c */ __NL80211_ATTR_AFTER_LAST,
@@ -3592,6 +3604,9 @@ enum nl80211_ap_sme_features {* interface. An active monitor interface behaves like a normal monitor * interface, but gets added to the driver. It ensures that incoming * unicast packets directed at the configured interface address get ACKed. +* @NL80211_FEATURE_P2P_PROBE_RESP_OFFLOAD: When in P2P find phase, +* the device may respond to some probe-requests in hardware; +* replied probe-requests may be not reported to the upper layers. */ enum nl80211_feature_flags {NL80211_FEATURE_SK_TX_STATUS =1 <<0 ,
@@ -3612,6 +3627,7 @@ enum nl80211_feature_flags {NL80211_FEATURE_FULL_AP_CLIENT_STATE =1 <<15 ,NL80211_FEATURE_USERSPACE_MPM =1 <<16 ,NL80211_FEATURE_ACTIVE_MONITOR =1 <<17 , + NL80211_FEATURE_P2P_PROBE_RESP_OFFLOAD = 1 << 18, };/**
net/wireless/nl80211.c +181 -0
211 lines not on this page · raw message
net/wireless/rdev-ops.h +19 -0
@@ -923,4 +923,23 @@ static inline void rdev_crit_proto_stop(struct cfg80211_registered_device *rdev, trace_rdev_return_void(&rdev->wiphy); } +static inline int rdev_start_p2p_find (struct cfg80211_registered_device *rdev, +struct wireless_dev *wdev, +struct cfg80211_p2p_find_params *params) +{ +int ret; +trace_rdev_start_p2p_find (&rdev->wiphy, wdev, params); + ret = rdev->ops->start_p2p_find (&rdev->wiphy, wdev, params); +trace_rdev_return_int (&rdev->wiphy, ret); +return ret; +} + +static inline void rdev_stop_p2p_find (struct cfg80211_registered_device *rdev, +struct wireless_dev *wdev) +{ +trace_rdev_stop_p2p_find (&rdev->wiphy, wdev); + rdev->ops->stop_p2p_find (&rdev->wiphy, wdev); +trace_rdev_return_void (&rdev->wiphy); +} +#endif /* __CFG80211_RDEV_OPS */
net/wireless/trace.h +42 -0
54 lines not on this page · raw message
Signature · 1 line
1.8.1.2
RE: [PATCH v10 2/2] cfg80211: P2P find phase offload
Quoted 6 lines
/**
+ * structcfg80211_p2p_find_params- parameters for P2P find
+ * @probe_ie: extra IE's for probe frames
+ * @probe_ie_len: length, bytes, of @probe_ie
+ * @probe_resp_ie: extra IE's for probe response frames
+ * @probe_resp_ie_len: length, bytes, of @probe_resp_ie
Quoted 8 lines
+ * Driver/firmware may add additional IE's as well as modify
+ * provided ones; typical IE's to be added are
+ *WLAN_EID_EXT_SUPP_RATES,WLAN_EID_DS_PARAMS,
+ *WLAN_EID_HT_CAPABILITY.
+ * @min_discoverable_interval: and
+ * @max_discoverable_interval: min/max for random multiplier of 100TU's
+ * for the listen state duration
+ * @listen_channel: channels to listen on; not NULL
s/channels/channel/ (only a single listen channel)
Quoted 7 lines
+ * @start_p2p_find: start P2P find phase
+ * Parameters include IEs for probe/probe-resp frames;
+ * and channels to operate on.
+ * Parameters are not retained after call, driver need to copy data if
+ * it need it later.
+ * P2P find can't run concurrently with ROC or scan,
+ * conflict with scan detected by cfg80211 and-EBUSYreturned;
Quoted 8 lines
+ * and driver should check for ROC and return
-EBUSYto indicate conflict.
+ * While performing P2P discovery, driver should report received
+ * probe-request and probe-response frames viacfg80211_rx_mgmt
+ * accordingly to the rx mgmt filter, as set bymgmt_frame_register().
+ * If device indicatesNL80211_FEATURE_P2P_PROBE_RESP_OFFLOAD, it
may
+ * reply some matching probes and replied probes may be not reported to
+ * the upper layers; otherwise it must not reply any probe.
Just to clarify something: even if the driver reports that it supports probe response offloading, can wpas choose not to use this capability and handle all the probe requests on its own (at least for debugging)? For example in case that the probe response IE len is zero, the driver can deduce the it should not respond to probe requests.
include/uapi/linux/nl80211.h enum nl80211_attrs { · line 1753
Quoted 7 lines
include/uapi/linux/nl80211.h +3
-0@@ -1740,6 +1748,10 @@ enum nl80211_attrs {NL80211_ATTR_RXMGMT_FLAGS , +NL80211_ATTR_MIN_DISCOVERABLE_INTERVAL , +NL80211_ATTR_MAX_DISCOVERABLE_INTERVAL , + NL80211_ATTR_LISTEN_FREQ,
You can use NL80211_ATTR_WIPHY_FREQ
net/wireless/trace.h TRACE_EVENT(rdev_crit_proto_stop, · line 1853
Quoted 10 lines
net/wireless/trace.h +10
-0+TRACE_EVENT(rdev_start_p2p_find, + TP_PROTO(struct wiphy *wiphy, struct wireless_dev *wdev, + struct cfg80211_p2p_find_params *params), + TP_ARGS(wiphy, wdev, params), + TP_STRUCT__entry( + WIPHY_ENTRY + WDEV_ENTRY + __field(u32, min_di) + __field(u32, max_di) + __field(int, n_channels)
Can you also add here the listen channel?
Thanks,
Ilan
Re: [PATCH v10 2/2] cfg80211: P2P find phase offload
Quoted 3 lines · Ilan
Quoted 1 line
+ * @listen_channel: channels to listen on; not NULL
s/channels/channel/ (only a single listen channel)
Sure, thanks
<skip>
Quoted 1 line
Just to clarify something: even if the driver reports that it supports probe response offloading, can wpas choose not to use this capability and handle all the probe requests on its own (at least for debugging)? For example in case that the probe response IE len is zero, the driver can deduce the it should not respond to probe requests.
Problem is, some hardware do not let you to do so; it simply replies by itself. NL80211_FEATURE_P2P_PROBE_RESP_OFFLOAD indicates device __can__ answer. From this, wpa_s can conclude it may be answered by device probes that is may see or not. It is out of scope for this commit to specify how to tell to the device to not answer (I suppose to use debugfs for this)
Quoted 10 lines
include/uapi/linux/nl80211.h enum nl80211_attrs { · line 1753
Quoted 8 lines
include/uapi/linux/nl80211.h +3
-0@@ -1740,6 +1748,10 @@ enum nl80211_attrs {NL80211_ATTR_RXMGMT_FLAGS , +NL80211_ATTR_MIN_DISCOVERABLE_INTERVAL , +NL80211_ATTR_MAX_DISCOVERABLE_INTERVAL , + NL80211_ATTR_LISTEN_FREQ,You can use
NL80211_ATTR_WIPHY_FREQ
OK, will do so.
Quoted 13 lines
net/wireless/trace.h TRACE_EVENT(rdev_crit_proto_stop, · line 1853
Quoted 11 lines
net/wireless/trace.h +10
-0+TRACE_EVENT(rdev_start_p2p_find, + TP_PROTO(struct wiphy *wiphy, struct wireless_dev *wdev, + struct cfg80211_p2p_find_params *params), + TP_ARGS(wiphy, wdev, params), + TP_STRUCT__entry( + WIPHY_ENTRY + WDEV_ENTRY + __field(u32, min_di) + __field(u32, max_di) + __field(int, n_channels)Can you also add here the listen channel?
Sure
Thanks, Vladimir