of_partition: devfs_add_partition returns an error pointer
Check for the return value of devfs_add_partition with IS_ERR.
Otherwise we dereference a NULL pointer when devfs_add_partition
fails.

Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
1 parent a3abbad commit 01ed1ab7b5966f535a6844eb31a882700e1a9784
@Sascha Hauer Sascha Hauer authored on 31 Jul 2014
Showing 1 changed file
View
drivers/of/partition.c