All of lore.kernel.org
 help / color / mirror / Atom feed
From: Daniel Vetter <daniel.vetter@ffwll.ch>
To: DRI Development <dri-devel@lists.freedesktop.org>
Cc: Daniel Vetter <daniel.vetter@ffwll.ch>,
	Intel Graphics Development <intel-gfx@lists.freedesktop.org>
Subject: [PATCH 00/22] drm_event cleanup, round 2
Date: Mon, 11 Jan 2016 22:40:54 +0100	[thread overview]
Message-ID: <1452548477-15905-1-git-send-email-daniel.vetter@ffwll.ch> (raw)

Hi all,

Mostly just small changes from review feedback (plus a few misplaced hunks,
silly me). Plus an attempt at better kerneldoc to explain how this works. Since
that caused questions both from Thomas and Laurent let me explain things also
here:

Currently anyone using drm_events (vblank code, atomic/legacy flips, drivers
like exynos) need to handle event setup, sending to the drm file and handling
when the drm file disappears themselves. This patch series provides functions to
encapsulate all these steps. Furthermore the file closing is handled
differently: Events are no longer completely destroyed in preclose hooks like
all current users do, but instead they're just unlinked from the file. The new
drm_send_event can still be called, but instead of transmitting the event to the
file it'll destroy it right away.

This means that when the drm file disappears it's entirely transparent to
drivers, and we can remove all the special tracking and cleanup code around
preclose functions.

The other consequence is that it's opt-in - drivers are still free to remove
events explicitly when the file disappears, it's just needless code. Which means
the patch series can be split up really nicely into core parts + driver patches.
The only patch I didn't split up in this fashion is the one that creates
drm_send_event - it's imo easier to review this way, and the driver changes are
really simple.

Cheers, Daniel

Daniel Vetter (22):
  drm: kerneldoc for drm_fops.c
  drm: Add functions to setup/tear down drm_events.
  drm/exynos: Use the new event init/free functions
  drm/vmwgfx: Use the new event init/free functions
  drm: Create drm_send_event helpers
  drm/fsl: Remove preclose hook
  drm/armada: Remove NULL open/pre/postclose hooks
  drm/gma500: Remove empty preclose hook
  drm: Clean up pending events in the core
  drm: Nuke vblank event file cleanup code
  drm/i915: Nuke intel_modeset_preclose
  drm/atmel: Nuke preclose
  drm/exynos: Remove event cancelling from postclose
  drm/imx: Unconfuse preclose logic
  drm/msm: Nuke preclose hooks
  drm/omap: Nuke close hooks
  drm/rcar: Nuke preclose hook
  drm/shmob: Nuke preclose hook
  drm/tegra: Stop cancelling page flip events
  drm/tilcdc: Nuke preclose hook
  drm/vc4: Nuke preclose hook
  drm/vmwgfx: Nuke preclose hook

 Documentation/DocBook/gpu.tmpl                 |  48 +----
 drivers/gpu/drm/armada/armada_drv.c            |   3 -
 drivers/gpu/drm/atmel-hlcdc/atmel_hlcdc_crtc.c |  18 --
 drivers/gpu/drm/atmel-hlcdc/atmel_hlcdc_dc.c   |  10 -
 drivers/gpu/drm/atmel-hlcdc/atmel_hlcdc_dc.h   |   3 -
 drivers/gpu/drm/drm_atomic.c                   |  44 +---
 drivers/gpu/drm/drm_crtc.c                     |  36 +---
 drivers/gpu/drm/drm_fops.c                     | 271 ++++++++++++++++++++++---
 drivers/gpu/drm/drm_irq.c                      |   7 +-
 drivers/gpu/drm/exynos/exynos_drm_drv.c        |  14 --
 drivers/gpu/drm/exynos/exynos_drm_g2d.c        |  36 +---
 drivers/gpu/drm/exynos/exynos_drm_ipp.c        |  28 +--
 drivers/gpu/drm/fsl-dcu/fsl_dcu_drm_drv.c      |   5 -
 drivers/gpu/drm/gma500/psb_drv.c               |   9 -
 drivers/gpu/drm/i915/i915_dma.c                |   2 -
 drivers/gpu/drm/i915/intel_display.c           |  21 --
 drivers/gpu/drm/i915/intel_drv.h               |   1 -
 drivers/gpu/drm/imx/imx-drm-core.c             |  13 --
 drivers/gpu/drm/imx/ipuv3-crtc.c               |   4 -
 drivers/gpu/drm/msm/mdp/mdp4/mdp4_crtc.c       |   7 -
 drivers/gpu/drm/msm/mdp/mdp4/mdp4_kms.c        |  11 -
 drivers/gpu/drm/msm/mdp/mdp4/mdp4_kms.h        |   1 -
 drivers/gpu/drm/msm/mdp/mdp5/mdp5_crtc.c       |   6 -
 drivers/gpu/drm/msm/mdp/mdp5/mdp5_kms.c        |  11 -
 drivers/gpu/drm/msm/mdp/mdp5/mdp5_kms.h        |   1 -
 drivers/gpu/drm/omapdrm/omap_crtc.c            |  13 +-
 drivers/gpu/drm/omapdrm/omap_drv.c             |  41 ----
 drivers/gpu/drm/omapdrm/omap_drv.h             |   1 -
 drivers/gpu/drm/rcar-du/rcar_du_crtc.c         |  20 --
 drivers/gpu/drm/rcar-du/rcar_du_crtc.h         |   2 -
 drivers/gpu/drm/rcar-du/rcar_du_drv.c          |  10 -
 drivers/gpu/drm/shmobile/shmob_drm_crtc.c      |  20 --
 drivers/gpu/drm/shmobile/shmob_drm_crtc.h      |   2 -
 drivers/gpu/drm/shmobile/shmob_drm_drv.c       |   8 -
 drivers/gpu/drm/tegra/dc.c                     |  17 --
 drivers/gpu/drm/tegra/drm.c                    |   3 -
 drivers/gpu/drm/tegra/drm.h                    |   1 -
 drivers/gpu/drm/tilcdc/tilcdc_crtc.c           |  20 --
 drivers/gpu/drm/tilcdc/tilcdc_drv.c            |   8 -
 drivers/gpu/drm/tilcdc/tilcdc_drv.h            |   1 -
 drivers/gpu/drm/vc4/vc4_crtc.c                 |  20 --
 drivers/gpu/drm/vc4/vc4_drv.c                  |  10 -
 drivers/gpu/drm/vc4/vc4_drv.h                  |   1 -
 drivers/gpu/drm/vmwgfx/vmwgfx_drv.c            |  11 -
 drivers/gpu/drm/vmwgfx/vmwgfx_drv.h            |   1 -
 drivers/gpu/drm/vmwgfx/vmwgfx_fence.c          |  87 +-------
 drivers/gpu/drm/vmwgfx/vmwgfx_fence.h          |   2 -
 include/drm/drmP.h                             |  26 ++-
 48 files changed, 312 insertions(+), 623 deletions(-)

-- 
2.6.4

_______________________________________________
Intel-gfx mailing list
Intel-gfx@lists.freedesktop.org
http://lists.freedesktop.org/mailman/listinfo/intel-gfx

             reply	other threads:[~2016-01-11 21:40 UTC|newest]

Thread overview: 46+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2016-01-11 21:40 Daniel Vetter [this message]
2016-01-11 21:40 ` [PATCH 01/22] drm: kerneldoc for drm_fops.c Daniel Vetter
2016-01-11 21:40 ` [PATCH 02/22] drm: Add functions to setup/tear down drm_events Daniel Vetter
2016-01-14 18:46   ` Laurent Pinchart
2016-01-11 21:40 ` [PATCH 03/22] drm/exynos: Use the new event init/free functions Daniel Vetter
2016-01-11 21:40 ` [PATCH 04/22] drm/vmwgfx: " Daniel Vetter
2016-01-11 21:40 ` [PATCH 05/22] drm: Create drm_send_event helpers Daniel Vetter
2016-01-14 18:46   ` Laurent Pinchart
2016-01-11 21:41 ` [PATCH 06/22] drm/fsl: Remove preclose hook Daniel Vetter
2016-01-11 21:41 ` [PATCH 07/22] drm/armada: Remove NULL open/pre/postclose hooks Daniel Vetter
2016-01-12 11:51   ` Russell King - ARM Linux
2016-01-12 12:33     ` Daniel Vetter
2016-01-11 21:41 ` [PATCH 08/22] drm/gma500: Remove empty preclose hook Daniel Vetter
2016-01-12 10:11   ` Patrik Jakobsson
2016-01-11 21:41 ` [PATCH 09/22] drm: Clean up pending events in the core Daniel Vetter
2016-01-14 18:45   ` Laurent Pinchart
2016-01-25 14:45   ` [REGRESSION] " Maarten Lankhorst
2016-01-11 21:41 ` [PATCH 10/22] drm: Nuke vblank event file cleanup code Daniel Vetter
2016-01-25  0:26   ` Laurent Pinchart
2016-01-11 21:41 ` [PATCH 11/22] drm/i915: Nuke intel_modeset_preclose Daniel Vetter
2016-01-11 21:41 ` [PATCH 12/22] drm/atmel: Nuke preclose Daniel Vetter
2016-01-13 14:56   ` Boris Brezillon
2016-01-11 21:41 ` [PATCH 13/22] drm/exynos: Remove event cancelling from postclose Daniel Vetter
2016-01-12  6:13   ` Inki Dae
2016-01-11 21:41 ` [PATCH 14/22] drm/imx: Unconfuse preclose logic Daniel Vetter
2016-01-12  8:57   ` Philipp Zabel
2016-01-11 21:41 ` [PATCH 15/22] drm/msm: Nuke preclose hooks Daniel Vetter
2016-01-11 21:41 ` [PATCH 16/22] drm/omap: Nuke close hooks Daniel Vetter
2016-01-12 14:09   ` Tomi Valkeinen
2016-01-13 11:00   ` Tomi Valkeinen
2016-01-13 11:05   ` [PATCH] " Daniel Vetter
2016-01-13 23:07     ` Laurent Pinchart
2016-01-11 21:41 ` [PATCH 17/22] drm/rcar: Nuke preclose hook Daniel Vetter
2016-01-11 21:41 ` [PATCH 18/22] drm/shmob: " Daniel Vetter
2016-01-11 21:41 ` [PATCH 19/22] drm/tegra: Stop cancelling page flip events Daniel Vetter
2016-01-13 14:03   ` Thierry Reding
2016-01-11 21:41 ` [PATCH 20/22] drm/tilcdc: Nuke preclose hook Daniel Vetter
2016-01-12 14:19   ` Tomi Valkeinen
2016-01-12 15:12     ` Daniel Vetter
2016-01-13 11:25       ` Tomi Valkeinen
2016-01-11 21:41 ` [PATCH 21/22] drm/vc4: " Daniel Vetter
2016-01-18 17:19   ` Eric Anholt
2016-01-11 21:41 ` [PATCH 22/22] drm/vmwgfx: " Daniel Vetter
2016-01-11 21:41 ` [PATCH] " Daniel Vetter
2016-01-12  8:30 ` ✗ failure: Fi.CI.BAT Patchwork
2016-01-25  7:50 ` [PATCH 00/22] drm_event cleanup, round 2 Daniel Vetter

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=1452548477-15905-1-git-send-email-daniel.vetter@ffwll.ch \
    --to=daniel.vetter@ffwll.ch \
    --cc=dri-devel@lists.freedesktop.org \
    --cc=intel-gfx@lists.freedesktop.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.