]> git.kernelconcepts.de Git - karo-tx-linux.git/commit
mac80211: pid, fix memory corruption
authorJiri Slaby <jirislaby@gmail.com>
Mon, 4 May 2009 16:10:28 +0000 (18:10 +0200)
committerGreg Kroah-Hartman <gregkh@suse.de>
Mon, 15 Jun 2009 16:40:12 +0000 (09:40 -0700)
commit94a9ef2fbeed9360a2036fcc79873dcf9ab7acf3
treea37a6a229ee7c86637e97f74f524668c4eb9be79
parent5a28cafbab1d07e4161f00678b6a45620a2c2e4f
mac80211: pid, fix memory corruption

commit 6909268dc93ae4b0b8e1ebb4b2fa70b1a47dd347 upstream.

pid doesn't count with some band having more bitrates than the one
associated the first time.
Fix that by counting the maximal available bitrate count and allocate
big enough space.

Secondly, fix touching uninitialized memory which causes panics.
Index sucked from this random memory points to the hell.
The fix is to sort the rates on each band change.

Signed-off-by: Jiri Slaby <jirislaby@gmail.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
net/mac80211/rc80211_pid_algo.c