Support badged SMC caps to restrict SMC function IDs - #589
Open
midnightveil wants to merge 5 commits into
Open
Conversation
This is useful as we are going to add SMC caps and they don't reference PD name/ID, so we need to distinguish them. Signed-off-by: Julia Vassiliki <julia.vassiliki@unsw.edu.au>
midnightveil
force-pushed
the
julia/badged-smc
branch
from
August 11, 2026 00:32
468c32d to
4fb3591
Compare
Needed for new SMC badge changes. Signed-off-by: Julia Vassiliki <julia.vassiliki@unsw.edu.au>
Useful for debugging. Signed-off-by: Julia Vassiliki <julia.vassiliki@unsw.edu.au>
The "smc=true" attribute on a PD would provide an unbadged SMC capability that allows a component to invoke any function exposed by the ARM Secure Monitor. Use our extra capabilities / cap mappings feature to support this. This leaves the "smc=true" still enabled and useable. Signed-off-by: Julia Vassiliki <julia.vassiliki@unsw.edu.au>
Use instead <cap_sc> feature instead for allow-listed function IDs. Signed-off-by: Julia Vassiliki <julia.vassiliki@unsw.edu.au>
midnightveil
force-pushed
the
julia/badged-smc
branch
from
August 11, 2026 00:44
4fb3591 to
c7191ec
Compare
midnightveil
marked this pull request as ready for review
August 11, 2026 02:53
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Note: this contains a breaking change by removing the SMC attribute.
This should be fine, as the 3.0.0 release is planned to be breaking anyway.
This change could be reverted; it is left as a separate commit to make that easy.
The other design choice here was that we do not permit "function_id=0", or some other way to make
badge = 0 <=> unbadged smc capwhich has no allowlisting, instead allowing everything. This is always (in my opinion) a bad design.Review commit-by-commit.