[PATCH 1/2] supplicant: Use high-priority queue for management packets.

Johannes Berg johannes at sipsolutions.net
Tue Jan 7 09:59:49 EST 2014


On Mon, 2013-09-23 at 09:04 -0700, Ben Greear wrote:
> On 09/23/2013 01:08 AM, Jouni Malinen wrote:
> > On Mon, Sep 09, 2013 at 11:49:04AM -0700, greearb at candelatech.com wrote:
> >> Without this patch, wpa_supplicant EAPOL packets (at least)
> >> are sent on normal best-effort TX queue.  I believe they
> >> should be on the VO high-priority queue instead.
> >
> >> diff --git a/src/l2_packet/l2_packet_linux.c b/src/l2_packet/l2_packet_linux.c
> >
> >> @@ -97,6 +97,7 @@ struct l2_packet_data * l2_packet_init(
> >> +	/* Use high-priority queue for management packets
> >> +	 * http://wireless.kernel.org/en/developers/Documentation/mac80211/queues
> >> +	 */
> >> +	if (setsockopt(l2->fd, SOL_SOCKET,
> >> +		       SO_PRIORITY, (char*)&val, sizeof(val)) < 0) {
> >
> > This seems to be assuming that mac80211 is used always. That is not
> > really the case and I guess this SO_PRIORITY change to a special
> > mac80211-specific value could result in undesired results with
> > non-mac80211 drivers.
> 
> The special priority is defined in the net/wireless/ dir of the kernel,
> and does not make special mention of mac80211 v/s other logic.
> 
>  From what I can tell, there is no other way to specify QoS when
> sending on packet-sockets.  The skb->priority never hits the wire
> directly, so either something should be using it properly, or it
> will just be ignored and we are no worse off than before.  If
> some driver is actually conflicting with the documentation, then
> we just need to fix it.

That code isn't really documentation though :)

johannes



More information about the HostAP mailing list