From patchwork Mon Feb 15 06:53:15 2016 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Archit Taneja X-Patchwork-Id: 8310141 Return-Path: X-Original-To: patchwork-dri-devel@patchwork.kernel.org Delivered-To: patchwork-parsemail@patchwork2.web.kernel.org Received: from mail.kernel.org (mail.kernel.org [198.145.29.136]) by patchwork2.web.kernel.org (Postfix) with ESMTP id E40B1C02AE for ; Mon, 15 Feb 2016 06:54:01 +0000 (UTC) Received: from mail.kernel.org (localhost [127.0.0.1]) by mail.kernel.org (Postfix) with ESMTP id EA44920524 for ; Mon, 15 Feb 2016 06:54:00 +0000 (UTC) Received: from gabe.freedesktop.org (gabe.freedesktop.org [131.252.210.177]) by mail.kernel.org (Postfix) with ESMTP id B70AA2051C for ; Mon, 15 Feb 2016 06:53:59 +0000 (UTC) Received: from gabe.freedesktop.org (localhost [127.0.0.1]) by gabe.freedesktop.org (Postfix) with ESMTP id 221586E5D7; Mon, 15 Feb 2016 06:53:59 +0000 (UTC) X-Original-To: dri-devel@lists.freedesktop.org Delivered-To: dri-devel@lists.freedesktop.org Received: from smtp.codeaurora.org (smtp.codeaurora.org [198.145.29.96]) by gabe.freedesktop.org (Postfix) with ESMTPS id E806C6E5D7 for ; Mon, 15 Feb 2016 06:53:57 +0000 (UTC) Received: from smtp.codeaurora.org (localhost [127.0.0.1]) by smtp.codeaurora.org (Postfix) with ESMTP id D3D8A6121B; Mon, 15 Feb 2016 06:53:57 +0000 (UTC) Received: by smtp.codeaurora.org (Postfix, from userid 1000) id C7C4F6121D; Mon, 15 Feb 2016 06:53:57 +0000 (UTC) X-Spam-Checker-Version: SpamAssassin 3.3.1 (2010-03-16) on mail.kernel.org X-Spam-Level: X-Spam-Status: No, score=-4.2 required=5.0 tests=BAYES_00, RCVD_IN_DNSWL_MED, RP_MATCHES_RCVD, UNPARSEABLE_RELAY autolearn=unavailable version=3.3.1 Received: from localhost (unknown [202.46.23.61]) (using TLSv1.2 with cipher DHE-RSA-AES128-SHA (128/128 bits)) (No client certificate requested) (Authenticated sender: architt@smtp.codeaurora.org) by smtp.codeaurora.org (Postfix) with ESMTPSA id 8F5B96121A; Mon, 15 Feb 2016 06:53:56 +0000 (UTC) From: Archit Taneja To: robdclark@gmail.com Subject: [PATCH v2 02/13] drm/msm/hdmi: Create separate Makefile/Kconfig Date: Mon, 15 Feb 2016 12:23:15 +0530 Message-Id: <1455519206-12939-3-git-send-email-architt@codeaurora.org> X-Mailer: git-send-email 1.8.2.1 In-Reply-To: <1455519206-12939-1-git-send-email-architt@codeaurora.org> References: <1455519206-12939-1-git-send-email-architt@codeaurora.org> X-Virus-Scanned: ClamAV using ClamSMTP Cc: linux-arm-msm@vger.kernel.org, dri-devel@lists.freedesktop.org X-BeenThere: dri-devel@lists.freedesktop.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: Direct Rendering Infrastructure - Development List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , MIME-Version: 1.0 Errors-To: dri-devel-bounces@lists.freedesktop.org Sender: "dri-devel" X-Virus-Scanned: ClamAV using ClamSMTP The msm Makefile and Kconfig are getting conjusted. HDMI is going to have more configs and files in the future to manage, which will make managing these harder. Move HDMI related stuff into separate Kconfig and Makefile. Signed-off-by: Archit Taneja --- drivers/gpu/drm/msm/Kconfig | 1 + drivers/gpu/drm/msm/Makefile | 10 +--------- drivers/gpu/drm/msm/hdmi/Kconfig | 7 +++++++ drivers/gpu/drm/msm/hdmi/Makefile | 4 ++++ drivers/gpu/drm/msm/msm_drv.h | 16 ++++++++++++++++ 5 files changed, 29 insertions(+), 9 deletions(-) create mode 100644 drivers/gpu/drm/msm/hdmi/Kconfig create mode 100644 drivers/gpu/drm/msm/hdmi/Makefile diff --git a/drivers/gpu/drm/msm/Kconfig b/drivers/gpu/drm/msm/Kconfig index 83e0615..1c702f7 100644 --- a/drivers/gpu/drm/msm/Kconfig +++ b/drivers/gpu/drm/msm/Kconfig @@ -25,3 +25,4 @@ config DRM_MSM_REGISTER_LOGGING logging can be switched on via msm.reglog=y module param. source "drivers/gpu/drm/msm/dsi/Kconfig" +source "drivers/gpu/drm/msm/hdmi/Kconfig" diff --git a/drivers/gpu/drm/msm/Makefile b/drivers/gpu/drm/msm/Makefile index 7ac7221..66b7ec4 100644 --- a/drivers/gpu/drm/msm/Makefile +++ b/drivers/gpu/drm/msm/Makefile @@ -5,15 +5,6 @@ msm-y := \ adreno/adreno_gpu.o \ adreno/a3xx_gpu.o \ adreno/a4xx_gpu.o \ - hdmi/hdmi.o \ - hdmi/hdmi_audio.o \ - hdmi/hdmi_bridge.o \ - hdmi/hdmi_connector.o \ - hdmi/hdmi_hdcp.o \ - hdmi/hdmi_i2c.o \ - hdmi/hdmi_phy_8960.o \ - hdmi/hdmi_phy_8x60.o \ - hdmi/hdmi_phy_8x74.o \ edp/edp.o \ edp/edp_aux.o \ edp/edp_bridge.o \ @@ -56,5 +47,6 @@ msm-$(CONFIG_DRM_FBDEV_EMULATION) += msm_fbdev.o msm-$(CONFIG_COMMON_CLK) += mdp/mdp4/mdp4_lvds_pll.o obj-$(CONFIG_DRM_MSM_DSI) += dsi/ +obj-$(CONFIG_DRM_MSM_HDMI) += hdmi/ obj-$(CONFIG_DRM_MSM) += msm.o diff --git a/drivers/gpu/drm/msm/hdmi/Kconfig b/drivers/gpu/drm/msm/hdmi/Kconfig new file mode 100644 index 0000000..4b24e1e --- /dev/null +++ b/drivers/gpu/drm/msm/hdmi/Kconfig @@ -0,0 +1,7 @@ +config DRM_MSM_HDMI + bool "Enable HDMI support in MSM DRM driver" + depends on DRM_MSM + default y + help + Choose this option if you have a need for HDMI connector + support. diff --git a/drivers/gpu/drm/msm/hdmi/Makefile b/drivers/gpu/drm/msm/hdmi/Makefile new file mode 100644 index 0000000..3810388 --- /dev/null +++ b/drivers/gpu/drm/msm/hdmi/Makefile @@ -0,0 +1,4 @@ +ccflags-y := -Iinclude/drm -Idrivers/gpu/drm/msm + +obj-y := hdmi.o hdmi_audio.o hdmi_bridge.o hdmi_connector.o hdmi_hdcp.o \ + hdmi_i2c.o hdmi_phy_8960.o hdmi_phy_8x60.o hdmi_phy_8x74.o diff --git a/drivers/gpu/drm/msm/msm_drv.h b/drivers/gpu/drm/msm/msm_drv.h index c1e7bba..ba13ab6 100644 --- a/drivers/gpu/drm/msm/msm_drv.h +++ b/drivers/gpu/drm/msm/msm_drv.h @@ -242,10 +242,26 @@ struct drm_framebuffer *msm_framebuffer_create(struct drm_device *dev, struct drm_fb_helper *msm_fbdev_init(struct drm_device *dev); struct hdmi; +#ifdef CONFIG_DRM_MSM_HDMI int hdmi_modeset_init(struct hdmi *hdmi, struct drm_device *dev, struct drm_encoder *encoder); void __init hdmi_register(void); void __exit hdmi_unregister(void); +#else +static inline int hdmi_modeset_init(struct hdmi *hdmi, struct drm_device *dev, + struct drm_encoder *encoder) +{ + return -EINVAL; +} + +static inline void __init hdmi_register(void) +{ +} + +static inline void __exit hdmi_unregister(void) +{ +} +#endif struct msm_edp; void __init msm_edp_register(void);