sc16is7xx: null ptr check
authorSean Nyekjaer <sean.nyekjaer@prevas.dk>
Sun, 4 Oct 2015 16:59:45 +0000 (18:59 +0200)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Sun, 4 Oct 2015 18:14:26 +0000 (19:14 +0100)
commit2b0159d1ecfbc11badb96466c0c1582ee5ffe78f
tree4b927dd4e443947073e3b958803d1694db261b1f
parentadfb9233e434896e87811339ca0c18bc923b262f
sc16is7xx: null ptr check

If a wrong compatible flag in specified, the of_match_device
returning null.
Implemented check and if NULL then returning -ENODEV.

Signed-off-by: Sean Nyekjaer <sean.nyekjaer@prevas.dk>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
drivers/tty/serial/sc16is7xx.c