staging: vchiq_arm: Improve error handling on loading drivers
authorDave Stevenson <dave.stevenson@raspberrypi.org>
Mon, 3 Dec 2018 12:50:38 +0000 (12:50 +0000)
committerpopcornmix <popcornmix@gmail.com>
Mon, 13 May 2019 23:08:11 +0000 (00:08 +0100)
commit83111772d9a6486a4acffe8f389d8bcdf05996d0
tree81334f3bc92ac081fe8eed3d803f7e7da8d075dd
parent8f1103e1e713f0a6aea2cbf85c51eb9ecc04c913
staging: vchiq_arm: Improve error handling on loading drivers

The handling of loading platform drivers requires checking IS_ERR
for the pointer on unload.
If the driver fails to load, NULL the pointer during probe as
platform_device_unregister already checks for NULL.

Signed-off-by: Dave Stevenson <dave.stevenson@raspberrypi.org>
drivers/staging/vc04_services/interface/vchiq_arm/vchiq_arm.c