summaryrefslogtreecommitdiffstats
path: root/drivers/dma/txx9dmac.c
diff options
context:
space:
mode:
authorJingoo Han <jg1.han@samsung.com>2013-07-30 04:09:11 -0400
committerVinod Koul <vinod.koul@intel.com>2013-08-13 07:26:41 -0400
commitd4adcc0160404c3237fe6ffa09dd2dd039dd3975 (patch)
treeaa9d7b76f16d21b38ffb8dbfe3c12986b0fd97f9 /drivers/dma/txx9dmac.c
parent696b4ff8b2e6fd3f01c9acf6687ec4660143b614 (diff)
dma: use dev_get_platdata()
Use the wrapper function for retrieving the platform data instead of accessing dev->platform_data directly. Signed-off-by: Jingoo Han <jg1.han@samsung.com> Signed-off-by: Vinod Koul <vinod.koul@intel.com>
Diffstat (limited to 'drivers/dma/txx9dmac.c')
-rw-r--r--drivers/dma/txx9dmac.c9
1 files changed, 5 insertions, 4 deletions
diff --git a/drivers/dma/txx9dmac.c b/drivers/dma/txx9dmac.c
index 59357db62359..71e8e775189e 100644
--- a/drivers/dma/txx9dmac.c
+++ b/drivers/dma/txx9dmac.c
@@ -1117,9 +1117,10 @@ static void txx9dmac_off(struct txx9dmac_dev *ddev)
1117 1117
1118static int __init txx9dmac_chan_probe(struct platform_device *pdev) 1118static int __init txx9dmac_chan_probe(struct platform_device *pdev)
1119{ 1119{
1120 struct txx9dmac_chan_platform_data *cpdata = pdev->dev.platform_data; 1120 struct txx9dmac_chan_platform_data *cpdata =
1121 dev_get_platdata(&pdev->dev);
1121 struct platform_device *dmac_dev = cpdata->dmac_dev; 1122 struct platform_device *dmac_dev = cpdata->dmac_dev;
1122 struct txx9dmac_platform_data *pdata = dmac_dev->dev.platform_data; 1123 struct txx9dmac_platform_data *pdata = dev_get_platdata(&dmac_dev->dev);
1123 struct txx9dmac_chan *dc; 1124 struct txx9dmac_chan *dc;
1124 int err; 1125 int err;
1125 int ch = pdev->id % TXX9_DMA_MAX_NR_CHANNELS; 1126 int ch = pdev->id % TXX9_DMA_MAX_NR_CHANNELS;
@@ -1202,7 +1203,7 @@ static int txx9dmac_chan_remove(struct platform_device *pdev)
1202 1203
1203static int __init txx9dmac_probe(struct platform_device *pdev) 1204static int __init txx9dmac_probe(struct platform_device *pdev)
1204{ 1205{
1205 struct txx9dmac_platform_data *pdata = pdev->dev.platform_data; 1206 struct txx9dmac_platform_data *pdata = dev_get_platdata(&pdev->dev);
1206 struct resource *io; 1207 struct resource *io;
1207 struct txx9dmac_dev *ddev; 1208 struct txx9dmac_dev *ddev;
1208 u32 mcr; 1209 u32 mcr;
@@ -1281,7 +1282,7 @@ static int txx9dmac_resume_noirq(struct device *dev)
1281{ 1282{
1282 struct platform_device *pdev = to_platform_device(dev); 1283 struct platform_device *pdev = to_platform_device(dev);
1283 struct txx9dmac_dev *ddev = platform_get_drvdata(pdev); 1284 struct txx9dmac_dev *ddev = platform_get_drvdata(pdev);
1284 struct txx9dmac_platform_data *pdata = pdev->dev.platform_data; 1285 struct txx9dmac_platform_data *pdata = dev_get_platdata(&pdev->dev);
1285 u32 mcr; 1286 u32 mcr;
1286 1287
1287 mcr = TXX9_DMA_MCR_MSTEN | MCR_LE; 1288 mcr = TXX9_DMA_MCR_MSTEN | MCR_LE;