Messages in this thread | | | Date | Fri, 8 Jul 2022 18:51:16 -0700 | Subject | Re: [PATCH tip v8] x86/setup: Use rng seeds from setup_data | From | "H. Peter Anvin" <> |
| |
On 7/8/22 04:39, Jason A. Donenfeld wrote: > > diff --git a/arch/x86/include/uapi/asm/bootparam.h b/arch/x86/include/uapi/asm/bootparam.h > index ca0796ac4403..2cbfe630230d 100644 > --- a/arch/x86/include/uapi/asm/bootparam.h > +++ b/arch/x86/include/uapi/asm/bootparam.h > @@ -12,6 +12,7 @@ > #define SETUP_JAILHOUSE 6 > #define SETUP_CC_BLOB 7 > #define SETUP_IMA 8 > +#define SETUP_RNG_SEED 9 > > #define SETUP_INDIRECT (1<<31) >
Just one miss here: you need to bump SETUP_TYPE_MAX. It is a bit more confusing than it needs to be that SETUP_INDIRECT sits in between, and honestly I think SETUP_TYPE_MAX shouldn't include the SETUP_INDIRECT bit; however, this is uapi and so we can't change that per se.
Perhaps we should do:
#define SETUP_ENUM_MAX SETUP_RNG_SEED #define SETUP_INDIRECT (1<<31) #define SETUP_TYPE_MAX (SETUP_ENUM_MAX | SETUP_INDIRECT)
-hpa
| |