From patchwork Tue Sep 17 05:03:19 2013 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Jingoo Han X-Patchwork-Id: 2900731 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 30B2A9F1BF for ; Tue, 17 Sep 2013 05:03:25 +0000 (UTC) Received: from mail.kernel.org (localhost [127.0.0.1]) by mail.kernel.org (Postfix) with ESMTP id 30B8C20250 for ; Tue, 17 Sep 2013 05:03:24 +0000 (UTC) Received: from vger.kernel.org (vger.kernel.org [209.132.180.67]) by mail.kernel.org (Postfix) with ESMTP id CEB932022D for ; Tue, 17 Sep 2013 05:03:22 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1751658Ab3IQFDW (ORCPT ); Tue, 17 Sep 2013 01:03:22 -0400 Received: from mailout1.samsung.com ([203.254.224.24]:59381 "EHLO mailout1.samsung.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1751644Ab3IQFDV (ORCPT ); Tue, 17 Sep 2013 01:03:21 -0400 Received: from epcpsbgr5.samsung.com (u145.gpu120.samsung.co.kr [203.254.230.145]) by mailout1.samsung.com (Oracle Communications Messaging Server 7u4-24.01 (7.0.4.24.0) 64bit (built Nov 17 2011)) with ESMTP id <0MT900GUG7CMY7L0@mailout1.samsung.com> for linux-fbdev@vger.kernel.org; Tue, 17 Sep 2013 14:03:19 +0900 (KST) Received: from epcpsbgm1.samsung.com ( [203.254.230.50]) by epcpsbgr5.samsung.com (EPCPMTA) with SMTP id 54.77.29948.792E7325; Tue, 17 Sep 2013 14:03:19 +0900 (KST) X-AuditID: cbfee691-b7f4a6d0000074fc-7d-5237e29771c0 Received: from epmmp2 ( [203.254.227.17]) by epcpsbgm1.samsung.com (EPCPMTA) with SMTP id 17.2F.09055.792E7325; Tue, 17 Sep 2013 14:03:19 +0900 (KST) Received: from DOJG1HAN03 ([12.23.120.99]) by mmp2.samsung.com (Oracle Communications Messaging Server 7u4-24.01 (7.0.4.24.0) 64bit (built Nov 17 2011)) with ESMTPA id <0MT900FF57DJVW20@mmp2.samsung.com>; Tue, 17 Sep 2013 14:03:19 +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 09/19] video: sh_mobile_hdmi: use dev_get_platdata() Date: Tue, 17 Sep 2013 14:03:19 +0900 Message-id: <000e01ceb363$39e44b00$adace100$%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: Ac6zYdQuTiueM9xuSEGq26qTfKM1MwAAUKzA Content-language: ko x-cr-hashedpuzzle: AS7c CG+F DIlZ DguQ E920 IqQk KboD Np1S NzHU PFcy RaOP SIke TKX/ TrKs a6IG eIFi; 4; agBnADEALgBoAGEAbgBAAHMAYQBtAHMAdQBuAGcALgBjAG8AbQA7AGwAaQBuAHUAeAAtAGYAYgBkAGUAdgBAAHYAZwBlAHIALgBrAGUAcgBuAGUAbAAuAG8AcgBnADsAcABsAGEAZwBuAGkAbwBqAEAAagBjAHIAbwBzAG8AZgB0AC4AYwBvAG0AOwB0AG8AbQBpAC4AdgBhAGwAawBlAGkAbgBlAG4AQAB0AGkALgBjAG8AbQA=; Sosha1_v1; 7; {C94FF680-FF2E-4C23-8367-DAE2977F04CE}; agBnADEALgBoAGEAbgBAAHMAYQBtAHMAdQBuAGcALgBjAG8AbQA=; Tue, 17 Sep 2013 05:03:14 GMT; WwBQAEEAVABDAEgAIAAwADkALwAxADkAXQAgAHYA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SXmKPExsVy+t9jQd3pj8yDDKZ+1rG4vPASq8WJvg+s FusevmCyWD//FpsDi8erC3dYPPq2rGL0OH5jO5PH501yASxRDYw2GamJKalFCql5yfkpmXnp tkrewfHO8aZmBoa6hpYW5koKeYm5qbZKLj4Bum6ZOUA7lRTKEnNKgUIBicXFSvp2mCaEhrjp WsA0Ruj6hgTB9RgZoIGEdYwZn5edZyk4z1vRMmMFSwPjIe4uRk4OCQETiSmnbrJB2GISF+6t B7K5OIQEpjNKrLt7hx3C+cUocevYB3aQKjYBNYkvXw6D2SICOhKTFvUwgxQxCzQySrR0P2cF SQgJ2ErMfnGVBcTmFLCT2D9hLpgtLOAi8WTPe6AGDg4WAVWJe9PMQMK8QOWLF+5ngrAFJX5M vgdWziygJbF+53EmCFteYvOat2CtEgLqEo/+6kKcYCTRuvInI0SJiMS+F+8YQc6REOhglbjf 2MEM8ZmpxImV81kmMIrMQrJiFpIVs5CsmIVk1gJGllWMoqkFyQXFSem5hnrFibnFpXnpesn5 uZsYwWnimdQOxpUNFocYBTgYlXh4Z0iZBwmxJpYVV+YeYpTgYFYS4Q3TBQrxpiRWVqUW5ccX leakFh9iTAYGwERmKdHkfGAKyyuJNzQ2MTOyNDKzMDIxNydNWEmc90CrdaCQQHpiSWp2ampB ahHMFiYOTqkGRoPdO429My83Zgepda7rP/tcM6Lo78qlnwoOCOdYbFzYvSuM43pfgH/q+q7/ GzhUjuxhLXc3OHnnYZmI3RYuRYevhr4tk7lTNPnm+vqrS6hpvTkVm73shuCWsFuLWaazeX8R DE5ROf7zNL/qwfC+Zca7F1yut/x2k33qCssFNYYnPy5gq/g0TYmlOCPRUIu5qDgRALyXehdX AwAA 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/sh_mobile_hdmi.c | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/drivers/video/sh_mobile_hdmi.c b/drivers/video/sh_mobile_hdmi.c index bfe4728..45417fa 100644 --- a/drivers/video/sh_mobile_hdmi.c +++ b/drivers/video/sh_mobile_hdmi.c @@ -498,7 +498,7 @@ static void sh_hdmi_video_config(struct sh_hdmi *hdmi) static void sh_hdmi_audio_config(struct sh_hdmi *hdmi) { u8 data; - struct sh_mobile_hdmi_info *pdata = hdmi->dev->platform_data; + struct sh_mobile_hdmi_info *pdata = dev_get_platdata(hdmi->dev); /* * [7:4] L/R data swap control @@ -815,7 +815,7 @@ static unsigned long sh_hdmi_rate_error(struct sh_hdmi *hdmi, unsigned long *hdmi_rate, unsigned long *parent_rate) { unsigned long target = PICOS2KHZ(mode->pixclock) * 1000, rate_error; - struct sh_mobile_hdmi_info *pdata = hdmi->dev->platform_data; + struct sh_mobile_hdmi_info *pdata = dev_get_platdata(hdmi->dev); *hdmi_rate = clk_round_rate(hdmi->hdmi_clk, target); if ((long)*hdmi_rate < 0) @@ -1271,7 +1271,7 @@ static void sh_hdmi_htop1_init(struct sh_hdmi *hdmi) static int __init sh_hdmi_probe(struct platform_device *pdev) { - struct sh_mobile_hdmi_info *pdata = pdev->dev.platform_data; + struct sh_mobile_hdmi_info *pdata = dev_get_platdata(&pdev->dev); struct resource *res = platform_get_resource(pdev, IORESOURCE_MEM, 0); struct resource *htop1_res; int irq = platform_get_irq(pdev, 0), ret;