Intel-GFX Archive on lore.kernel.org
 help / color / mirror / Atom feed
From: Thomas Zimmermann <tzimmermann@suse.de>
To: daniel@ffwll.ch, airlied@gmail.com, deller@gmx.de, javierm@redhat.com
Cc: linux-fbdev@vger.kernel.org, intel-gfx@lists.freedesktop.org,
	linux-hyperv@vger.kernel.org, amd-gfx@lists.freedesktop.org,
	dri-devel@lists.freedesktop.org,
	Thomas Zimmermann <tzimmermann@suse.de>,
	linux-arm-kernel@lists.infradead.org
Subject: [Intel-gfx] [PATCH 00/18] drm, fbdev: Remove apertures structure and FBINFO_MISC_FIRMWARE
Date: Mon, 19 Dec 2022 17:04:58 +0100	[thread overview]
Message-ID: <20221219160516.23436-1-tzimmermann@suse.de> (raw)

Remove struct fb_info.apertures and FBINFO_MISC_FIRMWARE from fbdev
and handle the aperture ownership without involving the fbdev core.

The apertures field in struct fb_info is a remnant from earlier
ownership management for framebuffer apertures. When fbdev core code
still handled ownership of the framebuffer among fbdev device drivers,
generic drivers set the aperture ranges to claim the firmware scanout
buffer for themselves.

Now that we have a module with helpers that manage aperture and
framebuffer ownership among drivers, the aperture field is not needed
any longer. In fact, several drivers set this field, even though they
are not generic fbdev drivers. Only drivers that set FBINFO_MISC_FIRMWARE
can use apertures in a meaningful way.

To remove FBINFO_MISC_FIRMWARE, patches 1 and 2 remove it from fbcon. It
was used to work around issues with font loading. That is now all handled
in userspace.

Patches 3 to 9 remove aperture setup from all non-generic drivers. These
drivers are not for firmware graphics and do not have to set the values.
For DRM, we do not need to allocate the apertures field any longer.

Patches 10 to 17 update all generic fbdev drivers to manage aperture
ownership by themselves by called Linux aperture helpers. The setup of
the apertures field and setting FBINFO_MISC_FIRMWARE is being removed as
a result of that.

With all of its users gone, patch 18 removes FBINFO_MISC_FIRMWARE, struct
fb_info.apertures and the fbdev core's aperture code.

Tested with handover combinations of efifb, simpledrm and radeon.

Thomas Zimmermann (18):
  fbcon: Remove trailing whitespaces
  Revert "fbcon: don't lose the console font across generic->chip driver
    switch"
  drm/gma500: Do not set struct fb_info.apertures
  drm/i915: Do not set struct fb_info.apertures
  drm/radeon: Do not set struct fb_info.apertures
  drm/fb-helper: Do not allocate unused apertures structure
  fbdev/clps711x-fb: Do not set struct fb_info.apertures
  fbdev/hyperv-fb: Do not set struct fb_info.apertures
  vfio-mdev/mdpy-fb: Do not set struct fb_info.apertures
  fbdev/efifb: Add struct efifb_par for driver data
  fbdev/efifb: Do not use struct fb_info.apertures
  fbdev/offb: Allocate struct offb_par with framebuffer_alloc()
  fbdev/offb: Do not use struct fb_info.apertures
  fbdev/simplefb: Do not use struct fb_info.apertures
  fbdev/vesafb: Remove trailing whitespaces
  fbdev/vesafb: Do not use struct fb_info.apertures
  fbdev/vga16fb: Do not use struct fb_info.apertures
  drm/fbdev: Remove aperture handling and FBINFO_MISC_FIRMWARE

 drivers/gpu/drm/drm_fb_helper.c            | 20 ++---------
 drivers/gpu/drm/gma500/framebuffer.c       |  5 ---
 drivers/gpu/drm/i915/display/intel_fbdev.c |  7 ----
 drivers/gpu/drm/radeon/radeon_fb.c         |  4 ---
 drivers/video/fbdev/clps711x-fb.c          | 10 +-----
 drivers/video/fbdev/core/fbcon.c           | 41 ++++++++++------------
 drivers/video/fbdev/core/fbmem.c           | 33 -----------------
 drivers/video/fbdev/core/fbsysfs.c         |  1 -
 drivers/video/fbdev/efifb.c                | 35 +++++++++++-------
 drivers/video/fbdev/hyperv_fb.c            | 17 ++++-----
 drivers/video/fbdev/offb.c                 | 33 +++++++++--------
 drivers/video/fbdev/simplefb.c             | 19 +++++-----
 drivers/video/fbdev/vesafb.c               | 37 ++++++++++---------
 drivers/video/fbdev/vga16fb.c              | 15 +++-----
 include/linux/fb.h                         | 22 ------------
 samples/vfio-mdev/mdpy-fb.c                |  8 -----
 16 files changed, 99 insertions(+), 208 deletions(-)


base-commit: d322881f7e33af24901ee8ccaec3beef82f21203
prerequisite-patch-id: c2b2f08f0eccc9f5df0c0da49fa1d36267deb11d
prerequisite-patch-id: c67e5d886a47b7d0266d81100837557fda34cb24
prerequisite-patch-id: 3f204510fcbf9530d6540bd8e6128cce598988b6
-- 
2.39.0


             reply	other threads:[~2022-12-19 16:07 UTC|newest]

Thread overview: 41+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2022-12-19 16:04 Thomas Zimmermann [this message]
2022-12-19 16:04 ` [Intel-gfx] [PATCH 01/18] fbcon: Remove trailing whitespaces Thomas Zimmermann
2022-12-20  9:10   ` Javier Martinez Canillas
2022-12-19 16:05 ` [Intel-gfx] [PATCH 02/18] Revert "fbcon: don't lose the console font across generic->chip driver switch" Thomas Zimmermann
2022-12-20  9:17   ` Javier Martinez Canillas
2022-12-19 16:05 ` [Intel-gfx] [PATCH 03/18] drm/gma500: Do not set struct fb_info.apertures Thomas Zimmermann
2022-12-20  9:18   ` Javier Martinez Canillas
2022-12-19 16:05 ` [Intel-gfx] [PATCH 04/18] drm/i915: " Thomas Zimmermann
2022-12-20  9:19   ` Javier Martinez Canillas
2022-12-19 16:05 ` [Intel-gfx] [PATCH 05/18] drm/radeon: " Thomas Zimmermann
2022-12-20  9:19   ` Javier Martinez Canillas
2022-12-19 16:05 ` [Intel-gfx] [PATCH 06/18] drm/fb-helper: Do not allocate unused apertures structure Thomas Zimmermann
2022-12-20  9:22   ` Javier Martinez Canillas
2022-12-19 16:05 ` [Intel-gfx] [PATCH 07/18] fbdev/clps711x-fb: Do not set struct fb_info.apertures Thomas Zimmermann
2022-12-20  9:24   ` Javier Martinez Canillas
2022-12-19 16:05 ` [Intel-gfx] [PATCH 08/18] fbdev/hyperv-fb: " Thomas Zimmermann
2022-12-20  9:24   ` Javier Martinez Canillas
2022-12-29 15:57   ` Michael Kelley (LINUX)
2022-12-19 16:05 ` [Intel-gfx] [PATCH 09/18] vfio-mdev/mdpy-fb: " Thomas Zimmermann
2022-12-20  9:32   ` Javier Martinez Canillas
2023-01-03 13:54     ` Thomas Zimmermann
2022-12-19 16:05 ` [Intel-gfx] [PATCH 10/18] fbdev/efifb: Add struct efifb_par for driver data Thomas Zimmermann
2022-12-20  9:33   ` Javier Martinez Canillas
2022-12-19 16:05 ` [Intel-gfx] [PATCH 11/18] fbdev/efifb: Do not use struct fb_info.apertures Thomas Zimmermann
2022-12-20  9:35   ` Javier Martinez Canillas
2022-12-19 16:05 ` [Intel-gfx] [PATCH 12/18] fbdev/offb: Allocate struct offb_par with framebuffer_alloc() Thomas Zimmermann
2022-12-20  9:37   ` Javier Martinez Canillas
2022-12-19 16:05 ` [Intel-gfx] [PATCH 13/18] fbdev/offb: Do not use struct fb_info.apertures Thomas Zimmermann
2022-12-20  9:38   ` Javier Martinez Canillas
2022-12-19 16:05 ` [Intel-gfx] [PATCH 14/18] fbdev/simplefb: " Thomas Zimmermann
2022-12-20  9:40   ` Javier Martinez Canillas
2022-12-19 16:05 ` [Intel-gfx] [PATCH 15/18] fbdev/vesafb: Remove trailing whitespaces Thomas Zimmermann
2022-12-20  9:40   ` Javier Martinez Canillas
2022-12-19 16:05 ` [Intel-gfx] [PATCH 16/18] fbdev/vesafb: Do not use struct fb_info.apertures Thomas Zimmermann
2022-12-20  9:43   ` Javier Martinez Canillas
2022-12-19 16:05 ` [Intel-gfx] [PATCH 17/18] fbdev/vga16fb: " Thomas Zimmermann
2022-12-20  9:44   ` Javier Martinez Canillas
2022-12-19 16:05 ` [Intel-gfx] [PATCH 18/18] drm/fbdev: Remove aperture handling and FBINFO_MISC_FIRMWARE Thomas Zimmermann
2022-12-20  9:46   ` Javier Martinez Canillas
2022-12-22  8:12 ` [Intel-gfx] ✓ Fi.CI.BAT: success for drm, fbdev: Remove apertures structure and FBINFO_MISC_FIRMWARE (rev2) Patchwork
2022-12-22 13:26 ` [Intel-gfx] ✓ Fi.CI.IGT: " Patchwork

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=20221219160516.23436-1-tzimmermann@suse.de \
    --to=tzimmermann@suse.de \
    --cc=airlied@gmail.com \
    --cc=amd-gfx@lists.freedesktop.org \
    --cc=daniel@ffwll.ch \
    --cc=deller@gmx.de \
    --cc=dri-devel@lists.freedesktop.org \
    --cc=intel-gfx@lists.freedesktop.org \
    --cc=javierm@redhat.com \
    --cc=linux-arm-kernel@lists.infradead.org \
    --cc=linux-fbdev@vger.kernel.org \
    --cc=linux-hyperv@vger.kernel.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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox