[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <20240506182111.3c6673a0@aktux>
Date: Mon, 6 May 2024 18:21:11 +0200
From: Andreas Kemnade <andreas@...nade.info>
To: Andy Shevchenko <andy.shevchenko@...il.com>
Cc: dmitry.torokhov@...il.com, robh@...nel.org, krzk+dt@...nel.org,
 conor+dt@...nel.org, u.kleine-koenig@...gutronix.de, hdegoede@...hat.com,
 siebren.vroegindeweij@...mail.com, linux-input@...r.kernel.org,
 devicetree@...r.kernel.org, linux-kernel@...r.kernel.org
Subject: Re: [PATCH v2 3/3] Input: ektf2127 - add ektf2232 support
On Mon, 6 May 2024 15:05:52 +0300
Andy Shevchenko <andy.shevchenko@...il.com> wrote:
> From: Andy Shevchenko <andy.shevchenko@...il.com>
> To: Andreas Kemnade <andreas@...nade.info>
> Cc: dmitry.torokhov@...il.com, robh@...nel.org, krzk+dt@...nel.org,   conor+dt@...nel.org, u.kleine-koenig@...gutronix.de, hdegoede@...hat.com,   siebren.vroegindeweij@...mail.com, linux-input@...r.kernel.org,   devicetree@...r.kernel.org, linux-kernel@...r.kernel.org
> Subject: Re: [PATCH v2 3/3] Input: ektf2127 - add ektf2232 support
> Date: Mon, 6 May 2024 15:05:52 +0300
> 
> On Mon, May 6, 2024 at 12:48 AM Andreas Kemnade <andreas@...nade.info> wrote:
> >
> > The chip is similar, but has status bits at different positions,
> > so use the correct bits.  
> 
> ...
> 
> > @@ -46,6 +47,11 @@ struct ektf2127_ts {
> >         struct input_dev *input;
> >         struct gpio_desc *power_gpios;
> >         struct touchscreen_properties prop;
> > +       int status_shift;
> > +};
> > +
> > +struct ektf2127_i2c_chip_data {
> > +       int status_shift;
> >  };
> >
> >  static void ektf2127_parse_coordinates(const u8 *buf, unsigned int touch_count,  
> 
> I'm wondering if you are using --histogram diff algo when preparing the patches.
No, I am not using that, it seems to not make that chunk nicer. 
Yes, we want
+       int status_shift;
 };
+
+struct ektf2127_i2c_chip_data {
+       int status_shift;
+};
But that is not shorter or simpler, just more readable.
Regards,
Andreas
Powered by blists - more mailing lists
 
