[<prev] [next>] [<thread-prev] [day] [month] [year] [list]
Message-ID: <YTWDW0bt32GRp3PU@google.com>
Date: Sun, 5 Sep 2021 19:56:27 -0700
From: Dmitry Torokhov <dmitry.torokhov@...il.com>
To: "simba.hsu" <simba.hsu@...dium.corp-partner.google.com>
Cc: simba.hsu@...-ic.com, furquan@...gle.com, seanpaul@...omium.org,
rrangle@...omium.org, linux-input@...r.kernel.org,
linux-kernel@...r.kernel.org, KP.li@...-ic.com,
jeffrey.lin@...-ic.com
Subject: Re: [PATCH] Input: raydium_i2c_ts - read device version in
bootloader mode
On Wed, Aug 18, 2021 at 02:36:44PM +0800, simba.hsu wrote:
> Add support reading device ID when controller is in bootloader
> mode, which may happen if firmware update has been interrupted.
>
> Signed-off-by: simba.hsu <simba.hsu@...-ic.com>
> ---
> drivers/input/touchscreen/raydium_i2c_ts.c | 52 ++++++++++++++++++----
> 1 file changed, 44 insertions(+), 8 deletions(-)
>
> diff --git a/drivers/input/touchscreen/raydium_i2c_ts.c b/drivers/input/touchscreen/raydium_i2c_ts.c
> index 4d2d22a86977..d3f8cc3285a2 100644
> --- a/drivers/input/touchscreen/raydium_i2c_ts.c
> +++ b/drivers/input/touchscreen/raydium_i2c_ts.c
> @@ -36,7 +36,8 @@
> #define RM_CMD_BOOT_CHK 0x33 /* send data check */
> #define RM_CMD_BOOT_READ 0x44 /* send wait bl data ready*/
>
> -#define RM_BOOT_RDY 0xFF /* bl data ready */
> +#define RM_BOOT_RDY 0xFF /* bl data ready */
> +#define RM_BOOT_CMD_READHWID 0x0E /* read hwid */
>
> /* I2C main commands */
> #define RM_CMD_QUERY_BANK 0x2B
> @@ -155,6 +156,7 @@ static int raydium_i2c_xfer(struct i2c_client *client, u32 addr,
> * sent first. Else, skip the header i.e. xfer[0].
> */
> int xfer_start_idx = (addr > 0xff) ? 0 : 1;
> +
> xfer_count -= xfer_start_idx;
I dropped this unrelated chunk, made couple of cosmetic changes and
applied, thank you.
--
Dmitry
Powered by blists - more mailing lists