* [PATCH 0/2] i386: Don't build TDX for 32-bit target
@ 2025-06-25 3:49 Xiaoyao Li
2025-06-25 3:49 ` [PATCH 1/2] i386/Kconfig: Make I386 and X86_64 independant Xiaoyao Li
2025-06-25 3:49 ` [PATCH 2/2] i386/tdx: Don't build TDX for 32bit target Xiaoyao Li
0 siblings, 2 replies; 6+ messages in thread
From: Xiaoyao Li @ 2025-06-25 3:49 UTC (permalink / raw)
To: Paolo Bonzini
Cc: Philippe Mathieu-Daudé, Cédric Le Goater,
Daniel P. Berrangé, xiaoyao.li, qemu-devel
Build errors of TDX were reported when built on 32-bit host[1][2].
People were agreed to disable TDX on 32-bit build[3].
This series implemnts the agreement that it makes TDX available when
!I386.
[1] https://lore.kernel.org/qemu-devel/20250602173101.1052983-1-clg@redhat.com/
[2] https://lore.kernel.org/qemu-devel/b8171c39-6a92-4078-a59a-a63d7452e1e9@kaod.org/
[3] https://lore.kernel.org/qemu-devel/a838e7cc-968e-4ca4-ba60-bbf201d689aa@redhat.com/
Xiaoyao Li (2):
i386/Kconfig: Make I386 and X86_64 independant
i386/tdx: Don't build TDX for 32bit target
hw/i386/Kconfig | 12 ++++++------
target/i386/Kconfig | 1 -
2 files changed, 6 insertions(+), 7 deletions(-)
--
2.43.0
^ permalink raw reply [flat|nested] 6+ messages in thread
* [PATCH 1/2] i386/Kconfig: Make I386 and X86_64 independant
2025-06-25 3:49 [PATCH 0/2] i386: Don't build TDX for 32-bit target Xiaoyao Li
@ 2025-06-25 3:49 ` Xiaoyao Li
2025-06-25 3:49 ` [PATCH 2/2] i386/tdx: Don't build TDX for 32bit target Xiaoyao Li
1 sibling, 0 replies; 6+ messages in thread
From: Xiaoyao Li @ 2025-06-25 3:49 UTC (permalink / raw)
To: Paolo Bonzini
Cc: Philippe Mathieu-Daudé, Cédric Le Goater,
Daniel P. Berrangé, xiaoyao.li, qemu-devel
Commit 4921d0a7535b ('i386: switch boards to "default y"') makes
CONIFG_X86_64 select CONFIG_I386, which makes it difficult to define
X86_64 only configs, e.g., for TDX.
Decouple I386 from X86_64.
Signed-off-by: Xiaoyao Li <xiaoyao.li@intel.com>
---
hw/i386/Kconfig | 10 +++++-----
target/i386/Kconfig | 1 -
2 files changed, 5 insertions(+), 6 deletions(-)
diff --git a/hw/i386/Kconfig b/hw/i386/Kconfig
index eb65bda6e071..6fc353930985 100644
--- a/hw/i386/Kconfig
+++ b/hw/i386/Kconfig
@@ -74,7 +74,7 @@ config PC_ACPI
config I440FX
bool
default y
- depends on I386
+ depends on (I386 || X86_64)
imply E1000_PCI
imply VMPORT
imply VMMOUSE
@@ -91,7 +91,7 @@ config I440FX
config ISAPC
bool
default y
- depends on I386
+ depends on (I386 || X86_64)
imply VGA_ISA
select ISA_BUS
select PC
@@ -103,7 +103,7 @@ config ISAPC
config Q35
bool
default y
- depends on I386
+ depends on (I386 || X86_64)
imply VTD
imply AMD_IOMMU
imply E1000E_PCI_EXPRESS
@@ -122,7 +122,7 @@ config Q35
config MICROVM
bool
default y
- depends on I386 && FDT
+ depends on (I386 || X86_64) && FDT
select DEVICE_TREE
select SERIAL_ISA # for serial_hds_isa_init()
select ISA_BUS
@@ -168,4 +168,4 @@ config VMMOUSE
config XEN_EMU
bool
default y
- depends on KVM && I386
+ depends on KVM && (I386 || X86_64)
diff --git a/target/i386/Kconfig b/target/i386/Kconfig
index 6b0feef02997..f16efa7137d5 100644
--- a/target/i386/Kconfig
+++ b/target/i386/Kconfig
@@ -6,4 +6,3 @@ config I386
config X86_64
bool
- select I386
--
2.43.0
^ permalink raw reply related [flat|nested] 6+ messages in thread
* [PATCH 2/2] i386/tdx: Don't build TDX for 32bit target
2025-06-25 3:49 [PATCH 0/2] i386: Don't build TDX for 32-bit target Xiaoyao Li
2025-06-25 3:49 ` [PATCH 1/2] i386/Kconfig: Make I386 and X86_64 independant Xiaoyao Li
@ 2025-06-25 3:49 ` Xiaoyao Li
2025-06-25 5:59 ` Cédric Le Goater
1 sibling, 1 reply; 6+ messages in thread
From: Xiaoyao Li @ 2025-06-25 3:49 UTC (permalink / raw)
To: Paolo Bonzini
Cc: Philippe Mathieu-Daudé, Cédric Le Goater,
Daniel P. Berrangé, xiaoyao.li, qemu-devel
TDX cannot work on 32-bit host. It's also not worth supported TDX with
32-bit QEMU.
Thus, make TDX depends on !I386.
Signed-off-by: Xiaoyao Li <xiaoyao.li@intel.com>
---
hw/i386/Kconfig | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/hw/i386/Kconfig b/hw/i386/Kconfig
index 6fc353930985..c58802462a45 100644
--- a/hw/i386/Kconfig
+++ b/hw/i386/Kconfig
@@ -13,7 +13,7 @@ config SGX
config TDX
bool
select X86_FW_OVMF
- depends on KVM
+ depends on KVM && !I386
config PC
bool
--
2.43.0
^ permalink raw reply related [flat|nested] 6+ messages in thread
* Re: [PATCH 2/2] i386/tdx: Don't build TDX for 32bit target
2025-06-25 3:49 ` [PATCH 2/2] i386/tdx: Don't build TDX for 32bit target Xiaoyao Li
@ 2025-06-25 5:59 ` Cédric Le Goater
2025-06-25 6:36 ` Xiaoyao Li
0 siblings, 1 reply; 6+ messages in thread
From: Cédric Le Goater @ 2025-06-25 5:59 UTC (permalink / raw)
To: Xiaoyao Li, Paolo Bonzini
Cc: Philippe Mathieu-Daudé, Daniel P. Berrangé, qemu-devel
On 6/25/25 05:49, Xiaoyao Li wrote:
> TDX cannot work on 32-bit host. It's also not worth supported TDX with
> 32-bit QEMU.
>
> Thus, make TDX depends on !I386.
>
> Signed-off-by: Xiaoyao Li <xiaoyao.li@intel.com>
> ---
> hw/i386/Kconfig | 2 +-
> 1 file changed, 1 insertion(+), 1 deletion(-)
>
> diff --git a/hw/i386/Kconfig b/hw/i386/Kconfig
> index 6fc353930985..c58802462a45 100644
> --- a/hw/i386/Kconfig
> +++ b/hw/i386/Kconfig
> @@ -13,7 +13,7 @@ config SGX
> config TDX
> bool
> select X86_FW_OVMF
> - depends on KVM
> + depends on KVM && !I386
>
> config PC
> bool
Both patches look OK.
Out of curiosity, would the change below work as well (without patch 1) ?
Thanks,
C.
@@ -13,7 +13,7 @@ config SGX
config TDX
bool
select X86_FW_OVMF
- depends on KVM
+ depends on KVM && X86_64
config PC
bool
^ permalink raw reply [flat|nested] 6+ messages in thread
* Re: [PATCH 2/2] i386/tdx: Don't build TDX for 32bit target
2025-06-25 5:59 ` Cédric Le Goater
@ 2025-06-25 6:36 ` Xiaoyao Li
2025-06-25 7:12 ` Cédric Le Goater
0 siblings, 1 reply; 6+ messages in thread
From: Xiaoyao Li @ 2025-06-25 6:36 UTC (permalink / raw)
To: Cédric Le Goater, Paolo Bonzini
Cc: Philippe Mathieu-Daudé, Daniel P. Berrangé, qemu-devel
On 6/25/2025 1:59 PM, Cédric Le Goater wrote:
> On 6/25/25 05:49, Xiaoyao Li wrote:
>> TDX cannot work on 32-bit host. It's also not worth supported TDX with
>> 32-bit QEMU.
>>
>> Thus, make TDX depends on !I386.
>>
>> Signed-off-by: Xiaoyao Li <xiaoyao.li@intel.com>
>> ---
>> hw/i386/Kconfig | 2 +-
>> 1 file changed, 1 insertion(+), 1 deletion(-)
>>
>> diff --git a/hw/i386/Kconfig b/hw/i386/Kconfig
>> index 6fc353930985..c58802462a45 100644
>> --- a/hw/i386/Kconfig
>> +++ b/hw/i386/Kconfig
>> @@ -13,7 +13,7 @@ config SGX
>> config TDX
>> bool
>> select X86_FW_OVMF
>> - depends on KVM
>> + depends on KVM && !I386
>> config PC
>> bool
>
> Both patches look OK.
>
> Out of curiosity, would the change below work as well (without patch 1) ?
>
> Thanks,
>
> C.
>
>
>
>
> @@ -13,7 +13,7 @@ config SGX
> config TDX
> bool
> select X86_FW_OVMF
> - depends on KVM
> + depends on KVM && X86_64
>
> config PC
> bool
>
It works! (It turns out I'm not clever enough)
Let's leave it to Paolo to pick.
^ permalink raw reply [flat|nested] 6+ messages in thread
* Re: [PATCH 2/2] i386/tdx: Don't build TDX for 32bit target
2025-06-25 6:36 ` Xiaoyao Li
@ 2025-06-25 7:12 ` Cédric Le Goater
0 siblings, 0 replies; 6+ messages in thread
From: Cédric Le Goater @ 2025-06-25 7:12 UTC (permalink / raw)
To: Xiaoyao Li, Paolo Bonzini
Cc: Philippe Mathieu-Daudé, Daniel P. Berrangé, qemu-devel
On 6/25/25 08:36, Xiaoyao Li wrote:
> On 6/25/2025 1:59 PM, Cédric Le Goater wrote:
>> On 6/25/25 05:49, Xiaoyao Li wrote:
>>> TDX cannot work on 32-bit host. It's also not worth supported TDX with
>>> 32-bit QEMU.
>>>
>>> Thus, make TDX depends on !I386.
>>>
>>> Signed-off-by: Xiaoyao Li <xiaoyao.li@intel.com>
>>> ---
>>> hw/i386/Kconfig | 2 +-
>>> 1 file changed, 1 insertion(+), 1 deletion(-)
>>>
>>> diff --git a/hw/i386/Kconfig b/hw/i386/Kconfig
>>> index 6fc353930985..c58802462a45 100644
>>> --- a/hw/i386/Kconfig
>>> +++ b/hw/i386/Kconfig
>>> @@ -13,7 +13,7 @@ config SGX
>>> config TDX
>>> bool
>>> select X86_FW_OVMF
>>> - depends on KVM
>>> + depends on KVM && !I386
>>> config PC
>>> bool
>>
>> Both patches look OK.
>>
>> Out of curiosity, would the change below work as well (without patch 1) ?
>>
>> Thanks,
>>
>> C.
>>
>>
>>
>>
>> @@ -13,7 +13,7 @@ config SGX
>> config TDX
>> bool
>> select X86_FW_OVMF
>> - depends on KVM
>> + depends on KVM && X86_64
>>
>> config PC
>> bool
>>
>
> It works! (It turns out I'm not clever enough)
>
> Let's leave it to Paolo to pick.
Could you please resend a v2 so someone can merge it while Paolo is on PTO ?
Thanks,
C.
^ permalink raw reply [flat|nested] 6+ messages in thread
end of thread, other threads:[~2025-06-25 7:14 UTC | newest]
Thread overview: 6+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2025-06-25 3:49 [PATCH 0/2] i386: Don't build TDX for 32-bit target Xiaoyao Li
2025-06-25 3:49 ` [PATCH 1/2] i386/Kconfig: Make I386 and X86_64 independant Xiaoyao Li
2025-06-25 3:49 ` [PATCH 2/2] i386/tdx: Don't build TDX for 32bit target Xiaoyao Li
2025-06-25 5:59 ` Cédric Le Goater
2025-06-25 6:36 ` Xiaoyao Li
2025-06-25 7:12 ` Cédric Le Goater
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).