sections which are accessing those
resources with drm_dev_enter() and drm_dev_exit().
Signed-off-by: Danilo Krummrich
---
drivers/gpu/drm/fsl-dcu/fsl_dcu_drm_plane.c | 14 --
1 file changed, 12 insertions(+), 2 deletions(-)
diff --git a/drivers/gpu/drm/fsl-dcu/fsl_dcu_drm_plane.c
b
patches.
Signed-off-by: Danilo Krummrich
---
drivers/gpu/drm/fsl-dcu/fsl_dcu_drm_drv.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/drivers/gpu/drm/fsl-dcu/fsl_dcu_drm_drv.c
b/drivers/gpu/drm/fsl-dcu/fsl_dcu_drm_drv.c
index 4139f674c5de..3ac57516c3fe 100644
--- a/drivers/gpu
Use drm managed resources to allocate driver structures and get rid of
the deprecated drm_dev_alloc() call and replace it with
devm_drm_dev_alloc().
This also serves as preparation to get rid of drm_device->dev_private
and to fix use-after-free issues on driver unload.
Signed-off-by: Dan
Using drm_device->dev_private is deprecated. Since we've switched to
devm_drm_dev_alloc(), struct drm_device is now embedded in struct
malidp_drm, hence we can use container_of() to get the struct drm_device
instance instead.
Signed-off-by: Danilo Krummrich
---
drivers/gpu/drm/fsl-
Hi,
This patch series converts the driver to use drm managed resources to prevent
potential use-after-free issues on driver unbind/rebind and to get rid of the
usage of deprecated APIs.
Danilo Krummrich (8):
drm/fsl-dcu: use drmm_* to allocate driver structures
drm/fsl-dcu: replace drm
sections which are accessing those
resources with drm_dev_enter() and drm_dev_exit().
Signed-off-by: Danilo Krummrich
---
drivers/gpu/drm/arm/hdlcd_crtc.c | 52 ++--
1 file changed, 49 insertions(+), 3 deletions(-)
diff --git a/drivers/gpu/drm/arm/hdlcd_crtc.c b/drivers
Use drm managed resources to allocate driver structures and get rid of
the deprecated drm_dev_alloc() call and replace it with
devm_drm_dev_alloc().
This also serves as preparation to get rid of drm_device->dev_private
and to fix use-after-free issues on driver unload.
Signed-off-by: Dan
sections which are accessing those
resources with drm_dev_enter() and drm_dev_exit().
Signed-off-by: Danilo Krummrich
---
drivers/gpu/drm/arm/hdlcd_drv.c | 12 ++--
1 file changed, 10 insertions(+), 2 deletions(-)
diff --git a/drivers/gpu/drm/arm/hdlcd_drv.c b/drivers/gpu/drm/arm/hdlcd_drv.c
Use drm managed resource allocation (drmm_universal_plane_alloc()) in
order to get rid of the explicit destroy hook in struct drm_plane_funcs.
Signed-off-by: Danilo Krummrich
---
drivers/gpu/drm/arm/hdlcd_crtc.c | 20 +++-
1 file changed, 7 insertions(+), 13 deletions(-)
diff
patches.
Signed-off-by: Danilo Krummrich
---
drivers/gpu/drm/arm/hdlcd_drv.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/drivers/gpu/drm/arm/hdlcd_drv.c b/drivers/gpu/drm/arm/hdlcd_drv.c
index 120c87934a91..e41def6d47cc 100644
--- a/drivers/gpu/drm/arm/hdlcd_drv.c
+++ b
Using drm_device->dev_private is deprecated. Since we've switched to
devm_drm_dev_alloc(), struct drm_device is now embedded in struct
hdlcd_drm_private, hence we can use container_of() to get the struct
drm_device instance instead.
Signed-off-by: Danilo Krummrich
---
drivers/gpu/drm/
Hi,
This patch series converts the driver to use drm managed resources to prevent
potential use-after-free issues on driver unbind/rebind and to get rid of the
usage of deprecated APIs.
Changes in v2:
- drop patch "drm/arm/hdlcd: crtc: use drmm_crtc_init_with_planes()"
Danilo Kr
On 9/13/22 10:58, Liviu Dudau wrote:
On Mon, Sep 12, 2022 at 09:50:26PM +0200, Danilo Krummrich wrote:
Hi Liviu,
Hi Danilo,
Thanks for having a look!
This is not about this patch, it's about patch 3/7 "drm/arm/hdlcd: crtc: use
drmm_crtc_init_with_planes()".
Agre
.destroy hook is still required or I'm missing some other
required
series where the WARN has been removed?
Best regards,
Liviu
On Mon, Sep 05, 2022 at 05:27:16PM +0200, Danilo Krummrich wrote:
Use drm managed resource allocation (drmm_universal_plane_alloc()) in
order to get rid of the
sections which are accessing those
resources with drm_dev_enter() and drm_dev_exit().
Signed-off-by: Danilo Krummrich
---
drivers/gpu/drm/arm/hdlcd_drv.c | 12 ++--
1 file changed, 10 insertions(+), 2 deletions(-)
diff --git a/drivers/gpu/drm/arm/hdlcd_drv.c b/drivers/gpu/drm/arm/hdlcd_drv.c
sections which are accessing those
resources with drm_dev_enter() and drm_dev_exit().
Signed-off-by: Danilo Krummrich
---
drivers/gpu/drm/arm/hdlcd_crtc.c | 49 ++--
1 file changed, 47 insertions(+), 2 deletions(-)
diff --git a/drivers/gpu/drm/arm/hdlcd_crtc.c b/drivers
Use drm managed resource allocation (drmm_universal_plane_alloc()) in
order to get rid of the explicit destroy hook in struct drm_plane_funcs.
Signed-off-by: Danilo Krummrich
---
drivers/gpu/drm/arm/hdlcd_crtc.c | 20 +++-
1 file changed, 7 insertions(+), 13 deletions(-)
diff
patches.
Signed-off-by: Danilo Krummrich
---
drivers/gpu/drm/arm/hdlcd_drv.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/drivers/gpu/drm/arm/hdlcd_drv.c b/drivers/gpu/drm/arm/hdlcd_drv.c
index 120c87934a91..e41def6d47cc 100644
--- a/drivers/gpu/drm/arm/hdlcd_drv.c
+++ b
Use drm managed resources to allocate driver structures and get rid of
the deprecated drm_dev_alloc() call and replace it with
devm_drm_dev_alloc().
This also serves as preparation to get rid of drm_device->dev_private
and to fix use-after-free issues on driver unload.
Signed-off-by: Dan
Use drmm_crtc_init_with_planes() instead of drm_crtc_init_with_planes()
to get rid of the explicit drm_crtc_cleanup() call.
Signed-off-by: Danilo Krummrich
---
drivers/gpu/drm/arm/hdlcd_crtc.c | 5 ++---
1 file changed, 2 insertions(+), 3 deletions(-)
diff --git a/drivers/gpu/drm/arm
Using drm_device->dev_private is deprecated. Since we've switched to
devm_drm_dev_alloc(), struct drm_device is now embedded in struct
hdlcd_drm_private, hence we can use container_of() to get the struct
drm_device instance instead.
Signed-off-by: Danilo Krummrich
---
drivers/gpu/drm/
Hi,
This patch series converts the driver to use drm managed resources to prevent
potential use-after-free issues on driver unbind/rebind and to get rid of the
usage of deprecated APIs.
Danilo Krummrich (7):
drm/arm/hdlcd: use drmm_* to allocate driver structures
drm/arm/hdlcd: replace drm
sections which are accessing those
resources with drm_dev_enter() and drm_dev_exit().
Signed-off-by: Danilo Krummrich
---
drivers/gpu/drm/arm/malidp_drv.c | 7 ++-
1 file changed, 6 insertions(+), 1 deletion(-)
diff --git a/drivers/gpu/drm/arm/malidp_drv.c b/drivers/gpu/drm/arm/malidp_drv.c
index
sections which are accessing those
resources with drm_dev_enter() and drm_dev_exit().
Signed-off-by: Danilo Krummrich
---
drivers/gpu/drm/arm/malidp_crtc.c | 41 +--
1 file changed, 39 insertions(+), 2 deletions(-)
diff --git a/drivers/gpu/drm/arm/malidp_crtc.c
b/drivers
sections which are accessing those
resources with drm_dev_enter() and drm_dev_exit().
Signed-off-by: Danilo Krummrich
---
drivers/gpu/drm/arm/malidp_planes.c | 13 -
1 file changed, 12 insertions(+), 1 deletion(-)
diff --git a/drivers/gpu/drm/arm/malidp_planes.c
b/drivers/gpu/drm/arm
patches.
Signed-off-by: Danilo Krummrich
---
drivers/gpu/drm/arm/malidp_drv.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/drivers/gpu/drm/arm/malidp_drv.c b/drivers/gpu/drm/arm/malidp_drv.c
index 678c5b0d8014..aedd30f5f451 100644
--- a/drivers/gpu/drm/arm/malidp_drv.c
+++ b
Use drm managed resource allocation (drmm_universal_plane_alloc()) in
order to get rid of the explicit destroy hook in struct drm_plane_funcs.
Signed-off-by: Danilo Krummrich
---
drivers/gpu/drm/arm/malidp_planes.c | 28 +++-
1 file changed, 7 insertions(+), 21 deletions
Use drmm_crtc_init_with_planes() instead of drm_crtc_init_with_planes()
to get rid of the explicit destroy hook in struct drm_plane_funcs.
Signed-off-by: Danilo Krummrich
---
drivers/gpu/drm/arm/malidp_crtc.c | 5 ++---
1 file changed, 2 insertions(+), 3 deletions(-)
diff --git a/drivers/gpu
Using drm_device->dev_private is deprecated. Since we've switched to
devm_drm_dev_alloc(), struct drm_device is now embedded in struct
malidp_drm, hence we can use container_of() to get the struct drm_device
instance instead.
Signed-off-by: Danilo Krummrich
---
drivers/gpu/drm/arm/malidp_crt
Hi,
This patch series converts the driver to use drm managed resources to prevent
potential use-after-free issues on driver unbind/rebind and to get rid of the
usage of deprecated APIs.
Danilo Krummrich (8):
drm/arm/malidp: use drmm_* to allocate driver structures
drm/arm/malidp: replace drm
Use drm managed resources to allocate driver structures and get rid of
the deprecated drm_dev_alloc() call and replace it with
devm_drm_dev_alloc().
This also serves as preparation to get rid of drm_device->dev_private
and to fix use-after-free issues on driver unload.
Signed-off-by: Dan
Changes in v3:
- vc4_plane: Actually protect entire functions to increase readability
(Maxime)
Danilo Krummrich (4):
drm/vc4: hdmi: unlock mutex when device is unplugged
drm/vc4: plane: protect device resources after removal
drm/vc4: crtc: protect device resources after removal
drm/vc4: hvs
sections which are accessing those
resources with drm_dev_enter() and drm_dev_exit().
Signed-off-by: Danilo Krummrich
---
drivers/gpu/drm/arm/malidp_crtc.c | 41 +--
1 file changed, 39 insertions(+), 2 deletions(-)
diff --git a/drivers/gpu/drm/arm/malidp_crtc.c
b/drivers
Use drm managed resource allocation (drmm_universal_plane_alloc()) in
order to get rid of the explicit destroy hook in struct drm_plane_funcs.
Signed-off-by: Danilo Krummrich
---
drivers/gpu/drm/arm/malidp_planes.c | 28 +++-
1 file changed, 7 insertions(+), 21 deletions
which are accessing those
resources with drm_dev_enter() and drm_dev_exit().
Fixes: 9872c7a31921 ("drm/vc4: plane: Switch to drmm_universal_plane_alloc()")
Signed-off-by: Danilo Krummrich
---
drivers/gpu/drm/vc4/vc4_drv.h | 1 +
drivers/gpu/drm/vc4/vc4_plane.c | 25 ++
resources after removal")
Signed-off-by: Danilo Krummrich
---
drivers/gpu/drm/vc4/vc4_hdmi.c | 7 +--
1 file changed, 5 insertions(+), 2 deletions(-)
diff --git a/drivers/gpu/drm/vc4/vc4_hdmi.c b/drivers/gpu/drm/vc4/vc4_hdmi.c
index 84e5a91c2ea7..4d3ff51ad2a8 100644
--- a/drivers/gpu/drm/
("drm/vc4: hvs: Protect device resources after removal")
Signed-off-by: Danilo Krummrich
---
drivers/gpu/drm/vc4/vc4_hvs.c | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
diff --git a/drivers/gpu/drm/vc4/vc4_hvs.c b/drivers/gpu/drm/vc4/vc4_hvs.c
index 9e823e0de197..4ac9f5a2d
which are accessing those
resources with drm_dev_enter() and drm_dev_exit().
Fixes: 9872c7a31921 ("drm/vc4: plane: Switch to drmm_universal_plane_alloc()")
Signed-off-by: Danilo Krummrich
---
drivers/gpu/drm/vc4/vc4_plane.c | 20
1 file changed, 20 insertions(+)
which are accessing those
resources with drm_dev_enter() and drm_dev_exit().
Fixes: 7cc4214c27cf ("drm/vc4: crtc: Switch to drmm_kzalloc")
Signed-off-by: Danilo Krummrich
---
drivers/gpu/drm/vc4/vc4_crtc.c | 41 +-
1 file changed, 40 insertions(+),
Hi Maxime,
On 8/24/22 17:48, Maxime Ripard wrote:
@@ -1252,12 +1261,17 @@ void vc4_plane_async_set_fb(struct drm_plane *plane,
struct drm_framebuffer *fb)
WARN_ON_ONCE(plane->state->crtc_x < 0 || plane->state->crtc_y < 0);
addr = bo->dma_addr + fb->offsets[0];
+ if
sections which are accessing those
resources with drm_dev_enter() and drm_dev_exit().
Signed-off-by: Danilo Krummrich
---
drivers/gpu/drm/arm/hdlcd_crtc.c | 49 ++--
1 file changed, 47 insertions(+), 2 deletions(-)
diff --git a/drivers/gpu/drm/arm/hdlcd_crtc.c b/drivers
patches.
Signed-off-by: Danilo Krummrich
---
drivers/gpu/drm/arm/hdlcd_drv.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/drivers/gpu/drm/arm/hdlcd_drv.c b/drivers/gpu/drm/arm/hdlcd_drv.c
index 120c87934a91..e41def6d47cc 100644
--- a/drivers/gpu/drm/arm/hdlcd_drv.c
+++ b
Use drm managed resource allocation (drmm_universal_plane_alloc()) in
order to get rid of the explicit destroy hook in struct drm_plane_funcs.
Signed-off-by: Danilo Krummrich
---
drivers/gpu/drm/arm/hdlcd_crtc.c | 20 +++-
1 file changed, 7 insertions(+), 13 deletions(-)
diff
Use drm managed resources to allocate driver structures and get rid of
the deprecated drm_dev_alloc() call and replace it with
devm_drm_dev_alloc().
This also serves as preparation to get rid of drm_device->dev_private
and to fix use-after-free issues on driver unload.
Signed-off-by: Dan
Using drm_device->dev_private is deprecated. Since we've switched to
devm_drm_dev_alloc(), struct drm_device is now embedded in struct
hdlcd_drm_private, hence we can use container_of() to get the struct
drm_device instance instead.
Signed-off-by: Danilo Krummrich
---
drivers/gpu/drm/
sections which are accessing those
resources with drm_dev_enter() and drm_dev_exit().
Signed-off-by: Danilo Krummrich
---
drivers/gpu/drm/arm/hdlcd_drv.c | 12 ++--
1 file changed, 10 insertions(+), 2 deletions(-)
diff --git a/drivers/gpu/drm/arm/hdlcd_drv.c b/drivers/gpu/drm/arm/hdlcd_drv.c
Use drmm_crtc_init_with_planes() instead of drm_crtc_init_with_planes()
to get rid of the explicit drm_crtc_cleanup() call.
Signed-off-by: Danilo Krummrich
---
drivers/gpu/drm/arm/hdlcd_crtc.c | 5 ++---
1 file changed, 2 insertions(+), 3 deletions(-)
diff --git a/drivers/gpu/drm/arm
Hi,
This patch series converts the driver to use drm managed resources to prevent
potential use-after-free issues on driver unbind/rebind and to get rid of the
usage of deprecated APIs.
Danilo Krummrich (7):
drm/arm/hdlcd: use drmm_* to allocate driver structures
drm/arm/hdlcd: replace drm
sections which are accessing those
resources with drm_dev_enter() and drm_dev_exit().
Signed-off-by: Danilo Krummrich
---
drivers/gpu/drm/arm/malidp_drv.c | 7 ++-
1 file changed, 6 insertions(+), 1 deletion(-)
diff --git a/drivers/gpu/drm/arm/malidp_drv.c b/drivers/gpu/drm/arm/malidp_drv.c
index
patches.
Signed-off-by: Danilo Krummrich
---
drivers/gpu/drm/arm/malidp_drv.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/drivers/gpu/drm/arm/malidp_drv.c b/drivers/gpu/drm/arm/malidp_drv.c
index 678c5b0d8014..aedd30f5f451 100644
--- a/drivers/gpu/drm/arm/malidp_drv.c
+++ b
sections which are accessing those
resources with drm_dev_enter() and drm_dev_exit().
Signed-off-by: Danilo Krummrich
---
drivers/gpu/drm/arm/malidp_planes.c | 13 -
1 file changed, 12 insertions(+), 1 deletion(-)
diff --git a/drivers/gpu/drm/arm/malidp_planes.c
b/drivers/gpu/drm/arm
Use drmm_crtc_init_with_planes() instead of drm_crtc_init_with_planes()
to get rid of the explicit destroy hook in struct drm_plane_funcs.
Signed-off-by: Danilo Krummrich
---
drivers/gpu/drm/arm/malidp_crtc.c | 5 ++---
1 file changed, 2 insertions(+), 3 deletions(-)
diff --git a/drivers/gpu
Use drm managed resources to allocate driver structures and get rid of
the deprecated drm_dev_alloc() call and replace it with
devm_drm_dev_alloc().
This also serves as preparation to get rid of drm_device->dev_private
and to fix use-after-free issues on driver unload.
Signed-off-by: Dan
Using drm_device->dev_private is deprecated. Since we've switched to
devm_drm_dev_alloc(), struct drm_device is now embedded in struct
malidp_drm, hence we can use container_of() to get the struct drm_device
instance instead.
Signed-off-by: Danilo Krummrich
---
drivers/gpu/drm/arm/malidp_crt
Hi,
This patch series converts the driver to use drm managed resources to prevent
potential use-after-free issues on driver unbind/rebind and to get rid of the
usage of deprecated APIs.
Danilo Krummrich (8):
drm/arm/malidp: use drmm_* to allocate driver structures
drm/arm/malidp: replace drm
Hi Maxime,
On 8/19/22 09:26, Maxime Ripard wrote:
Hi,
On Fri, Aug 19, 2022 at 02:29:04AM +0200, Danilo Krummrich wrote:
(Hardware) resources which are bound to the driver and device lifecycle
must not be accessed after the device and driver are unbound.
However, the DRM device isn't freed
("drm/vc4: hvs: Protect device resources after removal")
Signed-off-by: Danilo Krummrich
---
drivers/gpu/drm/vc4/vc4_hvs.c | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
diff --git a/drivers/gpu/drm/vc4/vc4_hvs.c b/drivers/gpu/drm/vc4/vc4_hvs.c
index 9e823e0de197..4ac9f5a2d
which are accessing those
resources with drm_dev_enter() and drm_dev_exit().
Fixes: 9872c7a31921 ("drm/vc4: plane: Switch to drmm_universal_plane_alloc()")
Signed-off-by: Danilo Krummrich
---
drivers/gpu/drm/vc4/vc4_plane.c | 20
1 file changed, 20 insertions(+)
which are accessing those
resources with drm_dev_enter() and drm_dev_exit().
Fixes: 7cc4214c27cf ("drm/vc4: crtc: Switch to drmm_kzalloc")
Signed-off-by: Danilo Krummrich
---
drivers/gpu/drm/vc4/vc4_crtc.c | 41 +-
1 file changed, 40 insertions(+),
resources after removal")
Signed-off-by: Danilo Krummrich
---
drivers/gpu/drm/vc4/vc4_hdmi.c | 7 +--
1 file changed, 5 insertions(+), 2 deletions(-)
diff --git a/drivers/gpu/drm/vc4/vc4_hdmi.c b/drivers/gpu/drm/vc4/vc4_hdmi.c
index 84e5a91c2ea7..4d3ff51ad2a8 100644
--- a/drivers/gpu/drm/
Danilo Krummrich (4):
drm/vc4: hdmi: unlock mutex when device is unplugged
drm/vc4: plane: protect device resources after removal
drm/vc4: crtc: protect device resources after removal
drm/vc4: hvs: protect drm_print_regset32()
drivers/gpu/drm/vc4/vc4_crtc.c | 41
resources after removal")
Signed-off-by: Danilo Krummrich
---
drivers/gpu/drm/vc4/vc4_hdmi.c | 7 +--
1 file changed, 5 insertions(+), 2 deletions(-)
diff --git a/drivers/gpu/drm/vc4/vc4_hdmi.c b/drivers/gpu/drm/vc4/vc4_hdmi.c
index 84e5a91c2ea7..4d3ff51ad2a8 100644
--- a/drivers/gpu/drm/
which are accessing those
resources with drm_dev_enter() and drm_dev_exit().
Fixes: 7cc4214c27cf ("drm/vc4: crtc: Switch to drmm_kzalloc")
Signed-off-by: Danilo Krummrich
---
drivers/gpu/drm/vc4/vc4_crtc.c | 41 +-
1 file changed, 40 insertions(+),
is unbound, but the
DRM potentially isn't freed yet and userspace can still call into the driver.
Danilo Krummrich (3):
drm/vc4: hdmi: unlock mutex when device is unplugged
drm/vc4: plane: protect device resources after removal
drm/vc4: crtc: protect device resources after removal
drivers/gpu/drm
drmm_universal_plane_alloc() already registers drm_plane_cleanup() as
managed release action via drmm_add_action_or_reset(). Hence,
drm_plane_cleanup() should not be set as drm_plane_funcs.destroy hook.
Fixes: 7847628862a8 ("drm/virtio: plane: use drm managed resources")
Signed-off-
Both, GEM and FB, CMA helpers were renamed to "GEM DMA" and "FB DMA",
hence the task can be removed.
Acked-by: Sam Ravnborg
Acked-by: Thomas Zimmermann
Reviewed-by: Laurent Pinchart
Signed-off-by: Danilo Krummrich
---
Documentation/gpu/todo.rst | 13 -
ollowing modifications in some DRM Kconfig files
- select CMA if HAVE_DMA_CONTIGUOUS
+ select DMA if HAVE_DMA_CONTIGUOUS
as well as manually picking the occurrences of 'CMA'/'cma' in comments and
documentation which relate to "FB CMA", but not "GEM CMA".
This patc
-time tested with:
```
make ARCH={x86_64,arm,arm64} allyesconfig
make ARCH={x86_64,arm,arm64} drivers/gpu/drm`
```
Acked-by: Sam Ravnborg
Suggested-by: Laurent Pinchart
Reviewed-by: Laurent Pinchart
Signed-off-by: Danilo Krummrich
---
.../arm/display/komeda/komeda_framebuffer.c | 4
Quite a lot of drivers include the drm_fb_cma_helper.h header file
without actually making use of it's provided API, hence remove those
includes.
Suggested-by: Sam Ravnborg
Signed-off-by: Danilo Krummrich
---
drivers/gpu/drm/arm/hdlcd_drv.c | 1 -
drivers/gpu/drm/arm
Fix `select DRM_KMS_{CMA => DMA}_HELPER` and
`select DRM_GEM_{CMA => DMA}_HELPER` in
drivers/gpu/drm/logicvc/Kconfig and drivers/gpu/drm/mxsfb/Kconfig which
slipped through in a rebase.
- Another rebase.
Danilo Krummrich (5):
drm/fb: remove unused includes of drm_fb_cma_help
On 7/28/22 16:44, Maxime Ripard wrote:
On Thu, Jul 28, 2022 at 04:41:41PM +0200, Maxime Ripard wrote:
On Fri, 1 Jul 2022 20:52:53 +0200, d...@redhat.com wrote:
From: Danilo Krummrich
This patch series initializes IDRs with idr_init_base(, 1) rather than
idr_init() in case for the particular
Both, GEM and FB, CMA helpers were renamed to "GEM DMA" and "FB DMA",
hence the task can be removed.
Acked-by: Sam Ravnborg
Acked-by: Thomas Zimmermann
Reviewed-by: Laurent Pinchart
Signed-off-by: Danilo Krummrich
---
Documentation/gpu/todo.rst | 13 -
ollowing modifications in some DRM Kconfig files
- select CMA if HAVE_DMA_CONTIGUOUS
+ select DMA if HAVE_DMA_CONTIGUOUS
as well as manually picking the occurrences of 'CMA'/'cma' in comments and
documentation which relate to "FB CMA", but not "GEM CMA".
This patc
-time tested with:
```
make ARCH={x86_64,arm,arm64} allyesconfig
make ARCH={x86_64,arm,arm64} drivers/gpu/drm`
```
Acked-by: Sam Ravnborg
Suggested-by: Laurent Pinchart
Reviewed-by: Laurent Pinchart
Signed-off-by: Danilo Krummrich
---
.../arm/display/komeda/komeda_framebuffer.c | 4
Quite a lot of drivers include the drm_fb_cma_helper.h header file
without actually making use of it's provided API, hence remove those
includes.
Suggested-by: Sam Ravnborg
Signed-off-by: Danilo Krummrich
---
drivers/gpu/drm/arm/hdlcd_drv.c | 1 -
drivers/gpu/drm/arm
- Rebased all patches on drm-misc/drm-misc-next.
Changes in v5:
- Rebase of v4, meanwhile some merge conflicts came up on
drm-misc/drm-misc-next.
Changes in v6:
- Added a patch to remove unused include occurances of drm_fb_cma_helper.h
in various drivers.
Danilo Krummri
Hi Sam,
On 7/20/22 19:23, Sam Ravnborg wrote:
Hi Danilo,
On Wed, Jul 20, 2022 at 05:31:25PM +0200, Danilo Krummrich wrote:
Rename "FB CMA" helpers to "FB DMA" helpers - considering the hierarchy
of APIs (mm/cma -> dma -> fb dma) calling them "FB DMA" s
Hi Sam,
On 7/20/22 17:17, Sam Ravnborg wrote:
Hi Danilo,
thanks for submitting this patch.
On Wed, Jul 20, 2022 at 04:02:13PM +0200, Danilo Krummrich wrote:
Use drm managed resource allocation (drmm_universal_plane_alloc()) in
order to cleanup/simplify drm plane .destroy callback.
Signed
-time tested with:
```
make ARCH={x86_64,arm,arm64} allyesconfig
make ARCH={x86_64,arm,arm64} drivers/gpu/drm`
```
Reviewed-by: Laurent Pinchart
Signed-off-by: Danilo Krummrich
---
.../arm/display/komeda/komeda_framebuffer.c | 4 +--
drivers/gpu/drm/arm/malidp_mw.c | 2
Both, GEM and FB, CMA helpers were renamed to "GEM DMA" and "FB DMA",
hence the task can be removed.
Acked-by: Thomas Zimmermann
Reviewed-by: Laurent Pinchart
Signed-off-by: Danilo Krummrich
---
Documentation/gpu/todo.rst | 13 -
1 file changed, 13 dele
ollowing modifications in some DRM Kconfig files
- select CMA if HAVE_DMA_CONTIGUOUS
+ select DMA if HAVE_DMA_CONTIGUOUS
as well as manually picking the occurrences of 'CMA'/'cma' in comments and
documentation which relate to "FB CMA", but not "GEM CMA&quo
- Rebased all patches on drm-misc/drm-misc-next.
Changes in v5:
- Rebase of v4, meanwhile some merge conflicts came up on
drm-misc/drm-misc-next.
Danilo Krummrich (4):
drm/fb: rename FB CMA helpers to FB DMA helpers
drm/gem: rename GEM CMA helpers to GEM DMA helpers
drm/gem:
Allocate driver structures with drm managed resource allocators in order
to cleanup/simplify the drm driver .release callback.
Signed-off-by: Danilo Krummrich
---
drivers/gpu/drm/virtio/virtgpu_kms.c | 16 +++-
1 file changed, 7 insertions(+), 9 deletions(-)
diff --git a/drivers
Use drm managed resource allocation (drmm_universal_plane_alloc()) in
order to cleanup/simplify drm plane .destroy callback.
Signed-off-by: Danilo Krummrich
---
drivers/gpu/drm/virtio/virtgpu_plane.c | 30 +++---
1 file changed, 8 insertions(+), 22 deletions(-)
diff --git
This patch series converts plain memory allocations for driver structures and
planes to drm managed allocations in order to cleanup/simply the corresponding
release/destroy callbacks.
Danilo Krummrich (2):
drm/virtio: plane: use drm managed resources
drm/virtio: kms: use drm managed resources
All IDRs in the DRM core and drivers which are applicable for using
idr_init_base() over idr_init() should be set up to use a proper base in
order to avoid unnecessary tree walks.
Signed-off-by: Danilo Krummrich
Acked-by: Christian König
---
Documentation/gpu/todo.rst | 12
1 file
.
Signed-off-by: Danilo Krummrich
Acked-by: Christian König
---
drivers/gpu/drm/sis/sis_drv.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/drivers/gpu/drm/sis/sis_drv.c b/drivers/gpu/drm/sis/sis_drv.c
index e35e719cf315..6173020a9bf5 100644
--- a/drivers/gpu/drm/sis/sis_drv.c
.
Signed-off-by: Danilo Krummrich
Acked-by: Christian König
---
drivers/gpu/drm/drm_auth.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/drivers/gpu/drm/drm_auth.c b/drivers/gpu/drm/drm_auth.c
index 63395bebaa6b..cf92a9ae8034 100644
--- a/drivers/gpu/drm/drm_auth.c
+++ b/dr
.
Signed-off-by: Danilo Krummrich
Reviewed-by: Christian König
---
drivers/gpu/drm/amd/amdgpu/amdgpu_kms.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/drivers/gpu/drm/amd/amdgpu/amdgpu_kms.c
b/drivers/gpu/drm/amd/amdgpu/amdgpu_kms.c
index 6de63ea6687e..103927c48d05 100644
.
Signed-off-by: Danilo Krummrich
Acked-by: Christian König
---
drivers/gpu/drm/drm_mode_config.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/drivers/gpu/drm/drm_mode_config.c
b/drivers/gpu/drm/drm_mode_config.c
index e2a295a4ee0b..3d1c1ade5a25 100644
--- a/dr
.
Signed-off-by: Danilo Krummrich
Acked-by: Christian König
---
drivers/gpu/drm/v3d/v3d_perfmon.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/drivers/gpu/drm/v3d/v3d_perfmon.c
b/drivers/gpu/drm/v3d/v3d_perfmon.c
index f6a88abccc7d..48972c49 100644
--- a/driver
.
Signed-off-by: Danilo Krummrich
Acked-by: Christian König
---
drivers/gpu/drm/via/via_map.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/drivers/gpu/drm/via/via_map.c b/drivers/gpu/drm/via/via_map.c
index a9f6b0c11966..c20bb20c0e09 100644
--- a/drivers/gpu/drm/via/via_map.c
This patch series initializes IDRs with idr_init_base(, 1) rather than
idr_init() in case for the particular IDR no IDs < 1 are ever requested -
this avoids unnecessary tree walks.
Danilo Krummrich (10):
drm/amdgpu: use idr_init_base() to initialize mgr->ctx_handles
drm/amdgp
.
Signed-off-by: Danilo Krummrich
Acked-by: Christian König
---
drivers/gpu/drm/drm_auth.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/drivers/gpu/drm/drm_auth.c b/drivers/gpu/drm/drm_auth.c
index 6e433d465f41..63395bebaa6b 100644
--- a/drivers/gpu/drm/drm_auth.c
+++ b/dr
.
Signed-off-by: Danilo Krummrich
Acked-by: Christian König
---
drivers/gpu/drm/drm_mode_config.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/drivers/gpu/drm/drm_mode_config.c
b/drivers/gpu/drm/drm_mode_config.c
index 37b4b9f0e468..e2a295a4ee0b 100644
--- a/dr
idr_init_base(), implemented by commit 6ce711f27500 ("idr: Make 1-based
IDRs more efficient"), let us set an arbitrary base other than
idr_init(), which uses base 0.
Since, for this IDR, no ID < 1 is ever requested, using
idr_init_base(, 1) avoids unnecessary tree walks.
Signed-o
Hi Maxime,
On 7/13/22 11:10, Maxime Ripard wrote:
Hi Danilo,
On Wed, Jul 13, 2022 at 10:54:57AM +0200, Danilo Krummrich wrote:
This patch series converts DRM modeset object allocations from devm_*()
to drmm_*() memory allocators, or their corresponding convenience
wrappers, respectively
Allocate driver structures with drm managed resource allocators in order
to cleanup/simplify the drm driver .release callback.
Signed-off-by: Danilo Krummrich
---
drivers/gpu/drm/virtio/virtgpu_kms.c | 16 +++-
1 file changed, 7 insertions(+), 9 deletions(-)
diff --git a/drivers
Use drm managed resource allocation (drmm_universal_plane_alloc()) in
order to cleanup/simplify drm plane .destroy callback.
Signed-off-by: Danilo Krummrich
---
drivers/gpu/drm/virtio/virtgpu_plane.c | 30 +++---
1 file changed, 8 insertions(+), 22 deletions(-)
diff --git
This patch series converts plain memory allocations for driver structures and
planes to drm managed allocations in order to cleanup/simply the corresponding
release/destroy callbacks.
Danilo Krummrich (2):
drm/virtio: plane: use drm managed resources
drm/virtio: kms: use drm managed resources
701 - 800 of 831 matches
Mail list logo