Re: [RFC 4/4] nl80211: Implement TX of control port frames

2018-01-03 Thread Denis Kenzior
Hi Arend, So essentially we'd need a new operation in cfg80211_ops that would accept the control port frame data and some control flags. Do we want to pass in an skb with all the 802.11 headers set or a 802.3 formatted skb (since that is what other data frames look like initially on the netdev)

Re: [RFC 4/4] nl80211: Implement TX of control port frames

2018-01-03 Thread Johannes Berg
Hi, > > > If so, can we do something like what ieee80211_process_sa_query_req in > > > net/mac80211/rx.c or ieee80211_tdls_prep_mgmt_packet in > > > net/mac80211/tdls.c do? E.g. use ieee80211_tx_skb or > > > __ieee80211_subif_start_xmit or similar to inject the skb with the > > > DONT_ENCRYPT fla

Re: [RFC 4/4] nl80211: Implement TX of control port frames

2018-01-03 Thread Arend Van Spriel
On Wed, Jan 3, 2018 at 6:17 PM, Denis Kenzior wrote: > Hi Johannes, > > > >>> If so, can we do something like what ieee80211_process_sa_query_req in >>> net/mac80211/rx.c or ieee80211_tdls_prep_mgmt_packet in >>> net/mac80211/tdls.c do? E.g. use ieee80211_tx_skb or >>> __ieee80211_subif_start_xm

Re: [RFC 4/4] nl80211: Implement TX of control port frames

2018-01-03 Thread Denis Kenzior
Hi Johannes, If so, can we do something like what ieee80211_process_sa_query_req in net/mac80211/rx.c or ieee80211_tdls_prep_mgmt_packet in net/mac80211/tdls.c do? E.g. use ieee80211_tx_skb or __ieee80211_subif_start_xmit or similar to inject the skb with the DONT_ENCRYPT flag? Yes, this wi

Re: [RFC 4/4] nl80211: Implement TX of control port frames

2018-01-02 Thread Johannes Berg
On Tue, 2018-01-02 at 12:22 -0600, Denis Kenzior wrote: > > There are cases where CONTROL_PORT_ETHERTYPE_NO_ENCRYPT should be > > unset, but specific frames still shouldn't be encrypted. > > > > So I think for this particular path it would be better to deprecate > > CONTROL_PORT_ETHERTYPE_NO_ENCR

Re: [RFC 4/4] nl80211: Implement TX of control port frames

2018-01-02 Thread Denis Kenzior
Hi Johannes, On 01/02/2018 07:30 AM, Johannes Berg wrote: On Thu, 2017-12-28 at 11:58 -0600, Denis Kenzior wrote: This commit implements the TX side of NL80211_CMD_CONTROL_PORT_FRAME. Userspace provides the raw EAPoL frame using NL80211_ATTR_FRAME. A skbuf is built and then injected onto the n

Re: [RFC 4/4] nl80211: Implement TX of control port frames

2018-01-02 Thread Johannes Berg
On Thu, 2017-12-28 at 11:58 -0600, Denis Kenzior wrote: > This commit implements the TX side of NL80211_CMD_CONTROL_PORT_FRAME. > Userspace provides the raw EAPoL frame using NL80211_ATTR_FRAME. A > skbuf is built and then injected onto the netdev of the wireless device. > The CONTROL_PORT_ETHERTY

[RFC 4/4] nl80211: Implement TX of control port frames

2017-12-28 Thread Denis Kenzior
This commit implements the TX side of NL80211_CMD_CONTROL_PORT_FRAME. Userspace provides the raw EAPoL frame using NL80211_ATTR_FRAME. A skbuf is built and then injected onto the netdev of the wireless device. The CONTROL_PORT_ETHERTYPE_NO_ENCRYPT will still in theory be honored by the underlying