dentproject / dentOS

dentOS SwitchDev based NOS
Other
199 stars 58 forks source link

import dts(i) files from kernel tree #286

Open KanjiMonster opened 9 months ago

KanjiMonster commented 9 months ago

The DentOS own DTS files are in no shape to be upstreamed, and there likely is no one willing to spend the effort to do so, so there is no good reason to carry them as commits for the kernel source.

Instead provide them within the build system, as they are independent from the kernel.

This also makes it easier to provide new device support without the need to update the kernel, or atomic changes of device drivers and the associated device trees.

KanjiMonster commented 9 months ago

Tested by slightly modifying one device tree file in the tree and then checking if the change was propagated into the image.

I'm not totally happy with the kernel-specific path, but then again by the time we switch to a different kernel we might already moved on to Yocto anyway.

paulmenzel commented 9 months ago

My understanding of dentOS is, that everything should go upstream.

paulmenzel commented 9 months ago

… and contributions should adhere to Linux’ upstream standards.

KanjiMonster commented 9 months ago

In general I would agree with you, but I do not see anyone attempting to do so for the device tree files, and as they also rely on out-of-tree drivers that are far from an upstreamable shape. So the reality is that this won't happen anytime soon, if it even ever happens.

Upstreaming "legacy" third party code/files is clerical, unsexy work. I fear noone wants to pay for that. Or have their own people with the appropriate skills and perseverance for that.

Apart from that devicetrees are the one component that can actually be easily built outside of the kernel and don't rely on a specific kernel version1, so there it is a-okay to exist outside of it.

So this PR is the acceptance of this state and for now making it easier to add newer device support (also allows better seeing the dts in context with the drivers added).

1The expectation is usually that older dtbs work with newer kernels, but there is no guarantee that newer dtbs work with older kernels.

KanjiMonster commented 9 months ago

… and contributions should adhere to Linux’ upstream standards.

I could try to enforce that, but I fear I would then scare away any remaining parties interested in this project.