On Fri, Jul 26, 2024 at 06:58:00PM +0000, Tim Merrifield wrote: > Add a new process-level prctl option to enable/disable user-level > hypercalls when running in a confidential VM. Add support for > checking this flag on VMCALL #VE for TDX and transfer control to > a hypervisor vendor-specific handler. We need more context from the cover letter here. > diff --git a/arch/x86/kernel/process.c b/arch/x86/kernel/process.c > index f63f8fd00a91..198431919fd2 100644 > --- a/arch/x86/kernel/process.c > +++ b/arch/x86/kernel/process.c > @@ -1042,6 +1042,24 @@ unsigned long __get_wchan(struct task_struct *p) > return addr; > } > > +static int get_coco_user_hcall_mode(void) > +{ > + return !test_bit(MM_CONTEXT_COCO_USER_HCALL, > + ¤t->mm->context.flags); Hm. Why "!"? -- Kiryl Shutsemau / Kirill A. Shutemov