[PATCH 0/3] Add separate non-KMS state; constify struct drm_driver

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



This patchset moves legacy, non-KMS driver state from struct drm_driver
into struct drm_legacy_state. Only non-KMS drivers provide an instance
of the latter structure. One special case is nouveau, which supports
legacy interfaces. It also provides an instance of the legacy state if
the legacy interfaces have been enabled (i.e., defines the config option
CONFIG_NOUVEAU_LEGACY_CTX_SUPPORT)

I reviewed all call sites of legacy state and functions to verify that
DRIVER_LEGACY or DRIVER_KMS_LEGACY_CONTEXT is set on the device; or that
DRIVER_MODESET is not set.

With the mutable KMS state removed, instances of struct drm_driver can
be declared as constant. The patchset modifies the DRM core accordingly.
Individual drivers can follow later on.

Thomas Zimmermann (3):
  drm: Add separate state structure for legacy, non-KMS drivers
  drm: Move non-kms driver state into struct drm_legacy_state
  drm: Constify struct drm_driver in DRM core

 drivers/gpu/drm/drm_bufs.c            | 10 +++++-----
 drivers/gpu/drm/drm_context.c         |  9 +++++----
 drivers/gpu/drm/drm_drv.c             | 12 ++++++++----
 drivers/gpu/drm/drm_file.c            |  4 ++--
 drivers/gpu/drm/drm_legacy_misc.c     |  6 +++---
 drivers/gpu/drm/drm_lock.c            |  7 ++++---
 drivers/gpu/drm/drm_pci.c             | 16 ++++++++++------
 drivers/gpu/drm/drm_vblank.c          | 11 ++++++-----
 drivers/gpu/drm/i810/i810_drv.c       | 10 +++++++---
 drivers/gpu/drm/mga/mga_drv.c         | 16 ++++++++++------
 drivers/gpu/drm/nouveau/nouveau_drm.c |  8 ++++++++
 drivers/gpu/drm/r128/r128_drv.c       | 16 ++++++++++------
 drivers/gpu/drm/savage/savage_drv.c   | 12 ++++++++----
 drivers/gpu/drm/sis/sis_drv.c         |  8 ++++++--
 drivers/gpu/drm/tdfx/tdfx_drv.c       |  6 +++++-
 drivers/gpu/drm/via/via_drv.c         | 16 ++++++++++------
 include/drm/drm_device.h              |  2 +-
 include/drm/drm_drv.h                 | 21 +++++----------------
 include/drm/drm_legacy.h              | 27 +++++++++++++++++++++++----
 include/drm/drm_pci.h                 |  4 ++--
 20 files changed, 138 insertions(+), 83 deletions(-)

--
2.25.0

_______________________________________________
dri-devel mailing list
dri-devel@xxxxxxxxxxxxxxxxxxxxx
https://lists.freedesktop.org/mailman/listinfo/dri-devel



[Index of Archives]     [Linux DRI Users]     [Linux Intel Graphics]     [Linux USB Devel]     [Video for Linux]     [Linux Audio Users]     [Yosemite News]     [Linux Kernel]     [Linux SCSI]     [XFree86]     [Linux USB Devel]     [Video for Linux]     [Linux Audio Users]     [Linux Kernel]     [Linux SCSI]     [XFree86]
  Powered by Linux