Skip to content
Snippets Groups Projects
  1. Dec 21, 2021
  2. Dec 10, 2021
    • Yang Zhong's avatar
      numa: Enable numa for SGX EPC sections · 11058123
      Yang Zhong authored
      
      The basic SGX did not enable numa for SGX EPC sections, which
      result in all EPC sections located in numa node 0. This patch
      enable SGX numa function in the guest and the EPC section can
      work with RAM as one numa node.
      
      The Guest kernel related log:
      [    0.009981] ACPI: SRAT: Node 0 PXM 0 [mem 0x180000000-0x183ffffff]
      [    0.009982] ACPI: SRAT: Node 1 PXM 1 [mem 0x184000000-0x185bfffff]
      The SRAT table can normally show SGX EPC sections menory info in different
      numa nodes.
      
      The SGX EPC numa related command:
       ......
       -m 4G,maxmem=20G \
       -smp sockets=2,cores=2 \
       -cpu host,+sgx-provisionkey \
       -object memory-backend-ram,size=2G,host-nodes=0,policy=bind,id=node0 \
       -object memory-backend-epc,id=mem0,size=64M,prealloc=on,host-nodes=0,policy=bind \
       -numa node,nodeid=0,cpus=0-1,memdev=node0 \
       -object memory-backend-ram,size=2G,host-nodes=1,policy=bind,id=node1 \
       -object memory-backend-epc,id=mem1,size=28M,prealloc=on,host-nodes=1,policy=bind \
       -numa node,nodeid=1,cpus=2-3,memdev=node1 \
       -M sgx-epc.0.memdev=mem0,sgx-epc.0.node=0,sgx-epc.1.memdev=mem1,sgx-epc.1.node=1 \
       ......
      
      Signed-off-by: default avatarYang Zhong <yang.zhong@intel.com>
      Message-Id: <20211101162009.62161-2-yang.zhong@intel.com>
      Signed-off-by: default avatarPaolo Bonzini <pbonzini@redhat.com>
      11058123
  3. Nov 02, 2021
  4. Oct 31, 2021
  5. Oct 29, 2021
  6. Oct 02, 2021
  7. Sep 30, 2021
    • Yang Zhong's avatar
      sgx-epc: Add the fill_device_info() callback support · a7c565a9
      Yang Zhong authored
      
      Since there is no fill_device_info() callback support, and when we
      execute "info memory-devices" command in the monitor, the segfault
      will be found.
      
      This patch will add this callback support and "info memory-devices"
      will show sgx epc memory exposed to guest. The result as below:
      
      qemu) info memory-devices
      Memory device [sgx-epc]: ""
        memaddr: 0x180000000
        size: 29360128
        memdev: /objects/mem1
      Memory device [sgx-epc]: ""
        memaddr: 0x181c00000
        size: 10485760
        memdev: /objects/mem2
      
      Signed-off-by: default avatarYang Zhong <yang.zhong@intel.com>
      Message-Id: <20210719112136.57018-33-yang.zhong@intel.com>
      Signed-off-by: default avatarPaolo Bonzini <pbonzini@redhat.com>
      a7c565a9
  8. Sep 27, 2021
    • Markus Armbruster's avatar
      hmp: Unbreak "change vnc" · 6193344f
      Markus Armbruster authored
      
      HMP command "change vnc" can take the password as argument, or prompt
      for it:
      
          (qemu) change vnc password 123
          (qemu) change vnc password
          Password: ***
          (qemu)
      
      This regressed in commit cfb5387a "hmp: remove "change vnc TARGET"
      command", v6.0.0.
      
          (qemu) change vnc passwd 123
          Password: ***
          (qemu) change vnc passwd
          (qemu)
      
      The latter passes NULL to qmp_change_vnc_password(), which is a no-no.
      Looks like it puts the display into "password required, but none set"
      state.
      
      The logic error is easy to miss in review, but testing should've
      caught it.
      
      Fix the obvious way.
      
      Fixes: cfb5387a
      Cc: qemu-stable@nongnu.org
      Signed-off-by: default avatarMarkus Armbruster <armbru@redhat.com>
      Reviewed-by: default avatarDaniel P. Berrangé <berrange@redhat.com>
      Reviewed-by: default avatarGerd Hoffmann <kraxel@redhat.com>
      Message-Id: <20210909081219.308065-2-armbru@redhat.com>
      Signed-off-by: default avatarLaurent Vivier <laurent@vivier.eu>
      6193344f
    • Markus Armbruster's avatar
      qapi: Convert simple union TpmTypeOptions to flat one · 39dc3e4a
      Markus Armbruster authored
      
      Simple unions predate flat unions.  Having both complicates the QAPI
      schema language and the QAPI generator.  We haven't been using simple
      unions in new code for a long time, because they are less flexible and
      somewhat awkward on the wire.
      
      To prepare for their removal, convert simple union TpmTypeOptions to
      an equivalent flat one, with existing enum TpmType replacing implicit
      enum TpmTypeOptionsKind.  Adds some boilerplate to the schema, which
      is a bit ugly, but a lot easier to maintain than the simple union
      feature.
      
      Cc: Stefan Berger <stefanb@linux.vnet.ibm.com>
      Signed-off-by: default avatarMarkus Armbruster <armbru@redhat.com>
      Acked-by: default avatarStefan Berger <stefanb@linux.ibm.com>
      Reviewed-by: default avatarEric Blake <eblake@redhat.com>
      Message-Id: <20210917143134.412106-6-armbru@redhat.com>
      [Indentation tidied up]
      39dc3e4a
  9. Aug 26, 2021
  10. Aug 05, 2021
  11. Jul 21, 2021
    • Stefano Garzarella's avatar
      iothread: add aio-max-batch parameter · 1793ad02
      Stefano Garzarella authored
      
      The `aio-max-batch` parameter will be propagated to AIO engines
      and it will be used to control the maximum number of queued requests.
      
      When there are in queue a number of requests equal to `aio-max-batch`,
      the engine invokes the system call to forward the requests to the kernel.
      
      This parameter allows us to control the maximum batch size to reduce
      the latency that requests might accumulate while queued in the AIO
      engine queue.
      
      If `aio-max-batch` is equal to 0 (default value), the AIO engine will
      use its default maximum batch size value.
      
      Signed-off-by: default avatarStefano Garzarella <sgarzare@redhat.com>
      Message-id: 20210721094211.69853-3-sgarzare@redhat.com
      Signed-off-by: default avatarStefan Hajnoczi <stefanha@redhat.com>
      1793ad02
  12. Jul 12, 2021
  13. Jul 09, 2021
  14. Jun 15, 2021
  15. Jun 03, 2021
  16. Jun 02, 2021
  17. May 26, 2021
  18. May 13, 2021
  19. May 12, 2021
  20. May 02, 2021
  21. Mar 23, 2021
  22. Mar 19, 2021
    • Markus Armbruster's avatar
      qapi: Implement deprecated-output=hide for QMP introspection · 2df68d77
      Markus Armbruster authored
      
      This policy suppresses deprecated bits in output, and thus permits
      "testing the future".  Implement it for QMP command query-qmp-schema:
      suppress information on deprecated commands, events and object type
      members, i.e. anything that has the special feature flag "deprecated".
      
      Signed-off-by: default avatarMarkus Armbruster <armbru@redhat.com>
      Reviewed-by: default avatarEric Blake <eblake@redhat.com>
      Message-Id: <20210318155519.1224118-8-armbru@redhat.com>
      2df68d77
    • Markus Armbruster's avatar
      monitor: Drop query-qmp-schema 'gen': false hack · 624fa80c
      Markus Armbruster authored
      
      QMP commands return their response as a generated QAPI type, which the
      monitor core converts to JSON via QObject.
      
      query-qmp-schema's response is the generated introspection data.  This
      is a QLitObject since commit 7d0f982b "qapi: generate a literal
      qobject for introspection", v2.12).  Before, it was a string.  Instead
      of converting QLitObject / string -> QObject -> QAPI type
      SchemaInfoList -> QObject -> JSON, we take a shortcut: the command is
      'gen': false, so it can return the QObject instead of the QAPI type.
      Slightly simpler and more efficient.
      
      The next commit will filter the response for output policy, and this
      is easier in the SchemaInfoList representation.  Drop the shortcut.
      
      This replaces the manual command registration by a generated one.  The
      manual registration makes the command available before the machine is
      built by passing flag QCO_ALLOW_PRECONFIG.  To keep it available
      there, we need need to add 'allow-preconfig': true to its definition
      in the schema.
      
      Signed-off-by: default avatarMarkus Armbruster <armbru@redhat.com>
      Reviewed-by: default avatarEric Blake <eblake@redhat.com>
      Message-Id: <20210318155519.1224118-7-armbru@redhat.com>
      624fa80c
    • Kevin Wolf's avatar
      hmp: QAPIfy object_add · da0a932b
      Kevin Wolf authored
      
      This switches the HMP command object_add from a QemuOpts-based parser to
      user_creatable_add_from_str() which uses a keyval parser and enforces
      the QAPI schema.
      
      Apart from being a cleanup, this makes non-scalar properties and help
      accessible. In order for help to be printed to the monitor instead of
      stdout, the printf() calls in the help functions are changed to
      qemu_printf().
      
      Signed-off-by: default avatarKevin Wolf <kwolf@redhat.com>
      Acked-by: default avatarPaolo Bonzini <pbonzini@redhat.com>
      Acked-by: default avatarPeter Krempa <pkrempa@redhat.com>
      Reviewed-by: default avatarEric Blake <eblake@redhat.com>
      Reviewed-by: default avatarDr. David Alan Gilbert <dgilbert@redhat.com>
      da0a932b
    • Kevin Wolf's avatar
      qapi/qom: QAPIfy object-add · 9151e59a
      Kevin Wolf authored
      
      This converts object-add from 'gen': false to the ObjectOptions QAPI
      type. As an immediate benefit, clients can now use QAPI schema
      introspection for user creatable QOM objects.
      
      It is also the first step towards making the QAPI schema the only
      external interface for the creation of user creatable objects. Once all
      other places (HMP and command lines of the system emulator and all
      tools) go through QAPI, too, some object implementations can be
      simplified because some checks (e.g. that mandatory options are set) are
      already performed by QAPI, and in another step, QOM boilerplate code
      could be generated from the schema.
      
      Signed-off-by: default avatarKevin Wolf <kwolf@redhat.com>
      Acked-by: default avatarPaolo Bonzini <pbonzini@redhat.com>
      Acked-by: default avatarPeter Krempa <pkrempa@redhat.com>
      Reviewed-by: default avatarEric Blake <eblake@redhat.com>
      9151e59a
  23. Mar 18, 2021
Loading