From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1751515AbaHDEzz (ORCPT ); Mon, 4 Aug 2014 00:55:55 -0400 Received: from regular1.263xmail.com ([211.150.99.133]:46564 "EHLO regular1.263xmail.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1750904AbaHDEzw (ORCPT ); Mon, 4 Aug 2014 00:55:52 -0400 X-263anti-spam: KSV:0; X-MAIL-GRAY: 0 X-MAIL-DELIVERY: 1 X-ABS-CHECKED: 4 X-KSVirus-check: 0 X-RL-SENDER: yzq@rock-chips.com X-FST-TO: heiko@sntech.de X-SENDER-IP: 127.0.0.1 X-LOGIN-NAME: yzq@rock-chips.com X-UNIQUE-TAG: <84347b3a9ea5aef27aabec6591555cba> X-ATTACHMENT-NUM: 0 X-DNS-TYPE: 1 From: mark yao To: heiko@sntech.de, Rob Clark , Rob Herring , Pawel Moll , Mark Rutland , Ian Campbell , Kumar Gala , Randy Dunlap , David Airlie , Grant Likely , Greg Kroah-Hartman , John Stultz , Rom Lemarchand Cc: devicetree@vger.kernel.org, linux-doc@vger.kernel.org, linux-kernel@vger.kernel.org, dri-devel@lists.freedesktop.org, linux-api@vger.kernel.org, olof@lixom.net, djkurtz@chromium.org, xjq@rock-chips.com, kfx@rock-chips.com, cym@rock-chips.com, cf@rock-chips.com, zyw@rock-chips.com, zwl@rock-chips.com, xxm@rock-chips.com, huangtao@rock-chips.com, kever.yang@rock-chips.com, zhangqing@rock-chips.com, yxj@rock-chips.com, wxt@rock-chips.com, xw@rock-chips.com, mark yao Subject: [PATCH 7/9] drm: add Rockchip Soc rk3288 lvds connector Date: Mon, 4 Aug 2014 12:54:34 +0800 Message-Id: <1407128074-1882-1-git-send-email-yzq@rock-chips.com> X-Mailer: git-send-email 1.7.9.5 In-Reply-To: <1407127274-1356-1-git-send-email-mark.yao@rock-chips.com> References: <1407127274-1356-1-git-send-email-mark.yao@rock-chips.com> Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Signed-off-by: mark yao --- drivers/gpu/drm/rockchip/Kconfig | 1 + drivers/gpu/drm/rockchip/Makefile | 2 +- drivers/gpu/drm/rockchip/connector/Kconfig | 8 + drivers/gpu/drm/rockchip/connector/Makefile | 4 + drivers/gpu/drm/rockchip/connector/rk3288_lvds.c | 332 ++++++++++++++++++++++ drivers/gpu/drm/rockchip/connector/rk3288_lvds.h | 50 ++++ drivers/gpu/drm/rockchip/rockchip_drm_drv.c | 13 + drivers/gpu/drm/rockchip/rockchip_drm_drv.h | 3 + 8 files changed, 412 insertions(+), 1 deletion(-) create mode 100644 drivers/gpu/drm/rockchip/connector/Kconfig create mode 100644 drivers/gpu/drm/rockchip/connector/Makefile create mode 100644 drivers/gpu/drm/rockchip/connector/rk3288_lvds.c create mode 100644 drivers/gpu/drm/rockchip/connector/rk3288_lvds.h diff --git a/drivers/gpu/drm/rockchip/Kconfig b/drivers/gpu/drm/rockchip/Kconfig index ccce827..407cbb6 100644 --- a/drivers/gpu/drm/rockchip/Kconfig +++ b/drivers/gpu/drm/rockchip/Kconfig @@ -40,3 +40,4 @@ config DRM_ROCKCHIP_CONNECTOR such as lcd plane, lvds, edp , mipi, etc. source "drivers/gpu/drm/rockchip/lcdc/Kconfig" +source "drivers/gpu/drm/rockchip/connector/Kconfig" diff --git a/drivers/gpu/drm/rockchip/Makefile b/drivers/gpu/drm/rockchip/Makefile index 6d49edc..7d5877a 100644 --- a/drivers/gpu/drm/rockchip/Makefile +++ b/drivers/gpu/drm/rockchip/Makefile @@ -8,6 +8,6 @@ rockchipdrm-y := rockchip_drm_drv.o rockchip_drm_gem.o \ rockchip_drm_fb.o rockchip_drm_fbdev.o \ rockchip_panel.o -obj-$(CONFIG_DRM_ROCKCHIP_CONNECTOR) += rockchip_drm_connector.o +obj-$(CONFIG_DRM_ROCKCHIP_CONNECTOR) += rockchip_drm_connector.o connector/ obj-$(CONFIG_DRM_ROCKCHIP_LCDC) += rockchip_drm_lcdc.o lcdc/ obj-$(CONFIG_DRM_ROCKCHIP) += rockchipdrm.o diff --git a/drivers/gpu/drm/rockchip/connector/Kconfig b/drivers/gpu/drm/rockchip/connector/Kconfig new file mode 100644 index 0000000..248942f --- /dev/null +++ b/drivers/gpu/drm/rockchip/connector/Kconfig @@ -0,0 +1,8 @@ +config RK3288_LVDS + bool "RK3288 lvds connector support" + depends on DRM_ROCKCHIP_CONNECTOR + help + Choose this option if you have a rk3288 lvds connector. + rk3288 lvds transmitter support ttl rgb, lvds and dual lvds + mode, dual lvds mode is support for the plane which need dual + lvds channels. diff --git a/drivers/gpu/drm/rockchip/connector/Makefile b/drivers/gpu/drm/rockchip/connector/Makefile new file mode 100644 index 0000000..dcfbdef --- /dev/null +++ b/drivers/gpu/drm/rockchip/connector/Makefile @@ -0,0 +1,4 @@ +# +# Makefile for display connector like lvds edp mipi +# +obj-$(CONFIG_RK3288_LVDS) += rk3288_lvds.o diff --git a/drivers/gpu/drm/rockchip/connector/rk3288_lvds.c b/drivers/gpu/drm/rockchip/connector/rk3288_lvds.c new file mode 100644 index 0000000..3ca4c6f --- /dev/null +++ b/drivers/gpu/drm/rockchip/connector/rk3288_lvds.c @@ -0,0 +1,332 @@ +/* + * Copyright (C) Fuzhou Rockchip Electronics Co.Ltd + * Author: + * hjc + * mark yao + * + * This software is licensed under the terms of the GNU General Public + * License version 2, as published by the Free Software Foundation, and + * may be copied, distributed, and modified under those terms. + * + * This program is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. + */ + +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include + +#include