From: Wolfram Sang <wsa+renesas@sang-engineering.com>
To: linux-i2c@vger.kernel.org
Cc: Wolfram Sang <wsa+renesas@sang-engineering.com>,
Alessandro Zummo <a.zummo@towertech.it>,
Alexandre Belloni <alexandre.belloni@bootlin.com>,
linux-rtc@vger.kernel.org, linux-kernel@vger.kernel.org
Subject: [PATCH 29/34] rtc: rx8010: simplify getting the adapter of a client
Date: Sat, 8 Jun 2019 12:56:08 +0200 [thread overview]
Message-ID: <20190608105619.593-30-wsa+renesas@sang-engineering.com> (raw)
In-Reply-To: <20190608105619.593-1-wsa+renesas@sang-engineering.com>
We have a dedicated pointer for that, so use it. Much easier to read and
less computation involved.
Signed-off-by: Wolfram Sang <wsa+renesas@sang-engineering.com>
---
Please apply to your subsystem tree.
drivers/rtc/rtc-rx8010.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/drivers/rtc/rtc-rx8010.c b/drivers/rtc/rtc-rx8010.c
index 7ddc22eb5b0f..2b58b9b683a9 100644
--- a/drivers/rtc/rtc-rx8010.c
+++ b/drivers/rtc/rtc-rx8010.c
@@ -437,7 +437,7 @@ static struct rtc_class_ops rx8010_rtc_ops = {
static int rx8010_probe(struct i2c_client *client,
const struct i2c_device_id *id)
{
- struct i2c_adapter *adapter = to_i2c_adapter(client->dev.parent);
+ struct i2c_adapter *adapter = client->adapter;
struct rx8010_data *rx8010;
int err = 0;
--
2.19.1
next prev parent reply other threads:[~2019-06-08 10:56 UTC|newest]
Thread overview: 14+ messages / expand[flat|nested] mbox.gz Atom feed top
2019-06-08 10:55 [PATCH 00/34] treewide: simplify getting the adapter of an I2C client Wolfram Sang
2019-06-08 10:56 ` [PATCH 26/34] rtc: fm3130: simplify getting the adapter of a client Wolfram Sang
2019-06-09 14:48 ` Alexandre Belloni
2019-06-08 10:56 ` [PATCH 27/34] rtc: m41t80: " Wolfram Sang
2019-06-09 14:48 ` Alexandre Belloni
2019-06-08 10:56 ` [PATCH 28/34] rtc: rv8803: " Wolfram Sang
2019-06-09 14:49 ` Alexandre Belloni
2019-06-08 10:56 ` Wolfram Sang [this message]
2019-06-09 14:49 ` [PATCH 29/34] rtc: rx8010: " Alexandre Belloni
2019-06-08 10:56 ` [PATCH 30/34] rtc: rx8025: " Wolfram Sang
2019-06-09 14:49 ` Alexandre Belloni
2019-06-09 16:37 ` [PATCH 00/34] treewide: simplify getting the adapter of an I2C client Peter Rosin
2019-06-10 7:15 ` Wolfram Sang
2019-06-27 18:28 ` Sebastian Reichel
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=20190608105619.593-30-wsa+renesas@sang-engineering.com \
--to=wsa+renesas@sang-engineering.com \
--cc=a.zummo@towertech.it \
--cc=alexandre.belloni@bootlin.com \
--cc=linux-i2c@vger.kernel.org \
--cc=linux-kernel@vger.kernel.org \
--cc=linux-rtc@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;
as well as URLs for NNTP newsgroup(s).