]> git.proxmox.com Git - mirror_ubuntu-artful-kernel.git/commit - drivers/base/soc.c
base: soc: Check for NULL SoC device attributes
authorGeert Uytterhoeven <geert+renesas@glider.be>
Mon, 3 Oct 2016 15:43:41 +0000 (17:43 +0200)
committerGeert Uytterhoeven <geert+renesas@glider.be>
Thu, 10 Nov 2016 09:10:33 +0000 (10:10 +0100)
commitab6a713e7dc2f92ad3bc3387122524655431501e
tree2c77f6c81d3665f4e1af5c75d1a989fa55dfd17b
parentc97db7cc7778e34a53b42d58c766f0ec0e30d580
base: soc: Check for NULL SoC device attributes

If soc_device_match() is used to check the value of a specific
attribute that is not present for the current SoC, the kernel crashes
with a NULL pointer dereference.

Fix this by explicitly checking for the absence of a needed property,
and considering this a non-match.

Signed-off-by: Geert Uytterhoeven <geert+renesas@glider.be>
Acked-by: Arnd Bergmann <arnd@arndb.de>
Acked-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
drivers/base/soc.c