mirror of https://lore.kernel.org/lkml/
 help / color / mirror / Atom feed
From: Irina Tirdea <irina.tirdea@intel.com>
To: Dmitry Torokhov <dmitry.torokhov@gmail.com>,
	Bastien Nocera <hadess@hadess.net>,
	Mark Rutland <mark.rutland@arm.com>,
	linux-input@vger.kernel.org, devicetree@vger.kernel.org
Cc: linux-kernel@vger.kernel.org, Rob Herring <robh+dt@kernel.org>,
	Pawel Moll <pawel.moll@arm.com>,
	Ian Campbell <ijc+devicetree@hellion.org.uk>,
	Kumar Gala <galak@codeaurora.org>,
	Irina Tirdea <irina.tirdea@intel.com>
Subject: [PATCH v3 4/5] Input: goodix - use goodix_i2c_write_u8 instead of i2c_master_send
Date: Mon, 29 Jun 2015 19:28:23 +0300	[thread overview]
Message-ID: <1435595304-4840-5-git-send-email-irina.tirdea@intel.com> (raw)
In-Reply-To: <1435595304-4840-1-git-send-email-irina.tirdea@intel.com>

Use goodix_i2c_write_u8 instead of i2c_master_send to simplify code.

Signed-off-by: Irina Tirdea <irina.tirdea@intel.com>
---
 drivers/input/touchscreen/goodix.c | 7 +------
 1 file changed, 1 insertion(+), 6 deletions(-)

diff --git a/drivers/input/touchscreen/goodix.c b/drivers/input/touchscreen/goodix.c
index a50a1fd..7958d50 100644
--- a/drivers/input/touchscreen/goodix.c
+++ b/drivers/input/touchscreen/goodix.c
@@ -235,16 +235,11 @@ static void goodix_process_events(struct goodix_ts_data *ts)
  */
 static irqreturn_t goodix_ts_irq_handler(int irq, void *dev_id)
 {
-	static const u8 end_cmd[] = {
-		GOODIX_READ_COOR_ADDR >> 8,
-		GOODIX_READ_COOR_ADDR & 0xff,
-		0
-	};
 	struct goodix_ts_data *ts = dev_id;
 
 	goodix_process_events(ts);
 
-	if (i2c_master_send(ts->client, end_cmd, sizeof(end_cmd)) < 0)
+	if (goodix_i2c_write_u8(ts->client, GOODIX_READ_COOR_ADDR, 0) < 0)
 		dev_err(&ts->client->dev, "I2C write end_cmd error\n");
 
 	return IRQ_HANDLED;
-- 
1.9.1


  parent reply	other threads:[~2015-06-29 16:30 UTC|newest]

Thread overview: 19+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2015-06-29 16:28 [PATCH v3 0/5] Goodix touchscreen enhancements Irina Tirdea
2015-06-29 16:28 ` [PATCH v3 1/5] Input: goodix - reset device at init Irina Tirdea
2015-06-30 15:56   ` Bastien Nocera
2015-07-30 11:27     ` Tirdea, Irina
2015-09-09 17:02       ` Bastien Nocera
2015-09-10 14:04         ` Tirdea, Irina
2015-09-25 14:44           ` Bastien Nocera
2015-09-25 21:04             ` Tirdea, Irina
2015-09-29  2:04               ` Bastien Nocera
2015-09-29 17:47                 ` Tirdea, Irina
2015-09-30 11:15                   ` Bastien Nocera
2015-09-30 14:01                     ` Carlos Garnacho
2015-10-01 14:42                       ` Tirdea, Irina
2015-06-29 16:28 ` [PATCH v3 2/5] Input: goodix - write configuration data to device Irina Tirdea
2015-06-29 16:28 ` [PATCH v3 3/5] Input: goodix - add power management support Irina Tirdea
2015-06-30 15:56   ` Bastien Nocera
2015-07-30 11:32     ` Tirdea, Irina
2015-06-29 16:28 ` Irina Tirdea [this message]
2015-06-29 16:28 ` [PATCH v3 5/5] Input: goodix - add support for ESD Irina Tirdea

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=1435595304-4840-5-git-send-email-irina.tirdea@intel.com \
    --to=irina.tirdea@intel.com \
    --cc=devicetree@vger.kernel.org \
    --cc=dmitry.torokhov@gmail.com \
    --cc=galak@codeaurora.org \
    --cc=hadess@hadess.net \
    --cc=ijc+devicetree@hellion.org.uk \
    --cc=linux-input@vger.kernel.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=mark.rutland@arm.com \
    --cc=pawel.moll@arm.com \
    --cc=robh+dt@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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox

all inboxes | Powered by JetHome®