drm: add Atmel HLCDC Display Controller support

The Atmel HLCDC (HLCD Controller) IP available on some Atmel SoCs (i.e.
at91sam9n12, at91sam9x5 family or sama5d3 family) provides a display
controller device.

This display controller supports at least one primary plane and might
provide several overlays and an hardware cursor depending on the IP
version.

At the moment, this driver only implements an RGB connector to interface
with LCD panels, but support for other kind of external devices might be
added later.

Signed-off-by: Boris BREZILLON <boris.brezillon@free-electrons.com>
drm: add DT bindings documentation for atmel-hlcdc-dc driver

The Atmel HLCDC (HLCD Controller) IP available on some Atmel SoCs (i.e.
at91sam9n12, at91sam9x5 family or sama5d3 family) provides a display
controller device.

The HLCDC block provides a single RGB output port, and only supports LCD
panels connection to LCD panels for now.

The atmel,panel property link the HLCDC RGB output with the LCD panel
connected on this port (note that the HLCDC RGB connector implementation
makes use of the DRM panel framework).

Connection to other external devices (DRM bridges) might be added later by
mean of a new atmel,xxx (atmel,bridge) property.

Signed-off-by: Boris BREZILLON <boris.brezillon@free-electrons.com>
ARM: AT91/dt: split sama5d3 lcd pin definitions to match RGB mode configs

The HLCDC (HLCD Controller) IP supports 4 different output mode (RGB444,
RGB565, RGB666 and RGB888) and the pin muxing will depend on the chosen
RGB mode.

Split pin definitions to be able to set pin config according to the
selected mode.

Signed-off-by: Boris BREZILLON <boris.brezillon@free-electrons.com>
ARM: AT91/dt: add alternative pin muxing for sama5d3 lcd pins

Define alternative pin muxing for the LCDC pins.

Signed-off-by: Boris BREZILLON <boris.brezillon@free-electrons.com>
ARM: at91/dt: define the HLCDC node available on sama5d3 SoCs

Define the HLCDC (HLCD Controller) IP available on some sama5d3 SoCs
(i.e. sama5d31, sama5d33, sama5d34 and sama5d36) in sama5d3 dtsi file.

Signed-off-by: Boris BREZILLON <boris.brezillon@free-electrons.com>
ARM: at91/dt: add LCD panel description to sama5d3xdm.dtsi

Add LCD panel related nodes (backlight, regulators and panel) to sama5d3
Display Module dtsi.

Reference LCD pin muxing used by sama5d3xek boards.

Signed-off-by: Boris BREZILLON <boris.brezillon@free-electrons.com>
ARM: at91/dt: enable the LCD panel on sama5d3xek boards

Enable LCD related nodes.

Signed-off-by: Boris BREZILLON <boris.brezillon@free-electrons.com>
atmel-hlcdc: add DMA config bits

Signed-off-by: Boris BREZILLON <boris.brezillon@free-electrons.com>
drm: atmel-hlcdc: remove duplicated ARGB1555 entries

Signed-off-by: Boris BREZILLON <boris.brezillon@free-electrons.com>
drm: atmel-hlcdc: fix rotation for RGB888 and YUV formats

Signed-off-by: Boris BREZILLON <boris.brezillon@free-electrons.com>
drm: atmel-hlcdc: add missing MACROs for register fields

Signed-off-by: Boris BREZILLON <boris.brezillon@free-electrons.com>
drm: atmel-hlcdc: check position and size consistency

Signed-off-by: Boris BREZILLON <boris.brezillon@free-electrons.com>
drm: atmel-hlcdc: fix status flag update

Signed-off-by: Boris BREZILLON <boris.brezillon@free-electrons.com>
drm: atmel-hlcdc: add missing call to finished callback

Signed-off-by: Boris BREZILLON <boris.brezillon@free-electrons.com>
drm: atmel-hlcdc: disable the layer when an overflow occurs

Signed-off-by: Boris BREZILLON <boris.brezillon@free-electrons.com>
drm: atmel-hlcdc: add support for at91sam9x5 SoCs

Define at91sam9x5 HLCDC capabilities.

Signed-off-by: Boris BREZILLON <boris.brezillon@free-electrons.com>
mfd: atmel-hlcdc: add support for at91sam9x5 SoCs

Signed-off-by: Boris BREZILLON <boris.brezillon@free-electrons.com>
ARM: at91/dt: add at91sam9x5 Display Module dtsi

Signed-off-by: Boris BREZILLON <boris.brezillon@free-electrons.com>
ARM: at91/dt: define hlcdc node in at91sam9x5_lcd.dtsi

Signed-off-by: Boris BREZILLON <boris.brezillon@free-electrons.com>
ARM: at91/dt: include lcd dtsi in at91sam9x35 dtsi

Signed-off-by: Boris BREZILLON <boris.brezillon@free-electrons.com>