]> git.proxmox.com Git - mirror_ubuntu-eoan-kernel.git/commit
[media] s5p-mfc: Use preallocated block allocator always for MFC v6+
authorMarek Szyprowski <m.szyprowski@samsung.com>
Mon, 13 Feb 2017 10:58:14 +0000 (08:58 -0200)
committerMauro Carvalho Chehab <mchehab@s-opensource.com>
Wed, 5 Apr 2017 19:34:47 +0000 (16:34 -0300)
commit60641e22599a61b8f0356aa8c3755ea26f17a62b
tree24a0c78aee161651797092f176807d97a9f1f195
parent8e409f1d06686882c4c48ff04babce0469afe1b6
[media] s5p-mfc: Use preallocated block allocator always for MFC v6+

It turned out that all versions of MFC v6+ hardware doesn't have a strict
requirement for ALL buffers to be allocated on higher addresses than the
firmware base like it was documented for MFC v5. This requirement is true
only for the device and per-context buffers. All video data buffers can be
allocated anywhere for all MFC v6+ versions. Basing on this fact, the
special DMA configuration based on two reserved memory regions is not
really needed for MFC v6+ devices, because the memory requirements for the
firmware, device and per-context buffers can be fulfilled by the simple
probe-time pre-allocated block allocator introduced in previous patch.

This patch enables support for such pre-allocated block based allocator
always for MFC v6+ devices. Due to the limitations of the memory management
subsystem the largest supported size of the pre-allocated buffer when no
CMA (Contiguous Memory Allocator) is enabled is 4 MiB.

This patch also removes the requirement to provide two reserved memory
regions for MFC v6+ devices in device tree. Now the driver is fully
functional without them.

Signed-off-by: Marek Szyprowski <m.szyprowski@samsung.com>
Reviewed-by: Javier Martinez Canillas <javier@osg.samsung.com>
Tested-by: Javier Martinez Canillas <javier@osg.samsung.com>
Acked-by: Andrzej Hajda <a.hajda@samsung.com>
Tested-by: Smitha T Murthy <smitha.t@samsung.com>
Signed-off-by: Sylwester Nawrocki <s.nawrocki@samsung.com>
Signed-off-by: Mauro Carvalho Chehab <mchehab@s-opensource.com>
Documentation/devicetree/bindings/media/s5p-mfc.txt
drivers/media/platform/s5p-mfc/s5p_mfc.c