[PATCH 2/2] drm/mediatek: Use struct dma_buf_map in GEM vmap ops

2020-11-09 Thread Thomas Zimmermann
Fixes a build failure with mediatek. This change was supposed to be part of commit 49a3f51dfeee ("drm/gem: Use struct dma_buf_map in GEM vmap ops and convert GEM backends"), but mediatek was forgotten. Signed-off-by: Thomas Zimmermann Fixes: 49a3f51dfeee ("drm/gem: Use struct dma

Re: [PATCH v5 09/10] dma-buf-map: Add memcpy and pointer-increment interfaces

2020-11-05 Thread Thomas Zimmermann
Hi Am 05.11.20 um 11:07 schrieb Linus Walleij: > Overall I like this, just an inline question: > > On Tue, Oct 20, 2020 at 2:20 PM Thomas Zimmermann wrote: > >> To do framebuffer updates, one needs memcpy from system memory and a >> pointer-increment funct

[PATCH v7 10/10] drm/fb_helper: Support framebuffers in I/O memory

2020-11-03 Thread Thomas Zimmermann
(fbdev testcase) v5: * implement fb_read/fb_write internally (Daniel, Sam) v4: * move dma_buf_map changes into separate patch (Daniel) * TODO list: comment on fbdev updates (Daniel) Signed-off-by: Thomas Zimmermann Reviewed-by: Daniel Vetter Reviewed-by: Sam Ravnborg

[PATCH v7 06/10] drm/gem: Use struct dma_buf_map in GEM vmap ops and convert GEM backends

2020-11-03 Thread Thomas Zimmermann
helpers to use struct dma_buf_map Signed-off-by: Thomas Zimmermann Acked-by: Christian König Tested-by: Sam Ravnborg --- Documentation/gpu/todo.rst | 18 drivers/gpu/drm/Kconfig | 2 + drivers/gpu/drm/amd/amdgpu/amdgpu_dma_buf.c | 36 --- drivers/gpu

[PATCH v7 03/10] drm/etnaviv: Remove empty etnaviv_gem_prime_vunmap()

2020-11-03 Thread Thomas Zimmermann
The function etnaviv_gem_prime_vunmap() is empty. Remove it before changing the interface to use struct drm_buf_map. Signed-off-by: Thomas Zimmermann Acked-by: Christian König Tested-by: Sam Ravnborg --- drivers/gpu/drm/etnaviv/etnaviv_drv.h | 1 - drivers/gpu/drm/etnaviv/etnaviv_gem.c

[PATCH v7 01/10] drm/vram-helper: Remove invariant parameters from internal kmap function

2020-11-03 Thread Thomas Zimmermann
The parameters map and is_iomem are always of the same value. Removed them to prepares the function for conversion to struct dma_buf_map. v4: * don't check for !kmap->virtual; will always be false Signed-off-by: Thomas Zimmermann Reviewed-by: Daniel Vetter Reviewed-by: Christian Kö

[PATCH v7 08/10] drm/gem: Store client buffer mappings as struct dma_buf_map

2020-11-03 Thread Thomas Zimmermann
and modified with dma_buf_map interfaces. v6: * don't call page_to_phys() on framebuffers in I/O memory; warn instead (Daniel) Signed-off-by: Thomas Zimmermann Reviewed-by: Daniel Vetter Tested-by: Sam Ravnborg --- drivers/gpu/drm/drm_client.c| 34

[PATCH v7 09/10] dma-buf-map: Add memcpy and pointer-increment interfaces

2020-11-03 Thread Thomas Zimmermann
To do framebuffer updates, one needs memcpy from system memory and a pointer-increment function. Add both interfaces with documentation. v5: * include to build on sparc64 (Sam) Signed-off-by: Thomas Zimmermann Reviewed-by: Sam Ravnborg Tested-by: Sam Ravnborg --- include/linux/dma

[PATCH v7 05/10] drm/ttm: Add vmap/vunmap to TTM and TTM GEM helpers

2020-11-03 Thread Thomas Zimmermann
) * ignore premapped memory areas correctly in ttm_bo_vunmap() * rebase onto latest TTM interfaces (Christian) * remove BUG() from ttm_bo_vmap() (Christian) v4: * drop ttm_kmap_obj_to_dma_buf() in favor of vmap helpers (Daniel, Christian) Signed-off-by: Thomas Zimmermann

[PATCH v7 00/10] Support GEM object mappings from I/O memory

2020-11-03 Thread Thomas Zimmermann
] https://gitlab.freedesktop.org/tzimmermann/igt-gpu-tools/-/merge_requests/1 Thomas Zimmermann (10): drm/vram-helper: Remove invariant parameters from internal kmap function drm/cma-helper: Remove empty drm_gem_cma_prime_vunmap() drm/etnaviv: Remove empty etnaviv_gem_prime_vunmap() drm

[PATCH v7 02/10] drm/cma-helper: Remove empty drm_gem_cma_prime_vunmap()

2020-11-03 Thread Thomas Zimmermann
The function drm_gem_cma_prime_vunmap() is empty. Remove it before changing the interface to use struct drm_buf_map. Signed-off-by: Thomas Zimmermann Reviewed-by: Christian König Tested-by: Sam Ravnborg --- drivers/gpu/drm/drm_gem_cma_helper.c | 17 - drivers/gpu/drm/vc4

[PATCH v7 04/10] drm/exynos: Remove empty exynos_drm_gem_prime_{vmap,vunmap}()

2020-11-03 Thread Thomas Zimmermann
The functions exynos_drm_gem_prime_{vmap,vunmap}() are empty. Remove them before changing the interface to use struct drm_buf_map. As a side effect of removing drm_gem_prime_vmap(), the error code changes from ENOMEM to EOPNOTSUPP. Signed-off-by: Thomas Zimmermann Acked-by: Christian König

[PATCH v7 07/10] drm/gem: Update internal GEM vmap/vunmap interfaces to use struct dma_buf_map

2020-11-03 Thread Thomas Zimmermann
GEM's vmap and vunmap interfaces now wrap memory pointers in struct dma_buf_map. Signed-off-by: Thomas Zimmermann Reviewed-by: Daniel Vetter Tested-by: Sam Ravnborg --- drivers/gpu/drm/drm_client.c | 18 +++--- drivers/gpu/drm/drm_gem.c | 26

[PATCH v6 04/10] drm/exynos: Remove empty exynos_drm_gem_prime_{vmap,vunmap}()

2020-10-28 Thread Thomas Zimmermann
The functions exynos_drm_gem_prime_{vmap,vunmap}() are empty. Remove them before changing the interface to use struct drm_buf_map. As a side effect of removing drm_gem_prime_vmap(), the error code changes from ENOMEM to EOPNOTSUPP. Signed-off-by: Thomas Zimmermann Acked-by: Christian König

[PATCH v6 02/10] drm/cma-helper: Remove empty drm_gem_cma_prime_vunmap()

2020-10-28 Thread Thomas Zimmermann
The function drm_gem_cma_prime_vunmap() is empty. Remove it before changing the interface to use struct drm_buf_map. Signed-off-by: Thomas Zimmermann Reviewed-by: Christian König Tested-by: Sam Ravnborg --- drivers/gpu/drm/drm_gem_cma_helper.c | 17 - drivers/gpu/drm/vc4

[PATCH v6 03/10] drm/etnaviv: Remove empty etnaviv_gem_prime_vunmap()

2020-10-28 Thread Thomas Zimmermann
The function etnaviv_gem_prime_vunmap() is empty. Remove it before changing the interface to use struct drm_buf_map. Signed-off-by: Thomas Zimmermann Acked-by: Christian König Tested-by: Sam Ravnborg --- drivers/gpu/drm/etnaviv/etnaviv_drv.h | 1 - drivers/gpu/drm/etnaviv/etnaviv_gem.c

[PATCH v6 05/10] drm/ttm: Add vmap/vunmap to TTM and TTM GEM helpers

2020-10-28 Thread Thomas Zimmermann
) * ignore premapped memory areas correctly in ttm_bo_vunmap() * rebase onto latest TTM interfaces (Christian) * remove BUG() from ttm_bo_vmap() (Christian) v4: * drop ttm_kmap_obj_to_dma_buf() in favor of vmap helpers (Daniel, Christian) Signed-off-by: Thomas Zimmermann

[PATCH v6 08/10] drm/gem: Store client buffer mappings as struct dma_buf_map

2020-10-28 Thread Thomas Zimmermann
and modified with dma_buf_map interfaces. v6: * don't call page_to_phys() on framebuffers in I/O memory; warn instead (Daniel) Signed-off-by: Thomas Zimmermann Reviewed-by: Daniel Vetter Tested-by: Sam Ravnborg --- drivers/gpu/drm/drm_client.c| 34

[PATCH v6 10/10] drm/fb_helper: Support framebuffers in I/O memory

2020-10-28 Thread Thomas Zimmermann
into separate patch (Daniel) * TODO list: comment on fbdev updates (Daniel) Signed-off-by: Thomas Zimmermann Reviewed-by: Daniel Vetter Reviewed-by: Sam Ravnborg Tested-by: Sam Ravnborg --- Documentation/gpu/todo.rst| 19 ++- drivers/gpu/drm/bochs/bochs_kms.c | 1 - drivers/gpu

[PATCH v6 00/10] Support GEM object mappings from I/O memory

2020-10-28 Thread Thomas Zimmermann
patchset on top of struct dma_buf_map v2: * RFC patchset Thomas Zimmermann (10): drm/vram-helper: Remove invariant parameters from internal kmap function drm/cma-helper: Remove empty drm_gem_cma_prime_vunmap() drm/etnaviv: Remove empty etnaviv_gem_prime_vunmap() drm/exynos: Remove

[PATCH v6 01/10] drm/vram-helper: Remove invariant parameters from internal kmap function

2020-10-28 Thread Thomas Zimmermann
The parameters map and is_iomem are always of the same value. Removed them to prepares the function for conversion to struct dma_buf_map. v4: * don't check for !kmap->virtual; will always be false Signed-off-by: Thomas Zimmermann Reviewed-by: Daniel Vetter Reviewed-by: Christian Kö

[PATCH v6 09/10] dma-buf-map: Add memcpy and pointer-increment interfaces

2020-10-28 Thread Thomas Zimmermann
To do framebuffer updates, one needs memcpy from system memory and a pointer-increment function. Add both interfaces with documentation. v5: * include to build on sparc64 (Sam) Signed-off-by: Thomas Zimmermann Reviewed-by: Sam Ravnborg Tested-by: Sam Ravnborg --- include/linux/dma

[PATCH v6 07/10] drm/gem: Update internal GEM vmap/vunmap interfaces to use struct dma_buf_map

2020-10-28 Thread Thomas Zimmermann
GEM's vmap and vunmap interfaces now wrap memory pointers in struct dma_buf_map. Signed-off-by: Thomas Zimmermann Reviewed-by: Daniel Vetter Tested-by: Sam Ravnborg --- drivers/gpu/drm/drm_client.c | 18 +++--- drivers/gpu/drm/drm_gem.c | 26

[PATCH v6 06/10] drm/gem: Use struct dma_buf_map in GEM vmap ops and convert GEM backends

2020-10-28 Thread Thomas Zimmermann
, Christian) * fix a trailing { in drm_gem_vmap() * remove several empty functions instead of converting them (Daniel) * comment uses of raw pointers with a TODO (Daniel) * TODO list: convert more helpers to use struct dma_buf_map Signed-off-by: Thomas Zimmermann Acked

Re: [PATCH v5 10/10] drm/fb_helper: Support framebuffers in I/O memory

2020-10-26 Thread Thomas Zimmermann
Hi Am 24.10.20 um 22:38 schrieb Sam Ravnborg: > Hi Thomas. > > On Tue, Oct 20, 2020 at 02:20:46PM +0200, Thomas Zimmermann wrote: >> At least sparc64 requires I/O-specific access to framebuffers. This >> patch updates the fbdev console accordingly. >> >&g

Re: [PATCH v5 08/10] drm/gem: Store client buffer mappings as struct dma_buf_map

2020-10-22 Thread Thomas Zimmermann
Hi On 22.10.20 10:49, Daniel Vetter wrote: > On Tue, Oct 20, 2020 at 02:20:44PM +0200, Thomas Zimmermann wrote: >> Kernel DRM clients now store their framebuffer address in an instance >> of struct dma_buf_map. Depending on the buffer's location, the address >> refers to

Re: [PATCH v5 10/10] drm/fb_helper: Support framebuffers in I/O memory

2020-10-22 Thread Thomas Zimmermann
Hi On 22.10.20 10:05, Daniel Vetter wrote: > On Tue, Oct 20, 2020 at 02:20:46PM +0200, Thomas Zimmermann wrote: >> At least sparc64 requires I/O-specific access to framebuffers. This >> patch updates the fbdev console accordingly. >> >> For drivers with direct acces

[PATCH v5 05/10] drm/ttm: Add vmap/vunmap to TTM and TTM GEM helpers

2020-10-20 Thread Thomas Zimmermann
) * ignore premapped memory areas correctly in ttm_bo_vunmap() * rebase onto latest TTM interfaces (Christian) * remove BUG() from ttm_bo_vmap() (Christian) v4: * drop ttm_kmap_obj_to_dma_buf() in favor of vmap helpers (Daniel, Christian) Signed-off-by: Thomas Zimmermann

[PATCH v5 06/10] drm/gem: Use struct dma_buf_map in GEM vmap ops and convert GEM backends

2020-10-20 Thread Thomas Zimmermann
, Christian) * fix a trailing { in drm_gem_vmap() * remove several empty functions instead of converting them (Daniel) * comment uses of raw pointers with a TODO (Daniel) * TODO list: convert more helpers to use struct dma_buf_map Signed-off-by: Thomas Zimmermann Acked

[PATCH v5 09/10] dma-buf-map: Add memcpy and pointer-increment interfaces

2020-10-20 Thread Thomas Zimmermann
To do framebuffer updates, one needs memcpy from system memory and a pointer-increment function. Add both interfaces with documentation. v5: * include to build on sparc64 (Sam) Signed-off-by: Thomas Zimmermann Reviewed-by: Sam Ravnborg Tested-by: Sam Ravnborg --- include/linux/dma

[PATCH v5 02/10] drm/cma-helper: Remove empty drm_gem_cma_prime_vunmap()

2020-10-20 Thread Thomas Zimmermann
The function drm_gem_cma_prime_vunmap() is empty. Remove it before changing the interface to use struct drm_buf_map. Signed-off-by: Thomas Zimmermann Reviewed-by: Christian König Tested-by: Sam Ravnborg --- drivers/gpu/drm/drm_gem_cma_helper.c | 17 - drivers/gpu/drm/vc4

[PATCH v5 07/10] drm/gem: Update internal GEM vmap/vunmap interfaces to use struct dma_buf_map

2020-10-20 Thread Thomas Zimmermann
GEM's vmap and vunmap interfaces now wrap memory pointers in struct dma_buf_map. Signed-off-by: Thomas Zimmermann Reviewed-by: Daniel Vetter Tested-by: Sam Ravnborg --- drivers/gpu/drm/drm_client.c | 18 +++--- drivers/gpu/drm/drm_gem.c | 26

[PATCH v5 04/10] drm/exynos: Remove empty exynos_drm_gem_prime_{vmap,vunmap}()

2020-10-20 Thread Thomas Zimmermann
The functions exynos_drm_gem_prime_{vmap,vunmap}() are empty. Remove them before changing the interface to use struct drm_buf_map. As a side effect of removing drm_gem_prime_vmap(), the error code changes from ENOMEM to EOPNOTSUPP. Signed-off-by: Thomas Zimmermann Acked-by: Christian König

[PATCH v5 01/10] drm/vram-helper: Remove invariant parameters from internal kmap function

2020-10-20 Thread Thomas Zimmermann
The parameters map and is_iomem are always of the same value. Removed them to prepares the function for conversion to struct dma_buf_map. v4: * don't check for !kmap->virtual; will always be false Signed-off-by: Thomas Zimmermann Reviewed-by: Daniel Vetter Reviewed-by: Christian Kö

[PATCH v5 10/10] drm/fb_helper: Support framebuffers in I/O memory

2020-10-20 Thread Thomas Zimmermann
into separate patch (Daniel) * TODO list: comment on fbdev updates (Daniel) Signed-off-by: Thomas Zimmermann Tested-by: Sam Ravnborg --- Documentation/gpu/todo.rst| 19 ++- drivers/gpu/drm/bochs/bochs_kms.c | 1 - drivers/gpu/drm/drm_fb_helper.c | 227

[PATCH v5 03/10] drm/etnaviv: Remove empty etnaviv_gem_prime_vunmap()

2020-10-20 Thread Thomas Zimmermann
The function etnaviv_gem_prime_vunmap() is empty. Remove it before changing the interface to use struct drm_buf_map. Signed-off-by: Thomas Zimmermann Acked-by: Christian König Tested-by: Sam Ravnborg --- drivers/gpu/drm/etnaviv/etnaviv_drv.h | 1 - drivers/gpu/drm/etnaviv/etnaviv_gem.c

[PATCH v5 00/10] Support GEM object mappings from I/O memory

2020-10-20 Thread Thomas Zimmermann
GEM helpers and convert drivers over (Christian, Daniel) * remove several empty functions * more TODOs and documentation (Daniel) v3: * recreate the whole patchset on top of struct dma_buf_map v2: * RFC patchset Thomas Zimmermann (10): drm/vram-helper

[PATCH v5 08/10] drm/gem: Store client buffer mappings as struct dma_buf_map

2020-10-20 Thread Thomas Zimmermann
and modified with dma_buf_map interfaces. Signed-off-by: Thomas Zimmermann Reviewed-by: Daniel Vetter Tested-by: Sam Ravnborg --- drivers/gpu/drm/drm_client.c| 34 +++-- drivers/gpu/drm/drm_fb_helper.c | 23 +- include/drm/drm_client.h| 7

Re: [PATCH v4 05/10] drm/ttm: Add vmap/vunmap to TTM and TTM GEM helpers

2020-10-19 Thread Thomas Zimmermann
Hi Christian On 15.10.20 16:08, Christian König wrote: > Am 15.10.20 um 14:38 schrieb Thomas Zimmermann: >> The new functions ttm_bo_{vmap,vunmap}() map and unmap a TTM BO in kernel >> address space. The mapping's address is returned as struct dma_buf_map. >> Each function is

Re: [PATCH v4 10/10] drm/fb_helper: Support framebuffers in I/O memory

2020-10-16 Thread Thomas Zimmermann
Hi On Fri, 16 Oct 2020 14:03:47 +0200 Sam Ravnborg wrote: > Hi Thomas. > > On Thu, Oct 15, 2020 at 02:38:06PM +0200, Thomas Zimmermann wrote: > > At least sparc64 requires I/O-specific access to framebuffers. This > > patch updates the fbdev console accordingly.

Re: [PATCH v4 10/10] drm/fb_helper: Support framebuffers in I/O memory

2020-10-16 Thread Thomas Zimmermann
Hi On Fri, 16 Oct 2020 12:58:54 +0200 Sam Ravnborg wrote: > Hi Thomas. > > On Thu, Oct 15, 2020 at 02:38:06PM +0200, Thomas Zimmermann wrote: > > At least sparc64 requires I/O-specific access to framebuffers. This > > patch updates the fbdev console accordingly.

Re: [PATCH v4 09/10] dma-buf-map: Add memcpy and pointer-increment interfaces

2020-10-16 Thread Thomas Zimmermann
Hi Sam On Fri, 16 Oct 2020 12:08:54 +0200 Sam Ravnborg wrote: > Hi Thomas. > > On Thu, Oct 15, 2020 at 02:38:05PM +0200, Thomas Zimmermann wrote: > > To do framebuffer updates, one needs memcpy from system memory and a > > pointer-increment function. Add both interfac

Re: [PATCH v4 05/10] drm/ttm: Add vmap/vunmap to TTM and TTM GEM helpers

2020-10-15 Thread Thomas Zimmermann
Hi On Thu, 15 Oct 2020 16:08:13 +0200 Christian König wrote: > Am 15.10.20 um 14:38 schrieb Thomas Zimmermann: > > The new functions ttm_bo_{vmap,vunmap}() map and unmap a TTM BO in kernel > > address space. The mapping's address is returned as struct dma_buf_map. &g

Re: [PATCH v4 05/10] drm/ttm: Add vmap/vunmap to TTM and TTM GEM helpers

2020-10-15 Thread Thomas Zimmermann
Hi On Thu, 15 Oct 2020 18:49:09 +0200 Daniel Vetter wrote: > On Thu, Oct 15, 2020 at 04:08:13PM +0200, Christian König wrote: > > Am 15.10.20 um 14:38 schrieb Thomas Zimmermann: > > > The new functions ttm_bo_{vmap,vunmap}() map and unmap a TTM BO in > > > kernel a

[PATCH v4 08/10] drm/gem: Store client buffer mappings as struct dma_buf_map

2020-10-15 Thread Thomas Zimmermann
and modified with dma_buf_map interfaces. Signed-off-by: Thomas Zimmermann Reviewed-by: Daniel Vetter --- drivers/gpu/drm/drm_client.c| 34 +++-- drivers/gpu/drm/drm_fb_helper.c | 23 +- include/drm/drm_client.h| 7 --- 3 files changed

[PATCH v4 09/10] dma-buf-map: Add memcpy and pointer-increment interfaces

2020-10-15 Thread Thomas Zimmermann
To do framebuffer updates, one needs memcpy from system memory and a pointer-increment function. Add both interfaces with documentation. Signed-off-by: Thomas Zimmermann --- include/linux/dma-buf-map.h | 72 +++-- 1 file changed, 62 insertions(+), 10 deletions

[PATCH v4 03/10] drm/etnaviv: Remove empty etnaviv_gem_prime_vunmap()

2020-10-15 Thread Thomas Zimmermann
The function etnaviv_gem_prime_vunmap() is empty. Remove it before changing the interface to use struct drm_buf_map. Signed-off-by: Thomas Zimmermann --- drivers/gpu/drm/etnaviv/etnaviv_drv.h | 1 - drivers/gpu/drm/etnaviv/etnaviv_gem.c | 1 - drivers/gpu/drm/etnaviv

[PATCH v4 07/10] drm/gem: Update internal GEM vmap/vunmap interfaces to use struct dma_buf_map

2020-10-15 Thread Thomas Zimmermann
GEM's vmap and vunmap interfaces now wrap memory pointers in struct dma_buf_map. Signed-off-by: Thomas Zimmermann Reviewed-by: Daniel Vetter --- drivers/gpu/drm/drm_client.c | 18 +++--- drivers/gpu/drm/drm_gem.c | 26 +- drivers/gpu/drm

[PATCH v4 06/10] drm/gem: Use struct dma_buf_map in GEM vmap ops and convert GEM backends

2020-10-15 Thread Thomas Zimmermann
{ in drm_gem_vmap() * remove several empty functions instead of converting them (Daniel) * comment uses of raw pointers with a TODO (Daniel) * TODO list: convert more helpers to use struct dma_buf_map Signed-off-by: Thomas Zimmermann --- Documentation/gpu/todo.rst | 18

[PATCH v4 10/10] drm/fb_helper: Support framebuffers in I/O memory

2020-10-15 Thread Thomas Zimmermann
of struct dma_buf_map, this is not required any longer. The patch removes the rsp code from both, bochs and fbdev. v4: * move dma_buf_map changes into separate patch (Daniel) * TODO list: comment on fbdev updates (Daniel) Signed-off-by: Thomas Zimmermann --- Documentation/gpu

[PATCH v4 02/10] drm/cma-helper: Remove empty drm_gem_cma_prime_vunmap()

2020-10-15 Thread Thomas Zimmermann
The function drm_gem_cma_prime_vunmap() is empty. Remove it before changing the interface to use struct drm_buf_map. Signed-off-by: Thomas Zimmermann --- drivers/gpu/drm/drm_gem_cma_helper.c | 17 - drivers/gpu/drm/vc4/vc4_bo.c | 1 - include/drm/drm_gem_cma_helper.h

[PATCH v4 05/10] drm/ttm: Add vmap/vunmap to TTM and TTM GEM helpers

2020-10-15 Thread Thomas Zimmermann
, Christian) Signed-off-by: Thomas Zimmermann --- drivers/gpu/drm/drm_gem_ttm_helper.c | 38 +++ drivers/gpu/drm/ttm/ttm_bo_util.c| 72 include/drm/drm_gem_ttm_helper.h | 6 +++ include/drm/ttm/ttm_bo_api.h | 28

[PATCH v4 00/10] Support GEM object mappings from I/O memory

2020-10-15 Thread Thomas Zimmermann
on top of struct dma_buf_map v2: * RFC patchset Thomas Zimmermann (10): drm/vram-helper: Remove invariant parameters from internal kmap function drm/cma-helper: Remove empty drm_gem_cma_prime_vunmap() drm/etnaviv: Remove empty etnaviv_gem_prime_vunmap() drm/exynos: Remove

[PATCH v4 01/10] drm/vram-helper: Remove invariant parameters from internal kmap function

2020-10-15 Thread Thomas Zimmermann
The parameters map and is_iomem are always of the same value. Removed them to prepares the function for conversion to struct dma_buf_map. v4: * don't check for !kmap->virtual; will always be false Signed-off-by: Thomas Zimmermann Reviewed-by: Daniel Vetter --- drivers/gpu/

[PATCH v4 04/10] drm/exynos: Remove empty exynos_drm_gem_prime_{vmap,vunmap}()

2020-10-15 Thread Thomas Zimmermann
The functions exynos_drm_gem_prime_{vmap,vunmap}() are empty. Remove them before changing the interface to use struct drm_buf_map. As a side effect of removing drm_gem_prime_vmap(), the error code changes from ENOMEM to EOPNOTSUPP. Signed-off-by: Thomas Zimmermann --- drivers/gpu/drm/exynos

Re: [PATCH v3 6/7] drm/fb_helper: Support framebuffers in I/O memory

2020-10-08 Thread Thomas Zimmermann
Hi Am 02.10.20 um 20:44 schrieb Daniel Vetter: > On Fri, Oct 2, 2020 at 8:05 PM Daniel Vetter wrote: >> >> On Tue, Sep 29, 2020 at 05:14:36PM +0200, Thomas Zimmermann wrote: >>> At least sparc64 requires I/O-specific access to framebuffers. This >>> patch upda

Re: [PATCH v3 2/7] drm/ttm: Add ttm_kmap_obj_to_dma_buf_map() for type conversion

2020-10-08 Thread Thomas Zimmermann
Hi Am 07.10.20 um 16:30 schrieb Daniel Vetter: > On Wed, Oct 7, 2020 at 3:25 PM Christian König > wrote: >> >> Am 07.10.20 um 15:20 schrieb Thomas Zimmermann: >>> Hi >>> >>> Am 07.10.20 um 15:10 schrieb Daniel Vetter: >>>> On Wed, Oct 7,

Re: [PATCH v3 2/7] drm/ttm: Add ttm_kmap_obj_to_dma_buf_map() for type conversion

2020-10-07 Thread Thomas Zimmermann
Hi Am 07.10.20 um 15:10 schrieb Daniel Vetter: > On Wed, Oct 7, 2020 at 2:57 PM Thomas Zimmermann wrote: >> >> Hi >> >> Am 02.10.20 um 11:58 schrieb Daniel Vetter: >>> On Wed, Sep 30, 2020 at 02:51:46PM +0200, Daniel Vetter wrote: >>>> On Wed, Sep

Re: [PATCH v3 2/7] drm/ttm: Add ttm_kmap_obj_to_dma_buf_map() for type conversion

2020-10-07 Thread Thomas Zimmermann
20 at 10:34:31AM +0200, Christian König wrote: >>>>> Am 30.09.20 um 10:19 schrieb Thomas Zimmermann: >>>>>> Hi >>>>>> >>>>>> Am 30.09.20 um 10:05 schrieb Christian König: >>>>>>> Am 29.09.20 um 19:49 schrieb

Re: [PATCH v3 2/7] drm/ttm: Add ttm_kmap_obj_to_dma_buf_map() for type conversion

2020-09-30 Thread Thomas Zimmermann
Hi Am 30.09.20 um 10:05 schrieb Christian König: > Am 29.09.20 um 19:49 schrieb Thomas Zimmermann: >> Hi Christian >> >> Am 29.09.20 um 17:35 schrieb Christian König: >>> Am 29.09.20 um 17:14 schrieb Thomas Zimmermann: >>>> The new helper ttm_kmap_obj_

Re: [PATCH v3 2/7] drm/ttm: Add ttm_kmap_obj_to_dma_buf_map() for type conversion

2020-09-29 Thread Thomas Zimmermann
Hi Christian Am 29.09.20 um 17:35 schrieb Christian König: > Am 29.09.20 um 17:14 schrieb Thomas Zimmermann: >> The new helper ttm_kmap_obj_to_dma_buf() extracts address and location >> from and instance of TTM's kmap_obj and initializes struct dma_buf_map >> with these va

[PATCH v3 0/7] Support GEM object mappings from I/O memory

2020-09-29 Thread Thomas Zimmermann
improvements v3: * recreate the whole patchset on top of struct dma_buf_map v2: * RFC patchset Thomas Zimmermann (7): drm/vram-helper: Remove invariant parameters from internal kmap function drm/ttm: Add ttm_kmap_obj_to_dma_buf_map() for type conversion drm/gem: Use

[PATCH v3 5/7] drm/gem: Store client buffer mappings as struct dma_buf_map

2020-09-29 Thread Thomas Zimmermann
and modified with dma_buf_map interfaces. Signed-off-by: Thomas Zimmermann --- drivers/gpu/drm/drm_client.c| 34 +++-- drivers/gpu/drm/drm_fb_helper.c | 23 +- include/drm/drm_client.h| 7 --- 3 files changed, 38 insertions(+), 26

[PATCH v3 4/7] drm/gem: Update internal GEM vmap/vunmap interfaces to use struct dma_buf_map

2020-09-29 Thread Thomas Zimmermann
GEM's vmap and vunmap interfaces now wrap memory pointers in struct dma_buf_map. Signed-off-by: Thomas Zimmermann --- drivers/gpu/drm/drm_client.c | 18 +++--- drivers/gpu/drm/drm_gem.c | 28 ++-- drivers/gpu/drm/drm_internal.h | 5 +++-- drivers/gpu

[PATCH v3 3/7] drm/gem: Use struct dma_buf_map in GEM vmap ops and convert GEM backends

2020-09-29 Thread Thomas Zimmermann
address is in system or I/O memory. Signed-off-by: Thomas Zimmermann --- drivers/gpu/drm/amd/amdgpu/amdgpu_dma_buf.c | 14 ++-- drivers/gpu/drm/amd/amdgpu/amdgpu_dma_buf.h | 4 +- drivers/gpu/drm/ast/ast_cursor.c| 29 +++ drivers/gpu/drm/ast/ast_drv.h | 7

[PATCH v3 7/7] drm/todo: Update entries around struct dma_buf_map

2020-09-29 Thread Thomas Zimmermann
Instances of struct dma_buf_map should be useful throughout DRM's memory management code. Furthermore, several drivers can now use generic fbdev emulation. Signed-off-by: Thomas Zimmermann --- Documentation/gpu/todo.rst | 24 ++-- 1 file changed, 22 insertions(+), 2

[PATCH v3 1/7] drm/vram-helper: Remove invariant parameters from internal kmap function

2020-09-29 Thread Thomas Zimmermann
The parameters map and is_iomem are always of the same value. Removed them to prepares the function for conversion to struct dma_buf_map. Signed-off-by: Thomas Zimmermann --- drivers/gpu/drm/drm_gem_vram_helper.c | 17 ++--- 1 file changed, 6 insertions(+), 11 deletions(-) diff

[PATCH v3 6/7] drm/fb_helper: Support framebuffers in I/O memory

2020-09-29 Thread Thomas Zimmermann
of struct dma_buf_map, this is not required any longer. The patch removes the rsp code from both, bochs and fbdev. Signed-off-by: Thomas Zimmermann --- drivers/gpu/drm/bochs/bochs_kms.c | 1 - drivers/gpu/drm/drm_fb_helper.c | 217 -- include/drm/drm_mode_config.h

[PATCH v3 2/7] drm/ttm: Add ttm_kmap_obj_to_dma_buf_map() for type conversion

2020-09-29 Thread Thomas Zimmermann
The new helper ttm_kmap_obj_to_dma_buf() extracts address and location from and instance of TTM's kmap_obj and initializes struct dma_buf_map with these values. Helpful for TTM-based drivers. Signed-off-by: Thomas Zimmermann --- include/drm/ttm/ttm_bo_api.h | 24

Re: [PATCH v3 00/22] Convert all remaining drivers to GEM object functions

2020-09-25 Thread Thomas Zimmermann
hanks for the nice cleanup, > Christian. > > Am 23.09.20 um 12:21 schrieb Thomas Zimmermann: >> The GEM and PRIME related callbacks in struct drm_driver are >> deprecated in >> favor of GEM object functions in struct drm_gem_object_funcs. This >> patchset &g

[PATCH v3 22/22] drm: Remove obsolete GEM and PRIME callbacks from struct drm_driver

2020-09-23 Thread Thomas Zimmermann
is not set * drop all checks for obj->funcs * clean up TODO list and documentation v2: * update related TODO item (Sam) Signed-off-by: Thomas Zimmermann Acked-by: Daniel Vetter --- Documentation/gpu/drm-mm.rst | 4 +- Documentation/gpu/todo.rst |

[PATCH v3 20/22] drm/xen: Introduce GEM object functions

2020-09-23 Thread Thomas Zimmermann
() to static callback (Oleksandr) Signed-off-by: Thomas Zimmermann Acked-by: Oleksandr Andrushchenko --- drivers/gpu/drm/xen/xen_drm_front.c | 44 ++--- drivers/gpu/drm/xen/xen_drm_front.h | 2 ++ drivers/gpu/drm/xen/xen_drm_front_gem.c | 15 + 3

[PATCH v3 21/22] drm/xlnx: Initialize DRM driver instance with CMA helper macro

2020-09-23 Thread Thomas Zimmermann
implementations, so they are just kept empty now. v2: * initialize with DRM_GEM_CMA_DRIVER_OPS_WITH_DUMB_CREATE (Laurent) Signed-off-by: Thomas Zimmermann Reviewed-by: Laurent Pinchart Reviewed-by: Hyun Kwon --- drivers/gpu/drm/xlnx/zynqmp_dpsub.c | 14 +- 1 file changed, 1

[PATCH v3 10/22] drm/nouveau: Introduce GEM object functions

2020-09-23 Thread Thomas Zimmermann
GEM object functions deprecate several similar callback interfaces in struct drm_driver. This patch replaces the per-driver callbacks with per-instance callbacks in nouveau. Signed-off-by: Thomas Zimmermann Reviewed-by: Daniel Vetter --- drivers/gpu/drm/nouveau/nouveau_drm.c | 9

[PATCH v3 08/22] drm/mediatek: Introduce GEM object functions

2020-09-23 Thread Thomas Zimmermann
GEM object functions deprecate several similar callback interfaces in struct drm_driver. This patch replaces the per-driver callbacks with per-instance callbacks in mediatek. The only exception is gem_prime_mmap, which is non-trivial to convert. Signed-off-by: Thomas Zimmermann Reviewed

[PATCH v3 12/22] drm/pl111: Introduce GEM object functions

2020-09-23 Thread Thomas Zimmermann
drm_gem_cma_create_object_default_funcs() (Eric) Signed-off-by: Thomas Zimmermann Reviewed-by: Eric Anholt --- drivers/gpu/drm/pl111/pl111_drv.c | 5 + 1 file changed, 1 insertion(+), 4 deletions(-) diff --git a/drivers/gpu/drm/pl111/pl111_drv.c b/drivers/gpu/drm/pl111/pl111_drv.c index 46b0d1c4a16c..ecef8a2383d2 100644

[PATCH v3 14/22] drm/rockchip: Convert to drm_gem_object_funcs

2020-09-23 Thread Thomas Zimmermann
-by: Thomas Zimmermann Reviewed-by: Daniel Vetter --- drivers/gpu/drm/rockchip/rockchip_drm_drv.c | 5 - drivers/gpu/drm/rockchip/rockchip_drm_gem.c | 12 +++- 2 files changed, 11 insertions(+), 6 deletions(-) diff --git a/drivers/gpu/drm/rockchip/rockchip_drm_drv.c b/drivers/gpu/drm

[PATCH v3 19/22] drm/vkms: Introduce GEM object functions

2020-09-23 Thread Thomas Zimmermann
GEM object functions deprecate several similar callback interfaces in struct drm_driver. This patch replaces the per-driver callbacks with per-instance callbacks in vkms. Signed-off-by: Thomas Zimmermann Reviewed-by: Melissa Wen --- drivers/gpu/drm/vkms/vkms_drv.c | 8 drivers/gpu

[PATCH v3 17/22] drm/vgem: Introduce GEM object functions

2020-09-23 Thread Thomas Zimmermann
GEM object functions deprecate several similar callback interfaces in struct drm_driver. This patch replaces the per-driver callbacks with per-instance callbacks in vgem. The only exception is gem_prime_mmap, which is non-trivial to convert. Signed-off-by: Thomas Zimmermann Reviewed-by: Melissa

[PATCH v3 15/22] drm/tegra: Introduce GEM object functions

2020-09-23 Thread Thomas Zimmermann
GEM object functions deprecate several similar callback interfaces in struct drm_driver. This patch replaces the per-driver callbacks with per-instance callbacks in tegra. Signed-off-by: Thomas Zimmermann Acked-by: Thierry Reding --- drivers/gpu/drm/tegra/drm.c | 4 drivers/gpu/drm/tegra

[PATCH v3 18/22] drm/virtgpu: Set PRIME export function in struct drm_gem_object_funcs

2020-09-23 Thread Thomas Zimmermann
GEM object functions deprecate several similar callback interfaces in struct drm_driver. This patch replaces virtgpu's per-driver PRIME export function with a per-object function. Signed-off-by: Thomas Zimmermann Reviewed-by: Daniel Vetter --- drivers/gpu/drm/virtio/virtgpu_drv.c| 1

[PATCH v3 07/22] drm/imx/dcss: Initialize DRM driver instance with CMA helper macro

2020-09-23 Thread Thomas Zimmermann
to their default implementations, so they are just kept empty now. Signed-off-by: Thomas Zimmermann Reported-by: kernel test robot --- drivers/gpu/drm/imx/dcss/dcss-kms.c | 14 +- 1 file changed, 1 insertion(+), 13 deletions(-) diff --git a/drivers/gpu/drm/imx/dcss/dcss-kms.c b/drivers/gpu

[PATCH v3 16/22] drm/vc4: Introduce GEM object functions

2020-09-23 Thread Thomas Zimmermann
GEM object functions deprecate several similar callback interfaces in struct drm_driver. This patch replaces the per-driver callbacks with per-instance callbacks in vc4. The only exception is gem_prime_mmap, which is non-trivial to convert. Signed-off-by: Thomas Zimmermann Reviewed-by: Eric

[PATCH v3 09/22] drm/msm: Introduce GEM object funcs

2020-09-23 Thread Thomas Zimmermann
GEM object functions deprecate several similar callback interfaces in struct drm_driver. This patch replaces the per-driver callbacks with per-instance callbacks in msm. The only exception is gem_prime_mmap, which is non-trivial to convert. Signed-off-by: Thomas Zimmermann Reviewed-by: Daniel

[PATCH v3 03/22] drm/etnaviv: Introduce GEM object functions

2020-09-23 Thread Thomas Zimmermann
GEM object functions deprecate several similar callback interfaces in struct drm_driver. This patch replaces the per-driver callbacks with per-instance callbacks in etnaviv. The only exception is gem_prime_mmap, which is non-trivial to convert. Signed-off-by: Thomas Zimmermann Reviewed

[PATCH v3 13/22] drm/radeon: Introduce GEM object functions

2020-09-23 Thread Thomas Zimmermann
() (Christian) Signed-off-by: Thomas Zimmermann Reviewed-by: Christian König --- drivers/gpu/drm/radeon/radeon_drv.c | 23 + drivers/gpu/drm/radeon/radeon_gem.c | 31 + 2 files changed, 28 insertions(+), 26 deletions(-) diff --git a/drivers/gpu/drm

[PATCH v3 06/22] drm/i915: Introduce GEM object functions

2020-09-23 Thread Thomas Zimmermann
GEM object functions deprecate several similar callback interfaces in struct drm_driver. This patch replaces the per-driver callbacks with per-instance callbacks in i915. v2: * move object-function instance to i915_gem_object.c (Jani) Signed-off-by: Thomas Zimmermann Reviewed-by: Tvrtko

[PATCH v3 05/22] drm/gma500: Introduce GEM object functions

2020-09-23 Thread Thomas Zimmermann
GEM object functions deprecate several similar callback interfaces in struct drm_driver. This patch replaces the per-driver callbacks with per-instance callbacks in gma500. Signed-off-by: Thomas Zimmermann Reviewed-by: Daniel Vetter --- drivers/gpu/drm/gma500/framebuffer.c | 2 ++ drivers/gpu

[PATCH v3 04/22] drm/exynos: Introduce GEM object functions

2020-09-23 Thread Thomas Zimmermann
GEM object functions deprecate several similar callback interfaces in struct drm_driver. This patch replaces the per-driver callbacks with per-instance callbacks in exynos. The only exception is gem_prime_mmap, which is non-trivial to convert. Signed-off-by: Thomas Zimmermann Reviewed-by: Daniel

[PATCH v3 11/22] drm/omapdrm: Introduce GEM object functions

2020-09-23 Thread Thomas Zimmermann
GEM object functions deprecate several similar callback interfaces in struct drm_driver. This patch replaces the per-driver callbacks with per-instance callbacks in omapdrm. v2: * make omap_gem_free_object() static (Tomi) Signed-off-by: Thomas Zimmermann Reviewed-by: Laurent Pinchart

[PATCH v3 02/22] drm/armada: Introduce GEM object functions

2020-09-23 Thread Thomas Zimmermann
GEM object functions deprecate several similar callback interfaces in struct drm_driver. This patch replaces the per-driver callbacks with per-instance callbacks in armada. Signed-off-by: Thomas Zimmermann Acked-by: Russell King --- drivers/gpu/drm/armada/armada_drv.c | 3 --- drivers/gpu/drm

[PATCH v3 01/22] drm/amdgpu: Introduce GEM object functions

2020-09-23 Thread Thomas Zimmermann
(Christian) v2: * move object-function instance to amdgpu_gem.c (Christian) * set callbacks in amdgpu_gem_object_create() (Christian) Signed-off-by: Thomas Zimmermann Reviewed-by: Christian König --- drivers/gpu/drm/amd/amdgpu/amdgpu_drv.c | 6 -- drivers/gpu/drm/amd/amdgpu

[PATCH v3 00/22] Convert all remaining drivers to GEM object functions

2020-09-23 Thread Thomas Zimmermann
ist and documentation v2: * moved code in amdgpu and radeon * made several functions static in various drivers * updated TODO-list item * fix virtgpu Thomas Zimmermann (22): drm/amdgpu: Introduce GEM object functions drm/armada: Introduce GEM object functions drm/etna

Re: [PATCH v2 01/21] drm/amdgpu: Introduce GEM object functions

2020-09-17 Thread Thomas Zimmermann
Hi Am 15.09.20 um 17:05 schrieb Christian König: > Am 15.09.20 um 16:59 schrieb Thomas Zimmermann: >> GEM object functions deprecate several similar callback interfaces in >> struct drm_driver. This patch replaces the per-driver callbacks with >> per-instance callback

Re: [PATCH v2 00/21] Convert all remaining drivers to GEM object functions

2020-09-17 Thread Thomas Zimmermann
s, preferable, I'd merge it all through drm-misc. Best regards Thomas > > Christian. > > Am 15.09.20 um 16:59 schrieb Thomas Zimmermann: >> The GEM and PRIME related callbacks in struct drm_driver are >> deprecated in >> favor of GEM object functions in struct dr

Re: [PATCH v2 21/21] drm: Remove obsolete GEM and PRIME callbacks from struct drm_driver

2020-09-16 Thread Thomas Zimmermann
Am 15.09.20 um 16:59 schrieb Thomas Zimmermann: > Several GEM and PRIME callbacks have been deprecated in favor of > per-instance GEM object functions. Remove the callbacks as they are > now unused. The only exception is .gem_prime_mmap, which is still > in use by several driver

Re: [PATCH v2 04/21] drm/exynos: Introduce GEM object functions

2020-09-16 Thread Thomas Zimmermann
Hi Am 16.09.20 um 12:03 schrieb Daniel Vetter: > On Tue, Sep 15, 2020 at 04:59:41PM +0200, Thomas Zimmermann wrote: >> GEM object functions deprecate several similar callback interfaces in >> struct drm_driver. This patch replaces the per-driver callbacks with >> per-instanc

[PATCH v2 20/21] drm/xlnx: Initialize DRM driver instance with CMA helper macro

2020-09-15 Thread Thomas Zimmermann
implementations, so they are just kept empty now. v2: * initialize with DRM_GEM_CMA_DRIVER_OPS_WITH_DUMB_CREATE (Laurent) Signed-off-by: Thomas Zimmermann --- drivers/gpu/drm/xlnx/zynqmp_dpsub.c | 14 +- 1 file changed, 1 insertion(+), 13 deletions(-) diff --git a/drivers

[PATCH v2 10/21] drm/omapdrm: Introduce GEM object functions

2020-09-15 Thread Thomas Zimmermann
GEM object functions deprecate several similar callback interfaces in struct drm_driver. This patch replaces the per-driver callbacks with per-instance callbacks in omapdrm. v2: * make omap_gem_free_object() static (Tomi) Signed-off-by: Thomas Zimmermann Reviewed-by: Laurent Pinchart

[PATCH v2 19/21] drm/xen: Introduce GEM object functions

2020-09-15 Thread Thomas Zimmermann
() to static callback (Oleksandr) Signed-off-by: Thomas Zimmermann Acked-by: Oleksandr Andrushchenko --- drivers/gpu/drm/xen/xen_drm_front.c | 44 ++--- drivers/gpu/drm/xen/xen_drm_front.h | 2 ++ drivers/gpu/drm/xen/xen_drm_front_gem.c | 15 + 3

<    1   2   3   4   >