From: Jingoo Han <jg1.han@samsung.com>
To: "'John W. Linville'" <linville@tuxdriver.com>
Cc: linux-wireless@vger.kernel.org,
'Jingoo Han' <jg1.han@samsung.com>,
'Luciano Coelho' <luca@coelho.fi>
Subject: [PATCH 7/8] wireless: wlcore: use dev_get_platdata()
Date: Tue, 10 Sep 2013 17:57:57 +0900 [thread overview]
Message-ID: <005901ceae03$d88d31f0$89a795d0$%han@samsung.com> (raw)
In-Reply-To: <005101ceae02$9cbb95f0$d632c1d0$%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/net/wireless/ti/wlcore/main.c | 2 +-
drivers/net/wireless/ti/wlcore/spi.c | 2 +-
2 files changed, 2 insertions(+), 2 deletions(-)
diff --git a/drivers/net/wireless/ti/wlcore/main.c b/drivers/net/wireless/ti/wlcore/main.c
index 38995f9..c30e1f1 100644
--- a/drivers/net/wireless/ti/wlcore/main.c
+++ b/drivers/net/wireless/ti/wlcore/main.c
@@ -5900,7 +5900,7 @@ static void wlcore_nvs_cb(const struct firmware *fw, void *context)
{
struct wl1271 *wl = context;
struct platform_device *pdev = wl->pdev;
- struct wlcore_platdev_data *pdev_data = pdev->dev.platform_data;
+ struct wlcore_platdev_data *pdev_data = dev_get_platdata(&pdev->dev);
struct wl12xx_platform_data *pdata = pdev_data->pdata;
unsigned long irqflags;
int ret;
diff --git a/drivers/net/wireless/ti/wlcore/spi.c b/drivers/net/wireless/ti/wlcore/spi.c
index 1b0cd98..b2c018d 100644
--- a/drivers/net/wireless/ti/wlcore/spi.c
+++ b/drivers/net/wireless/ti/wlcore/spi.c
@@ -335,7 +335,7 @@ static int wl1271_probe(struct spi_device *spi)
if (!pdev_data)
goto out;
- pdev_data->pdata = spi->dev.platform_data;
+ pdev_data->pdata = dev_get_platdata(&spi->dev);
if (!pdev_data->pdata) {
dev_err(&spi->dev, "no platform data\n");
ret = -ENODEV;
--
1.7.10.4
next prev parent reply other threads:[~2013-09-10 8:57 UTC|newest]
Thread overview: 9+ messages / expand[flat|nested] mbox.gz Atom feed top
2013-09-10 8:49 [PATCH] wireless: use dev_get_platdata() Jingoo Han
2013-09-10 8:51 ` [PATCH 1/8] wireless: ath5k: " Jingoo Han
2013-09-10 8:53 ` [PATCH 2/8] wireless: ath9k: " Jingoo Han
2013-09-10 8:54 ` [PATCH 3/8] wireless: brcmfmac: " Jingoo Han
2013-09-10 8:55 ` [PATCH 4/8] wireless: cw1200: " Jingoo Han
2013-09-10 8:56 ` [PATCH 5/8] wireless: libertas: " Jingoo Han
2013-09-10 8:57 ` [PATCH 6/8] wireless: wl1251: " Jingoo Han
2013-09-10 8:57 ` Jingoo Han [this message]
2013-09-10 8:58 ` [PATCH 8/8] wireless: wl12xx: " 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='005901ceae03$d88d31f0$89a795d0$%han@samsung.com' \
--to=jg1.han@samsung.com \
--cc=linux-wireless@vger.kernel.org \
--cc=linville@tuxdriver.com \
--cc=luca@coelho.fi \
/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