Re: [PATCH 1/9] drm/simpledrm: Use fbdev defaults for shadow buffering

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

 



Hi

Am 08.03.22 um 10:31 schrieb Javier Martinez Canillas:
On 3/3/22 21:58, Thomas Zimmermann wrote:
Don't select shadow buffering for the fbdev console explicitly. The
fbdev emulation's heuristic will enable it for any framebuffer with
.dirty callback.


Indeed it does. Not related to your series but looking at this
patch I noticed that drivers/gpu/drm/tiny/bochs.c will be the
only driver that sets .prefer_shadow_fbdev after this lands.

The driver is using GEM so I wonder if after your series this
DRM driver could have a .dirty callback and the field just be
dropped? Or there would still be a case where it is needed ?
Bochs uses VRAM helpers (i.e., TTM). Fbdev and userspace would directly write into that buffer memory without a copy. So the dirty function would be empty.

Other drivers with VRAM helpers (e.g., hibmc, ast) operate on uncached I/O memory AFAICT. So they set .prefer_shadow, which also affects userspace. Bochs uses cached memory and shouldn't need prefer_shadow. Setting prefer_shadow_fbdev is only there for making the fbdev buffer object evictable from video memory.

As it stands, using prefer_shadow_fbdev is the cleanest solution, even if bochs is the only user of that field.

Alternatively, we could make it a requirement that qemu provides enough video memory for bochs to unconditionally pin the fbdev BO there without ever evicting. I guess, that would mean 32 MiB of VRAM at least.

Best regards
Thomas


Anyway, just wanted to mention in case I forget later.

Your patch looks good to me and I think it could be pushed
without waiting for the other patches in the series.

Reviewed-by: Javier Martinez Canillas <javierm@xxxxxxxxxx>


--
Thomas Zimmermann
Graphics Driver Developer
SUSE Software Solutions Germany GmbH
Maxfeldstr. 5, 90409 Nürnberg, Germany
(HRB 36809, AG Nürnberg)
Geschäftsführer: Ivo Totev

Attachment: OpenPGP_signature
Description: OpenPGP digital signature


[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