drm/sun4i: backend: Fetch backend ID from device tree

Some Allwinner SoCs have 2 display pipelines, as in 2 of each
components, including the frontend, backend, TCON, and any other
extras.

As the backend and TCON are always paired together and form the CRTC,
we need to know which backend or TCON we are currently probing, so we
can pair them when initializing the CRTC.

This patch figures out the backend's ID from the device tree and stores
it in the backend's data structure. It does this by looking at the "reg"
property of any remote endpoints connected to the backend's input port.

Signed-off-by: Chen-Yu Tsai <wens@csie.org>
Signed-off-by: Maxime Ripard <maxime.ripard@free-electrons.com>
Este commit está contenido en:
Chen-Yu Tsai
2017-04-21 16:38:52 +08:00
cometido por Maxime Ripard
padre fdde6e7bcd
commit da3a1c30dc
Se han modificado 2 ficheros con 46 adiciones y 0 borrados

Ver fichero

@@ -151,6 +151,8 @@ struct sun4i_backend {
struct clk *sat_clk;
struct reset_control *sat_reset;
int id;
/* Backend list management */
struct list_head list;
};