this post was submitted on 03 Sep 2023
340 points (100.0% liked)
Programming
423 readers
1 users here now
Welcome to the main community in programming.dev! Feel free to post anything relating to programming here!
Cross posting is strongly encouraged in the instance. If you feel your post or another person's post makes sense in another community cross post into it.
Hope you enjoy the instance!
Rules
Rules
- Follow the programming.dev instance rules
- Keep content related to programming in some way
- If you're posting long videos try to add in some form of tldr for those who don't want to watch videos
Wormhole
Follow the wormhole through a path of communities !webdev@programming.dev
founded 1 year ago
MODERATORS
you are viewing a single comment's thread
view the rest of the comments
view the rest of the comments
I am actually arguing for a stable ABI.
The few times I have had to compile out of tree drivers for the linux kernel its usually failed because the ABI has changed.
Each time I have looked into it, I found code churn, e.g. changing an enum to a char (or the other way) or messing with the parameter order.
If I was empire of the world, the linux kernel would be built using conan.io, with device trees pulling down drivers as dependencies.
The Linux ABI Headers would move out into their own seperately managed project. Which is released and managed at its own rate. Subsystem maintainers would have to raise pull requests to change the ABI and changing a parameter from enum to char because you prefer chars wouldn't be good enough.
Each subsystem would be its own "project" and with a logical repository structure (e.g. intel and amd gpu drivers don't share code so why would they be in the same repo?) And built against the appropriate ABI version with each repository released at its own rate.
Unsupported drivers would then be forked into their own repositories. This simplifies depreciation since its external to the supported drivers and doesn't need to be refactored or maintained. If distributions can build them and want to include the driver they can.
Linus job would be to maintain the core kernel, device trees and ABI projects and provide a bill of materials for a selection of linux kernel/abi/drivers version which are supported.
Lastly since every driver is a descrete buildable component, it would make it far easier for distributions to check if the driver is compatible (e.g. change a dependency version and build) with the kernel ABI they are using and provide new drivers with the build.
None of this will ever happen. C/C++ developers loath dependency management and people can ve stringly attached to mono repos for some reason.