drm/panel: rpi-touchscreen: propagate errors in rpi_touchscreen_i2c_read()
authorDan Carpenter <dan.carpenter@oracle.com>
Fri, 20 Oct 2017 00:28:45 +0000 (03:28 +0300)
committerRaspbian kernel package updater <root@raspbian.org>
Sat, 31 Mar 2018 14:57:32 +0000 (15:57 +0100)
commit2f1a46685ba019d37b5da70b6ce4140aa0fba356
tree2ab947f6cab40366774d0a90d00cad497960ab81
parent8cddd37e0372060a285dc6a8eeacecd6af01feac
drm/panel: rpi-touchscreen: propagate errors in rpi_touchscreen_i2c_read()

There is one caller which checks whether rpi_touchscreen_i2c_read()
returns negative error codes.  Currently it can't because negative
error codes are truncated to u8, but that's easy to fix if we change the
type to int.

Fixes: 2f733d6194bd ("drm/panel: Add support for the Raspberry Pi 7" Touchscreen.")
Signed-off-by: Dan Carpenter <dan.carpenter@oracle.com>
Signed-off-by: Eric Anholt <eric@anholt.net>
Link: https://patchwork.freedesktop.org/patch/msgid/20171020002845.kar2wg7gqxg7tzqi@mwanda
Reviewed-by: Eric Anholt <eric@anholt.net>
(cherry picked from commit 85b4587f8e94143bafb8b6a4003a5187b9a8753d)
drivers/gpu/drm/panel/panel-raspberrypi-touchscreen.c