summaryrefslogtreecommitdiff
path: root/drivers/video
AgeCommit message (Collapse)Author
2017-07-06avr32: Retire AVR32 for goodAndy Shevchenko
AVR32 is gone. It's already more than two years for no support in Buildroot, even longer there is no support in GCC (last version is heavily patched 4.2.4). Linux kernel v4.12 got rid of it (and v4.11 didn't build successfully). There is no good point to keep this support in U-Boot either. Reviewed-by: Simon Glass <sjg@chromium.org> Reviewed-by: Tom Rini <trini@konsulko.com> Reviewed-by: Heiko Schocher <hs@denx.de> Signed-off-by: Andy Shevchenko <andriy.shevchenko@linux.intel.com>
2017-06-12powerpc, 8xx: remove support for 8xxHeiko Schocher
There was for long time no activity in the 8xx area. We need to go further and convert to Kconfig, but it turned out, nobody is interested anymore in 8xx, so remove it (with a heavy heart, knowing that I remove here the root of U-Boot). Signed-off-by: Heiko Schocher <hs@denx.de>
2017-06-10Merge git://git.denx.de/u-boot-dmTom Rini
2017-06-09rockchip: video: Take the vop device out of standbySimon Glass
On reset the standby bit is clear, but if U-Boot is chain-loaded from another boot loader it may be set. Clear it before starting up video so that it works correctly. Signed-off-by: Simon Glass <sjg@chromium.org> Acked-by: Anatolij Gustschin <agust@denx.de> Squashed in 'rockchip: video: fix taking the VOP device out of standby': Signed-off-by: Philipp Tomsich <philipp.tomsich@theobroma-systems.com>
2017-06-09rockchip: video: Add remove() methodsSimon Glass
Add remove() methods for EDP and VOP so that U-Boot can shut down the video on exit. This avoids leaving DMA running while booting Linux which can cause problems if Linux uses the frame buffer for something else. It also makes it clear what is needed to shut down video. While we are here, make rkvop_enable() static. Signed-off-by: Simon Glass <sjg@chromium.org> Acked-by: Anatolij Gustschin <agust@denx.de> Squashed in 'rockchip: video: fix taking the VOP device out of standby': Signed-off-by: Philipp Tomsich <philipp.tomsich@theobroma-systems.com>
2017-06-09tegra: video: Don't power up the SOR twiceSimon Glass
If U-Boot is the secondary boot loader, or has been run from itself, the SOR may already be powered up. Powering it up again causes a hang, so detect this situation and skip it. Signed-off-by: Simon Glass <sjg@chromium.org> Acked-by: Anatolij Gustschin <agust@denx.de>
2017-06-09rockchip: video: document externally visible functions for rk_vopPhilipp Tomsich
Documents the externally visible functions shared between the VOP drivers for the RK3288 and RK3399. Signed-off-by: Philipp Tomsich <philipp.tomsich@theobroma-systems.com> Reviewed-by: Simon Glass <sjg@chromium.org>
2017-06-09rockchip: video: document externally visible functions for rk_hdmiPhilipp Tomsich
Documents the externally visible functions shared between the HDMI drivers for the RK3288 and RK3399. Signed-off-by: Philipp Tomsich <philipp.tomsich@theobroma-systems.com> Reviewed-by: Simon Glass <sjg@chromium.org>
2017-06-09video: atmel_hlcdfb: Fix misaligned cache operation warningWenyou Yang
Fix the warning, ---8<--- CACHE: Misaligned operation at range [3fdffff0, 3fdffffc] ---<8--- Signed-off-by: Wenyou Yang <wenyou.yang@atmel.com> Reviewed-by: Simon Glass <sjg@chromium.org>
2017-06-09sunxi: video: Add support for CSC and TVE to DE2 driverJernej Skrabec
Extend DE2 driver with support for TVE driver, which will be added in next commit. TVE unit expects data to be in YUV format, so CSC support is also added here. Note that HDMI driver has higher priority, so TV out is not probed if HDMI monitor is detected. Signed-off-by: Jernej Skrabec <jernej.skrabec@siol.net> Acked-by: Maxime Ripard <maxime.ripard@free-electrons.com> Reviewed-by: Simon Glass <sjg@chromium.org>
2017-06-09sunxi: video: Rename tve.c to tve_common.cJernej Skrabec
In order to avoid future confusion with similary named files, rename tve.c to tve_common.c. New name better represents the fact that this file holds code which can be and will be shared between multiple drivers. Signed-off-by: Jernej Skrabec <jernej.skrabec@siol.net> Acked-by: Maxime Ripard <maxime.ripard@free-electrons.com> Reviewed-by: Simon Glass <sjg@chromium.org>
2017-06-08rockchip: video: rk_vop: add grf fieldPhilipp Tomsich
The last set of rebases had dropped the 'grf' field from the common rk_vop. Add this back to un-break the build (and driver). Signed-off-by: Philipp Tomsich <philipp.tomsich@theobroma-systems.com>
2017-06-08rockchip: video: rk3399: add HDMI TX support on the RK3399Philipp Tomsich
This commit enables the RK3399 HDMI TX, which is very similar to the one found on the RK3288. As requested by Simon, this splits the HDMI driver into a SOC-specific portion (rk3399_hdmi.c, rk3288_hdmi.c) and a common portion (rk_hdmi.c). Note that the I2C communication for reading the EDID works well with the default settings, but does not with the alternate settings used on the RK3288... this configuration aspect is reflected by the driverdata for the RK3399 driver. Having some sort of DTS-based configuration for the regulator dependencies would be nice for the future, but for now we simply use lists of regulator names (also via driverdata) that we probe. Signed-off-by: Philipp Tomsich <philipp.tomsich@theobroma-systems.com> Reviewed-by: Simon Glass <sjg@chromium.org>
2017-06-08rockchip: video: split RK3288-specific part off from rk_hdmiPhilipp Tomsich
To prepare for the addition of RK3399 HDMI support, the HDMI driver is refactored and broken into a chip-specific and a generic part. This change adds the internal interfaces, makes common/reusable functions externally visible and splits the RK3288 driver into a separate file. For the probing of regulators, we reuse the infrastructure created during the VOP refactoring... i.e. we simply call into the helper function defined for the VOP. Signed-off-by: Philipp Tomsich <philipp.tomsich@theobroma-systems.com> Reviewed-by: Simon Glass <sjg@chromium.org>
2017-06-08rockchip: video: add mpixelclock settings from Linux driverPhilipp Tomsich
The Linux driver now supports higher mpixelclock settings. Add these to rockchip_phy_config[] and rockchip_mpll_cfg[]. Signed-off-by: Philipp Tomsich <philipp.tomsich@theobroma-systems.com> Reviewed-by: Simon Glass <sjg@chromium.org>
2017-06-08rockchip: video: rk3399: enable HDMI output (from the rk_vop) for the RK3399Philipp Tomsich
This commit adds a driver for the RK3399 VOPs capable and all the necessary plumbing to feed the HDMI encoder. For the VOP-big, this correctly tracks the ability to feed 10bit RGB data to the encoder. Signed-off-by: Philipp Tomsich <philipp.tomsich@theobroma-systems.com> Reviewed-by: Simon Glass <sjg@chromium.org>
2017-06-08rockchip: video: refactor rk_vop and split RK3288-specific code offPhilipp Tomsich
To prepare for adding the RK3399 VOP driver (which shares most of its registers and config logic with the RK3228 VOP), this change refactors the driver and splits the RK3288-specific driver off. The changes in detail are: - introduces a data-structure for chip-specific drivers to register features/callbacks with the common driver: at this time, this is limited to a callback for setting the pin polarities (between the VOP and the encoder modules) and a flag to signal 10bit RGB capability - refactors the probing of regulators into a helper function that can take a list of regulator names to probe and autoset - moves the priv data-structure into a (common) header file to be used by the chip-specific drivers to provide base addresses to the common driver - uses a callback into the chip-specific driver to set pin polarities (replacing the direct register accesses previously used) - splits enabling the output (towards an encoder) into a separate help function withint the common driver Signed-off-by: Philipp Tomsich <philipp.tomsich@theobroma-systems.com> Reviewed-by: Simon Glass <sjg@chromium.org>
2017-06-08rockchip: video: Kconfig: set MAX_XRES and MAX_YRES via KconfigPhilipp Tomsich
This introduces two new Kconfig options that configure the maximum allowable framebuffer size (i.e. the memory reservation/allocation for the framebuffer): - VIDEO_ROCKCHIP_MAX_XRES - VIDEO_ROCKCHIP_MAX_YRES The resulting memory allocation will cover 4 byte per pixel for these resolutions. Signed-off-by: Philipp Tomsich <philipp.tomsich@theobroma-systems.com> Reviewed-by: Simon Glass <sjg@chromium.org>
2017-06-08rockchip: video: Kconfig: reformat help for VIDEO_ROCKCHIPPhilipp Tomsich
For consistency sake (and as we are about to add new options to this file), reformat the help for VIDEO_ROCKCHIP. Signed-off-by: Philipp Tomsich <philipp.tomsich@theobroma-systems.com> Reviewed-by: Simon Glass <sjg@chromium.org>
2017-06-08rockchip: video: rk_hdmi: fix implicit definition warningsPhilipp Tomsich
When enabling CONFIG_DISPLAY_ROCKCHIP_HDMI, compile-time warning for the following implicitly defined functions are raised due to a missing include directive: drivers/video/rockchip/rk_hdmi.c: In function 'rk_hdmi_probe': drivers/video/rockchip/rk_hdmi.c:150:2: warning: implicit declaration of function 'rk_setreg' [-Wimplicit-function-declaration] rk_setreg(&priv->grf->soc_con6, 1 << 15); ^~~~~~~~~ drivers/video/rockchip/rk_hdmi.c:153:2: warning: implicit declaration of function 'rk_clrsetreg' [-Wimplicit-function-declaration] rk_clrsetreg(&priv->grf->soc_con6, 1 << 4, ^~~~~~~~~~~~ This change fixes this by including <asm/hardware.h> in rk_hdmi.c. Signed-off-by: Philipp Tomsich <philipp.tomsich@theobroma-systems.com> Acked-by: Simon Glass <sjg@chromium.org>
2017-06-05common: Drop inclusion of pci.hSimon Glass
This should not be in common.h - remove it and update the only file that needs it. Signed-off-by: Simon Glass <sjg@chromium.org>
2017-06-01dm: core: Replace of_offset with accessor (part 2)Simon Glass
At present devices use a simple integer offset to record the device tree node associated with the device. In preparation for supporting a live device tree, which uses a node pointer instead, refactor existing code to access this field through an inline function. Signed-off-by: Simon Glass <sjg@chromium.org>
2017-06-01dm: Fix up inclusion of common.hSimon Glass
It is good practice to include common.h as the first header. This ensures that required features like the DECLARE_GLOBAL_DATA_PTR macro, configuration options and common types are available. Fix up some files which currently don't do this. This is necessary because driver model will soon start using global data and configuration in the dm/read.h header file, included via dm.h. The gd->fdt_blob value will be used to access the device tree and CONFIG options will be used to determine whether to support inline functions in the header file. Signed-off-by: Simon Glass <sjg@chromium.org>
2017-06-01dm: Rename dev_addr..() functionsSimon Glass
These support the flat device tree. We want to use the dev_read_..() prefix for functions that support both flat tree and live tree. So rename the existing functions to avoid confusion. In the end we will have: 1. dev_read_addr...() - works on devices, supports flat/live tree 2. devfdt_get_addr...() - current functions, flat tree only 3. of_get_address() etc. - new functions, live tree only All drivers will be written to use 1. That function will in turn call either 2 or 3 depending on whether the flat or live tree is in use. Note this involves changing some dead code - the imx_lpi2c.c file. Signed-off-by: Simon Glass <sjg@chromium.org>
2017-05-15sunxi: video: Split out TVE codeJernej Skrabec
Newer SoCs use same TV encoder unit. Split it out so it can be reused with new DM video driver. Signed-off-by: Jernej Skrabec <jernej.skrabec@siol.net> Reviewed-by: Simon Glass <sjg@chromium.org>
2017-05-15video: bmp: rename CONFIG_BMP_24BMP to CONFIG_BMP_24BPPPhilipp Tomsich
Due to a typo, the 24 bit-per-pixel configuration ends in 24BMP instead of 24BPP. This change renames it throughout the source tree for consistency and to make moving these options into Kconfig easier and less error-prone. Signed-off-by: Philipp Tomsich <philipp.tomsich@theobroma-systems.com> Reviewed-by: Simon Glass <sjg@chromium.org> Reviewed-by: Hannes Schmelzer <hannes.schmelzer@br-automation.com>
2017-05-15rockchip: video: introduce VIDEO_DW_HDMI and select for Rockchip HDMIPhilipp Tomsich
Instead of having drivers/video/rockchip/Kconfig point outside of its hierarchy for dw_hdmi.o, we should use a configuration-option to include the Designware HDMI support. This change introduces a new config option (not to be selected via menuconfig, but to be selected from a dependent video driver's configuration option) that enables dw_hdmi.o and selects it whenever the HDMI support for Rockchip SoCs is selected. Signed-off-by: Philipp Tomsich <philipp.tomsich@theobroma-systems.com> Reviewed-by: Simon Glass <sjg@chromium.org>
2017-05-15video: dw_hdmi: Select HDMI mode only if monitor supports itJernej Skrabec
Some DVI monitors don't work in HDMI mode. Set it only if edid data explicitly states that it is supported. Signed-off-by: Jernej Skrabec <jernej.skrabec@siol.net> Reviewed-by: Simon Glass <sjg@chromium.org>
2017-05-12video: ld9040: Fix unused variable warningsTom Rini
The variables SEQ_SWRESET, SEQ_ELVSS_ON, SEQ_TEMP_SWIRE, SEQ_APON and SEQ_SLPIN are unreferenced, drop. Cc: Anatolij Gustschin <agust@denx.de> Signed-off-by: Tom Rini <trini@konsulko.com>
2017-05-10rockchip: video: vop: Reserve enough space for mipi dispalyEric Gao
plat->size here is used to reserve frame buffer space befor relocation. our mipi panel use 24 bitwidth, and vop require 32bit align. So the frame buffer size should be at least 1920*1200*32/8. Signed-off-by: Eric Gao <eric.gao@rock-chips.com> Reviewed-by: Simon Glass <sjg@chromium.org>
2017-05-10rockchip: video: vop: Set different bitwidth for different display modeEric Gao
Because the bitwidth is different for different display mode, so we need to set them according to demand. Signed-off-by: Eric Gao <eric.gao@rock-chips.com> Reviewed-by: Simon Glass <sjg@chromium.org>
2017-05-10rockchip: video: vop: Add mipi display mode for rk3399Eric Gao
Add mipi display mode for rk3399 vop, so that we can use mipi panel for display. Signed-off-by: Eric Gao <eric.gao@rock-chips.com> Reviewed-by: Simon Glass <sjg@chromium.org>
2017-05-10rockchip: video: vop: Fix rk_display_init() return errorEric Gao
It's caused by the difference of clk_set_rate function implement between rk3288 andd rk3399. clk_set_rate() of rk3288 return 0 in normal condition. clk_set_rate() of rk3399 return input parameter in normal condition. So check clk_set_rate's return value by IS_ERR_VALUE. Signed-off-by: Eric Gao <eric.gao@rock-chips.com>
2017-05-10rockchip: video: Add mipi driver support for rockchip socEric Gao
Add basic driver for mipi display on rockchip soc platform. Signed-off-by: Eric Gao <eric.gao@rock-chips.com> Acked-by: Simon Glass <sjg@chromium.org>
2017-05-10rockchip: video: Makefile: Modify Makefile for rockchip video drivereric.gao@rock-chips.com
Modify Makefile for rockchip video driver according to Kconfig, so that source code will not be compiled if not needed. Signed-off-by: Eric Gao <eric.gao@rock-chips.com> Acked-by: Simon Glass <sjg@chromium.org>
2017-05-10rockchip: video: Kconfig: Add Kconfig for rockchip video drivereric.gao@rock-chips.com
1. add Kconfig for rockchip video driver, so that video port can be selected as needed. 2. move VIDEO_ROCKCHIP option to new Kconfig for concision. Signed-off-by: Eric Gao <eric.gao@rock-chips.com> Acked-by: Simon Glass <sjg@chromium.org> Drop indenting in Kconfig: Signed-off-by: Simon Glass <sjg@chromium.org>
2017-05-10dm: video: arm: rpi: Convert to use driver model for videoSimon Glass
Adjust the video driver to work with driver model and move over existing baords. There is no need to keep the old code. We can also drop setting of CONFIG_FB_ADDR since driver model doesn't have this problem. Signed-off-by: Simon Glass <sjg@chromium.org> Acked-by: Anatolij Gustschin <agust@denx.de>
2017-05-10video: arm: rpi: Move the video settings out of the driverSimon Glass
Add a function to set the video parameters to the msg handler and remove it from the video driver. Signed-off-by: Simon Glass <sjg@chromium.org> Acked-by: Anatolij Gustschin <agust@denx.de>
2017-05-10video: arm: rpi: Move the video query out of the driverSimon Glass
Add a function to get the video size to the msg handler and remove it from the video driver. Signed-off-by: Simon Glass <sjg@chromium.org> Acked-by: Anatolij Gustschin <agust@denx.de>
2017-05-08Merge branch 'master' of git://git.denx.de/u-boot-sunxiTom Rini
2017-04-30Convert CONFIG_SYS_WHITE_ON_BLACK to KconfigSimon Glass
This converts the following to Kconfig: CONFIG_SYS_WHITE_ON_BLACK Signed-off-by: Simon Glass <sjg@chromium.org> [trini: Make this default y on various SoCs] Signed-off-by: Tom Rini <trini@konsulko.com>
2017-04-28sunxi: video: Add A64/H3/H5 HDMI driverJernej Skrabec
This commit adds support for HDMI output. Signed-off-by: Jernej Skrabec <jernej.skrabec@siol.net> Reviewed-by: Simon Glass <sjg@chromium.org> Acked-by: Maxime Ripard <maxime.ripard@free-electrons.com> Signed-off-by: Maxime Ripard <maxime.ripard@free-electrons.com>
2017-04-20sunxi: Add clock support for DE2/HDMI/TCON on newer SoCsJernej Skrabec
This is needed for HDMI, which will be added later. Signed-off-by: Jernej Skrabec <jernej.skrabec@siol.net> Reviewed-by: Simon Glass <sjg@chromium.org> Signed-off-by: Maxime Ripard <maxime.ripard@free-electrons.com>
2017-04-20sunxi: video: Convert lcdc to use struct display_timingJernej Skrabec
Video driver for older Allwinner SoCs uses cfb console framework which in turn uses struct ctfb_res_modes to hold timing informations. However, DM video framework uses different structure - struct display_timing. It makes more sense to convert lcdc to use new timing structure because all new drivers should use DM video framework and older drivers might be rewritten to use new framework too. Signed-off-by: Jernej Skrabec <jernej.skrabec@siol.net> Acked-by: Maxime Ripard <maxime.ripard@free-electrons.com> Signed-off-by: Maxime Ripard <maxime.ripard@free-electrons.com>
2017-04-20sunxi: video: Split out TCON codeJernej Skrabec
TCON unit has similar layout and functionality also on newer SoCs. This commit splits out TCON code for easier reuse later. Signed-off-by: Jernej Skrabec <jernej.skrabec@siol.net> Acked-by: Maxime Ripard <maxime.ripard@free-electrons.com> Signed-off-by: Maxime Ripard <maxime.ripard@free-electrons.com>
2017-04-15Merge branch 'master' of git://git.denx.de/u-boot-videoTom Rini
2017-04-14video: Fix crash when scroll screeneric.gao@rock-chips.com
After enabling log printing to lcd, when the screen starts scrolling, system crashes. Log is shown as bellow: "Synchronous Abort" handler, esr 0x96000045 "Synchronous Abort" handler, esr 0x96000045 Checking the source code, we found that the variable "pixels" gets a wrong value: int pixels = VIDEO_FONT_HEIGHT * vid_priv->line_length; "pixels" here means the value of pixels for a character, rather than the bytes for a character. So the variable "pixels" is 4 times bigger than it's exact value, which will cause the memory overflow when the cpu runs the following code: for (i = 0; i < pixels; i++) *dst++ = clr; <<---- Signed-off-by: Eric Gao <eric.gao@rock-chips.com>
2017-04-14at91: video: Support driver-model for the HLCD driverSongjun Wu
Add driver-model support to this driver. Signed-off-by: Songjun Wu <songjun.wu@microchip.com>
2017-04-14video: fsl_dcu_fb: add additional modes for DCUStefan Agner
Add common widescreen modes 800x480 and 1024x600. Signed-off-by: Stefan Agner <stefan.agner@toradex.com> Signed-off-by: Sanchayan Maity <maitysanchayan@gmail.com> Reviewed-by: Alison Wang <alison.wang@nxp.com>
2017-04-14video: fsl_dcu_fb: Fix DCU_MODE_BLEND_ITER settingStefan Agner
DCU_LAYER_MAX_NUM is currently used for DCU_MODE_BLEND_ITER and it actually overflows the maximum value of BLEND_ITER for Vybrid and LS102XA. Fix this by using a default value of 2. Signed-off-by: Stefan Agner <stefan.agner@toradex.com> Signed-off-by: Sanchayan Maity <maitysanchayan@gmail.com>