Skip to contentSkip to conversation

Change ioreq layout and reduce its size

PATCH In review Keir Fraser 2 participants 3 messages Oct 29, 2009

lore
Share & tools
lore
#0 lore raw

PATCH 1/1 Change ioreq layout and reduce its size

[Ian, please apply the attached ioemu patch and then send me an updated QEMU_TAG. The change to the ioreq layout requires the ioemu and xen-unstable patch check-ins to be closely synchronised.]

Reduce size of Xen-qemu shared ioreq structure to 32 bytes. This has two advantages:
1. We can support up to 128 VCPUs with a single shared page
2. If/when we want to go beyond 128 VCPUs, a whole number of ioreq_t
structures will pack into a single shared page, so a multi-page array will have no ioreq_t straddling a page boundary

Also, while modifying qemu, replace a 32-entry vcpu-indexed array with a dynamically-allocated array.

_______________________________________________
Xen-devel mailing list
[email protected]
http://lists.xensource.com/xen-devel

#1 lore raw
Quoted 6 lines · Keir Fraser

[Ian, please apply the attached ioemu patch and then send me an updated QEMU_TAG. The change to the ioreq layout requires the ioemu and xen-unstable patch check-ins to be closely synchronised.]

Reduce size of Xen-qemu shared ioreq structure to 32 bytes. This has two advantages:

Hi, Keir,
Reduce the ioreq structure has these advantages indeed, but do we need to consider the following compatibility issues? Thanks!
1) HVM guest could migrate/save/restore between the new and old hypervisor if vcpu number is less than 32.
2) Old qemu could work with new hypervisor if guest vcpu number is less than 32.

Best Regards,
-- Dongxiao

Quoted 9 lines

1. We can support up to 128 VCPUs with a single shared page
2. If/when we want to go beyond 128 VCPUs, a whole number of ioreq_t
structures will pack into a single shared page, so a multi-page array will have no ioreq_t straddling a page boundary

Also, while modifying qemu, replace a 32-entry vcpu-indexed array with a dynamically-allocated array.

#2 lore raw
Quoted 8 lines · Dongxiao
Quoted 2 lines

Reduce size of Xen-qemu shared ioreq structure to 32 bytes. This has two advantages:

Hi, Keir,
Reduce the ioreq structure has these advantages indeed, but do we need to consider the following compatibility issues? Thanks!
1) HVM guest could migrate/save/restore between the new and old hypervisor if vcpu number is less than 32.

It still can, as the ioreq struct is private to the hypervisor and qemu, neither of which is migrated/saved with the guest.

Quoted 2 lines

2) Old qemu could work with new hypervisor if guest vcpu number is less than 32.

Qemu, like the toolstack, is expected to be upgraded with the hypervisor.

-- Keir