sunxi: video: Improve monitor video-mode option handling

Add a sunxi_monitor enum and parse the monitor option string into this enum
once, rather then doing strcmp-s on it in various places. This also adds
checking for it being a valid value.

This also adds new "none" and "lcd" values in preparation for lcd support.

Signed-off-by: Hans de Goede <hdegoede@redhat.com>
sunxi: video: Prepare for lcd support

Refactor sunxi_mode_set into a bunch of helpers, and make it do a switch
case on sunxi_display.monitor to decide what to do.

Also rename sunxi_lcdc_mode_set to sunxi_lcdc_tcon1_mode_set, as it sets the
timings for tcon1, and for lcd support we need a similar function operating
on tcon0.

Signed-off-by: Hans de Goede <hdegoede@redhat.com>
sunxi: video: Modify sunxi_lcdc_pll_set to work with both tcon0 and tcon1

Modify sunxi_lcdc_pll_set to work with both tcon0 and tcon1, this is a
preparation patch for adding lcd support.

While at it also swap the divider search order, searching from low to
high, as the comment above the code says we should do. In cases where there
are multiple solutions this will result in picking a lower pll clock and
divider, which is more stable and saves power.

Signed-off-by: Hans de Goede <hdegoede@redhat.com>
sunxi: video: Move sunxi_drc_init

Move sunxi_drc_init to directly above sunxi_engines_init, to avoid unnecessary

Signed-off-by: Hans de Goede <hdegoede@redhat.com>
sunxi: video: Add lcd output support

Add lcd output support, see the new Kconfig entries and doc/README.video for
how to enable / configure this.

Signed-off-by: Hans de Goede <hdegoede@redhat.com>
sunxi: video: Add video suppport for sun8i

sun8i (the A23) only has lcd output support.

Signed-off-by: Hans de Goede <hdegoede@redhat.com>
sunxi: Ippo_q8h defconfigs: Enable the LCD panel found on these tablets.

Enable the new LCD support on Ippo_q8h tablets.

Signed-off-by: Hans de Goede <hdegoede@redhat.com>
sunxi: Add 2 defconfigs for using the Olimex 7" lcd with olinuxino boards

Add defconfigs for using the Olimex 7" lcd with the A10s-OLinuXino-M and
the A20-OLinuXino_MICRO boards.

Note I do not intend to add defconfigs for all possible permutation of Olimex
boards and LCD displays, these 2 serve mostly as examples. In the long run
this should be solved by moving all the LCD info into dts files and using
devicetree overlays for add-on modules like the LCD displays.

Signed-off-by: Hans de Goede <hdegoede@redhat.com>