Search Linux Wireless

Re: [PATCH 2/2] mac80211: Don't use a buf_size=0 in ADDBA requests

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Helmut Schaa <helmut.schaa@xxxxxxxxxxxxxx> writes:

> According to 802.11-2007, 7.3.1.14 it is compliant to use a buf_size of
> 0 in ADDBA requests. But some devices (AVM Fritz Stick N) arn't able to
> handle that correctly and will reply with an ADDBA reponse with a
> buf_size of 0 which in turn will disallow BA sessions for these
> devices.
>
> To work around this problem, if the hardware doesn't specify an upper
> limit for the number of subframes in an AMPDU send the maximum 0x40 by
> default in ADDBA requests.

[...]

> @@ -345,7 +345,9 @@ void ieee80211_tx_ba_session_handle_start(struct sta_info *sta, int tid)
>  	/* send AddBA request */
>  	ieee80211_send_addba_request(sdata, sta->sta.addr, tid,
>  				     tid_tx->dialog_token, start_seq_num,
> -				     local->hw.max_tx_aggregation_subframes,
> +				     local->hw.max_tx_aggregation_subframes ?
> +				     local->hw.max_tx_aggregation_subframes :
> +				     0x40,
>  				     tid_tx->timeout);

A define would be better than a magic value. This would also need a
comment but if you choose a good name for the define the comment won't
be needed. Also " ? :" inside a function call is not readable IMHO,
maybe instead a separate variable with if() statements?

-- 
Kalle Valo
--
To unsubscribe from this list: send the line "unsubscribe linux-wireless" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html


[Index of Archives]     [Linux Host AP]     [ATH6KL]     [Linux Bluetooth]     [Linux Netdev]     [Kernel Newbies]     [Linux Kernel]     [IDE]     [Security]     [Git]     [Netfilter]     [Bugtraq]     [Yosemite News]     [MIPS Linux]     [ARM Linux]     [Linux Security]     [Linux RAID]     [Linux ATA RAID]     [Samba]     [Device Mapper]
  Powered by Linux