From: Dmitry Torokhov <dmitry.torokhov@gmail.com>
To: Irina Tirdea <irina.tirdea@intel.com>
Cc: Bastien Nocera <hadess@hadess.net>,
linux-input@vger.kernel.org, devicetree@vger.kernel.org,
linux-kernel@vger.kernel.org
Subject: Re: [PATCH 1/9] input: goodix: fix alignment issues
Date: Fri, 5 Jun 2015 09:49:01 -0700 [thread overview]
Message-ID: <20150605164901.GE26708@dtor-ws> (raw)
In-Reply-To: <1432817265-23891-2-git-send-email-irina.tirdea@intel.com>
Hi Irina,
On Thu, May 28, 2015 at 03:47:37PM +0300, Irina Tirdea wrote:
> Fix alignment to match open parenthesis detected by
> running checkpatch.pl --strict.
Mixed bag of changes here, but that's checkpatch for you.
>
> Signed-off-by: Irina Tirdea <irina.tirdea@intel.com>
> ---
> drivers/input/touchscreen/goodix.c | 17 +++++++++--------
> 1 file changed, 9 insertions(+), 8 deletions(-)
>
> diff --git a/drivers/input/touchscreen/goodix.c b/drivers/input/touchscreen/goodix.c
> index 0d93b1e..c2e785c 100644
> --- a/drivers/input/touchscreen/goodix.c
> +++ b/drivers/input/touchscreen/goodix.c
> @@ -69,7 +69,7 @@ static const unsigned long goodix_irq_flags[] = {
> * @len: length of the buffer to write
> */
> static int goodix_i2c_read(struct i2c_client *client,
> - u16 reg, u8 *buf, int len)
> + u16 reg, u8 *buf, int len)
> {
> struct i2c_msg msgs[2];
> u16 wbuf = cpu_to_be16(reg);
> @@ -78,7 +78,7 @@ static int goodix_i2c_read(struct i2c_client *client,
> msgs[0].flags = 0;
> msgs[0].addr = client->addr;
> msgs[0].len = 2;
> - msgs[0].buf = (u8 *) &wbuf;
> + msgs[0].buf = (u8 *)&wbuf;
Good.
>
> msgs[1].flags = I2C_M_RD;
> msgs[1].addr = client->addr;
> @@ -112,7 +112,7 @@ static int goodix_ts_read_input_report(struct goodix_ts_data *ts, u8 *data)
> data += 1 + GOODIX_CONTACT_SIZE;
> error = goodix_i2c_read(ts->client,
> GOODIX_READ_COOR_ADDR +
> - 1 + GOODIX_CONTACT_SIZE,
> + 1 + GOODIX_CONTACT_SIZE,
Bad - makes 1 + GOODIX_CONTACT_SIZE look like extra argument, not
continuation of expression.
> data,
> GOODIX_CONTACT_SIZE * (touch_num - 1));
> if (error)
> @@ -157,7 +157,8 @@ static void goodix_process_events(struct goodix_ts_data *ts)
>
> for (i = 0; i < touch_num; i++)
> goodix_ts_report_touch(ts,
> - &point_data[1 + GOODIX_CONTACT_SIZE * i]);
> + &point_data[1 +
> + GOODIX_CONTACT_SIZE * i]);
No, this is plain ugly.
>
> input_mt_sync_frame(ts->input_dev);
> input_sync(ts->input_dev);
> @@ -199,8 +200,8 @@ static void goodix_read_config(struct goodix_ts_data *ts)
> int error;
>
> error = goodix_i2c_read(ts->client, GOODIX_REG_CONFIG_DATA,
> - config,
> - GOODIX_CONFIG_MAX_LENGTH);
> + config,
> + GOODIX_CONFIG_MAX_LENGTH);
Good.
> if (error) {
> dev_warn(&ts->client->dev,
> "Error reading config (%d), using defaults\n",
> @@ -297,9 +298,9 @@ static int goodix_request_input_dev(struct goodix_ts_data *ts)
> BIT_MASK(EV_ABS);
>
> input_set_abs_params(ts->input_dev, ABS_MT_POSITION_X, 0,
> - ts->abs_x_max, 0, 0);
> + ts->abs_x_max, 0, 0);
Good.
> input_set_abs_params(ts->input_dev, ABS_MT_POSITION_Y, 0,
> - ts->abs_y_max, 0, 0);
> + ts->abs_y_max, 0, 0);
Good.
> input_set_abs_params(ts->input_dev, ABS_MT_WIDTH_MAJOR, 0, 255, 0, 0);
> input_set_abs_params(ts->input_dev, ABS_MT_TOUCH_MAJOR, 0, 255, 0, 0);
>
> --
> 1.9.1
>
Thanks.
--
Dmitry
next prev parent reply other threads:[~2015-06-05 16:49 UTC|newest]
Thread overview: 62+ messages / expand[flat|nested] mbox.gz Atom feed top
2015-05-28 12:47 [PATCH 0/9] Goodix touchscreen enhancements Irina Tirdea
2015-05-28 12:47 ` [PATCH 1/9] input: goodix: fix alignment issues Irina Tirdea
2015-06-04 12:48 ` Bastien Nocera
2015-06-05 16:49 ` Dmitry Torokhov [this message]
2015-06-05 17:07 ` Tirdea, Irina
2015-06-05 17:17 ` Joe Perches
2015-06-05 17:31 ` Dmitry Torokhov
2015-05-28 12:47 ` [PATCH 2/9] input: goodix: fix variable length array warning Irina Tirdea
2015-05-28 15:57 ` Antonio Ospite
2015-06-03 10:26 ` Tirdea, Irina
2015-06-03 20:49 ` Antonio Ospite
2015-06-03 20:49 ` Antonio Ospite
2015-06-05 16:34 ` Tirdea, Irina
2015-06-05 16:34 ` Tirdea, Irina
2015-06-05 16:40 ` Dmitry Torokhov
2015-06-05 16:40 ` Dmitry Torokhov
2015-06-05 17:00 ` Tirdea, Irina
2015-06-05 17:00 ` Tirdea, Irina
2015-06-05 17:11 ` Dmitry Torokhov
2015-06-05 17:11 ` Dmitry Torokhov
2015-06-05 17:34 ` Tirdea, Irina
2015-06-05 17:34 ` Tirdea, Irina
2015-05-28 12:47 ` [PATCH 3/9] input: goodix: export id and version read from device Irina Tirdea
2015-05-28 12:47 ` [PATCH 4/9] input: goodix: add ACPI IDs for GT911 and GT9271 Irina Tirdea
2015-06-04 12:51 ` Bastien Nocera
2015-06-05 16:36 ` Tirdea, Irina
2015-06-05 16:36 ` Tirdea, Irina
2015-06-05 16:41 ` Dmitry Torokhov
2015-06-05 17:01 ` Tirdea, Irina
2015-06-05 17:01 ` Tirdea, Irina
2015-05-28 12:47 ` [PATCH 5/9] input: goodix: reset device at init Irina Tirdea
[not found] ` <1432817265-23891-6-git-send-email-irina.tirdea-ral2JQCrhuEAvxtiuMwx3w@public.gmane.org>
2015-05-28 13:19 ` Mark Rutland
2015-05-28 13:19 ` Mark Rutland
2015-05-28 13:42 ` Tirdea, Irina
2015-05-28 12:47 ` [PATCH 6/9] input: goodix: write configuration data to device Irina Tirdea
2015-05-28 13:21 ` Mark Rutland
2015-05-28 13:51 ` Tirdea, Irina
2015-06-04 12:55 ` Bastien Nocera
2015-06-05 16:36 ` Tirdea, Irina
2015-06-05 16:36 ` Tirdea, Irina
2015-06-05 16:43 ` Dmitry Torokhov
2015-06-05 17:05 ` Tirdea, Irina
2015-05-28 12:47 ` [PATCH 7/9] input: goodix: add power management support Irina Tirdea
2015-06-04 13:01 ` Bastien Nocera
2015-06-05 16:42 ` Tirdea, Irina
2015-06-05 16:42 ` Tirdea, Irina
[not found] ` <1432817265-23891-1-git-send-email-irina.tirdea-ral2JQCrhuEAvxtiuMwx3w@public.gmane.org>
2015-05-28 12:47 ` [PATCH 8/9] input: goodix: add support for ESD Irina Tirdea
2015-05-28 12:47 ` Irina Tirdea
[not found] ` <1432817265-23891-9-git-send-email-irina.tirdea-ral2JQCrhuEAvxtiuMwx3w@public.gmane.org>
2015-05-28 13:23 ` Mark Rutland
2015-05-28 13:23 ` Mark Rutland
2015-05-28 14:26 ` Tirdea, Irina
2015-06-04 12:57 ` Bastien Nocera
2015-06-05 16:37 ` Tirdea, Irina
2015-06-05 16:37 ` Tirdea, Irina
2015-06-05 16:46 ` Dmitry Torokhov
2015-06-08 14:28 ` Tirdea, Irina
2015-07-30 12:06 ` Tirdea, Irina
2015-05-28 12:47 ` [PATCH 9/9] input: goodix: use goodix_i2c_write_u8 instead of i2c_master_send Irina Tirdea
2015-05-28 12:47 ` Irina Tirdea
2015-06-04 13:04 ` [PATCH 0/9] Goodix touchscreen enhancements Bastien Nocera
2015-06-05 16:36 ` Tirdea, Irina
2015-06-05 16:36 ` Tirdea, Irina
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20150605164901.GE26708@dtor-ws \
--to=dmitry.torokhov@gmail.com \
--cc=devicetree@vger.kernel.org \
--cc=hadess@hadess.net \
--cc=irina.tirdea@intel.com \
--cc=linux-input@vger.kernel.org \
--cc=linux-kernel@vger.kernel.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.