Re: [PATCH] mac80211 : fix a race with update_tkip_key

Johannes Berg
2009-08-22T07:45:43Z

[-- Attachment #1: Type: text/plain, Size: 764 bytes --]

On Sat, 2009-08-22 at 00:13 +0200, gregor kowski wrote:
> The mac80211 tkip code won't call update_tkip_key, if some rx packets

s/,// s/rx //

> get received without KEY_FLAG_UPLOADED_TO_HARDWARE. This can happen on

s/get/are/

> first packet because the hardware key stuff is called asynchronously with
> todo workqueue.
>
> This patch workaround that by tracking if we send the key to hardware.

s/send/sent/, s/hardware/the driver/

> +enum ieee80211_internal_tkip_initialized {
> + TKIP_INITIALIZED_NONE,
> + TKIP_INITIALIZED_PHASE1,
> + TKIP_INITIALIZED_UPDATE_KEY,
> +};

Those constants and the enum itself really need better names. This way,
there's no way to understand what it means without reading all the code.

johannes

[-- Attachment #2: This is a digitally signed message part --]
[-- Type: application/pgp-signature, Size: 801 bytes --]