Hi Am 26.04.23 um 16:56 schrieb Geert Uytterhoeven:
Hi Thomas, On Tue, Apr 25, 2023 at 4:28 PM Thomas Zimmermann <tzimmermann@xxxxxxx> wrote:Push the test for info->screen_base from fb_read() and fb_write() into the implementations of struct fb_ops.{fb_read,fb_write}. In cases where the driver operates on info->screen_buffer, test this field instead. Signed-off-by: Thomas Zimmermann <tzimmermann@xxxxxxx>Thanks for your patch! You forgot to mention why it is a good idea to duplicate this in all the implementations, instead of doing it once in the core?drivers/video/fbdev/cobalt_lcdfb.c | 6 ++++++ drivers/video/fbdev/core/fb_sys_fops.c | 6 ++++++ drivers/video/fbdev/core/fbmem.c | 10 ++++++++-- drivers/video/fbdev/sm712fb.c | 4 ++-- 4 files changed, 22 insertions(+), 4 deletions(-)Aren't there more fbdev drivers to fix, before you can move the checks in drivers/video/fbdev/core/fbmem.c?
I've found a few. And I've also found quite a number of drivers that use screen_base when they should use screen_buffer instead. I'll fix them as well.
Best regards Thomas
Gr{oetje,eeting}s, Geert
-- Thomas Zimmermann Graphics Driver Developer SUSE Software Solutions Germany GmbH Frankenstrasse 146, 90461 Nuernberg, Germany GF: Ivo Totev, Andrew Myers, Andrew McDonald, Boudien Moerman HRB 36809 (AG Nuernberg)
Attachment:
OpenPGP_signature
Description: OpenPGP digital signature