Commit 39841136 authored by Linus Walleij's avatar Linus Walleij Committed by Dmitry Torokhov
Browse files

Input: cyttsp - error message on boot mode exit error



Provide a proper error message when attempting to exit boot loader mode
and failing, which is something that happened to me.

Reviewed-by: default avatarJavier Martinez Canillas <javier@dowhile0.org>
Signed-off-by: default avatarLinus Walleij <linus.walleij@linaro.org>
Link: https://lore.kernel.org/r/20210408131153.3446138-5-linus.walleij@linaro.org


Signed-off-by: default avatarDmitry Torokhov <dmitry.torokhov@gmail.com>
parent 236798a1
Loading
Loading
Loading
Loading
+3 −1
Original line number Diff line number Diff line
@@ -408,9 +408,11 @@ static int cyttsp_power_on(struct cyttsp *ts)
	if (GET_BOOTLOADERMODE(ts->bl_data.bl_status) &&
	    IS_VALID_APP(ts->bl_data.bl_status)) {
		error = cyttsp_exit_bl_mode(ts);
		if (error)
		if (error) {
			dev_err(ts->dev, "failed to exit bootloader mode\n");
			return error;
		}
	}

	if (GET_HSTMODE(ts->bl_data.bl_file) != CY_OPERATE_MODE ||
	    IS_OPERATIONAL_ERR(ts->bl_data.bl_status)) {