Comments (2)
Sorry, I haven't replied in so long, I managed to miss this report.
As I recall the runtime overlays (as opposed to dtc compile time overlays) weren't really built to use non-symbol references. But I don't see any reason this shouldn't work.
Your patch looks correct, but isn't ideal. A reference starting with '/' must always be a path, not a symbol, so you should chek for that first, before attempting to resolve it as a symbol.
If you could send a patch to the mailing list, or make up a pull request with a proper commit message that would be great.
from dtc.
I do not know much about the dtc code but this was the issue I wanted to solve:
I am tinkering in an environment of a Fedora LXQt desktop on an arm imx6 platform. The distribution kernels come with several hundred dtb files. Rightfully without symbols compiled in to keep the size as small as possible. The need by anyone to apply overlays is quite sparse if at all. So every time a kernel update came in, I had to pull in the kernel sources, apply some dts patch to enable e.g. an attached camera and compile the dtb. This step has to be repeated if you want to apply several components in variing combinations. Those dts patches can't even land in mainline cause there individual manner. Current overlays can also not land in mainline as they can't be always applied against a dtb without symbols.
With "target_path" I was able to compose some overlays that could be applied with fdtoverlay to a dtb without symbols. But as soon as a label notion for a reference to another node in a cell array came into play I had lost.
While researching some other aspect of dts syntax I stumbled over the full path notion and realized this could solve my issue. Compiling an overlay with this syntax let the dtbo earn exact the information that fdtoverlay tries to acquire with the symbol resolution. So it was a small step to short-circuit the resolution in fdtoverlay with my provided patch as the "/" as first symbol character marks this situation.
Nowadays, if a kernel update comes in, I have only to do "fdtoverlay -i imx6q-hummingboard.dtb -o imx6q-hummingboard.dtb imx6q-hummingboard-pcam5c.dtbo" and I am done. Doing several flavors with different overlays is also a no-brainer.
With this feature in mainline dtc such overlays have even potential to land in mainline for general consumption. The "included symbols" constraint is removed and they can always be applied against a base dtb without any prior overlay preparation. As you say it can potentially work also with runtime overlays, even better.
Unfortunately I don't have the skill to implement it the proper way, so don't hesitate to take my proposal forward and make the world a little easier. If there shows up some proper implementation I am willingly prepared to do testing and give feedback.
from dtc.
Related Issues (20)
- Multiple-definition of fdt target in Meson definitions HOT 6
- unit_address_vs_reg: Wrong warning for /memory node HOT 3
- fdt.c crashes at absoffset = offset + fdt_off_dt_struct(fdt); HOT 6
- how can I download the archive inside debootstrap environment HOT 3
- `testCreate`/`testReserveMap` fails with Python 3.12 HOT 12
- python extension build with meson is always quiet HOT 2
- python extension rebuilt during meson's install phase HOT 6
- Improve dtdiff by avoiding or nulling the phandles HOT 11
- Char subscript error in Cygwin HOT 4
- 0xFFFFFFFF00000000 parsed as 32 bit HOT 5
- New release planned? HOT 8
- last commit breaks building the Python bindings HOT 2
- pylibfdt bindings cryptically fail to build with some build environments HOT 3
- Enabling -Wwrite-strings causes a number of warnings HOT 2
- README.md has no instructions for building with meson HOT 2
- Meson tests fail HOT 3
- 1.7.0-Testsuite-Error HOT 1
- 'struct fdt_header' has no member named [name] HOT 2
- 1.7.0: install target fails on HOT 10
- Apply multiple DTB overlays to create single DTB file? HOT 2
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from dtc.