From patchwork Mon Nov 5 07:51:27 2012 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Jingoo Han X-Patchwork-Id: 1695331 Return-Path: X-Original-To: patchwork-linux-fbdev@patchwork.kernel.org Delivered-To: patchwork-process-083081@patchwork2.kernel.org Received: from vger.kernel.org (vger.kernel.org [209.132.180.67]) by patchwork2.kernel.org (Postfix) with ESMTP id 430B6DF2AB for ; Mon, 5 Nov 2012 08:00:30 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1752989Ab2KEIA3 (ORCPT ); Mon, 5 Nov 2012 03:00:29 -0500 Received: from mailout3.samsung.com ([203.254.224.33]:15354 "EHLO mailout3.samsung.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1753011Ab2KEIA3 (ORCPT ); Mon, 5 Nov 2012 03:00:29 -0500 Received: from epcpsbgm1.samsung.com (epcpsbgm1 [203.254.230.26]) by mailout3.samsung.com (Oracle Communications Messaging Server 7u4-24.01(7.0.4.24.0) 64bit (built Nov 17 2011)) with ESMTP id <0MD000EQF8EZCWC0@mailout3.samsung.com> for linux-fbdev@vger.kernel.org; Mon, 05 Nov 2012 16:51:27 +0900 (KST) Received: from epcpsbgm1.samsung.com ( [203.254.230.51]) by epcpsbgm1.samsung.com (EPCPMTA) with SMTP id D8.69.01231.FFF67905; Mon, 05 Nov 2012 16:51:27 +0900 (KST) X-AuditID: cbfee61a-b7fa66d0000004cf-79-50976fff83b1 Received: from epmmp1.local.host ( [203.254.227.16]) by epcpsbgm1.samsung.com (EPCPMTA) with SMTP id 28.69.01231.FFF67905; Mon, 05 Nov 2012 16:51:27 +0900 (KST) Received: from DOJG1HAN02 ([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 <0MD0002H68HRYG70@mmp1.samsung.com> for linux-fbdev@vger.kernel.org; Mon, 05 Nov 2012 16:51:27 +0900 (KST) From: Jingoo Han To: 'Florian Tobias Schandinat' Cc: linux-fbdev@vger.kernel.org, 'Ajay Kumar' , 'Jingoo Han' References: <003301cdbb29$421e2ee0$c65a8ca0$%han@samsung.com> In-reply-to: <003301cdbb29$421e2ee0$c65a8ca0$%han@samsung.com> Subject: [PATCH v3 1/2] video: exynos_dp: Reset and initialize DP before requesting irq Date: Mon, 05 Nov 2012 16:51:27 +0900 Message-id: <003b01cdbb2a$5c2ce8c0$1486ba40$%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: Ac27KUIAmX/J1rmES6qj/A5auPWLMgAAOJjQ Content-language: ko DLP-Filter: Pass X-MTR: 20000000000000000@CPGS X-Brightmail-Tracker: H4sIAAAAAAAAA+NgFjrKIsWRmVeSWpSXmKPExsVy+t8zY93/+dMDDG4/V7Y40feB1YHR4/Mm uQDGKC6blNSczLLUIn27BK6MiW2HWAvm8lR8+LqdtYFxIlcXIyeHhICJxL/Hm1ghbDGJC/fW s3UxcnEICSxjlNj1ez0LTNHzVfsZIRKLGCU+dc5jgXBmMUnsPd/KBFLFJqAm8eXLYfYuRg4O EQEriU1bNUFMZoE8iRf/VEAqhARsJebe6GYGsTkF7CTebO4Hmy8sEClxon0S2BQWAVWJ7Tu/ gtXwAtVPnroUyhaU+DH5Hlg9s4CWxPqdx5kgbHmJzWveMoOskhBQl3j0VxckLCJgJPHtSAMr RImIxL4X7xghxgtIfJt8iAWiXFZi0wFmkEckBJaxS5yYvAbqXUmJgytusExglJiFZPMsJJtn Idk8C8mKBYwsqxhFUwuSC4qT0nMN9YoTc4tL89L1kvNzNzFC4kpqB+PKBotDjAIcjEo8vDPF pgcIsSaWFVfmHmKU4GBWEuHlYAAK8aYkVlalFuXHF5XmpBYfYvQBunwis5Rocj4w5vNK4g2N jU3MTExNzC1NzU1xCCuJ8zZ7pAQICaQnlqRmp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/NucDRKfqDEUpyRaKjFXFScCAB2 z34iBwMAAA== X-CFilter-Loop: Reflected Sender: linux-fbdev-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-fbdev@vger.kernel.org From: Ajay Kumar If DP is not reset properly before kernel bootup(in bootloader code), there can be few pending interrupts, and sometimes they invoke DP irq handler as soon as the irq handler is registered in DP probe. So, we make the DP driver more robust by resetting and initializing DP at the earliest and then registering the irq handler. Signed-off-by: Ajay Kumar Signed-off-by: Jingoo Han --- Added 'From: Ajay Kumar ' drivers/video/exynos/exynos_dp_core.c | 12 ++++++------ 1 files changed, 6 insertions(+), 6 deletions(-) diff --git a/drivers/video/exynos/exynos_dp_core.c b/drivers/video/exynos/exynos_dp_core.c index d55470e..d241fd3 100644 --- a/drivers/video/exynos/exynos_dp_core.c +++ b/drivers/video/exynos/exynos_dp_core.c @@ -901,6 +901,12 @@ static int __devinit exynos_dp_probe(struct platform_device *pdev) return -ENODEV; } + dp->video_info = pdata->video_info; + if (pdata->phy_init) + pdata->phy_init(); + + exynos_dp_init_dp(dp); + ret = devm_request_irq(&pdev->dev, dp->irq, exynos_dp_irq_handler, 0, "exynos-dp", dp); if (ret) { @@ -908,12 +914,6 @@ static int __devinit exynos_dp_probe(struct platform_device *pdev) return ret; } - dp->video_info = pdata->video_info; - if (pdata->phy_init) - pdata->phy_init(); - - exynos_dp_init_dp(dp); - ret = exynos_dp_detect_hpd(dp); if (ret) { dev_err(&pdev->dev, "unable to detect hpd\n");