]> git.karo-electronics.de Git - karo-tx-linux.git/commit
atl1: fix resume
authorLuca Tettamanti <kronos.it@gmail.com>
Wed, 22 Sep 2010 10:41:58 +0000 (10:41 +0000)
committerGreg Kroah-Hartman <gregkh@suse.de>
Mon, 21 Mar 2011 19:43:17 +0000 (12:43 -0700)
commit3220aa132790e798b2ebb3b43aa6545d25f24b8e
tree384986857a1e87399cef4fee31eeb6c00563ee00
parent99d1bac7375639ceb89e20f5a56b000a2fbf434b
atl1: fix resume

commit ec5a32f67c603b11d68eb283d94eb89a4f6cfce1 upstream.

adapter->cmb.cmb is initialized when the device is opened and freed when
it's closed. Accessing it unconditionally during resume results either
in a crash (NULL pointer dereference, when the interface has not been
opened yet) or data corruption (when the interface has been used and
brought down adapter->cmb.cmb points to a deallocated memory area).

Signed-off-by: Luca Tettamanti <kronos.it@gmail.com>
Acked-by: Chris Snook <chris.snook@gmail.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
drivers/net/atlx/atl1.c