From: Jingoo Han <jg1.han@samsung.com>
To: "'Andrew Morton'" <akpm@linux-foundation.org>
Cc: linux-kernel@vger.kernel.org,
"'Alessandro Zummo'" <a.zummo@towertech.it>,
rtc-linux@googlegroups.com, "'Jingoo Han'" <jg1.han@samsung.com>
Subject: [PATCH 14/15] rtc: rtc-sh: use dev_get_platdata()
Date: Mon, 23 Sep 2013 18:52:30 +0900 [thread overview]
Message-ID: <002a01ceb842$9e288110$da798330$%han@samsung.com> (raw)
In-Reply-To: <001801ceb840$9a81ab10$cf850130$%han@samsung.com>
Use the wrapper function for retrieving the platform data instead of
accessing dev->platform_data directly. This is a cosmetic change
to make the code simpler and enhance the readability.
Signed-off-by: Jingoo Han <jg1.han@samsung.com>
---
drivers/rtc/rtc-sh.c | 5 +++--
1 file changed, 3 insertions(+), 2 deletions(-)
diff --git a/drivers/rtc/rtc-sh.c b/drivers/rtc/rtc-sh.c
index 6d87e26..d0d2b04 100644
--- a/drivers/rtc/rtc-sh.c
+++ b/drivers/rtc/rtc-sh.c
@@ -649,8 +649,9 @@ static int __init sh_rtc_probe(struct platform_device *pdev)
clk_enable(rtc->clk);
rtc->capabilities = RTC_DEF_CAPABILITIES;
- if (pdev->dev.platform_data) {
- struct sh_rtc_platform_info *pinfo = pdev->dev.platform_data;
+ if (dev_get_platdata(&pdev->dev)) {
+ struct sh_rtc_platform_info *pinfo =
+ dev_get_platdata(&pdev->dev);
/*
* Some CPUs have special capabilities in addition to the
--
1.7.10.4
next prev parent reply other threads:[~2013-09-23 9:52 UTC|newest]
Thread overview: 17+ messages / expand[flat|nested] mbox.gz Atom feed top
2013-09-23 9:38 [PATCH 00/15] rtc: " Jingoo Han
2013-09-23 9:39 ` [PATCH 01/15] rtc: rtc-88pm80x: " Jingoo Han
2013-09-23 9:40 ` [PATCH 02/15] rtc: rtc-88pm860x: " Jingoo Han
2013-10-10 3:41 ` Haojian Zhuang
2013-09-23 9:41 ` [PATCH 03/15] rtc: rtc-cmos: " Jingoo Han
2013-09-23 9:43 ` [PATCH 04/15] rtc: rtc-da9055: " Jingoo Han
2013-09-23 9:43 ` [PATCH 05/15] rtc: rtc-ds1305: " Jingoo Han
2013-09-23 9:44 ` [PATCH 06/15] rtc: rtc-ds1307: " Jingoo Han
2013-09-23 9:45 ` [PATCH 07/15] rtc: rtc-ds2404: " Jingoo Han
2013-09-23 9:46 ` [PATCH 08/15] rtc: rtc-ep93xx: " Jingoo Han
2013-09-23 9:47 ` [PATCH 09/15] rtc: hid-sensor-time: " Jingoo Han
2013-09-23 9:48 ` [PATCH 10/15] rtc: rtc-m48t59: " Jingoo Han
2013-09-23 9:48 ` [PATCH 11/15] rtc: rtc-m48t86: " Jingoo Han
2013-09-23 9:49 ` [PATCH 12/15] rtc: rtc-pcf2123: " Jingoo Han
2013-09-23 9:50 ` [PATCH 13/15] rtc: rtc-rs5c348: " Jingoo Han
2013-09-23 9:52 ` Jingoo Han [this message]
2013-09-23 9:53 ` [PATCH 15/15] rtc: rtc-v3020: " Jingoo Han
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='002a01ceb842$9e288110$da798330$%han@samsung.com' \
--to=jg1.han@samsung.com \
--cc=a.zummo@towertech.it \
--cc=akpm@linux-foundation.org \
--cc=linux-kernel@vger.kernel.org \
--cc=rtc-linux@googlegroups.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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox
all inboxes | Powered by JetHome®