qemu-devel.nongnu.org archive mirror
 help / color / mirror / Atom feed
From: Paolo Bonzini <pbonzini@redhat.com>
To: qemu-devel@nongnu.org
Cc: ehabkost@redhat.com, hutao@cn.fujitsu.com, mtosatti@redhat.com,
	imammedo@redhat.com, a.motakis@virtualopensystems.com,
	gaowanlong@cn.fujitsu.com
Subject: [Qemu-devel] [PATCH 2.1 00/28] Current state of NUMA series, and hostmem improvements
Date: Tue,  4 Mar 2014 15:00:28 +0100	[thread overview]
Message-ID: <1393941656-29068-1-git-send-email-pbonzini@redhat.com> (raw)

This series includes all the pending work on QOMifying the memory
backends.  Some of the patches posted so far didn't correctly build
all targets, so I'm posting it as the basis for further work
(including memory hotplug!).  It's available at branch numa on
my github repository.

To recap, the idea is to delegate all properties of the memory
backend to a new QOM class hierarchy, in which the concrete classes
are hostmem-ram and hostmem-file.  The backend is passed to the
machine via "-numa node,memdev=foo" where "foo" is the id of the
backend object.

Patches 1-6: generic numa improvements
Patches 7-8: convert -m to QemuOpts, from the memory hotplug series
Patches 9-11: improvements to object-add and -object
Patches 12-15: infrastructure for QOM memory backends
Patches 16-20: preparation for replacing -mem-path with a QOM backend
Patches 21-24: new-style replacement for -mem-path, -mem-prealloc and madvise
Patch 25: support for MAP_SHARED (requested by vhost-user)
Patches 26-28: rest of Wanlong Gao and Hu Tao's NUMA policy work

New patches are patch 9, patch 11, patches 16-25.  Please review
them.

Missing, needed before merge:
1. conversion to memory_region_allocate_system_memory of all boards
2. more documentation

Missing, nice to have:
1. improvements to string visitors for ranges
2. HMP "info memdev" command

If anyone wants to pick up management of this series from now on,
just shout.

Paolo

Hu Tao (2):
  hostmem: add properties for NUMA memory policy
  qmp: add query-memdev

Igor Mammedov (3):
  vl: convert -m to QemuOpts
  qmp: allow object-add completion handler to get canonical path
  add memdev backend infrastructure

Luiz Capitulino (1):
  man: improve -numa doc

Paolo Bonzini (16):
  qemu-option: introduce qemu_find_opts_singleton
  vl: redo -object parsing
  qmp: improve error reporting for -object and object-add
  pc: pass QEMUMachineInitArgs to pc_memory_init
  numa: introduce memory_region_allocate_system_memory
  numa: add -numa node,memdev= option
  memory: reorganize file-based allocation
  memory: move mem_path handling to memory_region_allocate_system_memory
  memory: add error propagation to file-based RAM allocation
  memory: move preallocation code out of exec.c
  memory: move RAM_PREALLOC_MASK to exec.c, rename
  hostmem: add file-based HostMemoryBackend
  hostmem: separate allocation from UserCreatable complete method
  hostmem: add merge and dump properties
  hostmem: allow preallocation of any memory region
  hostmem: add property to map memory with MAP_SHARED

Wanlong Gao (6):
  NUMA: move numa related code to new file numa.c
  NUMA: check if the total numa memory size is equal to ram_size
  NUMA: Add numa_info structure to contain numa nodes info
  NUMA: convert -numa option to use OptsVisitor
  NUMA: expand MAX_NODES from 64 to 128
  configure: add Linux libnuma detection

 Makefile.target            |   2 +-
 backends/Makefile.objs     |   3 +
 backends/hostmem-file.c    | 134 +++++++++++++++++
 backends/hostmem-ram.c     |  50 +++++++
 backends/hostmem.c         | 346 ++++++++++++++++++++++++++++++++++++++++++++
 configure                  |  33 +++++
 cpus.c                     |  14 --
 exec.c                     | 206 +++++++++++++--------------
 hw/i386/pc.c               |  27 ++--
 hw/i386/pc_piix.c          |   8 +-
 hw/i386/pc_q35.c           |   4 +-
 hw/ppc/spapr.c             |  10 +-
 include/exec/cpu-all.h     |   8 --
 include/exec/cpu-common.h  |   2 +
 include/exec/memory.h      |  33 +++++
 include/exec/ram_addr.h    |   3 +
 include/hw/boards.h        |   4 +
 include/hw/i386/pc.h       |   7 +-
 include/qemu/config-file.h |   2 +
 include/qemu/osdep.h       |  12 ++
 include/sysemu/cpus.h      |   1 -
 include/sysemu/hostmem.h   |  68 +++++++++
 include/sysemu/sysemu.h    |  18 ++-
 memory.c                   |  29 ++++
 monitor.c                  |   2 +-
 numa.c                     | 347 +++++++++++++++++++++++++++++++++++++++++++++
 qapi-schema.json           |  89 ++++++++++++
 qemu-options.hx            |  25 +++-
 qmp-commands.hx            |  32 +++++
 qmp.c                      |  15 +-
 util/oslib-posix.c         |  73 ++++++++++
 util/qemu-config.c         |  14 ++
 vl.c                       | 323 ++++++++++++++---------------------------
 33 files changed, 1549 insertions(+), 395 deletions(-)
 create mode 100644 backends/hostmem-file.c
 create mode 100644 backends/hostmem-ram.c
 create mode 100644 backends/hostmem.c
 create mode 100644 include/sysemu/hostmem.h
 create mode 100644 numa.c

-- 
1.8.5.3

             reply	other threads:[~2014-03-04 14:01 UTC|newest]

Thread overview: 70+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2014-03-04 14:00 Paolo Bonzini [this message]
2014-03-04 14:00 ` [Qemu-devel] [PATCH 2.1 01/28] NUMA: move numa related code to new file numa.c Paolo Bonzini
2014-03-04 14:00 ` [Qemu-devel] [PATCH 2.1 02/28] NUMA: check if the total numa memory size is equal to ram_size Paolo Bonzini
2014-03-04 17:00   ` Eric Blake
2014-03-04 17:19     ` Paolo Bonzini
2014-03-04 14:00 ` [Qemu-devel] [PATCH 2.1 03/28] NUMA: Add numa_info structure to contain numa nodes info Paolo Bonzini
2014-03-04 14:00 ` [Qemu-devel] [PATCH 2.1 04/28] NUMA: convert -numa option to use OptsVisitor Paolo Bonzini
2014-03-04 14:00 ` [Qemu-devel] [PATCH 2.1 05/28] NUMA: expand MAX_NODES from 64 to 128 Paolo Bonzini
2014-03-04 14:00 ` [Qemu-devel] [PATCH 2.1 06/28] man: improve -numa doc Paolo Bonzini
2014-03-11 18:53   ` Eduardo Habkost
2014-03-04 14:00 ` [Qemu-devel] [PATCH 2.1 07/28] qemu-option: introduce qemu_find_opts_singleton Paolo Bonzini
2014-03-05 10:08   ` Andreas Färber
2014-03-07  2:27   ` Hu Tao
2014-03-11 18:55   ` Eduardo Habkost
2014-03-04 14:00 ` [Qemu-devel] [PATCH 2.1 08/28] vl: convert -m to QemuOpts Paolo Bonzini
2014-03-05 10:06   ` Andreas Färber
2014-03-05 10:31     ` Paolo Bonzini
2014-03-05 15:09     ` Igor Mammedov
2014-03-04 14:00 ` [Qemu-devel] [PATCH 2.1 09/28] vl: redo -object parsing Paolo Bonzini
2014-03-07  2:56   ` Hu Tao
2014-03-07  7:39     ` Paolo Bonzini
2014-03-04 14:00 ` [Qemu-devel] [PATCH 2.1 10/28] qmp: allow object-add completion handler to get canonical path Paolo Bonzini
2014-03-04 14:00 ` [Qemu-devel] [PATCH 2.1 11/28] qmp: improve error reporting for -object and object-add Paolo Bonzini
2014-03-07  3:07   ` Hu Tao
2014-03-07  7:57     ` Paolo Bonzini
2014-03-04 14:00 ` [Qemu-devel] [PATCH 2.1 12/28] pc: pass QEMUMachineInitArgs to pc_memory_init Paolo Bonzini
2014-03-07  3:09   ` Hu Tao
2014-03-04 14:00 ` [Qemu-devel] [PATCH 2.1 13/28] numa: introduce memory_region_allocate_system_memory Paolo Bonzini
2014-03-07  3:18   ` Hu Tao
2014-03-04 14:00 ` [Qemu-devel] [PATCH 2.1 14/28] add memdev backend infrastructure Paolo Bonzini
2014-03-07  3:31   ` Hu Tao
2014-03-04 14:00 ` [Qemu-devel] [PATCH 2.1 15/28] numa: add -numa node, memdev= option Paolo Bonzini
2014-03-04 17:52   ` Eric Blake
2014-03-07  5:33   ` Hu Tao
2014-03-07  7:41     ` Paolo Bonzini
2014-03-04 14:00 ` [Qemu-devel] [PATCH 2.1 16/28] memory: reorganize file-based allocation Paolo Bonzini
2014-03-07  6:09   ` Hu Tao
2014-03-07  6:34     ` Hu Tao
2014-03-07  7:47     ` Paolo Bonzini
2014-03-04 14:00 ` [Qemu-devel] [PATCH 2.1 17/28] memory: move mem_path handling to memory_region_allocate_system_memory Paolo Bonzini
2014-03-11  3:50   ` Hu Tao
2014-03-11  8:03     ` Paolo Bonzini
2014-03-12  2:08       ` Marcelo Tosatti
2014-03-04 14:00 ` [Qemu-devel] [PATCH 2.1 18/28] memory: add error propagation to file-based RAM allocation Paolo Bonzini
2014-03-04 14:00 ` [Qemu-devel] [PATCH 2.1 19/28] memory: move preallocation code out of exec.c Paolo Bonzini
2014-03-04 14:00 ` [Qemu-devel] [PATCH 2.1 20/28] memory: move RAM_PREALLOC_MASK to exec.c, rename Paolo Bonzini
2014-03-04 14:00 ` [Qemu-devel] [PATCH 2.1 21/28] hostmem: add file-based HostMemoryBackend Paolo Bonzini
2014-03-04 17:38   ` Eric Blake
2014-03-04 18:12     ` Paolo Bonzini
2014-03-07  6:57   ` Hu Tao
2014-03-04 14:00 ` [Qemu-devel] [PATCH 2.1 22/28] hostmem: separate allocation from UserCreatable complete method Paolo Bonzini
2014-03-07  7:08   ` Hu Tao
2014-03-04 14:00 ` [Qemu-devel] [PATCH 2.1 23/28] hostmem: add merge and dump properties Paolo Bonzini
2014-03-04 14:00 ` [Qemu-devel] [PATCH 2.1 24/28] hostmem: allow preallocation of any memory region Paolo Bonzini
2014-03-04 14:00 ` [Qemu-devel] [PATCH 2.1 25/28] hostmem: add property to map memory with MAP_SHARED Paolo Bonzini
2014-03-04 14:00 ` [Qemu-devel] [PATCH 2.1 26/28] configure: add Linux libnuma detection Paolo Bonzini
2014-03-04 14:00 ` [Qemu-devel] [PATCH 2.1 27/28] hostmem: add properties for NUMA memory policy Paolo Bonzini
2014-03-04 14:00 ` [Qemu-devel] [PATCH 2.1 28/28] qmp: add query-memdev Paolo Bonzini
2014-03-04 17:37   ` Eric Blake
2014-03-04 18:11     ` Paolo Bonzini
2014-03-05  3:50       ` Hu Tao
2014-03-05  8:17         ` Paolo Bonzini
2014-03-05  3:48   ` Hu Tao
2014-03-05 11:05 ` [Qemu-devel] [PATCH 2.1 00/28] Current state of NUMA series, and hostmem improvements Andreas Färber
2014-03-05 11:30   ` Paolo Bonzini
2014-03-07 11:59     ` Andreas Färber
2014-03-07 12:20       ` Paolo Bonzini
2014-03-07 12:56         ` Igor Mammedov
2014-03-07 13:35           ` Paolo Bonzini
2014-03-07 14:54             ` Igor Mammedov

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=1393941656-29068-1-git-send-email-pbonzini@redhat.com \
    --to=pbonzini@redhat.com \
    --cc=a.motakis@virtualopensystems.com \
    --cc=ehabkost@redhat.com \
    --cc=gaowanlong@cn.fujitsu.com \
    --cc=hutao@cn.fujitsu.com \
    --cc=imammedo@redhat.com \
    --cc=mtosatti@redhat.com \
    --cc=qemu-devel@nongnu.org \
    /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 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).