drm/todo: Drop todo item to request memory regions in all fbdev drivers
Subsystems (4)
Helge Deller
maintainerPATCH 1/1 drm/todo: Drop todo item to request memory regions in all fbdev drivers
This item is tagged for beginners, so often people not familiar with the fbdev drivers think this is an easy task, start up their AI tools and blindly send in the generated code as patches.
The problem:
- Those patches often introduce bugs, so
- ideally want the code tested, since ressource misconfigurations often lead to failing drivers
- The patches are often unnecessary, since in the old machines with the old graphic cards resource conflicts usually don't happen as only one graphic card can be used at a time anyway.
- and today most relevant drivers have necessary patches already implemented.
So, let's get rid of this todo item and silence the steady stream of stupid patches.
--- Documentation/gpu/todo.rst | 16 ---------------- 1 file changed, 16 deletions(-)
Documentation/gpu/todo.rst +0 -16
@@ -448,22 +448,6 @@ Contact: Thomas Zimmermann <[email protected]> Level: Intermediate -Request memory regions in all fbdev drivers --------------------------------------------- - -Old/ancient fbdev drivers do not request their memory properly. -Go through these drivers and add code to request the memory regions -that the driver uses. This requires adding calls to request_mem_region(), -pci_request_region() or similar functions. Use helpers for managed cleanup -where possible. Problematic areas include hardware that has exclusive ranges -like VGA. VGA16fb does not request the range as it is expected. -Drivers are pretty bad at doing this and there used to be conflicts among -DRM and fbdev drivers. Still, it's the correct thing to do. - -Contact: Thomas Zimmermann <[email protected]> - -Level: Starter - Remove driver dependencies on FB_DEVICE ---------------------------------------
Signature · 1 line
2.53.0
Hi Helge,
Quoted 7 lines · Helge Deller
This item is tagged for beginners, so often people not familiar with the fbdev drivers think this is an easy task, start up their AI tools and blindly send in the generated code as patches.
The problem:
- Those patches often introduce bugs, so
- ideally want the code tested, since ressource misconfigurations
resource
Quoted 11 lines
often lead to failing drivers
- The patches are often unnecessary, since in the old machines with the old graphic cards resource conflicts usually don't happen as only one graphic card can be used at a time anyway.
- and today most relevant drivers have necessary patches already implemented.So, let's get rid of this todo item and silence the steady stream of stupid patches.
Signed-off-by Helge Deller <[email protected]>
Thanks for your patch!
Quoted 11 lines
Documentation/gpu/todo.rst +0
-5@@ -448,22 +448,6 @@ Contact: Thomas Zimmermann <[email protected]> Level: Intermediate -Request memory regions in all fbdev drivers --------------------------------------------- - -Old/ancient fbdev drivers do not request their memory properly. -Go through these drivers and add code to request the memory regions
Documentation/gpu/todo.rst Contact: Thomas Zimmermann <[email protected]> · line 465
Quoted 10 lines
Documentation/gpu/todo.rst +0
-10-that the driver uses. This requires adding calls to request_mem_region(), -pci_request_region() or similar functions. Use helpers for managed cleanup -where possible. Problematic areas include hardware that has exclusive ranges -like VGA. VGA16fb does not request the range as it is expected. -Drivers are pretty bad at doing this and there used to be conflicts among -DRM and fbdev drivers. Still, it's the correct thing to do. - -Contact: Thomas Zimmermann <[email protected]> - -Level: Starter
I am not really against keeping this item. But as the related changes are not pure refactorings, and cause a change in behavior, they _must_ be tested on actual hardware. I guess making that explicit would be a bit silly (heck, all changes should be tested). And bumping the level to intermediate might send the wrong message, too (starters don't need to test? Doh...)
Thomas: do we still any hardware for which there exist both DRM and fbdev drivers, and the resource management is missing in the fbdev drivers?
Documentation/gpu/todo.rst Contact: Thomas Zimmermann <[email protected]> · line 453
Quoted 4 lines
Documentation/gpu/todo.rst +0
-1- Remove driver dependencies on FB_DEVICE ---------------------------------------
Gr{oetje,eeting}s,
Geert
Signature · 5 lines
Geert Uytterhoeven -- There's lots of Linux beyond ia32 -- [email protected] In personal conversations with technical people, I call myself a hacker. But when I'm talking to journalists I just say "programmer" or something like that. -- Linus Torvalds
Thomas Zimmermann
maintainerHi
Quoted 10 lines
Documentation/gpu/todo.rst Contact: Thomas Zimmermann <[email protected]> · line 465
Quoted 3 lines
Documentation/gpu/todo.rst +0
-3-Contact: Thomas Zimmermann <[email protected]> - -Level: StarterI am not really against keeping this item. But as the related changes are not pure refactorings, and cause a change in behavior, they _must_ be tested on actual hardware. I guess making that explicit would be a bit silly (heck, all changes should be tested). And bumping the level to intermediate might send the wrong message, too (starters don't need to test? Doh...)
Quoted 3 lines
Thomas: do we still any hardware for which there exist both DRM and fbdev drivers, and the resource management is missing in the fbdev drivers?
See my other reply on why this item exists. It's also about hand-over during boot up, which could affect any/most driver.
We can remove the item now, if that helps, but it might lead to other bug reports later on.
Best regards
Thomas
Quoted 9 lines
Quoted 5 lines
-
Remove driver dependencies onFB_DEVICE
---------------------------------------Gr{oetje,eeting}s,
Geert
Signature · 6 lines
-- Thomas Zimmermann Graphics Driver Developer SUSE Software Solutions Germany GmbH Frankenstr. 146, 90461 Nürnberg, Germany, www.suse.com GF: Jochen Jaser, Andrew McDonald, Werner Knoblich, (HRB 36809, AG Nürnberg)
Helge Deller
maintainerQuoted 12 lines · Thomas Zimmermann
Hi
Quoted 10 lines
Documentation/gpu/todo.rst Contact: Thomas Zimmermann <[email protected]> · line 465
Quoted 3 lines
Documentation/gpu/todo.rst +0
-3-Contact: Thomas Zimmermann <[email protected]> - -Level: StarterI am not really against keeping this item. But as the related changes are not pure refactorings, and cause a change in behavior, they _must_ be tested on actual hardware. I guess making that explicit would be a bit silly (heck, all changes should be tested). And bumping the level to intermediate might send the wrong message, too (starters don't need to test? Doh...)
Quoted 8 lines
Quoted 3 lines
Thomas: do we still any hardware for which there exist both DRM and fbdev drivers, and the resource management is missing in the fbdev drivers?
See my other reply on why this item exists. It's also about hand- over during boot up, which could affect any/most driver.
We can remove the item now, if that helps, but it might lead to other bug reports later on.
Thanks, I'll remove the item now.
In case we run into reports later on, I'm happy to work with you on them then.
Can I add an Acked-by from you?
Helge
Thomas Zimmermann
maintainerHi
Am 24.04.26 um 10:36 schrieb Helge Deller:
Quoted 20 lines · Thomas Zimmermann
Quoted 19 lines
Hi
Quoted 10 lines
Documentation/gpu/todo.rst Contact: Thomas Zimmermann <[email protected]> · line 465
Quoted 3 lines
Documentation/gpu/todo.rst +0
-3-Contact: Thomas Zimmermann <[email protected]> - -Level: StarterI am not really against keeping this item. But as the related changes are not pure refactorings, and cause a change in behavior, they _must_ be tested on actual hardware. I guess making that explicit would be a bit silly (heck, all changes should be tested). And bumping the level to intermediate might send the wrong message, too (starters don't need to test? Doh...)
Quoted 3 lines
Thomas: do we still any hardware for which there exist both DRM and fbdev drivers, and the resource management is missing in the fbdev drivers?
See my other reply on why this item exists. It's also about hand- over during boot up, which could affect any/most driver.
Quoted 6 lines
Quoted 1 line
We can remove the item now, if that helps, but it might lead to other bug reports later on.
Thanks, I'll remove the item now.
In case we run into reports later on, I'm happy to work with you on them then.Can I add an Acked-by from you?
No. I think I made my point clear why this item exists. We can talk about how to handle these old drivers (staging, removal, fixing, etc), but pretending it's all well will not solve any issues.
Best regards
Thomas
Quoted 2 lines
Helge
Signature · 6 lines
-- Thomas Zimmermann Graphics Driver Developer SUSE Software Solutions Germany GmbH Frankenstr. 146, 90461 Nürnberg, Germany, www.suse.com GF: Jochen Jaser, Andrew McDonald, Werner Knoblich, (HRB 36809, AG Nürnberg)
Thomas Zimmermann
maintainerHi
Am 23.04.26 um 22:55 schrieb Helge Deller:
Quoted 14 lines
This item is tagged for beginners, so often people not familiar with the fbdev drivers think this is an easy task, start up their AI tools and blindly send in the generated code as patches.
The problem:
- Those patches often introduce bugs, so
- ideally want the code tested, since ressource misconfigurations often lead to failing drivers
- The patches are often unnecessary, since in the old machines with the old graphic cards resource conflicts usually don't happen as only one graphic card can be used at a time anyway.
- and today most relevant drivers have necessary patches already implemented.
Quoted 2 lines
So, let's get rid of this todo item and silence the steady stream of stupid patches.
I see that AI patches can be problematic, but reserving these regions is still the correct thing to do. Removing the TODO item will not change that.
Some background on why this item exists: we currently use aperture helpers [1] to manage ownership of the framebuffer memory during boot up. This is necessary to switch from the system-framebuffer driver (i..e, simplefb, simpledrm, etc) to the hardware's native driver. But this is all ad-hoc because Linux' resource management doesn't do this for us. Before we can integrate any such functionality, we have to fix all drivers to reserve their resources correctly.
If we remove the TODO item, we'd likely still want to move forward with improving resource management. If that breaks unfixed fbdev drivers, users would then also send bug reports.
And the other point is (again) that if there are no means of testing a driver and no information whether a driver is actually in used by anyone, it's maybe time to remove the driver.
[1] https://elixir.bootlin.com/linux/v7.0.1/source/drivers/video/aperture.c#L17
Best regards
Thomas
Quoted 33 lines
Signed-off-by Helge Deller <[email protected]>--- Documentation/gpu/todo.rst | 16 ---------------- 1 file changed, 16 deletions(-)Documentation/gpu/todo.rst +0
-16@@ -448,22 +448,6 @@ Contact: Thomas Zimmermann <[email protected]> Level: Intermediate -Request memory regions in all fbdev drivers --------------------------------------------- - -Old/ancient fbdev drivers do not request their memory properly. -Go through these drivers and add code to request the memory regions -that the driver uses. This requires adding calls to request_mem_region(), -pci_request_region() or similar functions. Use helpers for managed cleanup -where possible. Problematic areas include hardware that has exclusive ranges -like VGA. VGA16fb does not request the range as it is expected. -Drivers are pretty bad at doing this and there used to be conflicts among -DRM and fbdev drivers. Still, it's the correct thing to do. - -Contact: Thomas Zimmermann <[email protected]> - -Level: Starter - Remove driver dependencies on FB_DEVICE ---------------------------------------
Signature · 6 lines
-- Thomas Zimmermann Graphics Driver Developer SUSE Software Solutions Germany GmbH Frankenstr. 146, 90461 Nürnberg, Germany, www.suse.com GF: Jochen Jaser, Andrew McDonald, Werner Knoblich, (HRB 36809, AG Nürnberg)
Helge Deller
maintainerQuoted 17 lines · Thomas Zimmermann
Hi
Am 23.04.26 um 22:55 schrieb Helge Deller:
Quoted 14 lines
This item is tagged for beginners, so often people not familiar with the fbdev drivers think this is an easy task, start up their AI tools and blindly send in the generated code as patches.
The problem:
- Those patches often introduce bugs, so
- ideally want the code tested, since ressource misconfigurations often lead to failing drivers
- The patches are often unnecessary, since in the old machines with the old graphic cards resource conflicts usually don't happen as only one graphic card can be used at a time anyway.
- and today most relevant drivers have necessary patches already implemented.
Quoted 6 lines
Quoted 2 lines
So, let's get rid of this todo item and silence the steady stream of stupid patches.
I see that AI patches can be problematic, but reserving these regions is still the correct thing to do. Removing the TODO item will not change that.
Sure.
Quoted 9 lines
Some background on why this item exists: we currently use aperture helpers [1] to manage ownership of the framebuffer memory during boot up. This is necessary to switch from the system-framebuffer driver (i..e, simplefb, simpledrm, etc) to the hardware's native driver. But this is all ad-hoc because Linux' resource management doesn't do this for us. Before we can integrate any such functionality, we have to fix all drivers to reserve their resources correctly.
Quoted 3 lines
If we remove the TODO item, we'd likely still want to move forward with improving resource management. If that breaks unfixed fbdev drivers, users would then also send bug reports.
Ok for me.
Helge
Quoted 39 lines
And the other point is (again) that if there are no means of testing a driver and no information whether a driver is actually in used by anyone, it's maybe time to remove the driver.
[1] https://elixir.bootlin.com/linux/v7.0.1/source/drivers/video/aperture.c#L17
Best regards
ThomasQuoted 30 lines
Signed-off-by Helge Deller <[email protected]>---
Documentation/gpu/todo.rst| 16 ----------------1 file changed, 16 deletions(-)Documentation/gpu/todo.rst +0
-0@@ -448,22 +448,6 @@ Contact: Thomas Zimmermann <[email protected]>Level: Intermediate
Documentation/gpu/todo.rst +0
-16-Request memory regions in all fbdev drivers --------------------------------------------- - -Old/ancient fbdev drivers do not request their memory properly. -Go through these drivers and add code to request the memory regions -that the driver uses. This requires adding calls to request_mem_region(), -pci_request_region() or similar functions. Use helpers for managed cleanup -where possible. Problematic areas include hardware that has exclusive ranges -like VGA. VGA16fb does not request the range as it is expected. -Drivers are pretty bad at doing this and there used to be conflicts among -DRM and fbdev drivers. Still, it's the correct thing to do. - -Contact: Thomas Zimmermann <[email protected]> - -Level: Starter -Remove driver dependencies on
FB_DEVICE
---------------------------------------