drm: drop DRIVER_HAVE_IRQ flag for some drivers
Subsystems (6)
PATCH v2 1/1 drm: drop DRIVER_HAVE_IRQ flag for some drivers
Since commit 4984979b9b90 ("drm/irq: simplify irq checks in drm_wait_vblank"), the drm driver feature flag DRIVER_HAVE_IRQ is only required for drivers that have an IRQ handler managed by the DRM core. Some drivers, armada, etnaviv, kirin and sti, set this flag without .irq_handler setup in drm_driver. These drivers manage IRQ handler by themselves and the flag DRIVER_HAVE_IRQ makes no sense there.
Drop the flag for these drivers to avoid confusion.
---
Changes for v2:
- Improve commit log per Russell's suggestion
- Add Russell's ACK tag
drivers/gpu/drm/armada/armada_drv.c | 2 +- drivers/gpu/drm/etnaviv/etnaviv_drv.c | 3 +-- drivers/gpu/drm/hisilicon/kirin/kirin_drm_drv.c | 2 +- drivers/gpu/drm/sti/sti_drv.c | 2 +- 4 files changed, 4 insertions(+), 5 deletions(-)
drivers/gpu/drm/armada/armada_drv.c +1 -1
@@ -211,7 +211,7 @@ static struct drm_driver armada_drm_driver = { .desc = "Armada SoC DRM", .date = "20120730", .driver_features = DRIVER_GEM | DRIVER_MODESET | - DRIVER_HAVE_IRQ | DRIVER_PRIME, + DRIVER_PRIME, .ioctls = armada_ioctls, .fops = &armada_drm_fops, };
drivers/gpu/drm/etnaviv/etnaviv_drv.c +1 -2
@@ -488,8 +488,7 @@ static const struct file_operations fops = { };static struct drm_driver etnaviv_drm_driver = { - .driver_features =DRIVER_HAVE_IRQ | -DRIVER_GEM | + .driver_features =DRIVER_GEM |DRIVER_PRIME |DRIVER_RENDER , .open = etnaviv_open,
drivers/gpu/drm/hisilicon/kirin/kirin_drm_drv.c +1 -1
@@ -169,7 +169,7 @@ static int kirin_gem_cma_dumb_create(struct drm_file *file,static struct drm_driver kirin_drm_driver = { .driver_features =DRIVER_GEM |DRIVER_MODESET |DRIVER_PRIME | -DRIVER_ATOMIC |DRIVER_HAVE_IRQ , +DRIVER_ATOMIC , .fops = &kirin_drm_fops, .gem_free_object_unlocked = drm_gem_cma_free_object,
drivers/gpu/drm/sti/sti_drv.c +1 -1
@@ -282,7 +282,7 @@ static const struct file_operations sti_driver_fops = { };static struct drm_driver sti_driver = { - .driver_features =DRIVER_HAVE_IRQ |DRIVER_MODESET | + .driver_features =DRIVER_MODESET |DRIVER_GEM |DRIVER_PRIME |DRIVER_ATOMIC , .gem_free_object_unlocked = drm_gem_cma_free_object, .gem_vm_ops = &drm_gem_cma_vm_ops,
Signature · 6 lines
1.9.1 _______________________________________________ dri-devel mailing list [email protected] https://lists.freedesktop.org/mailman/listinfo/dri-devel
Daniel Vetter
AppliedQuoted 7 lines · Shawn Guo
Since commit
4984979b9b90("drm/irq: simplify irq checks indrm_wait_vblank"), the drm driver feature flagDRIVER_HAVE_IRQis only required for drivers that have an IRQ handler managed by the DRM core. Some drivers, armada, etnaviv, kirin and sti, set this flag without .irq_handler setup indrm_driver. These drivers manage IRQ handler by themselves and the flagDRIVER_HAVE_IRQmakes no sense there.
Quoted 6 lines
Drop the flag for these drivers to avoid confusion.
Signed-off-by Shawn Guo <[email protected]>Cc Vincent Abriou <[email protected]>Cc Xinliang Liu <[email protected]>
Applied to drm-misc, thanks.
-Daniel
Quoted 67 lines
---
Changes for v2:
- Improve commit log per Russell's suggestion
- Add Russell's ACK tagdrivers/gpu/drm/armada/armada_drv.c | 2 +- drivers/gpu/drm/etnaviv/etnaviv_drv.c | 3 +-- drivers/gpu/drm/hisilicon/kirin/kirin_drm_drv.c | 2 +- drivers/gpu/drm/sti/sti_drv.c | 2 +- 4 files changed, 4 insertions(+), 5 deletions(-)drivers/gpu/drm/armada/armada_drv.c +1
-1@@ -211,7 +211,7 @@ static struct drm_driver armada_drm_driver = { .desc = "Armada SoC DRM", .date = "20120730", .driver_features = DRIVER_GEM | DRIVER_MODESET | - DRIVER_HAVE_IRQ | DRIVER_PRIME, + DRIVER_PRIME, .ioctls = armada_ioctls, .fops = &armada_drm_fops, };drivers/gpu/drm/etnaviv/etnaviv_drv.c +1
-2@@ -488,8 +488,7 @@ static const struct file_operations fops = { };static struct drm_driver etnaviv_drm_driver = { - .driver_features =DRIVER_HAVE_IRQ | -DRIVER_GEM | + .driver_features =DRIVER_GEM |DRIVER_PRIME |DRIVER_RENDER , .open = etnaviv_open,drivers/gpu/drm/hisilicon/kirin/kirin_drm_drv.c +1
-1@@ -169,7 +169,7 @@ static int kirin_gem_cma_dumb_create(struct drm_file *file,static struct drm_driver kirin_drm_driver = { .driver_features =DRIVER_GEM |DRIVER_MODESET |DRIVER_PRIME | -DRIVER_ATOMIC |DRIVER_HAVE_IRQ , +DRIVER_ATOMIC , .fops = &kirin_drm_fops, .gem_free_object_unlocked = drm_gem_cma_free_object,drivers/gpu/drm/sti/sti_drv.c +1
-1@@ -282,7 +282,7 @@ static const struct file_operations sti_driver_fops = { };static struct drm_driver sti_driver = { - .driver_features =DRIVER_HAVE_IRQ |DRIVER_MODESET | + .driver_features =DRIVER_MODESET |DRIVER_GEM |DRIVER_PRIME |DRIVER_ATOMIC , .gem_free_object_unlocked = drm_gem_cma_free_object, .gem_vm_ops = &drm_gem_cma_vm_ops,Signature · 1 line
1.9.1
Signature · 7 lines
Daniel Vetter Software Engineer, Intel Corporation http://blog.ffwll.ch _______________________________________________ dri-devel mailing list [email protected] https://lists.freedesktop.org/mailman/listinfo/dri-devel
Quoted 70 lines · Shawn Guo
Since commit
4984979b9b90("drm/irq: simplify irq checks indrm_wait_vblank"), the drm driver feature flagDRIVER_HAVE_IRQis only required for drivers that have an IRQ handler managed by the DRM core. Some drivers, armada, etnaviv, kirin and sti, set this flag without .irq_handler setup indrm_driver. These drivers manage IRQ handler by themselves and the flagDRIVER_HAVE_IRQmakes no sense there.Drop the flag for these drivers to avoid confusion.
Signed-off-by Shawn Guo <[email protected]>Cc Vincent Abriou <[email protected]>Cc Xinliang Liu <[email protected]>---
Changes for v2:
- Improve commit log per Russell's suggestion
- Add Russell's ACK tagdrivers/gpu/drm/armada/armada_drv.c | 2 +- drivers/gpu/drm/etnaviv/etnaviv_drv.c | 3 +-- drivers/gpu/drm/hisilicon/kirin/kirin_drm_drv.c | 2 +- drivers/gpu/drm/sti/sti_drv.c | 2 +- 4 files changed, 4 insertions(+), 5 deletions(-)drivers/gpu/drm/armada/armada_drv.c +1
-1@@ -211,7 +211,7 @@ static struct drm_driver armada_drm_driver = { .desc = "Armada SoC DRM", .date = "20120730", .driver_features = DRIVER_GEM | DRIVER_MODESET | - DRIVER_HAVE_IRQ | DRIVER_PRIME, + DRIVER_PRIME, .ioctls = armada_ioctls, .fops = &armada_drm_fops, };drivers/gpu/drm/etnaviv/etnaviv_drv.c +1
-2@@ -488,8 +488,7 @@ static const struct file_operations fops = { };static struct drm_driver etnaviv_drm_driver = { - .driver_features =DRIVER_HAVE_IRQ | -DRIVER_GEM | + .driver_features =DRIVER_GEM |DRIVER_PRIME |DRIVER_RENDER , .open = etnaviv_open,drivers/gpu/drm/hisilicon/kirin/kirin_drm_drv.c +1
-1@@ -169,7 +169,7 @@ static int kirin_gem_cma_dumb_create(struct drm_file *file,static struct drm_driver kirin_drm_driver = { .driver_features =DRIVER_GEM |DRIVER_MODESET |DRIVER_PRIME | -DRIVER_ATOMIC |DRIVER_HAVE_IRQ , +DRIVER_ATOMIC , .fops = &kirin_drm_fops, .gem_free_object_unlocked = drm_gem_cma_free_object,drivers/gpu/drm/sti/sti_drv.c +0
-0
drivers/gpu/drm/sti/sti_drv.c static const struct file_operations sti_driver_fops = { · line 288
Quoted 8 lines
drivers/gpu/drm/sti/sti_drv.c +1
-1@@ -282,7 +282,7 @@ static const struct file_operations sti_driver_fops = { };static struct drm_driver sti_driver = { - .driver_features =DRIVER_HAVE_IRQ |DRIVER_MODESET | + .driver_features =DRIVER_MODESET |DRIVER_GEM |DRIVER_PRIME |DRIVER_ATOMIC , .gem_free_object_unlocked = drm_gem_cma_free_object, .gem_vm_ops = &drm_gem_cma_vm_ops,
_______________________________________________
dri-devel mailing list
[email protected]
https://lists.freedesktop.org/mailman/listinfo/dri-devel