the server
returns.
Set the io channel non-blocking and register the socket fd with the main
loop. Move the read operation into the callback. When the fd is readable,
inovke the callback to handle the quote data.
Signed-off-by: Chenyi Qiang
Signed-off-by: Xiaoyao Li
---
target/i386/kvm/tdx.c
.
Signed-off-by: Xiaoyao Li
Acked-by: Gerd Hoffmann
---
hw/i386/x86.c | 1 +
include/hw/i386/x86.h | 1 +
target/i386/kvm/tdx.c | 2 ++
3 files changed, 4 insertions(+)
diff --git a/hw/i386/x86.c b/hw/i386/x86.c
index a0c9f4d646e2..567384484244 100644
--- a/hw/i386/x86.c
+++ b/hw/i386
Add docs/system/i386/tdx.rst for TDX support, and add tdx in
confidential-guest-support.rst
Signed-off-by: Xiaoyao Li
---
Changes since v1:
- Add prerequisite of private gmem;
- update example command to launch TD;
Changes since RFC v4:
- add the restriction that kernel-irqchip must be
TDX doesn't support SMM and VMM cannot emulate SMM for TDX VMs because
VMM cannot manipulate TDX VM's memory.
Disable SMM for TDX VMs and error out if user requests to enable SMM.
Signed-off-by: Xiaoyao Li
Acked-by: Gerd Hoffmann
---
target/i386/kvm/tdx.c | 8
1 file
Sean Christopherson
Signed-off-by: Xiaoyao Li
Acked-by: Gerd Hoffmann
---
target/i386/kvm/kvm.c | 11 +++
1 file changed, 11 insertions(+)
diff --git a/target/i386/kvm/kvm.c b/target/i386/kvm/kvm.c
index d542351983cd..1422c79aca40 100644
--- a/target/i386/kvm/kvm.c
+++ b/target/i386/kvm/
igned-off-by: Xiaoyao Li
---
target/i386/kvm/tdx.c | 19 ++-
1 file changed, 18 insertions(+), 1 deletion(-)
diff --git a/target/i386/kvm/tdx.c b/target/i386/kvm/tdx.c
index 0c43c1f7759f..ced55be506d1 100644
--- a/target/i386/kvm/tdx.c
+++ b/target/i386/kvm/tdx.c
@@ -994,12 +9
: Xiaoyao Li
---
target/i386/kvm/kvm.c | 9 ++
target/i386/kvm/tdx-stub.c | 4 +++
target/i386/kvm/tdx.c | 61 ++
target/i386/kvm/tdx.h | 6
4 files changed, 80 insertions(+)
diff --git a/target/i386/kvm/kvm.c b/target/i386/kvm/kvm.c
index
LMCE is not supported TDX since KVM doesn't provide emulation for
MSR_IA32_FEAT_CTL.
Signed-off-by: Xiaoyao Li
---
target/i386/kvm/kvm-cpu.c | 5 +
1 file changed, 5 insertions(+)
diff --git a/target/i386/kvm/kvm-cpu.c b/target/i386/kvm/kvm-cpu.c
index 7237378a7d4e..bec8b5f918e7 1
mmand line example:
qemu-system-x86_64 \
-object 'tdx-guest,id=tdx0,quote-generation-service=localhost:1234' \
-machine confidential-guest-support=tdx0
Signed-off-by: Isaku Yamahata
Signed-off-by: Xiaoyao Li
---
qapi/qom.json | 5 +-
target/i386/kvm/tdx.c | 380 +
From: Chao Peng
Allocate private gmem memory for BIOS if it's TD VM.
Signed-off-by: Chao Peng
Co-developed-by: Xiaoyao Li
Signed-off-by: Xiaoyao Li
---
hw/i386/x86.c | 9 -
target/i386/kvm/tdx.c | 17 +
target/i386/kvm/tdx.h | 2 ++
3 files change
From: Isaku Yamahata
TSC of TDs is not accessible and KVM doesn't allow access of
MSR_IA32_TSC for TDs. To avoid the assert() in kvm_get_tsc, make
kvm_synchronize_all_tsc() noop for TDs,
Signed-off-by: Isaku Yamahata
Reviewed-by: Connor Kuehl
Signed-off-by: Xiaoyao Li
Acked-by: Gerd Hof
Signed-off-by: Xiaoyao Li
---
target/i386/kvm/tdx.c | 40
1 file changed, 40 insertions(+)
diff --git a/target/i386/kvm/tdx.c b/target/i386/kvm/tdx.c
index ced55be506d1..f111b46dac92 100644
--- a/target/i386/kvm/tdx.c
+++ b/target/i386/kvm/tdx.c
s and error out if user wants PIC.
Signed-off-by: Xiaoyao Li
Acked-by: Gerd Hoffmann
---
target/i386/kvm/tdx.c | 7 +++
1 file changed, 7 insertions(+)
diff --git a/target/i386/kvm/tdx.c b/target/i386/kvm/tdx.c
index f9d03ab0f461..23ecd84a9e21 100644
--- a/target/i386/kvm/tdx.c
+++ b/target/i38
Invoke KVM_TDX_FINALIZE_VM to finalize the TD's measurement and make
the TD vCPUs runnable once machine initialization is complete.
Signed-off-by: Xiaoyao Li
Acked-by: Gerd Hoffmann
---
target/i386/kvm/tdx.c | 7 +++
1 file changed, 7 insertions(+)
diff --git a/target/i386/kvm/td
TDX vcpu needs to be initialized by SEAMCALL(TDH.VP.INIT) and KVM
provides vcpu level IOCTL KVM_TDX_INIT_VCPU for it.
KVM_TDX_INIT_VCPU needs the address of the HOB as input. Invoke it for
each vcpu after HOB list is created.
Signed-off-by: Xiaoyao Li
Acked-by: Gerd Hoffmann
---
target/i386
From: Isaku Yamahata
When level trigger isn't supported on x86 platform,
forcibly report edge trigger in acpi tables.
Signed-off-by: Isaku Yamahata
Signed-off-by: Xiaoyao Li
Acked-by: Gerd Hoffmann
---
hw/i386/acpi-build.c | 99 ---
hw/i386
For TDs, only MSR_IA32_UCODE_REV in kvm_init_msrs() can be configured
by VMM, while the features enumerated/controlled by other MSRs except
MSR_IA32_UCODE_REV in kvm_init_msrs() are not under control of VMM.
Only configure MSR_IA32_UCODE_REV for TDs.
Signed-off-by: Xiaoyao Li
Acked-by: Gerd
onfig=0123456789abcdef0123456789abcdef0123456789abcdef0123456789abcdef0123456789abcdef0123456789abcdef
Signed-off-by: Isaku Yamahata
Signed-off-by: Xiaoyao Li
---
TODO:
- community requests to use base64 encoding if no special reason
---
qapi/qom.json | 11 ++-
target/i386/kvm/tdx.c
TDX doesn't support map different GPAs to same private memory. Thus,
aliasing top 128KB of BIOS as isa-bios is not supported.
On the other hand, TDX guest cannot go to real mode, it can work fine
without isa-bios.
Signed-off-by: Xiaoyao Li
Acked-by: Gerd Hoffmann
---
Changes from R
do the stuff.
Signed-off-by: Xiaoyao Li
Acked-by: Gerd Hoffmann
---
hw/i386/tdvf.c | 1 +
include/hw/i386/tdvf.h | 7 +++
target/i386/kvm/tdx.c | 31 +++
3 files changed, 39 insertions(+)
diff --git a/hw/i386/tdvf.c b/hw/i386/tdvf.c
index ff51f40088f0
Introduce tdx_kvm_init() and invoke it in kvm_confidential_guest_init()
if it's a TDX VM. More initialization will be added later.
Signed-off-by: Xiaoyao Li
Acked-by: Gerd Hoffmann
---
target/i386/kvm/kvm.c | 15 ++-
target/i386/kvm/meson.build | 2 +-
target/i386/kv
iolation
Originated-from: Isaku Yamahata
Signed-off-by: Xiaoyao Li
---
target/i386/kvm/tdx.c | 22 ++
1 file changed, 22 insertions(+)
diff --git a/target/i386/kvm/tdx.c b/target/i386/kvm/tdx.c
index 8a2491ed03c2..775110f8bd02 100644
--- a/target/i386/kvm/tdx.c
+++ b/target/
Introduce memory_region_init_ram_gmem() to allocate private gmem on the
MemoryRegion initialization. It's for the usercase of TDVF, which must
be private on TDX case.
Signed-off-by: Xiaoyao Li
---
include/exec/memory.h | 6 +
softmmu/memory.c
From: Isaku Yamahata
Allocate private gmem for TD guest, if the MemoryRegion is memory
backend and has private property on.
Signed-off-by: Isaku Yamahata
Signed-off-by: Xiaoyao Li
---
target/i386/kvm/tdx.c | 27 +--
1 file changed, 25 insertions(+), 2 deletions
Validate TD attributes with tdx_caps that fixed-0 bits must be zero and
fixed-1 bits must be set.
Besides, sanity check the attribute bits that have not been supported by
QEMU yet. e.g., debug bit, it will be allowed in the future when debug
TD support lands in QEMU.
Signed-off-by: Xiaoyao Li
, EFI_RESOURCE_MEMORY_UNACCEPTED will be added in future UEFI spec.
[1]
https://software.intel.com/content/dam/develop/external/us/en/documents/tdx-virtual-firmware-design-guide-rev-1.pdf
Signed-off-by: Xiaoyao Li
Acked-by: Gerd Hoffmann
---
include/standard-headers/uefi/uefi.h | 198 +++
1 file
For TDX, the address below 1MB are entirely general RAM. No need to
initialize pc.rom memory region for TDs.
Signed-off-by: Xiaoyao Li
---
This is more as a workaround of the issue that for q35 machine type, the
real memslot update (which requires memslot deletion )for pc.rom happens
after
d-off-by: Isaku Yamahata
Co-developed-by: Sean Christopherson
Signed-off-by: Sean Christopherson
Signed-off-by: Xiaoyao Li
Acked-by: Gerd Hoffmann
---
Changes from RFC v4:
- drop the code of adding mmio resources since OVMF prepares all the
MMIO hob itself.
---
hw/i386/meson.build
From: Isaku Yamahata
TDVF firmware (CODE and VARS) needs to be added/copied to TD's private
memory via KVM_TDX_INIT_MEM_REGION, as well as TD HOB and TEMP memory.
Signed-off-by: Isaku Yamahata
Signed-off-by: Xiaoyao Li
Acked-by: Gerd Hoffmann
---
Changes from RFC v4:
- rename var
From: Isaku Yamahata
Because vMMIO region needs to be shared region, guest TD may explicitly
convert such region from private to shared. Don't complain such
conversion.
Signed-off-by: Isaku Yamahata
Signed-off-by: Xiaoyao Li
---
accel/kvm/kvm-all.c | 20 ++--
1 file ch
;ed before TD runs and no need to be accepted runtime.
The TdxRamEntries[] are later used to setup the memory TD resource HOB
that passes memory info from QEMU to TDVF.
Signed-off-by: Xiaoyao Li
Acked-by: Gerd Hoffmann
---
Changes from RFC v4:
- simplify the algorithm of tdx_accept
offset of TDX metadata to the end
of firmware file.
Select X86_FW_OVMF when TDX is enable to leverage existing functions
to parse and search OVMF's GUID-ed structures.
Signed-off-by: Isaku Yamahata
Co-developed-by: Xiaoyao Li
Signed-off-by: Xiaoyao Li
Acked-by: Gerd Hoffmann
---
Changes
Introduce kvm_arch_pre_create_vcpu(), to perform arch-dependent
work prior to create any vcpu. This is for i386 TDX because it needs
call TDX_INIT_VM before creating any vcpu.
Signed-off-by: Xiaoyao Li
Acked-by: Gerd Hoffmann
---
accel/kvm/kvm-all.c | 12
include/sysemu/kvm.h
TDX cannot support pflash device since it doesn't support read-only
memslot and doesn't support emulation. Load TDVF(OVMF) with -bios option
for TDs.
When boot a TD, besides load TDVF to the address below 4G, it needs
parse TDVF metadata.
Signed-off-by: Xiaoyao Li
Acked-by: Ger
For QEMU VMs, PKS is configured via CPUID_7_0_ECX_PKS and PMU is
configured by x86cpu->enable_pmu. Reuse the existing configuration
interface for TDX VMs.
Signed-off-by: Xiaoyao Li
Acked-by: Gerd Hoffmann
---
target/i386/kvm/tdx.c | 14 +-
1 file changed, 13 insertions(+)
urable bits (it covers the other part of type #1);
- fix the ones in vmm_fixup;
- filter the one has valid .supported field;
(Calculated type is ignored since it's determined at runtime).
Co-developed-by: Chenyi Qiang
Signed-off-by: Chenyi Qiang
Signed-off-by: Xiaoyao Li
---
target/i3
Introduce a separate function kvm_confidential_guest_init() for SEV (and
future TDX).
Signed-off-by: Xiaoyao Li
Acked-by: Gerd Hoffmann
---
target/i386/kvm/kvm.c | 11 ++-
target/i386/sev.c | 1 -
target/i386/sev.h | 2 ++
3 files changed, 12 insertions(+), 2 deletions
MMIO. Ignore
memory conversion request of non-assigned region to shared and return
success. Otherwise OVMF is confused and panics there.
Signed-off-by: Isaku Yamahata
Signed-off-by: Xiaoyao Li
---
accel/kvm/kvm-all.c | 12
1 file changed, 12 insertions(+)
diff --git a/accel/kvm/k
TDX only supports readonly for shared memory but not for private memory.
In the view of QEMU, it has no idea whether a memslot is used as shared
memory of private. Thus just mark kvm_readonly_mem_enabled to false to
TDX VM for simplicity.
Signed-off-by: Xiaoyao Li
Acked-by: Gerd Hoffmann
Reuse "-cpu,tsc-frequency=" to get user wanted tsc frequency and call VM
scope VM_SET_TSC_KHZ to set the tsc frequency of TD before KVM_TDX_INIT_VM.
Besides, sanity check the tsc frequency to be in the legal range and
legal granularity (required by TDX module).
Signed-off-by: Xiaoyao
From: Isaku Yamahata
Implement property_add_sha384() which converts hex string <-> uint8_t[48]
It will be used for TDX which uses sha384 for measurement.
Signed-off-by: Isaku Yamahata
Signed-off-by: Xiaoyao Li
---
include/qom/object.h | 17 ++
qom/object.c
From: Sean Christopherson
Move the architectural (for lack of a better term) CPUID leaf generation
to a separate helper so that the generation code can be reused by TDX,
which needs to generate a canonical VM-scoped configuration.
Signed-off-by: Sean Christopherson
Signed-off-by: Xiaoyao Li
configure
this bit.
Signed-off-by: Xiaoyao Li
Acked-by: Gerd Hoffmann
---
qapi/qom.json | 4 +++-
target/i386/kvm/tdx.c | 24
2 files changed, 27 insertions(+), 1 deletion(-)
diff --git a/qapi/qom.json b/qapi/qom.json
index 2ca7ce7c0da5..cc08b9a98df9 100644
ITIES, QEMU chooses to try starting with a known number
and abort when it exceeds KVM_MAX_CPUID_ENTRIES.
Besides, introduce the interfaces to invoke TDX "ioctls" at different
scope (KVM, VM and VCPU) in preparation.
Signed-off-by: Xiaoyao Li
---
changes from v1:
- Make the error mes
From: Isaku Yamahata
For TDX KVM use case, Linux guest is the most major one. It requires
sept_ve_disable set. Make it default for the main use case. For other use
case, it can be enabled/disabled via qemu command line.
Signed-off-by: Isaku Yamahata
---
target/i386/kvm/tdx.c | 2 +-
1 file
ds by removing the bits that
reported from TDX module as configurable. This can adapt with the
updated TDX (module) automatically.
Signed-off-by: Xiaoyao Li
---
target/i386/kvm/tdx.c | 30 ++
1 file changed, 30 insertions(+)
diff --git a/target/i386/kvm/tdx.c b/target/i38
QEMU may change the CPUID
configuration when creating vCPUs, i.e. punts on refactoring QEMU to
provide a stable CPUID config prior to kvm_arch_init().
Signed-off-by: Xiaoyao Li
Acked-by: Gerd Hoffmann
---
accel/kvm/kvm-all.c| 9 +++-
target/i386/kvm/kvm.c | 8 +++
target
KVM requires userspace to pass XFAM configuration via CPUID 0xD leaves.
Convert tdx_caps->xfam_fixed0/1 into corresponding
tdx_cpuid_lookup[].tdx_fixed0/1 field of CPUID 0xD leaves. Thus the
requirement can be applied naturally.
Signed-off-by: Xiaoyao Li
---
target/i386/cpu.c |
Some bits in TD attributes have corresponding CPUID feature bits. Reflect
the fixed0/1 restriction on TD attributes to their corresponding CPUID
bits in tdx_cpuid_lookup[] as well.
Signed-off-by: Xiaoyao Li
---
target/i386/cpu-internal.h | 9 +
target/i386/cpu.c | 9
: Xiaoyao Li
---
target/i386/kvm/kvm.c | 10 +-
1 file changed, 9 insertions(+), 1 deletion(-)
diff --git a/target/i386/kvm/kvm.c b/target/i386/kvm/kvm.c
index 62f237068a3a..77f4772afe6c 100644
--- a/target/i386/kvm/kvm.c
+++ b/target/i386/kvm/kvm.c
@@ -32,6 +32,7 @@
#include "s
Pull in recent TDX updates, which are not backwards compatible.
It's just to make this series runnable. It will be updated by script
scripts/update-linux-headers.sh
once TDX support is upstreamed in linux kernel
Signed-off-by: Xiaoyao Li
---
linux-headers/asm-x86/kvm.h
It will need special handling for TDX VMs all around the QEMU.
Introduce is_tdx_vm() helper to query if it's a TDX VM.
Cache tdx_guest object thus no need to cast from ms->cgs every time.
Signed-off-by: Xiaoyao Li
Acked-by: Gerd Hoffmann
---
target/i386/kvm/tdx.c | 13 +
0 and not
configurable so far.
Signed-off-by: Xiaoyao Li
Acked-by: Gerd Hoffmann
---
changes from RFC-V4
- make @attributes not user-settable
---
configs/devices/i386-softmmu/default.mak | 1 +
hw/i386/Kconfig | 5 +++
qapi/qom.json| 12 +++
t
e helper
i386/tdx: Don't get/put guest state for TDX VMs
Xiaoyao Li (39):
*** HACK *** linux-headers: Update headers to pull in TDX API changes
i386: Introduce tdx-guest object
target/i386: Parse TDX vm type
target/i386: Introduce kvm_confidential_guest_init()
i386/tdx: Implemen
> 2023年8月14日 下午8:11,Raphael Norwitz 写道:
>
> Thanks for the cleanup! A few comments.
>
>> On Aug 4, 2023, at 1:29 AM, Li Feng wrote:
>>
>> Add a Error parameter to report the real error, like vhost-user-blk.
>>
>> Signed-off-by: Li Feng
>> -
{
/* @started: is the vhost device started? */
bool started;
bool log_enabled;
+bool inited;
uint64_t log_size;
Error *migration_blocker;
const VhostOps *vhost_ops;
Thanks.
>
>> On Aug 4, 2023, at 1:29 AM, Li Feng wrote:
>>
>> When the vhost
reports 0x3f when the intel processor has over 64 cores,
limit the max value written to EBX[31:26] to 63, so max num_cores should
be 64.
Signed-off-by: Qian Wen
Reviewed-by: Zhao Liu
Reviewed-by: Xiaoyao Li
---
target/i386/cpu.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff
by overflow, limit the max value written to
EBX[23:16] to 255 as the HW does.
Signed-off-by: Qian Wen
Reviewed-by: Zhao Liu
Reviewed-by: Xiaoyao Li
---
target/i386/cpu.c | 6 --
1 file changed, 4 insertions(+), 2 deletions(-)
diff --git a/target/i386/cpu.c b/target/i386/cpu.c
index 97ad229
The Svadu specification updated the name of the *envcfg bit from
HADE to ADUE.
Signed-off-by: Weiwei Li
Signed-off-by: Junqiang Wang
---
v2:
* rename hade variable name to adue suggested by Daniel
target/riscv/cpu.c| 4 ++--
target/riscv/cpu_bits.h | 8
target/riscv
Klaus Jensen 于2023年8月16日周三 15:37写道:
>
> On Aug 14 16:57, Sam Li wrote:
> > This patch series add a new extension - zoned format - to the
> > qcow2 driver thereby allowing full zoned storage emulation on
> > the qcow2 img file. Users can attach such a qcow2 file to the
>
Signed-off-by: Sam Li
---
block/block-backend.c | 8 ++
block/qcow2.c | 7 +-
hw/nvme/ctrl.c| 195 ++
include/sysemu/block-backend-io.h | 1 +
include/sysemu/dma.h | 3 +
softmmu/dma-helpers.c
attributes at the following eight bit of zoned bit of write
pointers for each zone. The ZDED is stored as part of zoned metadata as
write pointers.
Signed-off-by: Sam Li
---
block/qcow2.c| 44 +++-
hw/nvme/ctrl.c | 6 +
include
zone state transition and manage zone resources.
Signed-off-by: Sam Li
---
block/block-backend.c | 15 +
block/qcow2.c |3 +
hw/nvme/ctrl.c| 1114 ++---
hw/nvme/ns.c | 77 +-
hw/nvme/nvme.h
Zone descriptor data is host definied data that is associated with
each zone. Add zone descriptor extensions to zonedmeta and
blk_get_zone_extension to access zd_extensions.
Signed-off-by: Sam Li
---
block/block-backend.c | 15 ++
block/qcow2.c | 86
The zone information is contained in the BlockLimits fileds. Add blk_get_*()
functions
to access the block layer and update zone info accessing in the NVMe device
emulation.
Signed-off-by: Sam Li
---
block/block-backend.c | 56
block/qcow2.c
command line of QEMU, use:
-drive file=${znsimg},id=nvmezns0,format=qcow2,if=none \
-device nvme-ns,drive=nvmezns0,bus=nvme0,nsid=1,uuid=xxx \
Sam Li (5):
hw/nvme: use blk_get_*() to access zone info in the block layer
qcow2: add zone device metadata with zd_extension
hw/nvme: make the
:
https://lore.kernel.org/qemu-devel/camgffemg6tnq0n3+4ojagxc8j0oevy60khzekxcbs3lok9v...@mail.gmail.com/
Reported-by: Jack Wang
Signed-off-by: Pawan Gupta
Tested-by: Jack Wang
Tested-by: Daniel Sneddon
Reviewed-by: Xiaoyao Li
---
v2: Added commit tags
v1:
https://lore.kernel.org/qemu-devel
The Svadu specification updated the name of the *envcfg bit from
HADE to ADUE.
Signed-off-by: Weiwei Li
Signed-off-by: Junqiang Wang
---
target/riscv/cpu.c| 4 ++--
target/riscv/cpu_bits.h | 8
target/riscv/cpu_helper.c | 4 ++--
target/riscv/csr.c| 12
The zoned format feature can be tested by:
$ tests/qemu-iotests/check zoned-qcow2
Signed-off-by: Sam Li
---
tests/qemu-iotests/tests/zoned-qcow2 | 135 ++
tests/qemu-iotests/tests/zoned-qcow2.out | 140 +++
2 files changed, 275 insertions(+)
create
use bitwise or than addition
* fix wp index overflow and locking
* cleanups: comments, naming
Sam Li (4):
docs/qcow2: add the zoned format feature
qcow2: add configurations for zoned format extension
qcow2: add zoned emulation capability
iotests: test the zoned format feature for qcow2 f
a ZNS drive.
Signed-off-by: Sam Li
---
docs/system/qemu-block-drivers.rst.inc | 39 ++
1 file changed, 39 insertions(+)
diff --git a/docs/system/qemu-block-drivers.rst.inc
b/docs/system/qemu-block-drivers.rst.inc
index 105cb9679c..2c1620668f 100644
--- a/docs/system
corresponding state
changing.
Zoned devices have a limit on zone resources, which puts constraints on
write operations into zones.
Signed-off-by: Sam Li
---
block/qcow2.c | 676 -
block/qcow2.h | 2 +
docs/interop/qcow2.txt | 2 +
3
=0
-o zoned_profile=zbc/zns
Signed-off-by: Sam Li
---
block/qcow2.c| 125 +++
block/qcow2.h| 21 ++
docs/interop/qcow2.txt | 24 ++
include/block/block-common.h | 5 ++
include/block/block_int-common.h
. Berrangé"
Cc: Thomas Huth
Cc: "Philippe Mathieu-Daudé"
Cc: Gerd Hoffmann
Cc: Xiaojuan Yang
Cc: Song Gao
Cc: Bibo Mao
Signed-off-by: xianglai li
---
.gitmodules| 3 +++
meson.build| 2 +-
pc-bios/meson.build| 2 ++
roms/edk2-build.config | 14
On 8/7/2023 6:00 PM, Zhao Liu wrote:
Hi Xiaoyao,
On Mon, Aug 07, 2023 at 04:43:32PM +0800, Xiaoyao Li wrote:
Date: Mon, 7 Aug 2023 16:43:32 +0800
From: Xiaoyao Li
Subject: Re: [PATCH v3 03/17] softmmu: Fix CPUSTATE.nr_cores' calculation
On 8/7/2023 3:53 PM, Zhao Liu wrote:
diff --
On 8/7/2023 3:53 PM, Zhao Liu wrote:
diff --git a/target/i386/cpu.c b/target/i386/cpu.c
index 97ad229d8ba3..50613cd04612 100644
--- a/target/i386/cpu.c
+++ b/target/i386/cpu.c
@@ -6011,7 +6011,7 @@ void cpu_x86_cpuid(CPUX86State *env, uint32_t index,
uint32_t count,
X86CPUTopoInfo topo_in
On 8/1/2023 6:35 PM, Zhao Liu wrote:
From: Zhao Liu
Refer to the fixes of cache_info_passthrough ([1], [2]) and SDM, the
CPUID.04H:EAX[bits 25:14] and CPUID.04H:EAX[bits 31:26] should use the
nearest power-of-2 integer.
I doubt it. Especially for [1].
SDM doesn't state it should be the neare
On 7/28/2023 4:01 PM, Qian Wen wrote:
The legacy topology enumerated by CPUID.1.EBX[23:16] is defined in SDM
Vol2:
Bits 23-16: Maximum number of addressable IDs for logical processors in
this physical package.
To avoid data overflow, limit the max value written to EBX[23:16] to
255.
It's bett
On 8/1/2023 6:35 PM, Zhao Liu wrote:
From: Zhuocheng Ding
From CPUState.nr_cores' comment, it represents "number of cores within
this CPU package".
After 003f230e37d7 ("machine: Tweak the order of topology members in
struct CpuTopology"), the meaning of smp.cores changed to "the number of
cor
in
Reviewed-by: Xiaoyao Li
lying on QEMU's default topology
structure.
Fixes: 7e3482f82480 ("i386: Helpers to encode cache information consistently")
Suggested-by: Robert Hoo
Signed-off-by: Zhao Liu
Reviewed-by: Xiaoyao Li
---
Changes since v1:
* Split this fix from the patch named "i386/cpu: F
smartx.com/
Li Feng (2):
vhost-user: fix lost reconnect
vhost: Add Error parameter to vhost_scsi_common_start()
hw/scsi/vhost-scsi-common.c | 17 ++---
hw/scsi/vhost-scsi.c | 5 +++--
hw/scsi/vhost-user-scsi.c | 14 --
hw/vi
Add a Error parameter to report the real error, like vhost-user-blk.
Signed-off-by: Li Feng
---
hw/scsi/vhost-scsi-common.c | 17 ++---
hw/scsi/vhost-scsi.c | 5 +++--
hw/scsi/vhost-user-scsi.c | 14 --
include/hw/virtio/vhost-scsi
user-blk/scsi.
Fixes: 71e076a07d ("hw/virtio: generalise CHR_EVENT_CLOSED handling")
Signed-off-by: Li Feng
---
hw/virtio/vhost-user.c | 10 +-
1 file changed, 1 insertion(+), 9 deletions(-)
diff --git a/hw/virtio/vhost-user.c b/hw/virtio/vhost-user.c
index 8dcf049d42..697b403fe2 1006
On 8/2/2023 1:10 AM, Claudio Fontana wrote:
On 7/31/23 18:21, Xiaoyao Li wrote:
From: Chao Peng
Switch to KVM_SET_USER_MEMORY_REGION2 when supported by KVM.
With KVM_SET_USER_MEMORY_REGION2, QEMU can set up memory region that
backen'ed both by hva-based shared memory and gmem fd
On 8/2/2023 12:52 AM, Claudio Fontana wrote:
On 8/1/23 18:48, Claudio Fontana wrote:
On 7/31/23 18:21, Xiaoyao Li wrote:
Signed-off-by: Xiaoyao Li
---
include/exec/memory.h | 9 +
softmmu/memory.c | 5 +
2 files changed, 14 insertions(+)
diff --git a/include/exec
On 8/1/2023 10:57 PM, Daniel P. Berrangé wrote:
On Mon, Jul 31, 2023 at 07:22:05PM +0200, Markus Armbruster wrote:
Xiaoyao Li writes:
From: Isaku Yamahata
Signed-off-by: Isaku Yamahata
Signed-off-by: Xiaoyao Li
[...]
diff --git a/qapi/qom.json b/qapi/qom.json
index 7f92ea43e8e1
On 8/2/2023 1:21 AM, David Hildenbrand wrote:
On 31.07.23 18:21, Xiaoyao Li wrote:
From: Isaku Yamahata
Signed-off-by: Isaku Yamahata
Signed-off-by: Xiaoyao Li
---
backends/hostmem.c | 18 ++
include/sysemu/hostmem.h | 2 +-
qapi/qom.json | 4
3
On 8/1/2023 1:22 AM, Markus Armbruster wrote:
Xiaoyao Li writes:
From: Isaku Yamahata
Signed-off-by: Isaku Yamahata
Signed-off-by: Xiaoyao Li
[...]
diff --git a/qapi/qom.json b/qapi/qom.json
index 7f92ea43e8e1..e0b2044e3d20 100644
--- a/qapi/qom.json
+++ b/qapi/qom.json
@@ -605,6
On 8/1/2023 1:10 AM, Isaku Yamahata wrote:
On Mon, Jul 31, 2023 at 12:21:42PM -0400,
Xiaoyao Li wrote:
This is the first RFC version of enabling KVM gmem[1] as the backend for
private memory of KVM_X86_PROTECTED_VM.
It adds the support to create a specific KVM_X86_PROTECTED_VM type VM,
and
On 8/1/2023 12:51 AM, Daniel P. Berrangé wrote:
On Mon, Jul 31, 2023 at 12:21:42PM -0400, Xiaoyao Li wrote:
This is the first RFC version of enabling KVM gmem[1] as the backend for
private memory of KVM_X86_PROTECTED_VM.
It adds the support to create a specific KVM_X86_PROTECTED_VM type VM
From: Isaku Yamahata
Signed-off-by: Isaku Yamahata
Signed-off-by: Xiaoyao Li
---
backends/hostmem.c | 18 ++
include/sysemu/hostmem.h | 2 +-
qapi/qom.json| 4
3 files changed, 23 insertions(+), 1 deletion(-)
diff --git a/backends/hostmem.c b/backends
Register a memory listener for KVM_X86_SW_PROVTED_VM. It creates gmem
for the backend who sets the private property.
Signed-off-by: Xiaoyao Li
---
include/exec/memory.h | 1 +
target/i386/kvm/kvm.c | 38 ++
2 files changed, 39 insertions(+)
diff --git a
From: Isaku Yamahata
In mch_realize(), process PAM initialization before SMRAM initialization so
that later patch can skill all the SMRAM related with a single check.
Signed-off-by: Isaku Yamahata
Signed-off-by: Xiaoyao Li
---
hw/pci-host/q35.c | 19 ++-
1 file changed, 10
From: Isaku Yamahata
Signed-off-by: Isaku Yamahata
Signed-off-by: Xiaoyao Li
---
accel/kvm/kvm-all.c| 1 +
accel/kvm/trace-events | 2 +-
2 files changed, 2 insertions(+), 1 deletion(-)
diff --git a/accel/kvm/kvm-all.c b/accel/kvm/kvm-all.c
index 72d50b923bf2..c9f3aab5e587 100644
--- a
Signed-off-by: Xiaoyao Li
---
softmmu/physmem.c | 34 +++---
1 file changed, 15 insertions(+), 19 deletions(-)
diff --git a/softmmu/physmem.c b/softmmu/physmem.c
index 8f64128de0b5..05c981e5c18e 100644
--- a/softmmu/physmem.c
+++ b/softmmu/physmem.c
@@ -3430,16
stopherson
Signed-off-by: Sean Christopherson
Signed-off-by: Xiaoyao Li
---
hw/i386/pc_q35.c | 3 ++-
hw/pci-host/q35.c | 42 +++
include/hw/i386/pc.h | 1 +
include/hw/pci-host/q35.h | 1 +
4 files changed, 33 insertions(+), 14
only when the RAMBlock has
gmem memory backend.
Signed-off-by: Chao Peng
Signed-off-by: Xiaoyao Li
---
accel/kvm/kvm-all.c | 52 +
1 file changed, 52 insertions(+)
diff --git a/accel/kvm/kvm-all.c b/accel/kvm/kvm-all.c
index f9b5050b8885..72d50b923bf2
From: Chao Peng
This new routine adds support for memory conversion between
shared/private memory for gmem fd based private ram_block.
Signed-off-by: Chao Peng
Signed-off-by: Xiaoyao Li
---
include/exec/cpu-common.h | 2 ++
softmmu/physmem.c | 61
Implement mc->kvm_type() for i386 machines. It provides a way for user
to create SW_PROTECTE_VM.
Signed-off-by: Xiaoyao Li
---
hw/i386/x86.c | 27 +++
include/hw/i386/x86.h | 4
target/i386/kvm/kvm.c |
901 - 1000 of 4026 matches
Mail list logo