spi: rspi: Fix NULL pointer dereference on SH7757
SH7757 doesn't pass platform data, in which case spi-rspi uses default
parameters.
However, commit 5ce0ba88650f2606244a761d92e2b725f4ab3583 ("spi: rcar: add
Renesas QSPI support on RSPI") added a new user of the platform data, but
forgot to check for its validity first, causing a NULL pointer dereference
on SH7757.
Add the missing check to fix this.
Signed-off-by: Geert Uytterhoeven <geert+renesas@linux-m68k.org>
Acked-by: Simon Horman <horms+renesas@verge.net.au>
Signed-off-by: Mark Brown <broonie@linaro.org>
1 file changed