From: Wolfram Sang <wsa@the-dreams.de>
To: linux-i2c@vger.kernel.org
Cc: Peter Rosin <peda@axentia.se>, Wolfram Sang <wsa@the-dreams.de>,
Mauro Carvalho Chehab <mchehab@kernel.org>,
linux-media@vger.kernel.org, linux-kernel@vger.kernel.org
Subject: [PATCH 6/7] media: tm6000: don't check number of messages in the driver
Date: Sun, 20 May 2018 08:50:37 +0200 [thread overview]
Message-ID: <20180520065039.7989-7-wsa@the-dreams.de> (raw)
In-Reply-To: <20180520065039.7989-1-wsa@the-dreams.de>
Since commit 1eace8344c02 ("i2c: add param sanity check to
i2c_transfer()"), the I2C core does this check now. We can remove it
from drivers.
Signed-off-by: Wolfram Sang <wsa@the-dreams.de>
---
Only build tested.
drivers/media/usb/tm6000/tm6000-i2c.c | 2 --
1 file changed, 2 deletions(-)
diff --git a/drivers/media/usb/tm6000/tm6000-i2c.c b/drivers/media/usb/tm6000/tm6000-i2c.c
index 659b63febf85..ccd1adf862b1 100644
--- a/drivers/media/usb/tm6000/tm6000-i2c.c
+++ b/drivers/media/usb/tm6000/tm6000-i2c.c
@@ -145,8 +145,6 @@ static int tm6000_i2c_xfer(struct i2c_adapter *i2c_adap,
struct tm6000_core *dev = i2c_adap->algo_data;
int addr, rc, i, byte;
- if (num <= 0)
- return 0;
for (i = 0; i < num; i++) {
addr = (msgs[i].addr << 1) & 0xff;
i2c_dprintk(2, "%s %s addr=0x%x len=%d:",
--
2.11.0
next prev parent reply other threads:[~2018-05-20 6:50 UTC|newest]
Thread overview: 8+ messages / expand[flat|nested] mbox.gz Atom feed top
2018-05-20 6:50 [PATCH 0/7] don't check number of I2C messages in drivers Wolfram Sang
2018-05-20 6:50 ` [PATCH 1/7] media: netup_unidvb: don't check number of messages in the driver Wolfram Sang
2018-05-20 6:50 ` [PATCH 2/7] media: si4713: " Wolfram Sang
2018-05-20 6:50 ` [PATCH 3/7] media: cx231xx: " Wolfram Sang
2018-05-20 6:50 ` [PATCH 4/7] media: em28xx: " Wolfram Sang
2018-05-20 6:50 ` [PATCH 5/7] media: hdpvr: " Wolfram Sang
2018-05-20 6:50 ` Wolfram Sang [this message]
2018-05-20 6:50 ` [PATCH 7/7] media: dvb-usb: " Wolfram Sang
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=20180520065039.7989-7-wsa@the-dreams.de \
--to=wsa@the-dreams.de \
--cc=linux-i2c@vger.kernel.org \
--cc=linux-kernel@vger.kernel.org \
--cc=linux-media@vger.kernel.org \
--cc=mchehab@kernel.org \
--cc=peda@axentia.se \
/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;
as well as URLs for NNTP newsgroup(s).