From: Ben Dooks <ben-linux@fluff.org>
To: linux-kernel@vger.kernel.org
Cc: linux-fsdevel@vger.kernel.org, viro@zeniv.linux.org.uk,
Ben Dooks <ben-linux@fluff.org>
Subject: [PATCH] i2c: Fix warnings from I2C_BOARD_INFO()
Date: Tue, 14 Apr 2009 14:47:02 +0100 [thread overview]
Message-ID: <1239716822-29143-1-git-send-email-ben-linux@fluff.org> (raw)
The first argument for this macro is a string, and
thus having (arg) in the macro is causing gcc 4.2.4
to produce warnings about strings of the form ("str").
Remove the brackets from the first argument.
example warning:
mach-bast.c:545:3: warning: array initialized from parenthesized string constant
Signed-off-by: Ben Dooks <ben-linux@fluff.org>
---
include/linux/i2c.h | 2 +-
1 files changed, 1 insertions(+), 1 deletions(-)
diff --git a/include/linux/i2c.h b/include/linux/i2c.h
index 00ee11e..ad25805 100644
--- a/include/linux/i2c.h
+++ b/include/linux/i2c.h
@@ -274,7 +274,7 @@ struct i2c_board_info {
* are provided using conventional syntax.
*/
#define I2C_BOARD_INFO(dev_type, dev_addr) \
- .type = (dev_type), .addr = (dev_addr)
+ .type = dev_type, .addr = (dev_addr)
/* Add-on boards should register/unregister their devices; e.g. a board
--
1.5.6.5
next reply other threads:[~2009-04-14 13:50 UTC|newest]
Thread overview: 3+ messages / expand[flat|nested] mbox.gz Atom feed top
2009-04-14 13:47 Ben Dooks [this message]
2009-04-14 14:11 ` [PATCH] i2c: Fix warnings from I2C_BOARD_INFO() Mark Brown
2009-04-14 14:13 ` Ben Dooks
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=1239716822-29143-1-git-send-email-ben-linux@fluff.org \
--to=ben-linux@fluff.org \
--cc=linux-fsdevel@vger.kernel.org \
--cc=linux-kernel@vger.kernel.org \
--cc=viro@zeniv.linux.org.uk \
/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).