staging: vchiq_2835_arm: Make cache-line-size a required DT property
authorMichael Zoran <mzoran@crowfest.net>
Sat, 18 Feb 2017 11:22:01 +0000 (03:22 -0800)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Sun, 26 Feb 2017 16:05:48 +0000 (17:05 +0100)
commit6cf1bf636a067eb308cb3a8322b9d6b1844a075d
tree9fb47bc5a7b9f29c6284c1c4017f1679c876d477
parentf4082c6f28a8e77dcb694c6f23de9e533251051d
staging: vchiq_2835_arm: Make cache-line-size a required DT property

The original github source allowed for the cache-line-size property
to be missing.  Since recent firmwares also require this property,
it makes sense to always require it in the driver as well.

If the cache-line-size property is missing, then the driver probe
should fail as no dev since the kernel and dt may be out of sync.
The fix is to add a check for the return value of of_property_read_u32.

Changes V2:
1. Add error message if cache-line-size is missing.
2. Simple check for non-zero return value from
   of_property_read_u32.

Signed-off-by: Michael Zoran <mzoran@crowfest.net>
Acked-by: Stefan Wahren <stefan.wahren@i2se.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
drivers/staging/vc04_services/interface/vchiq_arm/vchiq_2835_arm.c