]> git.karo-electronics.de Git - karo-tx-linux.git/commit
ssb: fix NULL ptr deref when pcihost_wrapper is used
authorChristoph Fritz <chf.fritz@googlemail.com>
Fri, 28 May 2010 08:45:59 +0000 (10:45 +0200)
committerGreg Kroah-Hartman <gregkh@suse.de>
Mon, 21 Mar 2011 19:43:28 +0000 (12:43 -0700)
commitab8504259739d876befc79252e73d8017cc28db7
tree590935eaa9fcabf0c06ed936e76a03463df33cef
parent3385fd807f064c6a526af75ad9c0f82ea307aa52
ssb: fix NULL ptr deref when pcihost_wrapper is used

commit da1fdb02d9200ff28b6f3a380d21930335fe5429 upstream.

Ethernet driver b44 does register ssb by it's pcihost_wrapper
and doesn't set ssb_chipcommon. A check on this value
introduced with commit d53cdbb94a52a920d5420ed64d986c3523a56743
and ea2db495f92ad2cf3301623e60cb95b4062bc484 triggers:

BUG: unable to handle kernel NULL pointer dereference at 00000010
IP: [<c1266c36>] ssb_is_sprom_available+0x16/0x30

Signed-off-by: Christoph Fritz <chf.fritz@googlemail.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
Cc: Larry Finger <Larry.Finger@lwfinger.net>
Cc: Ben Hutchings <ben@decadent.org.uk>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
drivers/ssb/pci.c
drivers/ssb/sprom.c