Skip to content
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

RVA_020: Provide additional context for Ssccfg #21

Merged
merged 1 commit into from
Aug 31, 2024

Conversation

punitagrawal
Copy link

The privileged specification includes a chapter about "Smcdeleg" Counter Delegation Extension, Version 1.0.0 that includes the description of Smcdeleg and Ssccfg.

For clarity / ease of finding the the details, update the RVA_020 requirement to include a reference to Smcdeleg.

Closes: #19

@ved-rivos
Copy link
Collaborator

This was intentional. The Platform specification is written to provide the requirements that the privilege levels less than M can expect. We have not placed any mandates on the M-mode ISA in the Server Platform or the Server SoC specification. I notice we have Smcntrpmf which I think should also be removed.

Copy link
Collaborator

@ved-rivos ved-rivos left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The smcdeleg and smcntrpmf should be remove from the list.

@punitagrawal
Copy link
Author

@ved-rivos Thank you for taking a look.

The reason for adding smcdeleg was that there is confusion about ssccfg - folks have complained about not being able to find its description. Even the chapter describing it only includes smcdeleg. I've seen ssccfg being incorrectly referred to in many places as sscfg (one example[0]) which obviously then makes it even harder to find.

I just had a look to confirm the content of smcntrpmf - it seems to be implied if smcdeleg/ssccfg is implemented. So dropping it should be ok. Though I hope this indirect requirement doesn't get missed by any implementation.

For my learning - I was wondering what is the rationale for the platform specification targeting privilege levels less than M. Is there a downside to having M mode extensions also in the list?

@ved-rivos
Copy link
Collaborator

For my learning - I was wondering what is the rationale for the platform specification targeting privilege levels less than M. Is there a downside to having M mode extensions also in the list?

The RVA profiles, server SoC specification, and the server platform specification are written to specify requirements as perceived by the S-mode and lower. This is to ensure we can support a single binary OS distribution on compliant platforms. An implementation that claims support Ssccfg should provide that extension as perceived by the S-mode. We are presently not placing mandates on the M-mode ISA - in fact none of these specifications even require the M-mode ISA to be implemented - for instance the machine mode may be an emulator.

The Server Platform specification are written to specify requirements
as seen by S-mode and lower. The rationale is to not requiring
explicit implementation of M-mode ISA.

The features provided by Smcntrpmf are implied if Ssccfg is
implemented. So it is safe to drop the reference as long as Ssccfg is
specififed.

Considering the above two points, drop the reference to Smcntrpmf.

Signed-off-by: Punit Agrawal <punit.agrawal@bytedance.com>
@punitagrawal
Copy link
Author

The smcdeleg and smcntrpmf should be remove from the list.

I've pushed an updated patch doing this.

@andreiw andreiw merged commit d29f1fc into riscv-non-isa:main Aug 31, 2024
1 check passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

RVA_020: Should Ssccfg be updated to Smcdeleg
3 participants