Re: [RFC PATCH 05/12] include: sbi_domain: add Worlds WID fields
Pawandeep Oza <[email protected]> Mon, 13 Jul 2026 14:52:27 -0700
| Newsgroups | org.infradead.lists.opensbi |
|---|---|
| Message-ID | <CAAVgOkJDsTUhon3MvUrw-ufHfzKOrEkK93vdmRV74KBC-hqkKA@mail.gmail.com> |
On Fri, Jun 26, 2026 at 3:16 AM Yu-Chien Peter Lin <[email protected]> wrote: > > Adds next_wid (u32 WID for next boot stage), has_next_wid (distinguishes > explicit zero from unset for pmwid fallback), and next_widlist (u64 bitmask > specifying which WIDs can be delegated to this domain) to sbi_domain > structure. Enables per-domain World ID configuration. > > Signed-off-by: Yu-Chien Peter Lin <[email protected]> > --- > include/sbi/sbi_domain.h | 6 ++++++ > 1 file changed, 6 insertions(+) > > diff --git a/include/sbi/sbi_domain.h b/include/sbi/sbi_domain.h > index 16edd4ce..7d523493 100644 > --- a/include/sbi/sbi_domain.h > +++ b/include/sbi/sbi_domain.h > @@ -211,6 +211,12 @@ struct sbi_domain { > unsigned long next_addr; > /** Privilege mode of next booting stage for this domain */ > unsigned long next_mode; > + /** Next booting stage World ID for this domain */ > + u32 next_wid; oza: The next_ convention works well for one-time boot handoff fields like next_addr and next_mode But next_wid and next_widlist are not one-time boot fields — they are: Written on every domain entry via sbi_domain_worlds_enter() Active throughout the domain's lifetime Runtime isolation policy, not a boot handoff value So the next_ naming is semantically misleading here why not just have this naming widThe WID assigned to this domain. has_wid lwid_deleg The delegation budget to lower levels. > + /** Whether next_wid was explicitly set */ > + bool has_next_wid; > + /** Next booting stage World ID delegation bitmask for this domain */ > + u64 next_widlist; > /** Is domain allowed to reset the system */ > bool system_reset_allowed; > /** Is domain allowed to suspend the system */ > -- > 2.43.7 > > > -- > opensbi mailing list > [email protected] > http://lists.infradead.org/mailman/listinfo/opensbi -- opensbi mailing list [email protected] http://lists.infradead.org/mailman/listinfo/opensbi