Re: [PATCH] x86/tdx: Explicitly include <linux/errno.h> in <asm/tdx.h>

From: Huang, Kai
Date: Tue Jun 06 2023 - 18:51:00 EST


On Wed, 2023-06-07 at 01:45 +0300, Kirill A. Shutemov wrote:
> On Tue, Jun 06, 2023 at 10:17:53PM +0000, Huang, Kai wrote:
> > On Tue, 2023-06-06 at 06:10 -0700, Sathyanarayanan Kuppuswamy wrote:
> > >
> > > On 6/5/23 8:40 PM, Kai Huang wrote:
> > > > Currently, in <asm/tdx.h> tdx_kvm_hypercall() simply returns -ENODEV
> > > > when TDX guest isn't enabled in the Kconfig w/o having <linux/errno.h>
> > >
> > > Maybe you can explicitly say "CONFIG_INTEL_TDX_GUEST is not enabled"
> >
> > It also can be disabled by !CONFIG_KVM_GUEST.
>
> Borislav has already fixed it during unaccepted memory patchset
> application. He used <asm/errno.h>, not <linux/errno.h>.
>
> See [1] and [2].
>
> [1] https://git.kernel.org/pub/scm/linux/kernel/git/tip/tip.git/commit/?id=75d090fd167acab4d7eda7e2b65729e877c0fd64
> [2] https://lore.kernel.org/all/20230606161606.GDZH9bxhrGnFkaLl2A@fat_crate.local
>

Wonderful, then we can drop this one :)