Skip to content

Commit

Permalink
Merge tag 'drm-hisilicon-next-2016-04-29' of github.com:xin3liang/lin…
Browse files Browse the repository at this point in the history
…ux into drm-next

drm-hisilicon-next for 4.7

Add new hisilicon kirin drm driver:
- Add maintainer for hisilicon DRM driver
- Add support for external bridge
- Add designware dsi host driver
- Add designware dsi encoder driver
- Add cma fbdev and hotplug
- Add vblank driver for ADE
- Add plane driver for ADE
- Add crtc driver for ADE
- Add hisilicon kirin drm master driver
- Add device tree binding for hi6220 display subsystem

* tag 'drm-hisilicon-next-2016-04-29' of github.com:xin3liang/linux:
  MAINTAINERS: Add maintainer for hisilicon DRM driver
  drm/hisilicon: Add support for external bridge
  drm/hisilicon: Add designware dsi host driver
  drm/hisilicon: Add designware dsi encoder driver
  drm/hisilicon: Add cma fbdev and hotplug
  drm/hisilicon: Add vblank driver for ADE
  drm/hisilicon: Add plane driver for ADE
  drm/hisilicon: Add crtc driver for ADE
  drm/hisilicon: Add hisilicon kirin drm master driver
  drm/hisilicon: Add device tree binding for hi6220 display subsystem
  • Loading branch information
Dave Airlie committed May 4, 2016
2 parents 090e1a7 + c84ffde commit 4946dd2
Show file tree
Hide file tree
Showing 15 changed files with 2,828 additions and 0 deletions.
72 changes: 72 additions & 0 deletions Documentation/devicetree/bindings/display/hisilicon/dw-dsi.txt
Original file line number Diff line number Diff line change
@@ -0,0 +1,72 @@
Device-Tree bindings for DesignWare DSI Host Controller v1.20a driver

A DSI Host Controller resides in the middle of display controller and external
HDMI converter or panel.

Required properties:
- compatible: value should be "hisilicon,hi6220-dsi".
- reg: physical base address and length of dsi controller's registers.
- clocks: contains APB clock phandle + clock-specifier pair.
- clock-names: should be "pclk".
- ports: contains DSI controller input and output sub port.
The input port connects to ADE output port with the reg value "0".
The output port with the reg value "1", it could connect to panel or
any other bridge endpoints.
See Documentation/devicetree/bindings/graph.txt for more device graph info.

A example of HiKey board hi6220 SoC and board specific DT entry:
Example:

SoC specific:
dsi: dsi@f4107800 {
compatible = "hisilicon,hi6220-dsi";
reg = <0x0 0xf4107800 0x0 0x100>;
clocks = <&media_ctrl HI6220_DSI_PCLK>;
clock-names = "pclk";
status = "disabled";

ports {
#address-cells = <1>;
#size-cells = <0>;

/* 0 for input port */
port@0 {
reg = <0>;
dsi_in: endpoint {
remote-endpoint = <&ade_out>;
};
};
};
};


Board specific:
&dsi {
status = "ok";

ports {
/* 1 for output port */
port@1 {
reg = <1>;

dsi_out0: endpoint@0 {
remote-endpoint = <&adv7533_in>;
};
};
};
};

&i2c2 {
...

adv7533: adv7533@39 {
...

port {
adv7533_in: endpoint {
remote-endpoint = <&dsi_out0>;
};
};
};
};

64 changes: 64 additions & 0 deletions Documentation/devicetree/bindings/display/hisilicon/hisi-ade.txt
Original file line number Diff line number Diff line change
@@ -0,0 +1,64 @@
Device-Tree bindings for hisilicon ADE display controller driver

ADE (Advanced Display Engine) is the display controller which grab image
data from memory, do composition, do post image processing, generate RGB
timing stream and transfer to DSI.

Required properties:
- compatible: value should be "hisilicon,hi6220-ade".
- reg: physical base address and length of the ADE controller's registers.
- hisilicon,noc-syscon: ADE NOC QoS syscon.
- resets: The ADE reset controller node.
- interrupt: the ldi vblank interrupt number used.
- clocks: a list of phandle + clock-specifier pairs, one for each entry
in clock-names.
- clock-names: should contain:
"clk_ade_core" for the ADE core clock.
"clk_codec_jpeg" for the media NOC QoS clock, which use the same clock with
jpeg codec.
"clk_ade_pix" for the ADE pixel clok.
- assigned-clocks: Should contain "clk_ade_core" and "clk_codec_jpeg" clocks'
phandle + clock-specifier pairs.
- assigned-clock-rates: clock rates, one for each entry in assigned-clocks.
The rate of "clk_ade_core" could be "360000000" or "180000000";
The rate of "clk_codec_jpeg" could be or less than "1440000000".
These rate values could be configured according to performance and power
consumption.
- port: the output port. This contains one endpoint subnode, with its
remote-endpoint set to the phandle of the connected DSI input endpoint.
See Documentation/devicetree/bindings/graph.txt for more device graph info.

Optional properties:
- dma-coherent: Present if dma operations are coherent.


A example of HiKey board hi6220 SoC specific DT entry:
Example:

ade: ade@f4100000 {
compatible = "hisilicon,hi6220-ade";
reg = <0x0 0xf4100000 0x0 0x7800>;
reg-names = "ade_base";
hisilicon,noc-syscon = <&medianoc_ade>;
resets = <&media_ctrl MEDIA_ADE>;
interrupts = <0 115 4>; /* ldi interrupt */

clocks = <&media_ctrl HI6220_ADE_CORE>,
<&media_ctrl HI6220_CODEC_JPEG>,
<&media_ctrl HI6220_ADE_PIX_SRC>;
/*clock name*/
clock-names = "clk_ade_core",
"clk_codec_jpeg",
"clk_ade_pix";

assigned-clocks = <&media_ctrl HI6220_ADE_CORE>,
<&media_ctrl HI6220_CODEC_JPEG>;
assigned-clock-rates = <360000000>, <288000000>;
dma-coherent;

port {
ade_out: endpoint {
remote-endpoint = <&dsi_in>;
};
};
};
10 changes: 10 additions & 0 deletions MAINTAINERS
Original file line number Diff line number Diff line change
Expand Up @@ -3853,6 +3853,16 @@ T: git git://github.com/patjak/drm-gma500
S: Maintained
F: drivers/gpu/drm/gma500/

DRM DRIVERS FOR HISILICON
M: Xinliang Liu <z.liuxinliang@hisilicon.com>
R: Xinwei Kong <kong.kongxinwei@hisilicon.com>
R: Chen Feng <puck.chen@hisilicon.com>
L: dri-devel@lists.freedesktop.org
T: git git://github.com/xin3liang/linux.git
S: Maintained
F: drivers/gpu/drm/hisilicon/
F: Documentation/devicetree/bindings/display/hisilicon/

DRM DRIVERS FOR NVIDIA TEGRA
M: Thierry Reding <thierry.reding@gmail.com>
M: Terje Bergström <tbergstrom@nvidia.com>
Expand Down
2 changes: 2 additions & 0 deletions drivers/gpu/drm/Kconfig
Original file line number Diff line number Diff line change
Expand Up @@ -285,3 +285,5 @@ source "drivers/gpu/drm/vc4/Kconfig"
source "drivers/gpu/drm/etnaviv/Kconfig"

source "drivers/gpu/drm/arc/Kconfig"

source "drivers/gpu/drm/hisilicon/Kconfig"
1 change: 1 addition & 0 deletions drivers/gpu/drm/Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -80,3 +80,4 @@ obj-y += bridge/
obj-$(CONFIG_DRM_FSL_DCU) += fsl-dcu/
obj-$(CONFIG_DRM_ETNAVIV) += etnaviv/
obj-$(CONFIG_DRM_ARCPGU)+= arc/
obj-y += hisilicon/
5 changes: 5 additions & 0 deletions drivers/gpu/drm/hisilicon/Kconfig
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
#
# hisilicon drm device configuration.
# Please keep this list sorted alphabetically

source "drivers/gpu/drm/hisilicon/kirin/Kconfig"
5 changes: 5 additions & 0 deletions drivers/gpu/drm/hisilicon/Makefile
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
#
# Makefile for hisilicon drm drivers.
# Please keep this list sorted alphabetically

obj-$(CONFIG_DRM_HISI_KIRIN) += kirin/
18 changes: 18 additions & 0 deletions drivers/gpu/drm/hisilicon/kirin/Kconfig
Original file line number Diff line number Diff line change
@@ -0,0 +1,18 @@
config DRM_HISI_KIRIN
tristate "DRM Support for Hisilicon Kirin series SoCs Platform"
depends on DRM && OF && ARM64
select DRM_KMS_HELPER
select DRM_GEM_CMA_HELPER
select DRM_KMS_CMA_HELPER
help
Choose this option if you have a hisilicon Kirin chipsets(hi6220).
If M is selected the module will be called kirin-drm.

config HISI_KIRIN_DW_DSI
tristate "HiSilicon Kirin specific extensions for Synopsys DW MIPI DSI"
depends on DRM_HISI_KIRIN
select DRM_MIPI_DSI
help
This selects support for HiSilicon Kirin SoC specific extensions for
the Synopsys DesignWare DSI driver. If you want to enable MIPI DSI on
hi6220 based SoC, you should selet this option.
6 changes: 6 additions & 0 deletions drivers/gpu/drm/hisilicon/kirin/Makefile
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
kirin-drm-y := kirin_drm_drv.o \
kirin_drm_ade.o

obj-$(CONFIG_DRM_HISI_KIRIN) += kirin-drm.o

obj-$(CONFIG_HISI_KIRIN_DW_DSI) += dw_drm_dsi.o
Loading

0 comments on commit 4946dd2

Please sign in to comment.