This python script calls 'query-cpus' QMP command to retrieve
vCPUs thread IDs.
Thread IDs are then used by taskset to pin vCPUs to physical
CPUs passed in command line.
In case more vCPUs are present than the number of CPUs assigned
in command line, multiple vCPUs get pinned to physical CPUs.
If multiple vCPUs share a same thread ID (e.g. with TCG), the
thread ID is pinned a single time.
Signed-off-by: Maxime Coquelin <address@hidden>
---
Changes since RFC:
==================
- If vCPUs share a same TID, don't pin them multiple times (peterx)
scripts/qmp/qmp-vcpu-pin | 45 +++++++++++++++++++++++++++++++++++++++++++++
1 file changed, 45 insertions(+)
create mode 100755 scripts/qmp/qmp-vcpu-pin