Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
spi: orion: fix potential NULL pointer de-reference
It's possible that the call to of_match_device() (introduced in commit df59fa7 ["spi: orion: support armada extended baud rates"]) may return a NULL if there is no match in the device tree (or perhaps no device tree at all). Check the return pointer and set the local device data to the lowest common denominator orion device data if it is NULL. Reported-by: Karl Beldan <karl.beldan@gmail.com> Signed-off-by: Greg Ungerer <gerg@uclinux.org> Signed-off-by: Mark Brown <broonie@kernel.org>
- Loading branch information