All of lore.kernel.org
 help / color / mirror / Atom feed
From: Anthony Harivel <aharivel@redhat.com>
To: pbonzini@redhat.com, mtosatti@redhat.com, berrange@redhat.com
Cc: qemu-devel@nongnu.org, vchundur@redhat.com,
	Anthony Harivel <aharivel@redhat.com>
Subject: [PATCH v3 0/3] Add support for the RAPL MSRs series
Date: Thu, 25 Jan 2024 08:22:11 +0100	[thread overview]
Message-ID: <20240125072214.318382-1-aharivel@redhat.com> (raw)

Dear maintainers,

First of all, thank you very much for your recent review of my patch 
[1].

In this version (v3), I have attempted to address the most crucial and 
challenging aspect highlighted in your last review.

I am hopeful that we can now engage in a discussion and address the 
remaining potential points that need attention.

Thank you for your continued guidance.

v2 -> v3
--------

- Move all memory allocations from Clib to Glib

- Compile on *BSD (working on Linux only)

- No more limitation on the virtual package: each vCPU that belongs to 
  the same virtual package is giving the same results like expected on 
  a real CPU.
  This has been tested topology like:
     -smp 4,sockets=2
     -smp 16,sockets=4,cores=2,threads=2

v1 -> v2
--------

- To overcome the CVE-2020-8694 a socket communication is created
  to a priviliged helper

- Add the priviliged helper (qemu-vmsr-helper)

- Add SO_PEERCRED in qio channel socket

RFC -> v1
---------

- Add vmsr_* in front of all vmsr specific function

- Change malloc()/calloc()... with all glib equivalent

- Pre-allocate all dynamic memories when possible

- Add a Documentation of implementation, limitation and usage

Best regards,
Anthony

[1]: https://www.mail-archive.com/qemu-devel@nongnu.org/msg1003382.html

Anthony Harivel (3):
  qio: add support for SO_PEERCRED for socket channel
  tools: build qemu-vmsr-helper
  Add support for RAPL MSRs in KVM/Qemu

 accel/kvm/kvm-all.c                      |  27 ++
 contrib/systemd/qemu-vmsr-helper.service |  15 +
 contrib/systemd/qemu-vmsr-helper.socket  |   9 +
 docs/specs/index.rst                     |   1 +
 docs/specs/rapl-msr.rst                  | 133 ++++++
 docs/tools/index.rst                     |   1 +
 docs/tools/qemu-vmsr-helper.rst          |  89 ++++
 include/io/channel.h                     |  21 +
 include/sysemu/kvm_int.h                 |  17 +
 io/channel-socket.c                      |  23 +
 io/channel.c                             |  12 +
 meson.build                              |   5 +
 target/i386/cpu.h                        |   8 +
 target/i386/kvm/kvm.c                    | 348 ++++++++++++++++
 target/i386/kvm/meson.build              |   1 +
 target/i386/kvm/vmsr_energy.c            | 295 +++++++++++++
 target/i386/kvm/vmsr_energy.h            |  87 ++++
 tools/i386/qemu-vmsr-helper.c            | 507 +++++++++++++++++++++++
 tools/i386/rapl-msr-index.h              |  28 ++
 19 files changed, 1627 insertions(+)
 create mode 100644 contrib/systemd/qemu-vmsr-helper.service
 create mode 100644 contrib/systemd/qemu-vmsr-helper.socket
 create mode 100644 docs/specs/rapl-msr.rst
 create mode 100644 docs/tools/qemu-vmsr-helper.rst
 create mode 100644 target/i386/kvm/vmsr_energy.c
 create mode 100644 target/i386/kvm/vmsr_energy.h
 create mode 100644 tools/i386/qemu-vmsr-helper.c
 create mode 100644 tools/i386/rapl-msr-index.h

-- 
2.43.0



             reply	other threads:[~2024-01-25  7:25 UTC|newest]

Thread overview: 32+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2024-01-25  7:22 Anthony Harivel [this message]
2024-01-25  7:22 ` [PATCH v3 1/3] qio: add support for SO_PEERCRED for socket channel Anthony Harivel
2024-01-25 16:37   ` Daniel P. Berrangé
2024-01-29 19:25     ` Paolo Bonzini
2024-01-29 19:30       ` Daniel P. Berrangé
2024-01-25  7:22 ` [PATCH v3 2/3] tools: build qemu-vmsr-helper Anthony Harivel
2024-01-29 18:53   ` Daniel P. Berrangé
2024-01-29 19:33     ` Paolo Bonzini
2024-01-29 19:45       ` Daniel P. Berrangé
2024-01-29 19:53         ` Daniel P. Berrangé
2024-01-29 20:21           ` Paolo Bonzini
2024-02-21 13:19         ` Anthony Harivel
2024-02-21 13:47           ` Daniel P. Berrangé
2024-02-21 13:52             ` Anthony Harivel
2024-03-01 11:08       ` Anthony Harivel
2024-01-25  7:22 ` [PATCH v3 3/3] Add support for RAPL MSRs in KVM/Qemu Anthony Harivel
2024-01-29 19:29   ` Daniel P. Berrangé
2024-02-20 14:00     ` Anthony Harivel
2024-02-20 15:00       ` Daniel P. Berrangé
2024-03-05 14:58     ` Anthony Harivel
2024-01-30  9:13   ` Daniel P. Berrangé
2024-03-04 14:41     ` Anthony Harivel
2024-03-04 14:48       ` Daniel P. Berrangé
2024-03-05 13:25         ` Anthony Harivel
2024-03-05 13:57           ` Daniel P. Berrangé
2024-01-30  9:39   ` Daniel P. Berrangé
2024-03-12 11:21     ` Anthony Harivel
2024-03-12 15:49       ` Daniel P. Berrangé
2024-03-13 10:48         ` Anthony Harivel
2024-03-13 11:04           ` Daniel P. Berrangé
2024-03-14  8:26             ` Anthony Harivel
2024-03-14  8:55               ` Daniel P. Berrangé

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20240125072214.318382-1-aharivel@redhat.com \
    --to=aharivel@redhat.com \
    --cc=berrange@redhat.com \
    --cc=mtosatti@redhat.com \
    --cc=pbonzini@redhat.com \
    --cc=qemu-devel@nongnu.org \
    --cc=vchundur@redhat.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.