From patchwork Thu Nov 6 14:10:07 2014 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Inki Dae X-Patchwork-Id: 5242241 Return-Path: X-Original-To: patchwork-linux-samsung-soc@patchwork.kernel.org Delivered-To: patchwork-parsemail@patchwork2.web.kernel.org Received: from mail.kernel.org (mail.kernel.org [198.145.19.201]) by patchwork2.web.kernel.org (Postfix) with ESMTP id 46AAEC11AC for ; Thu, 6 Nov 2014 14:10:26 +0000 (UTC) Received: from mail.kernel.org (localhost [127.0.0.1]) by mail.kernel.org (Postfix) with ESMTP id 66EA42010F for ; Thu, 6 Nov 2014 14:10:24 +0000 (UTC) Received: from vger.kernel.org (vger.kernel.org [209.132.180.67]) by mail.kernel.org (Postfix) with ESMTP id 7C4F2200E8 for ; Thu, 6 Nov 2014 14:10:23 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1751176AbaKFOKO (ORCPT ); Thu, 6 Nov 2014 09:10:14 -0500 Received: from mailout1.samsung.com ([203.254.224.24]:18293 "EHLO mailout1.samsung.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1751293AbaKFOKK (ORCPT ); Thu, 6 Nov 2014 09:10:10 -0500 Received: from epcpsbgr3.samsung.com (u143.gpu120.samsung.co.kr [203.254.230.143]) by mailout1.samsung.com (Oracle Communications Messaging Server 7u4-24.01 (7.0.4.24.0) 64bit (built Nov 17 2011)) with ESMTP id <0NEM00MP1FCWXMB0@mailout1.samsung.com> for linux-samsung-soc@vger.kernel.org; Thu, 06 Nov 2014 23:10:08 +0900 (KST) Received: from epcpsbgm1.samsung.com ( [172.20.52.114]) by epcpsbgr3.samsung.com (EPCPMTA) with SMTP id 43.5F.18484.0418B545; Thu, 06 Nov 2014 23:10:08 +0900 (KST) X-AuditID: cbfee68f-f791c6d000004834-2a-545b8140c8a6 Received: from epmmp2 ( [203.254.227.17]) by epcpsbgm1.samsung.com (EPCPMTA) with SMTP id BF.68.20081.0418B545; Thu, 06 Nov 2014 23:10:08 +0900 (KST) Received: from daeinki-desktop.10.32.193.11 ([10.252.83.67]) by mmp2.samsung.com (Oracle Communications Messaging Server 7u4-24.01(7.0.4.24.0) 64bit (built Nov 17 2011)) with ESMTPA id <0NEM0074SFCVL4B0@mmp2.samsung.com>; Thu, 06 Nov 2014 23:10:08 +0900 (KST) From: Inki Dae To: airlied@linux.ie, dri-devel@lists.freedesktop.org Cc: linux-samsung-soc@vger.kernel.org, Inki Dae Subject: [PATCH] drm/exynos: resolve infinite loop issue on non multi-platform Date: Thu, 06 Nov 2014 23:10:07 +0900 Message-id: <1415283007-10096-1-git-send-email-inki.dae@samsung.com> X-Mailer: git-send-email 1.7.9.5 X-Brightmail-Tracker: H4sIAAAAAAAAA+NgFlrPLMWRmVeSWpSXmKPExsWyRsSkSNehMTrE4PoTGYvecyeZLK58fc9m Men+BBaLGef3MTmweGz/9oDV4373cSaPvi2rGD0+b5ILYInisklJzcksSy3St0vgyuhtbmMs mMVRsXnlBsYGxrdsXYycHBICJhK9+36xQthiEhfurQeKc3EICSxllFixdzcTTNGHj52sEInp jBKNV79CVXUzSWx9M5MZpIpNQFVi4or7YGNFBEwlOiYtZQGxmQXcJBafXg5mCwv4STxt+QG2 jgWo/ujvY4wgNq+Ai8S9FavZuxg5gLYpSMyZZAMyX0LgPpvEo18TGCHqBSS+TT7EAlEjK7Hp ADPEcZISB1fcYJnAKLiAkWEVo2hqQXJBcVJ6kbFecWJucWleul5yfu4mRmA4nv73rH8H490D 1ocYBTgYlXh4BU5EhQixJpYVV+YeYjQF2jCRWUo0OR8Y9Hkl8YbGZkYWpiamxkbmlmZK4rwL pX4GCwmkJ5akZqemFqQWxReV5qQWH2Jk4uCUamB0LKj6/c7gpN8MNk49q+NzXM+3tAeKPBBX SH2hNvPMMUNlEZuXS6/cUltztS9zqtz+ncdn9v67Yv2PwyZaIiDSJPxnu6L6xFjV2XM0Xf79 USoru3FVy+Bx9V7hC667/J5PnPhN7K2d6A4e5c9eUn6L+La93Ol29MfGbTJLpr0+wsT3QzR8 39YcJZbijERDLeai4kQACAdxP0ICAAA= X-Brightmail-Tracker: H4sIAAAAAAAAA+NgFvrJLMWRmVeSWpSXmKPExsVy+t9jQV2HxugQg0l/RC16z51ksrjy9T2b xaT7E1gsZpzfx+TA4rH92wNWj/vdx5k8+rasYvT4vEkugCWqgdEmIzUxJbVIITUvOT8lMy/d Vsk7ON453tTMwFDX0NLCXEkhLzE31VbJxSdA1y0zB2inkkJZYk4pUCggsbhYSd8O04TQEDdd C5jGCF3fkCC4HiMDNJCwhjGjt7mNsWAWR8XmlRsYGxjfsnUxcnJICJhIfPjYyQphi0lcuLce KM7FISQwnVGi8epXKKebSWLrm5nMIFVsAqoSE1fcB+sWETCV6Ji0lAXEZhZwk1h8ejmYLSzg J/G05QfYVBag+qO/jzGC2LwCLhL3Vqxm72LkANqmIDFnks0ERu4FjAyrGEVTC5ILipPScw31 ihNzi0vz0vWS83M3MYKD/ZnUDsaVDRaHGAU4GJV4eHccjQoRYk0sK67MPcQowcGsJMIbURcd IsSbklhZlVqUH19UmpNafIjRFGj5RGYp0eR8YCTmlcQbGpuYGVkamRtaGBmbK4nzHmi1DhQS SE8sSc1OTS1ILYLpY+LglGpgTA+asq0ywXiasuHCr4eU5x+Lm8whsfkJU6DrLfbPuc+du4tC jvs/NlpS/GTlmpmCCwJOz755MjEqcu5OzuiA5FYhphXivEyd6QxX1qt8mvrgFq/TpPfmggxc OTbXbWatq1EWvnvHm/WBs23CP9s5DlwKVbfOSRavvfLiXE6dWfvNsuYtB6xVlViKMxINtZiL ihMBjFt6cowCAAA= DLP-Filter: Pass X-MTR: 20000000000000000@CPGS X-CFilter-Loop: Reflected Sender: linux-samsung-soc-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-samsung-soc@vger.kernel.org X-Spam-Status: No, score=-7.5 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 This patch resovles the infinite loop issue incurred when Exyno drm driver is enabled but all kms drivers are disabled on Exynos board by returning -EPROBE_DEFER only in case that there is kms device registered. Signed-off-by: Inki Dae --- drivers/gpu/drm/exynos/exynos_drm_drv.c | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/drivers/gpu/drm/exynos/exynos_drm_drv.c b/drivers/gpu/drm/exynos/exynos_drm_drv.c index ecc86aa..14c6af7 100644 --- a/drivers/gpu/drm/exynos/exynos_drm_drv.c +++ b/drivers/gpu/drm/exynos/exynos_drm_drv.c @@ -488,6 +488,12 @@ static struct component_match *exynos_drm_match_add(struct device *dev) mutex_lock(&drm_component_lock); + /* Do not retry to probe if there is no any kms driver regitered. */ + if (list_empty(&drm_component_list)) { + mutex_unlock(&drm_component_lock); + return ERR_PTR(-ENODEV); + } + list_for_each_entry(cdev, &drm_component_list, list) { /* * Add components to master only in case that crtc and