linux_dsm_epyc7002/drivers/gpu/drm
Paul Cercueil fc1acf317b
drm/ingenic: Add support for the IPU
Add support for the Image Processing Unit (IPU) found in all Ingenic
SoCs.

The IPU can upscale and downscale a source frame of arbitrary size
ranging from 4x4 to 4096x4096 on newer SoCs, with bicubic filtering
on newer SoCs, bilinear filtering on older SoCs. Nearest-neighbour can
also be obtained with proper coefficients.

Starting from the JZ4725B, the IPU supports a mode where its output is
sent directly to the LCDC, without having to be written to RAM first.
This makes it possible to use the IPU as a DRM plane on the compatible
SoCs, and have it convert and scale anything the userspace asks for to
what's available for the display.

Regarding pixel formats, older SoCs support packed YUV 4:2:2 and various
planar YUV formats. Newer SoCs introduced support for RGB.

Since the IPU is a separate hardware block, to make it work properly the
Ingenic DRM driver will now register itself as a component master in
case the IPU driver has been enabled in the config.

When enabled in the config, the CRTC will see the IPU as a second primary
plane. It cannot be enabled at the same time as the regular primary
plane. It has the same priority, which means that it will also display
below the overlay plane.

v2: - ingenic-ipu is no longer its own module. It will be built
      into the ingenic-drm module.
    - If enabled in the config, both the core driver and the IPU
      driver will register as components; otherwise the core
      driver will bypass that and call the ingenic_drm_bind()
      function directly.
    - Since both files now build into the same module, the
      symbols previously exported as GPL are not exported anymore,
      since they are only used internally.
    - Fix SPDX license header in ingenic-ipu.h
    - Avoid using 'for(;;);' loops without trailing statement(s)

v3: - Pass priv structure to IRQ handler; that way we don't hardcode
      the expectation that the IPU plane is at index #0.
    - Rework osd_changed() to account for src_* changes
    - Add multiplanar YUV 4:4:4 support
    - Commit fb addresses to HW at vblank, since addr registers are
      not shadow registers
    - Probe IPU component later so that IPU plane is last
    - Fix driver not working on IPU-less hardware
    - Use IPU driver's name as the IRQ name to avoid having two
      'ingenic-drm' in /proc/interrupts
    - Fix IPU only working for still images on JZ4725B
    - Add a bit more code comments

Signed-off-by: Paul Cercueil <paul@crapouillou.net>
Reviewed-by: Sam Ravnborg <sam@ravnborg.org>
Link: https://patchwork.freedesktop.org/patch/msgid/20200716163846.174790-10-paul@crapouillou.net
2020-07-17 00:46:17 +02:00
..
amd drm/amdgpu: stop allocating dummy GTT nodes 2020-07-13 14:30:43 +02:00
arc drm/arc: Set GEM CMA functions with DRM_GEM_CMA_DRIVER_OPS 2020-06-10 09:02:03 +02:00
arm drm/atomic-helper: reset vblank on crtc reset 2020-07-02 20:25:51 +02:00
armada drm-misc-next for v5.9: 2020-06-24 15:45:51 +10:00
aspeed drm/cma-helper: Rename symbols from drm_cma_gem_ to drm_gem_cma_ 2020-06-10 09:01:38 +02:00
ast drm/ast: Initialize mode setting in ast_mode_config_init() 2020-07-07 11:12:06 +02:00
atmel-hlcdc drm/atomic-helper: reset vblank on crtc reset 2020-07-02 20:25:51 +02:00
bochs drm/bochs: use drm_gem_vram_offset to get bo offset v2 2020-06-25 11:59:43 +02:00
bridge drm/bridge: sil_sii8620: initialize return of sii8620_readb 2020-07-13 17:57:17 +02:00
etnaviv drm-misc-next for v5.9: 2020-06-24 15:45:51 +10:00
exynos drm-misc-next for v5.9: 2020-06-24 15:45:51 +10:00
fsl-dcu drm/fsl-dcu: Set GEM CMA functions with DRM_GEM_CMA_DRIVER_OPS 2020-06-10 09:02:52 +02:00
gma500 drm/gma500: Stop using mode->private_flags 2020-05-27 14:31:42 +03:00
hisilicon drm/hisilicon: Code refactoring for hibmc_drv_vdac 2020-07-06 11:06:39 +02:00
i2c drm: bridge: Pass drm_display_info to drm_bridge_funcs .mode_valid() 2020-06-23 19:53:27 +02:00
i810
i915 drm/i915: Fix the old vs. new epoch counter check during hotplug detect 2020-07-02 11:30:11 +03:00
imx drm/imx: Use __drm_atomic_helper_crtc_reset 2020-07-02 20:25:52 +02:00
ingenic drm/ingenic: Add support for the IPU 2020-07-17 00:46:17 +02:00
lib
lima drm/lima: Expose job_hang_limit module parameter 2020-07-13 13:47:41 +08:00
mcde drm/mcde: Set GEM CMA functions with DRM_GEM_CMA_DRIVER_OPS 2020-06-10 09:04:21 +02:00
mediatek drm/mtk: Use __drm_atomic_helper_crtc_reset 2020-07-02 20:25:52 +02:00
meson drm/meson: overlay: fix build failure 2020-07-07 15:53:44 +02:00
mga
mgag200 drm/mgag200: Inline mga_crtc_{prepare, commit}() into enable function 2020-07-14 09:14:06 +02:00
msm drm/atomic-helper: reset vblank on crtc reset 2020-07-02 20:25:51 +02:00
mxsfb drm/mxsfb: Set GEM CMA functions with DRM_GEM_CMA_DRIVER_OPS 2020-06-10 09:04:51 +02:00
nouveau drm/nouveau/kms/nvd9-: Fix disabling CRCs alongside OR reprogramming 2020-07-16 18:16:33 -04:00
omapdrm drm/atomic-helper: reset vblank on crtc reset 2020-07-02 20:25:51 +02:00
panel drm/panel-simple: Add 50 Hz mode to the Frida FRD350H54004 panel 2020-07-16 19:06:43 +02:00
panfrost drm/panfrost: Use kvfree() to free bo->sgts 2020-06-19 11:00:02 +01:00
pl111 drm: pl111: Absorb the external register header 2020-06-30 00:32:59 +02:00
qxl Backmerge remote-tracking branch 'drm/drm-next' into drm-misc-next 2020-06-29 12:16:26 +02:00
r128
radeon drm: radeon: fix common struct sg_table related issues 2020-07-13 10:48:07 +02:00
rcar-du drm/atomic-helper: reset vblank on crtc reset 2020-07-02 20:25:51 +02:00
rockchip drm: bridge: dw-hdmi: Pass drm_display_info to dw_hdmi_support_scdc() 2020-06-23 19:57:06 +02:00
savage
scheduler Backmerge remote-tracking branch 'drm/drm-next' into drm-misc-next 2020-06-29 12:16:26 +02:00
selftests drm/mm/selftests: fix wrong return type casting 2020-06-23 15:57:30 +02:00
shmobile drm/shmobile: Set GEM CMA functions with DRM_GEM_CMA_DRIVER_OPS 2020-06-10 09:05:18 +02:00
sis
sti drm/sti: Set GEM CMA functions with DRM_GEM_CMA_DRIVER_OPS 2020-06-10 09:05:45 +02:00
stm drm/stm: repair runtime power management 2020-07-08 11:47:01 +02:00
sun4i Backmerge remote-tracking branch 'drm/drm-next' into drm-misc-next 2020-06-29 12:16:26 +02:00
tdfx
tegra drm/atomic-helper: reset vblank on crtc reset 2020-07-02 20:25:51 +02:00
tidss drm/tidss: Replace HTTP links with HTTPS ones 2020-07-16 22:13:52 +02:00
tilcdc drm/tilcdc: Use standard drm_atomic_helper_commit 2020-07-14 10:32:33 +02:00
tiny drm/mipi-dbi: Remove ->enabled 2020-06-24 09:17:34 +02:00
ttm drm/ttm: further cleanup ttm_mem_reg handling 2020-07-13 14:29:40 +02:00
tve200 drm/tve200: Set GEM CMA functions with DRM_GEM_CMA_DRIVER_OPS 2020-06-10 09:06:11 +02:00
udl drm/udl: Use GEM vmap/mmap function from SHMEM helpers 2020-06-10 10:17:21 +02:00
v3d drm/v3d: remove _unlocked suffix in drm_gem_object_put_unlocked 2020-05-19 22:31:35 +01:00
vboxvideo drm/vboxvideo: Replace HTTP links with HTTPS ones 2020-07-16 22:12:50 +02:00
vc4 drm/vc4: crtc: Remove the feed_txp tests 2020-07-07 10:51:58 +02:00
vgem drm/vgem: Replace opencoded version of drm_gem_dumb_map_offset() 2020-07-08 22:00:21 +01:00
via
virtio drm/virtio: Remove open-coded commit-tail function 2020-07-14 10:47:16 +02:00
vkms drm/vkms: change the max cursor width/height 2020-07-12 18:09:13 -04:00
vmwgfx drm/vmwgfx: Use __drm_atomic_helper_crtc_reset 2020-07-02 20:25:52 +02:00
xen drm/xen: remove _unlocked suffix in drm_gem_object_put_unlocked 2020-05-19 22:31:36 +01:00
zte drm/zte: remove unneeded semicolon 2020-06-29 09:39:04 +02:00
drm_agpsupport.c
drm_atomic_helper.c drm: bridge: Pass drm_display_info to drm_bridge_funcs .mode_valid() 2020-06-23 19:53:27 +02:00
drm_atomic_state_helper.c drm/atomic-helper: reset vblank on crtc reset 2020-07-02 20:25:51 +02:00
drm_atomic_uapi.c drm : Insert blank lines after declarations. 2020-07-02 15:26:00 +02:00
drm_atomic.c drm : Insert blank lines after declarations. 2020-07-02 15:26:00 +02:00
drm_auth.c drm/auth: make drm_{set,drop}master_ioctl symmetrical 2020-06-15 14:49:50 +01:00
drm_blend.c drm: plane: Verify that no or all planes have a zpos property 2020-05-14 02:10:52 +03:00
drm_bridge_connector.c
drm_bridge.c drm: bridge: Pass drm_display_info to drm_bridge_funcs .mode_valid() 2020-06-23 19:53:27 +02:00
drm_bufs.c drm : Insert blank lines after declarations. 2020-07-02 15:26:00 +02:00
drm_cache.c
drm_client_modeset.c drm: Nuke mode->vrefresh 2020-05-27 14:31:42 +03:00
drm_client.c drm/client: Add drm_client_framebuffer_flush() 2020-05-26 13:31:01 +02:00
drm_color_mgmt.c
drm_connector.c drm : Insert blank lines after declarations. 2020-07-02 15:26:00 +02:00
drm_context.c
drm_crtc_helper_internal.h
drm_crtc_helper.c drm : Insert blank lines after declarations. 2020-07-02 15:26:00 +02:00
drm_crtc_internal.h
drm_crtc.c drm : Insert blank lines after declarations. 2020-07-02 15:26:00 +02:00
drm_damage_helper.c
drm_debugfs_crc.c
drm_debugfs.c drm/debug: Expose connector VRR monitor range via debugfs 2020-06-25 15:47:14 -07:00
drm_dma.c
drm_dp_aux_dev.c
drm_dp_cec.c
drm_dp_dual_mode_helper.c
drm_dp_helper.c drm/dp: Include the AUX CH name in the debug messages 2020-07-09 21:20:33 +03:00
drm_dp_mst_topology_internal.h
drm_dp_mst_topology.c drm : Insert blank lines after declarations. 2020-07-02 15:26:00 +02:00
drm_drv.c
drm_dsc.c
drm_dumb_buffers.c
drm_edid_load.c
drm_edid.c drm/edid: Clean up some curly braces 2020-07-09 21:46:51 +03:00
drm_encoder_slave.c drm: encoder_slave: use new I2C API 2020-06-19 09:20:21 +02:00
drm_encoder.c
drm_fb_cma_helper.c
drm_fb_helper.c drm: fb-helper: Convert logging to drm_* functions. 2020-07-10 20:21:45 +02:00
drm_file.c drm : Insert blank lines after declarations. 2020-07-02 15:26:00 +02:00
drm_flip_work.c
drm_format_helper.c drm/format-helper: Add drm_fb_swab() 2020-05-26 13:33:08 +02:00
drm_fourcc.c drm: drm_fourcc: add NV15, Q410, Q401 YUV formats 2020-06-19 13:33:40 +01:00
drm_framebuffer.c drm : Insert blank lines after declarations. 2020-07-02 15:26:00 +02:00
drm_gem_cma_helper.c drm/cma-helper: Rework DRM_GEM_CMA_VMAP_DRIVER_OPS macro 2020-06-10 09:01:41 +02:00
drm_gem_framebuffer_helper.c drm: remove _unlocked suffix in drm_gem_object_put_unlocked 2020-05-19 22:31:31 +01:00
drm_gem_shmem_helper.c drm/shmem-helper: Only dma-buf imports are private obj 2020-06-16 19:11:51 +02:00
drm_gem_ttm_helper.c drm: remove _unlocked suffix in drm_gem_object_put_unlocked 2020-05-19 22:31:31 +01:00
drm_gem_vram_helper.c drm/vram-helper: don't use ttm bo->offset v4 2020-06-25 11:59:28 +02:00
drm_gem.c drm: Remove struct drm_driver.gem_print_info 2020-06-10 09:06:30 +02:00
drm_hashtab.c
drm_hdcp.c
drm_internal.h drm/vblank: Add vblank works 2020-07-16 18:16:31 -04:00
drm_ioc32.c drm : Insert blank lines after declarations. 2020-07-02 15:26:00 +02:00
drm_ioctl.c drm-misc-next for v5.9: 2020-06-24 15:45:51 +10:00
drm_irq.c drm: use drm_dev_has_vblank more 2020-05-29 12:58:11 +02:00
drm_kms_helper_common.c
drm_lease.c drm : Insert blank lines after declarations. 2020-07-02 15:26:00 +02:00
drm_legacy_misc.c
drm_legacy.h
drm_lock.c drm : Insert blank lines after declarations. 2020-07-02 15:26:00 +02:00
drm_managed.c drm: Include internal header for managed function declarations 2020-05-18 16:27:54 +01:00
drm_memory.c
drm_mipi_dbi.c drm/mipi-dbi: Remove ->enabled 2020-06-24 09:17:34 +02:00
drm_mipi_dsi.c drm: mipi-dsi: Convert logging to drm_* functions. 2020-07-10 20:21:45 +02:00
drm_mm.c drm/mm: cleanup and improve next_hole_*_addr() 2020-06-23 15:46:40 +02:00
drm_mode_config.c drm : Insert blank lines after declarations. 2020-07-02 15:26:00 +02:00
drm_mode_object.c
drm_modes.c drm: Flatten drm_mode_vrefresh() 2020-05-27 14:31:42 +03:00
drm_modeset_helper.c
drm_modeset_lock.c
drm_of.c drm/of: Make drm_of_find_panel_or_bridge() to check graph's presence 2020-07-01 10:49:25 +02:00
drm_panel_orientation_quirks.c
drm_panel.c
drm_pci.c drm : Insert blank lines after declarations. 2020-07-02 15:26:00 +02:00
drm_plane_helper.c
drm_plane.c drm : Insert blank lines after declarations. 2020-07-02 15:26:00 +02:00
drm_prime.c drm : Insert blank lines after declarations. 2020-07-02 15:26:00 +02:00
drm_print.c
drm_probe_helper.c drm: Introduce epoch counter to drm_connector 2020-06-30 13:31:27 +02:00
drm_property.c
drm_rect.c
drm_scatter.c gpu/drm: remove the powerpc hack in drm_legacy_sg_alloc 2020-06-02 10:59:11 -07:00
drm_scdc_helper.c
drm_self_refresh_helper.c
drm_simple_kms_helper.c
drm_syncobj.c drm : Insert blank lines after declarations. 2020-07-02 15:26:00 +02:00
drm_sysfs.c drm/connector: notify userspace on hotplug after register complete 2020-06-03 10:24:23 +02:00
drm_trace_points.c
drm_trace.h
drm_vblank_work.c drm/vblank: Add vblank works 2020-07-16 18:16:31 -04:00
drm_vblank.c drm/vblank: Add vblank works 2020-07-16 18:16:31 -04:00
drm_vm.c drm-misc-next for v5.9: 2020-06-24 15:45:51 +10:00
drm_vma_manager.c
drm_writeback.c drm/writeback: don't set fence->ops to default 2020-05-20 20:03:45 +02:00
Kconfig drm pull for 5.8-rc1 2020-06-02 15:04:15 -07:00
Makefile drm/vblank: Add vblank works 2020-07-16 18:16:31 -04:00