On Mon, Jun 08, 2026 at 01:57:24PM +0800, Binbin Wu wrote:
[...snip...]
> +     } tdx_cmd = { .c = {                                            \
> +             .id = (cmd),                                            \
> +             .flags = (u32)(_flags),                         \
> > +           .data = (u64)(arg),                             \
> 
> Nit:
> The two lines' backslashes are misaligned.
> 
> > +
> > +#define tdx_vm_ioctl(vm, cmd, flags, arg)                          \
> > +({                                                                 \
> > +   int ret = __tdx_vm_ioctl(vm, cmd, flags, arg);                  \
> 
> tdx_cmd.c.hw_error is u64 and it could be assigned to ret, which is a int,
> the upper bits could be truncated if the upper 32-bit is set.

Thanks. Will fix these in the next version.

Lisa

> > +                                                                   \
> > +   __TEST_ASSERT_VM_VCPU_IOCTL(!ret, #cmd, ret, vm);               \
> > +})
> > +
> > +void tdx_init_vm(struct kvm_vm *vm, u64 attributes);
> > +
> >  #endif /* SELFTESTS_TDX_TDX_UTIL_H */[...]

Reply via email to