summaryrefslogtreecommitdiff
path: root/drivers/rtc
diff options
context:
space:
mode:
authorWolfram Sang <wsa+renesas@sang-engineering.com>2019-06-08 12:56:08 +0200
committerAlexandre Belloni <alexandre.belloni@bootlin.com>2019-06-09 16:48:08 +0200
commit9d085c54202dec9abcf401eb77013ea8603f5188 (patch)
treea0021e780acb22a00493fb9564a9a5834c88bf4f /drivers/rtc
parent5cb172694a010c9ec786f6ecc2290369f7271108 (diff)
rtc: rx8010: simplify getting the adapter of a client
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> Signed-off-by: Alexandre Belloni <alexandre.belloni@bootlin.com>
Diffstat (limited to 'drivers/rtc')
-rw-r--r--drivers/rtc/rtc-rx8010.c2
1 files changed, 1 insertions, 1 deletions
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;