diff options
author | Jingoo Han <jg1.han@samsung.com> | 2013-09-17 01:08:58 -0400 |
---|---|---|
committer | Tomi Valkeinen <tomi.valkeinen@ti.com> | 2013-09-20 05:22:03 -0400 |
commit | 1c8034c7f0a3b53bb27b0faa9a6e3f88da0322ea (patch) | |
tree | b2da323e941635fc5dc7fe6e41029a65604a6983 | |
parent | e09f398e534944146245a7fab7f642e9247b104a (diff) |
video: imxfb: use dev_get_platdata()
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>
Signed-off-by: Tomi Valkeinen <tomi.valkeinen@ti.com>
-rw-r--r-- | drivers/video/imxfb.c | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/drivers/video/imxfb.c b/drivers/video/imxfb.c index 38733ac2b698..44ee678481d5 100644 --- a/drivers/video/imxfb.c +++ b/drivers/video/imxfb.c | |||
@@ -755,7 +755,7 @@ static int imxfb_resume(struct platform_device *dev) | |||
755 | 755 | ||
756 | static int imxfb_init_fbinfo(struct platform_device *pdev) | 756 | static int imxfb_init_fbinfo(struct platform_device *pdev) |
757 | { | 757 | { |
758 | struct imx_fb_platform_data *pdata = pdev->dev.platform_data; | 758 | struct imx_fb_platform_data *pdata = dev_get_platdata(&pdev->dev); |
759 | struct fb_info *info = dev_get_drvdata(&pdev->dev); | 759 | struct fb_info *info = dev_get_drvdata(&pdev->dev); |
760 | struct imxfb_info *fbi = info->par; | 760 | struct imxfb_info *fbi = info->par; |
761 | struct device_node *np; | 761 | struct device_node *np; |
@@ -877,7 +877,7 @@ static int imxfb_probe(struct platform_device *pdev) | |||
877 | if (!res) | 877 | if (!res) |
878 | return -ENODEV; | 878 | return -ENODEV; |
879 | 879 | ||
880 | pdata = pdev->dev.platform_data; | 880 | pdata = dev_get_platdata(&pdev->dev); |
881 | 881 | ||
882 | info = framebuffer_alloc(sizeof(struct imxfb_info), &pdev->dev); | 882 | info = framebuffer_alloc(sizeof(struct imxfb_info), &pdev->dev); |
883 | if (!info) | 883 | if (!info) |
@@ -1066,7 +1066,7 @@ static int imxfb_remove(struct platform_device *pdev) | |||
1066 | #endif | 1066 | #endif |
1067 | unregister_framebuffer(info); | 1067 | unregister_framebuffer(info); |
1068 | 1068 | ||
1069 | pdata = pdev->dev.platform_data; | 1069 | pdata = dev_get_platdata(&pdev->dev); |
1070 | if (pdata && pdata->exit) | 1070 | if (pdata && pdata->exit) |
1071 | pdata->exit(fbi->pdev); | 1071 | pdata->exit(fbi->pdev); |
1072 | 1072 | ||