Messages in this thread | | | From | "Huang, Kai" <> | Subject | Re: [PATCH v11 02/20] x86/virt/tdx: Detect TDX during kernel boot | Date | Mon, 19 Jun 2023 23:58:26 +0000 |
| |
[...]
> > + /* > > + * Just use the first TDX KeyID as the 'global KeyID' and > > + * leave the rest for TDX guests. > > + */ > > + tdx_global_keyid = tdx_keyid_start; > > + tdx_guest_keyid_start = ++tdx_keyid_start; > > + tdx_nr_guest_keyids = --nr_tdx_keyids; > > tdx_guest_keyid_start = tdx_keyid_start + 1; > tdx_nr_guest_keyids = nr_tdx_keyids - 1; > > Easier to get, because the modified values are unused.
Will do.
> > I'd probably avoid the "tdx" terminology in the local variables > ("keid_start", "nr_keyids") to give a better hint what the global > variables are (tdx_*), but just a personal preference. >
Yeah in general I agree but I chose to have "tdx_*" because it allows me to easily distinguish function local variables and static variables, especially this file contains more than ~1500 LoC (it also makes life easier to name the local variables). So I'd like to keep the "tdx_*".
> > Apart from that, > > Reviewed-by: David Hildenbrand <david@redhat.com> >
Thanks!
| |