From: greg@kroah.com (Greg KH)
To: linux-kernel@vger.kernel.org, sensors@stimpy.netroedge.com
Subject: [PATCH] i2c driver changes for 2.5.67
Date: Thu, 19 May 2005 06:23:53 +0000 [thread overview]
Message-ID: <10499274991641@kroah.com> (raw)
In-Reply-To: <10499274991425@kroah.com>
In-Reply-To: <10499274993464@kroah.com>
ChangeSet 1.1133.1.2, 2003/04/08 02:48:29-07:00, kraxel@bytesex.org
[PATCH] i2c: add i2c_clientname()
This patch just adds a #define and a inline function to hide the
"i2c_client->name" => "i2c_client->dev.name" move introduced by
the recent i2c updates. That makes it easier to build i2c drivers
on both 2.4 and 2.5 kernels.
include/linux/i2c.h | 7 +++++++
1 files changed, 7 insertions(+)
diff -Nru a/include/linux/i2c.h b/include/linux/i2c.h
--- a/include/linux/i2c.h Wed Apr 9 15:16:15 2003
+++ b/include/linux/i2c.h Wed Apr 9 15:16:15 2003
@@ -182,6 +182,13 @@
return dev_set_drvdata (&dev->dev, data);
}
+#define I2C_DEVNAME(str) .dev = { .name = str }
+
+static inline char *i2c_clientname(struct i2c_client *c)
+{
+ return c->dev.name;
+}
+
/*
* The following structs are for those who like to implement new bus drivers:
* i2c_algorithm is the interface to a class of hardware solutions which can
WARNING: multiple messages have this Message-ID (diff)
From: Greg KH <greg@kroah.com>
To: linux-kernel@vger.kernel.org, sensors@stimpy.netroedge.com
Subject: Re: [PATCH] i2c driver changes for 2.5.67
Date: Wed, 9 Apr 2003 15:31:39 -0700 [thread overview]
Message-ID: <10499274991641@kroah.com> (raw)
In-Reply-To: <10499274991425@kroah.com>
ChangeSet 1.1133.1.2, 2003/04/08 02:48:29-07:00, kraxel@bytesex.org
[PATCH] i2c: add i2c_clientname()
This patch just adds a #define and a inline function to hide the
"i2c_client->name" => "i2c_client->dev.name" move introduced by
the recent i2c updates. That makes it easier to build i2c drivers
on both 2.4 and 2.5 kernels.
include/linux/i2c.h | 7 +++++++
1 files changed, 7 insertions(+)
diff -Nru a/include/linux/i2c.h b/include/linux/i2c.h
--- a/include/linux/i2c.h Wed Apr 9 15:16:15 2003
+++ b/include/linux/i2c.h Wed Apr 9 15:16:15 2003
@@ -182,6 +182,13 @@
return dev_set_drvdata (&dev->dev, data);
}
+#define I2C_DEVNAME(str) .dev = { .name = str }
+
+static inline char *i2c_clientname(struct i2c_client *c)
+{
+ return c->dev.name;
+}
+
/*
* The following structs are for those who like to implement new bus drivers:
* i2c_algorithm is the interface to a class of hardware solutions which can
next prev parent reply other threads:[~2005-05-19 6:23 UTC|newest]
Thread overview: 22+ messages / expand[flat|nested] mbox.gz Atom feed top
2003-04-09 22:31 [BK PATCH] i2c driver changes for 2.5.67 Greg KH
2005-05-19 6:23 ` Greg KH
2003-04-09 22:31 ` [PATCH] " Greg KH
2005-05-19 6:23 ` Greg KH
2003-04-09 22:31 ` Greg KH
2005-05-19 6:23 ` Greg KH
2003-04-09 22:31 ` Greg KH
2005-05-19 6:23 ` Greg KH
2003-04-09 22:31 ` Greg KH
2005-05-19 6:23 ` Greg KH
2003-04-09 22:31 ` Greg KH [this message]
2005-05-19 6:23 ` Greg KH
2003-04-09 22:31 ` Greg KH
2005-05-19 6:23 ` Greg KH
2003-04-09 22:31 ` Greg KH
2005-05-19 6:23 ` Greg KH
2003-04-09 22:31 ` Greg KH
2005-05-19 6:23 ` Greg KH
-- strict thread matches above, loose matches on Subject: below --
2003-04-11 23:40 [BK PATCH] i2c driver changes for 2.5.67 - take 2 Greg KH
2005-05-19 6:23 ` Greg KH
2003-04-11 23:46 ` Greg KH
2005-05-19 6:23 ` Greg KH
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=10499274991641@kroah.com \
--to=greg@kroah.com \
--cc=linux-kernel@vger.kernel.org \
--cc=sensors@stimpy.netroedge.com \
/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.