-
Notifications
You must be signed in to change notification settings - Fork 7k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
[Doc] How to link dts bindings with Kconfig flags #29779
Comments
I did some prototyping on this last night. So far I have a way for drivers to declare (via Doxygen) what devicetree compatibles they support, and build an index mapping compatible(s) <-> driver(s) from that. Note that this map can be many-to-many. It's not a function. A single compatible can be handled by multiple drivers. A single driver can handle multiple compatibles. Next steps are to generate documentation pages for these drivers and include the detailed description (again from Doxygen) into the Sphinx pages. I verified that the usual ways of embedding restructured text work. That allows us to say something like this in a driver file comment:
And the I will post a proof of concept sometime this week. |
cc @pabigot |
I'm fine with the approach! Txs @mbolivar-nordic. |
Sure, I'm happy to discuss and add CI checks like that depending on what subsystem maintainers decide should be required for driver documentation. |
Sorry for the delay, but here is a draft: #30104 There is a new "device drivers" index that pulls in Doxygen content from driver sources. It's at top level and is available on the sidebar. |
any comments on this? |
It's in my TODO list, sorry for the delay. |
Hi @carlescufi, @kartben, This issue, marked as an Enhancement, was opened a while ago and did not get any traction. It was just assigned to you based on the labels. If you don't consider yourself the right person to address this issue, please re-assing it to the right person. Please take a moment to review if the issue is still relevant to the project. If it is, please provide feedback and direction on how to move forward. If it is not, has already been addressed, is a duplicate, or is no longer relevant, please close it with a short comment explaining the reason. @erwango you are also encouraged to help moving this issue forward by providing additional information and confirming this request/issue is still relevant to you. Thanks! |
@kartben Feel free to close if this looks as a duplicate or if direction is not the good one |
Is your enhancement proposal related to a problem? Please describe.
DTS bindings are now available in zephyr documentation (https://docs.zephyrproject.org/latest/reference/devicetree/bindings.html)
and maintainers have a way to document these important pieces of driver configuration.
The last important missing piece of information is to indicate how a driver should be enabled, operation typically achieved using Kconfig flags.
This piece of info would would be missing to automatize generation of supported features in boards documentation (cf #29652).
One easy way to get this link would be to document drivers matching Kconfig flag in dts bindings flag directly.
But, as said @mbolivar-nordic: "kind of defeats the 'OS independent' goal for bindings IMO".
So I'm raising this issue in order to reach an agreement on how to document dts bindings Kconfig relation w/o breaking OS independent promises.
The text was updated successfully, but these errors were encountered: