]> www.infradead.org Git - users/jedix/linux-maple.git/commit
rt61pci: fix NULL pointer dereference in config_lna_gain
authorStanislaw Gruszka <sgruszka@redhat.com>
Fri, 3 Aug 2012 10:49:14 +0000 (12:49 +0200)
committerMaxim Uvarov <maxim.uvarov@oracle.com>
Mon, 8 Oct 2012 12:13:16 +0000 (05:13 -0700)
commit2036506f6934b8f12d85209d3d9737bd4ef8e355
treef2f6be227cc7888ec3ef406969c408a7090a474f
parent9c73ee3629f3ceb1b0db317bc79e77cb9b8056f6
rt61pci: fix NULL pointer dereference in config_lna_gain

commit deee0214def5d8a32b8112f11d9c2b1696e9c0cb upstream.

We can not pass NULL libconf->conf->channel to rt61pci_config() as it
is dereferenced unconditionally in rt61pci_config_lna_gain() subroutine.

Resolves:
https://bugzilla.kernel.org/show_bug.cgi?id=44361

Reported-and-tested-by: <dolohow@gmail.com>
Signed-off-by: Stanislaw Gruszka <sgruszka@redhat.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
drivers/net/wireless/rt2x00/rt61pci.c