From patchwork Tue Sep 17 05:11:34 2013 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Jingoo Han X-Patchwork-Id: 2900831 Return-Path: X-Original-To: patchwork-linux-fbdev@patchwork.kernel.org Delivered-To: patchwork-parsemail@patchwork1.web.kernel.org Received: from mail.kernel.org (mail.kernel.org [198.145.19.201]) by patchwork1.web.kernel.org (Postfix) with ESMTP id A826F9F1E3 for ; Tue, 17 Sep 2013 05:11:39 +0000 (UTC) Received: from mail.kernel.org (localhost [127.0.0.1]) by mail.kernel.org (Postfix) with ESMTP id D03912018B for ; Tue, 17 Sep 2013 05:11:38 +0000 (UTC) Received: from vger.kernel.org (vger.kernel.org [209.132.180.67]) by mail.kernel.org (Postfix) with ESMTP id D2F1720184 for ; Tue, 17 Sep 2013 05:11:37 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1751798Ab3IQFLh (ORCPT ); Tue, 17 Sep 2013 01:11:37 -0400 Received: from mailout3.samsung.com ([203.254.224.33]:12161 "EHLO mailout3.samsung.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1751739Ab3IQFLg (ORCPT ); Tue, 17 Sep 2013 01:11:36 -0400 Received: from epcpsbgr4.samsung.com (u144.gpu120.samsung.co.kr [203.254.230.144]) by mailout3.samsung.com (Oracle Communications Messaging Server 7u4-24.01 (7.0.4.24.0) 64bit (built Nov 17 2011)) with ESMTP id <0MT900F3L7Q5TNL0@mailout3.samsung.com> for linux-fbdev@vger.kernel.org; Tue, 17 Sep 2013 14:11:35 +0900 (KST) Received: from epcpsbgm2.samsung.com ( [203.254.230.51]) by epcpsbgr4.samsung.com (EPCPMTA) with SMTP id CE.51.31253.784E7325; Tue, 17 Sep 2013 14:11:35 +0900 (KST) X-AuditID: cbfee690-b7f3b6d000007a15-3d-5237e48760ac Received: from epmmp1.local.host ( [203.254.227.16]) by epcpsbgm2.samsung.com (EPCPMTA) with SMTP id C0.43.05832.784E7325; Tue, 17 Sep 2013 14:11:35 +0900 (KST) Received: from DOJG1HAN03 ([12.23.120.99]) by mmp1.samsung.com (Oracle Communications Messaging Server 7u4-24.01 (7.0.4.24.0) 64bit (built Nov 17 2011)) with ESMTPA id <0MT90001Q7RAFL80@mmp1.samsung.com>; Tue, 17 Sep 2013 14:11:34 +0900 (KST) From: Jingoo Han To: 'Tomi Valkeinen' Cc: 'Jean-Christophe PLAGNIOL-VILLARD' , linux-fbdev@vger.kernel.org, 'Jingoo Han' References: <000401ceb361$d84c4600$88e4d200$%han@samsung.com> In-reply-to: <000401ceb361$d84c4600$88e4d200$%han@samsung.com> Subject: [PATCH 18/19] video: tmiofb: use dev_get_platdata() Date: Tue, 17 Sep 2013 14:11:34 +0900 Message-id: <001801ceb364$611f5d30$235e1790$%han@samsung.com> MIME-version: 1.0 Content-type: text/plain; charset=us-ascii Content-transfer-encoding: 7bit X-Mailer: Microsoft Office Outlook 12.0 Thread-index: Ac6zYdQuTiueM9xuSEGq26qTfKM1MwAAnwxg Content-language: ko x-cr-hashedpuzzle: +6Y= FEKC G/TJ Ixcg JyhD K80n OD2C OkQQ Vl1e bNmY dX88 fcnn g+ee iPHR lHcU l6rP; 4; agBnADEALgBoAGEAbgBAAHMAYQBtAHMAdQBuAGcALgBjAG8AbQA7AGwAaQBuAHUAeAAtAGYAYgBkAGUAdgBAAHYAZwBlAHIALgBrAGUAcgBuAGUAbAAuAG8AcgBnADsAcABsAGEAZwBuAGkAbwBqAEAAagBjAHIAbwBzAG8AZgB0AC4AYwBvAG0AOwB0AG8AbQBpAC4AdgBhAGwAawBlAGkAbgBlAG4AQAB0AGkALgBjAG8AbQA=; Sosha1_v1; 7; {BE81E122-0C77-4769-A988-FB5A7F2A2542}; agBnADEALgBoAGEAbgBAAHMAYQBtAHMAdQBuAGcALgBjAG8AbQA=; Tue, 17 Sep 2013 05:11:28 GMT; WwBQAEEAVABDAEgAIAAxADgALwAxADkAXQAgAHYAaQB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dW i3UPXzBZrJ9/i82BxePVhTssHn1bVjF6HL+xncnj8ya5AJaoBkabjNTElNQihdS85PyUzLx0 WyXv4HjneFMzA0NdQ0sLcyWFvMTcVFslF58AXbfMHKCdSgpliTmlQKGAxOJiJX07TBNCQ9x0 LWAaI3R9Q4LgeowM0EDCOsaMT7M/shdME65o+3eAuYGxT6CLkZNDQsBEon3zVWYIW0ziwr31 bF2MXBxCAosYJSZ27mWEcH4xSvzeM5kJpIpNQE3iy5fD7CC2iICOxKRFPcwgRcwCjYwSLd3P WUESQgK2ErNfXGUBsTkF7CT2T5gLZHNwCAvYSNw4HAcSZhFQlViz9zQTSJgXqHza5UKQMK+A oMSPyffAOpkFtCTW7zzOBGHLS2xe85YZpFxCQF3i0V9diAuMJGa+/cAKUSIise/FO7CTJQQ+ sEisnLuIDaLeVOJmu8QERpFZSDbMQrJhFpINs5CMWsDIsopRNLUguaA4KT3XSK84Mbe4NC9d Lzk/dxMjOEU8k97BuKrB4hCjAAejEg/vDCnzICHWxLLiytxDjBIczEoivGG6QCHelMTKqtSi /Pii0pzU4kOMyUD/T2SWEk3OB6avvJJ4Q2MTMyNLIzMLIxNzc9KElcR5D7ZaBwoJpCeWpGan phakFsFsYeLglGpgnJm9rqLGpltb6NwRp5JM5m27Iq6sr+ypXPNs56vWVw2bFzf0bl6iyDX3 RmrKe+vV8yResS5e/yzA7l1kp3Vo6kPDNBu/Iw71eyIlxPZ7trsyXwt+4dD137aubStPj0Kd Y9Dxb/YpKXJqp06nVHRKCxzw+hm9+WVG1P6UF87sk57FCjrXJTIrsRRnJBpqMRcVJwIABIDm +FUDAAA= DLP-Filter: Pass X-MTR: 20000000000000000@CPGS X-CFilter-Loop: Reflected Sender: linux-fbdev-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-fbdev@vger.kernel.org X-Spam-Status: No, score=-7.6 required=5.0 tests=BAYES_00, RCVD_IN_DNSWL_HI, RP_MATCHES_RCVD, UNPARSEABLE_RELAY autolearn=unavailable version=3.3.1 X-Spam-Checker-Version: SpamAssassin 3.3.1 (2010-03-16) on mail.kernel.org X-Virus-Scanned: ClamAV using ClamSMTP 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 --- drivers/video/tmiofb.c | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/drivers/video/tmiofb.c b/drivers/video/tmiofb.c index deb8733..b5b69a6 100644 --- a/drivers/video/tmiofb.c +++ b/drivers/video/tmiofb.c @@ -250,7 +250,7 @@ static irqreturn_t tmiofb_irq(int irq, void *__info) */ static int tmiofb_hw_stop(struct platform_device *dev) { - struct tmio_fb_data *data = dev->dev.platform_data; + struct tmio_fb_data *data = dev_get_platdata(&dev->dev); struct fb_info *info = platform_get_drvdata(dev); struct tmiofb_par *par = info->par; @@ -311,7 +311,7 @@ static int tmiofb_hw_init(struct platform_device *dev) */ static void tmiofb_hw_mode(struct platform_device *dev) { - struct tmio_fb_data *data = dev->dev.platform_data; + struct tmio_fb_data *data = dev_get_platdata(&dev->dev); struct fb_info *info = platform_get_drvdata(dev); struct fb_videomode *mode = info->mode; struct tmiofb_par *par = info->par; @@ -557,7 +557,7 @@ static int tmiofb_ioctl(struct fb_info *fbi, static struct fb_videomode * tmiofb_find_mode(struct fb_info *info, struct fb_var_screeninfo *var) { - struct tmio_fb_data *data = info->device->platform_data; + struct tmio_fb_data *data = dev_get_platdata(info->device); struct fb_videomode *best = NULL; int i; @@ -577,7 +577,7 @@ static int tmiofb_check_var(struct fb_var_screeninfo *var, struct fb_info *info) { struct fb_videomode *mode; - struct tmio_fb_data *data = info->device->platform_data; + struct tmio_fb_data *data = dev_get_platdata(info->device); mode = tmiofb_find_mode(info, var); if (!mode || var->bits_per_pixel > 16) @@ -678,7 +678,7 @@ static struct fb_ops tmiofb_ops = { static int tmiofb_probe(struct platform_device *dev) { const struct mfd_cell *cell = mfd_get_cell(dev); - struct tmio_fb_data *data = dev->dev.platform_data; + struct tmio_fb_data *data = dev_get_platdata(&dev->dev); struct resource *ccr = platform_get_resource(dev, IORESOURCE_MEM, 1); struct resource *lcr = platform_get_resource(dev, IORESOURCE_MEM, 0); struct resource *vram = platform_get_resource(dev, IORESOURCE_MEM, 2);