From: Inki Dae Subject: [PATCH 1/3] drm/exynos: add super device support Date: Thu, 27 Mar 2014 21:43:50 +0900 Message-ID: <1395924232-26673-2-git-send-email-inki.dae@samsung.com> References: <1395924232-26673-1-git-send-email-inki.dae@samsung.com> Mime-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit Return-path: Received: from mailout1.samsung.com (mailout1.samsung.com [203.254.224.24]) by gabe.freedesktop.org (Postfix) with ESMTP id 652706E914 for ; Thu, 27 Mar 2014 05:43:57 -0700 (PDT) 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 <0N33006DTI164Y10@mailout1.samsung.com> for dri-devel@lists.freedesktop.org; Thu, 27 Mar 2014 21:43:54 +0900 (KST) In-reply-to: <1395924232-26673-1-git-send-email-inki.dae@samsung.com> List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: dri-devel-bounces@lists.freedesktop.org Sender: "dri-devel" To: airlied@linux.ie, dri-devel@lists.freedesktop.org Cc: a.hajda@samsung.com, kyungmin.park@samsung.com List-Id: dri-devel@lists.freedesktop.org This patch adds super device support to bind sub drivers using device tree. For this, you should add a super device node to each machine dt files like belows, In case of using MIPI-DSI, exynos-drm { compatible = "samsung,exynos-drm"; crtcs = <&fimd>; connectors = <&dsi>; }; In case of using DisplayPort, exynos-drm { compatible = "samsung,exynos-drm"; crtcs = <&fimd>; connectors = <&dp>; }; In case of using Parallel panel, exynos-drm { compatible = "samsung,exynos-drm"; crtcs = <&fimd>; connectors = <&panel>; }; And if you don't add connectors property to machine dt file like below, default parallel panel feature of exynos_drm_dpi module will be used as default. exynos-drm { compatible = "samsung,exynos-drm"; crtcs = <&fimd>; }; crtcs property can have the following device nodes, fimd or mixer connectors property can have the following device nodes, Panel, MIPI-DSI, eDP, or HDMI With this patch, we can resolve the probing order issue without some global lists. So this patch also removes the unnecessary lists and stuff related to these lists. Previous RFC patch, http://www.spinics.net/lists/dri-devel/msg54671.html Changelog since RFC patch: - Register sub drivers and probe them at load(). In case of non sub drivers, sub driver probe is needed. - Enable runtime pm at fimd_probe() instead of fimd_bind(). runtime pm should be enabled before iommu device is attached to fimd device. - Do not return an error with component_master_add fail. - Remove super device support from mipi dsi driver which was in RFC. - Add super device support to parallel driver. Signed-off-by: Inki Dae Signed-off-by: Kyungmin Park --- drivers/gpu/drm/exynos/exynos_dp_core.c | 45 +++--- drivers/gpu/drm/exynos/exynos_drm_core.c | 216 +++++------------------------ drivers/gpu/drm/exynos/exynos_drm_crtc.c | 17 +++ drivers/gpu/drm/exynos/exynos_drm_crtc.h | 4 + drivers/gpu/drm/exynos/exynos_drm_dpi.c | 14 +- drivers/gpu/drm/exynos/exynos_drm_drv.c | 218 +++++++++++++++++------------- drivers/gpu/drm/exynos/exynos_drm_drv.h | 69 ++++------ drivers/gpu/drm/exynos/exynos_drm_fimd.c | 57 ++++++-- drivers/gpu/drm/exynos/exynos_drm_vidi.c | 61 +++++++-- drivers/gpu/drm/exynos/exynos_hdmi.c | 45 +++--- drivers/gpu/drm/exynos/exynos_mixer.c | 54 ++++++-- 11 files changed, 401 insertions(+), 399 deletions(-) diff --git a/drivers/gpu/drm/exynos/exynos_dp_core.c b/drivers/gpu/drm/exynos/exynos_dp_core.c index a59bca9..cb9aa58 100644 --- a/drivers/gpu/drm/exynos/exynos_dp_core.c +++ b/drivers/gpu/drm/exynos/exynos_dp_core.c @@ -18,6 +18,7 @@ #include #include #include +#include #include #include