From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1753012AbcCRGpu (ORCPT ); Fri, 18 Mar 2016 02:45:50 -0400 Received: from mail-ig0-f194.google.com ([209.85.213.194]:33226 "EHLO mail-ig0-f194.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1751786AbcCRGpk (ORCPT ); Fri, 18 Mar 2016 02:45:40 -0400 Subject: Re: [PATCH v14.1 09/17] drm: rockchip: dp: add rockchip platform dp driver To: =?UTF-8?Q?Heiko_St=c3=bcbner?= , Yakir Yang References: <1455534485-1154-1-git-send-email-ykk@rock-chips.com> <1455534640-1877-1-git-send-email-ykk@rock-chips.com> <2523119.bAzQsAzOsc@diego> Cc: Krzysztof Kozlowski , Seung-Woo Kim , djkurtz@chromium.org, Andrzej Hajda , Gustavo Padovan , linux-samsung-soc@vger.kernel.org, Russell King , Joonyoung Shim , linux-rockchip@lists.infradead.org, Kishon Vijay Abraham I , javier@osg.samsung.com, Kukjin Kim , robherring2@gmail.com, Thierry Reding , devicetree@vger.kernel.org, Pawel Moll , Ian Campbell , Inki Dae , Rob Herring , Sean Paul , dri-devel@lists.freedesktop.org, linux-arm-kernel@lists.infradead.org, Mark Yao , Jingoo Han , emil.l.velikov@gmail.com, linux-kernel@vger.kernel.org, Kyungmin Park , Kumar Gala , ajaynumb@gmail.com, Andy Yan From: Caesar Wang Message-ID: <56EBA409.60707@gmail.com> Date: Fri, 18 Mar 2016 14:45:29 +0800 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:38.0) Gecko/20100101 Thunderbird/38.4.0 MIME-Version: 1.0 In-Reply-To: <2523119.bAzQsAzOsc@diego> Content-Type: text/plain; charset=UTF-8; format=flowed Content-Transfer-Encoding: 8bit Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org 在 2016年03月18日 05:51, Heiko Stübner 写道: > Rockchip have three clocks for dp controller, we leave pclk_edp > to analogix_dp driver control, and keep the sclk_edp_24m and > sclk_edp in platform driver. > > Signed-off-by: Yakir Yang > Tested-by: Javier Martinez Canillas Tested-by: Caesar Wang As the cover-letter said, verified on https://github.com/Caesar-github/rockchip/tree/veyron/next-stable-chromeos with linux-next for 20160317. > --- > Changes in v14.1: > - replace rockchip_drm_encoder_get_mux_id with the new > drm_of_encoder_active_endpoint_id > > Changes in v14: None > Changes in v13: > - Use .enable instead of preprare/commit in encoder_helper_funcs (Heiko) > - Fix the missing parameters with drm_encoder_init() helper function. (Heiko) > > Changes in v12: None > Changes in v11: None > Changes in v10: > - Correct the ROCKCHIP_ANALOGIX_DP indentation in Kconfig to tabs here (Heiko) > > Changes in v9: None > Changes in v8: None > Changes in v7: None > Changes in v6: None > Changes in v5: > - Remove the empty line at the end of document, and correct the endpoint > numbers in the example DT node, and remove the regulator iomux setting > in driver code while using the pinctl in devicetree instead. (Heiko) > - Add device type declared, cause the previous "platform device type > support (v4 11/16)" already merge into (v5 02/14). > - Implement connector registration code. (Thierry) > > Changes in v4: > - Remove some deprecated DT properties in rockchip dp document. > > Changes in v3: > - Leave "sclk_edp_24m" to rockchip dp phy driver which name to "24m", > and leave "sclk_edp" to analogix dp core driver which name to "dp", > and leave "pclk_edp" to rockchip dp platform driver which name to > "pclk". (Thierry & Heiko) > - Add devicetree binding document. (Heiko) > - Remove "rockchip,panel" DT property, take use of remote point to get panel > node. (Heiko) > - Add the new function point dp_platdata->get_modes() init. > > Changes in v2: > - Get panel node with remote-endpoint method, and create devicetree binding > for driver. (Heiko) > - Remove the clock enable/disbale with "sclk_edp" & "sclk_edp_24m", > leave those clock to rockchip dp phy driver. > > drivers/gpu/drm/rockchip/Kconfig | 9 + > drivers/gpu/drm/rockchip/Makefile | 1 + > drivers/gpu/drm/rockchip/analogix_dp-rockchip.c | 384 ++++++++++++++++++++++++ > include/drm/bridge/analogix_dp.h | 1 + > 4 files changed, 395 insertions(+) > create mode 100644 drivers/gpu/drm/rockchip/analogix_dp-rockchip.c > > diff --git a/drivers/gpu/drm/rockchip/Kconfig b/drivers/gpu/drm/rockchip/Kconfig > index 76b3362..d30bdc3 100644 > --- a/drivers/gpu/drm/rockchip/Kconfig > +++ b/drivers/gpu/drm/rockchip/Kconfig > @@ -16,6 +16,15 @@ config DRM_ROCKCHIP > 2D or 3D acceleration; acceleration is performed by other > IP found on the SoC. > > +config ROCKCHIP_ANALOGIX_DP > + tristate "Rockchip specific extensions for Analogix DP driver" > + depends on DRM_ROCKCHIP > + select DRM_ANALOGIX_DP > + help > + This selects support for Rockchip SoC specific extensions > + for the Analogix Core DP driver. If you want to enable DP > + on RK3288 based SoC, you should selet this option. > + > config ROCKCHIP_DW_HDMI > tristate "Rockchip specific extensions for Synopsys DW HDMI" > depends on DRM_ROCKCHIP > diff --git a/drivers/gpu/drm/rockchip/Makefile b/drivers/gpu/drm/rockchip/Makefile > index df8fbef..05d0713 100644 > --- a/drivers/gpu/drm/rockchip/Makefile > +++ b/drivers/gpu/drm/rockchip/Makefile > @@ -6,6 +6,7 @@ rockchipdrm-y := rockchip_drm_drv.o rockchip_drm_fb.o \ > rockchip_drm_gem.o rockchip_drm_vop.o > rockchipdrm-$(CONFIG_DRM_FBDEV_EMULATION) += rockchip_drm_fbdev.o > > +obj-$(CONFIG_ROCKCHIP_ANALOGIX_DP) += analogix_dp-rockchip.o > obj-$(CONFIG_ROCKCHIP_DW_HDMI) += dw_hdmi-rockchip.o > obj-$(CONFIG_ROCKCHIP_DW_MIPI_DSI) += dw-mipi-dsi.o > obj-$(CONFIG_ROCKCHIP_INNO_HDMI) += inno_hdmi.o > diff --git a/drivers/gpu/drm/rockchip/analogix_dp-rockchip.c b/drivers/gpu/drm/rockchip/analogix_dp-rockchip.c > new file mode 100644 > index 0000000..a1d94d8 > --- /dev/null > +++ b/drivers/gpu/drm/rockchip/analogix_dp-rockchip.c > @@ -0,0 +1,384 @@ > +/* > + * Rockchip SoC DP (Display Port) interface driver. > + * > + * Copyright (C) Fuzhou Rockchip Electronics Co., Ltd. > + * Author: Andy Yan > + * Yakir Yang > + * Jeff Chen > + * > + * This program is free software; you can redistribute it and/or modify it > + * under the terms of the GNU General Public License as published by the > + * Free Software Foundation; either version 2 of the License, or (at your > + * option) any later version. > + */ > + > +#include > +#include > +#include > +#include > +#include > +#include > + > +#include > +#include > +#include > +#include > +#include > + > +#include