-
Notifications
You must be signed in to change notification settings - Fork 3
Add check script for new entry to qcom-fitimage.its #26
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
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Can we add usage of the script in comments?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
done
check-fitimage-metadata.sh
Outdated
| set -euo pipefail | ||
|
|
||
| ITS_FILE="qcom-fitimage.its" | ||
| META_FILE="qcom-metadata.dts" |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Can we take the file path from user? If not provided, then fallback to these?
|
Analysis:
|
| next | ||
| } | ||
|
|
||
| in_configs && /^\}/ { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Checking only "}" for end of the node might be causing issues if the "}" is not properly added in new line?
Can we check number of braces instead?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thanks for pointing out. Added support for syntax check for qcom-metadata.dtb before starting string comparison.
Usage:
- for any config entry added to .its, the substrings used as part of each compatibles are checked if those are part of metadata or not.
- metadata syntax vallidation using dtc tool.
For each configuration subnode in qcom-fitimage.its:
- read its "compatible" property
- strip "qcom," prefix
- split the remaining string on "-"
- verify that each resulting substring exists as a subnode name
in qcom-metadata.dts
Output:
- If everything passes: "success"
- If any missing: one line per miss:
fail <substring> <config_subnode_name>
Signed-off-by: Amrit Anand <amrianan@qti.qualcomm.com>
|
The syntax for FIT ITS image is not being checked with the current version, otherwise LGTM. |
quic-kaushalk
left a comment
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Overall changes look fine. Naina, as discussed regarding syntax for FIT ITS image not being checked with the current version, we can keep track of it via a github issue in this project.
For each configuration subnode in qcom-fitimage.its:
Output: