From: Dan Carpenter <dan.carpenter@oracle.com>
To: Jonathan Cameron <jic23@cam.ac.uk>
Cc: Greg Kroah-Hartman <gregkh@suse.de>,
Bryan Freed <bfreed@chromium.org>,
Michael Hennerich <Michael.Hennerich@analog.com>,
Arnd Bergmann <arnd@arndb.de>,
linux-iio@vger.kernel.org, devel@driverdev.osuosl.org,
kernel-janitors@vger.kernel.org
Subject: [patch 2/2] Staging: iio/light/tsl2563: fix compile warning
Date: Thu, 06 Oct 2011 06:15:36 +0000 [thread overview]
Message-ID: <20111006061536.GB14701@elgon.mountain> (raw)
This fixes a compile warning:
drivers/staging/iio/light/tsl2563.c:696:2:
warning: initialization from incompatible pointer type [enabled by default]
drivers/staging/iio/light/tsl2563.c:696:2:
warning: (near initialization for ‘tsl2563_info.write_event_value’) [enabled by default]
The tsl2563_write_thresh() function returns zero on success and error
codes on failure, so nothing is lost by making the return type int
instead of ssize_t.
Signed-off-by: Dan Carpenter <dan.carpenter@oracle.com>
diff --git a/drivers/staging/iio/light/tsl2563.c b/drivers/staging/iio/light/tsl2563.c
index 8977f58..a5e08b3 100644
--- a/drivers/staging/iio/light/tsl2563.c
+++ b/drivers/staging/iio/light/tsl2563.c
@@ -569,7 +569,7 @@ static int tsl2563_read_thresh(struct iio_dev *indio_dev,
return 0;
}
-static ssize_t tsl2563_write_thresh(struct iio_dev *indio_dev,
+static int tsl2563_write_thresh(struct iio_dev *indio_dev,
u64 event_code,
int val)
{
next reply other threads:[~2011-10-06 6:15 UTC|newest]
Thread overview: 2+ messages / expand[flat|nested] mbox.gz Atom feed top
2011-10-06 6:15 Dan Carpenter [this message]
2011-10-06 11:11 ` [patch 2/2] Staging: iio/light/tsl2563: fix compile warning Jonathan Cameron
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=20111006061536.GB14701@elgon.mountain \
--to=dan.carpenter@oracle.com \
--cc=Michael.Hennerich@analog.com \
--cc=arnd@arndb.de \
--cc=bfreed@chromium.org \
--cc=devel@driverdev.osuosl.org \
--cc=gregkh@suse.de \
--cc=jic23@cam.ac.uk \
--cc=kernel-janitors@vger.kernel.org \
--cc=linux-iio@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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox