Skip to content
Snippets Groups Projects
  1. Sep 29, 2020
    • Peter Maydell's avatar
      docs/interop: Convert qemu-qmp-ref to rST · 4ac2ee19
      Peter Maydell authored
      
      Convert qemu-qmp-ref to rST format. This includes dropping
      the plain-text, pdf and info format outputs for this document;
      as with all our other Sphinx-based documentation, we provide
      HTML and manpage only.
      
      The qemu-qmp-ref.rst is somewhat more stripped down than
      the .texi was, because we do not (currently) attempt to
      generate indexes for the commands, events and data types
      being documented.
      
      Again, we drop the direct link from index.html.in now that
      the QMP ref is part of the interop manual.
      
      This commit removes the code from the root meson.build file that
      handled the various Texinfo-based outputs, because we no longer
      generate any documentation except for the Sphinx HTML manuals and the
      manpages, and the code can't handle having an empty list of files
      to process.. We'll do further cleanup of the remainders of
      Texinfo support in subsequent commits.
      
      Signed-off-by: default avatarPeter Maydell <peter.maydell@linaro.org>
      Message-Id: <20200925162316.21205-10-peter.maydell@linaro.org>
      Reviewed-by: default avatarMarkus Armbruster <armbru@redhat.com>
      [Unicode legacy literal dumbed down to plain string literal, TODO
      comment on displaying QEMU version added, "make html" fixed,
      storage-daemon/qapi/meson.build updated]
      Signed-off-by: default avatarMarkus Armbruster <armbru@redhat.com>
      4ac2ee19
    • Peter Maydell's avatar
      docs/interop: Convert qemu-ga-ref to rST · db16115f
      Peter Maydell authored
      
      Convert qemu-ga-ref to rST format. This includes dropping
      the plain-text, pdf and info format outputs for this document;
      as with all our other Sphinx-based documentation, we provide
      HTML and manpage only.
      
      The qemu-ga-ref.rst is somewhat more stripped down than
      the .texi was, because we do not (currently) attempt to
      generate indexes for the commands, events and data types
      being documented.
      
      As the GA ref is now part of the Sphinx 'interop' manual,
      we can delete the direct link from index.html.in.
      
      Reviewed-by: default avatarRichard Henderson <richard.henderson@linaro.org>
      Signed-off-by: default avatarPeter Maydell <peter.maydell@linaro.org>
      Message-Id: <20200925162316.21205-9-peter.maydell@linaro.org>
      Reviewed-by: default avatarMarkus Armbruster <armbru@redhat.com>
      [Unicode legacy literal dumbed down to plain string literal, TODO
      comment on displaying QEMU version added]
      Signed-off-by: default avatarMarkus Armbruster <armbru@redhat.com>
      db16115f
    • Peter Maydell's avatar
      docs/sphinx: Add new qapi-doc Sphinx extension · 4078ee54
      Peter Maydell authored
      
      Some of our documentation is auto-generated from documentation
      comments in the JSON schema.
      
      For Sphinx, rather than creating a file to include, the most natural
      way to handle this is to have a small custom Sphinx extension which
      processes the JSON file and inserts documentation into the rST
      file being processed.
      
      This is the same approach that kerneldoc and hxtool use.
      
      Signed-off-by: default avatarPeter Maydell <peter.maydell@linaro.org>
      Message-Id: <20200925162316.21205-8-peter.maydell@linaro.org>
      Reviewed-by: default avatarMarkus Armbruster <armbru@redhat.com>
      [Comment and doc string formatting tweaked, unused method dropped,
      a few line breaks tweaked to follow PEP 8 more closely, MAINTAINERS
      section QAPI updated]
      Signed-off-by: default avatarMarkus Armbruster <armbru@redhat.com>
      4078ee54
    • Peter Maydell's avatar
      qapi/machine.json: Escape a literal '*' in doc comment · 44e12af7
      Peter Maydell authored
      
      For rST, '*' is a kind of inline markup (for emphasis), so
      "*-softmmu" is a syntax error because of the missing closing '*'.
      Escape the '*' with a '\'.
      
      The texinfo document generator will leave the '\' in the
      output, which is not ideal, but that generator is going to
      go away in a subsequent commit.
      
      Reviewed-by: default avatarRichard Henderson <richard.henderson@linaro.org>
      Signed-off-by: default avatarPeter Maydell <peter.maydell@linaro.org>
      Message-Id: <20200925162316.21205-7-peter.maydell@linaro.org>
      Reviewed-by: default avatarMarkus Armbruster <armbru@redhat.com>
      Signed-off-by: default avatarMarkus Armbruster <armbru@redhat.com>
      44e12af7
    • Peter Maydell's avatar
      scripts/qapi/parser.py: improve doc comment indent handling · a69a6d4b
      Peter Maydell authored
      
      Make the handling of indentation in doc comments more sophisticated,
      so that when we see a section like:
      
      Notes: some text
             some more text
                indented line 3
      
      we save it for the doc-comment processing code as:
      
      some text
      some more text
         indented line 3
      
      and when we see a section with the heading on its own line:
      
      Notes:
      
      some text
      some more text
         indented text
      
      we also accept that and save it in the same form.
      
      If we detect that the comment document text is not indented as much
      as we expect it to be, we throw a parse error.  (We don't complain
      about over-indented sections, because for rST this can be legitimate
      markup.)
      
      The golden reference for the doc comment text is updated to remove
      the two 'wrong' indents; these now form a test case that we correctly
      stripped leading whitespace from an indented multi-line argument
      definition.
      
      We update the documentation in docs/devel/qapi-code-gen.txt to
      describe the new indentation rules.
      
      Signed-off-by: default avatarPeter Maydell <peter.maydell@linaro.org>
      Message-Id: <20200925162316.21205-6-peter.maydell@linaro.org>
      Reviewed-by: default avatarMarkus Armbruster <armbru@redhat.com>
      [Whitespace between sentences tweaked]
      Signed-off-by: default avatarMarkus Armbruster <armbru@redhat.com>
      a69a6d4b
    • Peter Maydell's avatar
      scripts/qapi: Move doc-comment whitespace stripping to doc.py · 99dff36d
      Peter Maydell authored
      
      As we accumulate lines from doc comments when parsing the JSON, the
      QAPIDoc class generally strips leading and trailing whitespace using
      line.strip() when it calls _append_freeform().  This is fine for
      Texinfo, but for rST leading whitespace is significant.  We'd like to
      move to having the text in doc comments be rST format rather than a
      custom syntax, so move the removal of leading whitespace from the
      QAPIDoc class to the texinfo-specific processing code in
      texi_format() in qapi/doc.py.
      
      (Trailing whitespace will always be stripped by the rstrip() in
      Section::append regardless.)
      
      In a followup commit we will make the whitespace in the lines of doc
      comment sections more consistently follow the input source.
      
      There is no change to the generated .texi files before and after this
      commit.
      
      Because the qapi-schema test checks the exact values of the
      documentation comments against a reference, we need to update that
      reference to match the new whitespace.  In the first four places this
      is now correctly checking that we did put in the amount of whitespace
      to pass a rST-formatted list to the backend; in the last two places
      the extra whitespace is 'wrong' and will go away again in the
      following commit.
      
      Reviewed-by: default avatarRichard Henderson <richard.henderson@linaro.org>
      Reviewed-by: default avatarMarkus Armbruster <armbru@redhat.com>
      Signed-off-by: default avatarPeter Maydell <peter.maydell@linaro.org>
      Message-Id: <20200925162316.21205-5-peter.maydell@linaro.org>
      Signed-off-by: default avatarMarkus Armbruster <armbru@redhat.com>
      99dff36d
    • Peter Maydell's avatar
      tests/qapi/doc-good.json: Prepare for qapi-doc Sphinx extension · 63a97cf5
      Peter Maydell authored
      
      doc-good.json tests doc comment parser corner cases.  We're about to
      largely replace it by a Sphinx extension, which will have different
      corner cases.  Tweak the test so it passes both with the old parser
      and the Sphinx extension, by making it match the more restrictive
      rST syntax:
      
       * in a single list the bullet types must all match
       * lists must have leading and following blank lines
       * the rules on when and where indentation matters differ
       * the '|' example syntax is going to go away entirely, so stop
         testing it
      
      This will avoid the tests spuriously breaking when we tighten up the
      parser code in the following commits.
      
      Reviewed-by: default avatarRichard Henderson <richard.henderson@linaro.org>
      Reviewed-by: default avatarMarkus Armbruster <armbru@redhat.com>
      Signed-off-by: default avatarPeter Maydell <peter.maydell@linaro.org>
      Message-Id: <20200925162316.21205-4-peter.maydell@linaro.org>
      Signed-off-by: default avatarMarkus Armbruster <armbru@redhat.com>
      63a97cf5
    • Peter Maydell's avatar
      qapi/block.json: Add newline after "Example:" for block-latency-histogram-set · 8b5905aa
      Peter Maydell authored
      
      The block-latency-histogram-set command is the only one which uses
      the Example/Examples section with the first line of the documentation
      immediately following the ':'. Bring it into line with the rest.
      
      This will allow us to avoid special-casing the indentation handling
      for "Examples" sections; instead for Examples as for any other section
      header these two indentations will be equivalent:
      
      Examples:
      Line one
      Line two
      
      Examples: Line one
                Line two
      
      Signed-off-by: default avatarPeter Maydell <peter.maydell@linaro.org>
      Message-Id: <20200925162316.21205-3-peter.maydell@linaro.org>
      Reviewed-by: default avatarMarkus Armbruster <armbru@redhat.com>
      [Commit message tweaked]
      Signed-off-by: default avatarMarkus Armbruster <armbru@redhat.com>
      8b5905aa
    • Peter Maydell's avatar
      qapi: Fix doc comment indentation again · 826bd069
      Peter Maydell authored
      
      In commit 26ec4e53 and similar commits we fixed the indentation
      for doc comments in our qapi json files to follow a new stricter
      standard for indentation, which permits only:
          @arg: description line 1
                description line 2
      
      or:
          @arg:
          line 1
          line 2
      
      but because the script updates that enforce this are not yet in the
      tree we have had a steady trickle of subsequent changes which didn't
      follow the new rules.
      
      Fix the latest round of mis-indented doc comments.
      
      Signed-off-by: default avatarPeter Maydell <peter.maydell@linaro.org>
      Message-Id: <20200925162316.21205-2-peter.maydell@linaro.org>
      Reviewed-by: default avatarMarkus Armbruster <armbru@redhat.com>
      [Updated for commit 4c437254 and a83e24ba]
      Signed-off-by: default avatarMarkus Armbruster <armbru@redhat.com>
      826bd069
    • Philippe Mathieu-Daudé's avatar
      qapi: Extract PCI commands to 'pci.json' · 61c7f987
      Philippe Mathieu-Daudé authored
      
      Only qemu-system-FOO and qemu-storage-daemon provide QMP
      monitors, therefore such declarations and definitions are
      irrelevant for user-mode emulation.
      
      Extracting the PCI commands to their own schema reduces the size of
      the qapi-misc* headers generated, and pulls less QAPI-generated code
      into user-mode.
      
      Suggested-by: default avatarMarkus Armbruster <armbru@redhat.com>
      Acked-by: default avatarMarkus Armbruster <armbru@redhat.com>
      Acked-by: default avatarPaolo Bonzini <pbonzini@redhat.com>
      Signed-off-by: default avatarPhilippe Mathieu-Daudé <philmd@redhat.com>
      Message-Id: <20200913195348.1064154-9-philmd@redhat.com>
      [Commit message tweaked]
      Signed-off-by: default avatarMarkus Armbruster <armbru@redhat.com>
      61c7f987
    • Philippe Mathieu-Daudé's avatar
      qapi: Extract ACPI commands to 'acpi.json' · 27c9188f
      Philippe Mathieu-Daudé authored
      
      Only qemu-system-FOO and qemu-storage-daemon provide QMP
      monitors, therefore such declarations and definitions are
      irrelevant for user-mode emulation.
      
      Extracting the ACPI commands to their own schema reduces the size of
      the qapi-misc* headers generated, and pulls less QAPI-generated code
      into user-mode.
      
      Suggested-by: default avatarMarkus Armbruster <armbru@redhat.com>
      Acked-by: default avatarIgor Mammedov <imammedo@redhat.com>
      Acked-by: default avatarMarkus Armbruster <armbru@redhat.com>
      Acked-by: default avatarPaolo Bonzini <pbonzini@redhat.com>
      Signed-off-by: default avatarPhilippe Mathieu-Daudé <philmd@redhat.com>
      Message-Id: <20200913195348.1064154-8-philmd@redhat.com>
      [Commit message tweaked]
      Signed-off-by: default avatarMarkus Armbruster <armbru@redhat.com>
      27c9188f
    • Philippe Mathieu-Daudé's avatar
      qapi: Restrict device memory commands to machine code · b495ec6c
      Philippe Mathieu-Daudé authored
      
      Only qemu-system-FOO and qemu-storage-daemon provide QMP
      monitors, therefore such declarations and definitions are
      irrelevant for user-mode emulation.
      
      Restricting the memory commands to machine.json pulls less
      QAPI-generated code into user-mode.
      
      Acked-by: default avatarIgor Mammedov <imammedo@redhat.com>
      Acked-by: default avatarPaolo Bonzini <pbonzini@redhat.com>
      Signed-off-by: default avatarPhilippe Mathieu-Daudé <philmd@redhat.com>
      Message-Id: <20200913195348.1064154-7-philmd@redhat.com>
      [Commit message tweaked]
      Signed-off-by: default avatarMarkus Armbruster <armbru@redhat.com>
      b495ec6c
    • Philippe Mathieu-Daudé's avatar
      qapi: Restrict query-uuid command to machine code · f68c0147
      Philippe Mathieu-Daudé authored
      
      Only qemu-system-FOO and qemu-storage-daemon provide QMP
      monitors, therefore such declarations and definitions are
      irrelevant for user-mode emulation.
      
      Restricting the query-uuid command to machine.json pulls less
      QAPI-generated code into user-mode.
      
      Acked-by: default avatarMarkus Armbruster <armbru@redhat.com>
      Acked-by: default avatarPaolo Bonzini <pbonzini@redhat.com>
      Signed-off-by: default avatarPhilippe Mathieu-Daudé <philmd@redhat.com>
      Message-Id: <20200913195348.1064154-6-philmd@redhat.com>
      [Commit message tweaked]
      Signed-off-by: default avatarMarkus Armbruster <armbru@redhat.com>
      f68c0147
    • Philippe Mathieu-Daudé's avatar
      qapi: Restrict query-vm-generation-id command to machine code · db0f08df
      Philippe Mathieu-Daudé authored
      
      Only qemu-system-FOO and qemu-storage-daemon provide QMP
      monitors, therefore such declarations and definitions are
      irrelevant for user-mode emulation.
      
      Restricting the query-vm-generation-id command to machine.json pulls
      less QAPI-generated code into user-mode.
      
      Acked-by: default avatarIgor Mammedov <imammedo@redhat.com>
      Acked-by: default avatarMarkus Armbruster <armbru@redhat.com>
      Acked-by: default avatarPaolo Bonzini <pbonzini@redhat.com>
      Signed-off-by: default avatarPhilippe Mathieu-Daudé <philmd@redhat.com>
      Message-Id: <20200913195348.1064154-5-philmd@redhat.com>
      [Commit message tweaked]
      Signed-off-by: default avatarMarkus Armbruster <armbru@redhat.com>
      db0f08df
    • Philippe Mathieu-Daudé's avatar
      qapi: Restrict balloon-related commands to machine code · a83e24ba
      Philippe Mathieu-Daudé authored
      
      Only qemu-system-FOO and qemu-storage-daemon provide QMP
      monitors, therefore such declarations and definitions are
      irrelevant for user-mode emulation.
      
      Restricting the balloon-related commands to machine.json pulls less
      QAPI-generated code into user-mode.
      
      Reviewed-by: default avatarDavid Hildenbrand <david@redhat.com>
      Acked-by: default avatarMarkus Armbruster <armbru@redhat.com>
      Acked-by: default avatarPaolo Bonzini <pbonzini@redhat.com>
      Signed-off-by: default avatarPhilippe Mathieu-Daudé <philmd@redhat.com>
      Message-Id: <20200913195348.1064154-4-philmd@redhat.com>
      [Commit message tweaked]
      Signed-off-by: default avatarMarkus Armbruster <armbru@redhat.com>
      a83e24ba
    • Philippe Mathieu-Daudé's avatar
      qapi: Correct balloon documentation · 81e248ce
      Philippe Mathieu-Daudé authored
      
      The documentation incorrectly uses the "size of the balloon"
      description when it should be "logical size of the VM". Fix it.
      
      The relation between both values is:
      
        logical_vm_size = vm_ram_size - balloon_size
      
      Reported-by: default avatarDavid Hildenbrand <david@redhat.com>
      Suggested-by: default avatarDavid Hildenbrand <david@redhat.com>
      Reviewed-by: default avatarDavid Hildenbrand <david@redhat.com>
      Acked-by: default avatarPaolo Bonzini <pbonzini@redhat.com>
      Signed-off-by: default avatarPhilippe Mathieu-Daudé <philmd@redhat.com>
      Message-Id: <20200913195348.1064154-3-philmd@redhat.com>
      Signed-off-by: default avatarMarkus Armbruster <armbru@redhat.com>
      81e248ce
    • Philippe Mathieu-Daudé's avatar
      qapi: Restrict LostTickPolicy enum to machine code · 8dc007d3
      Philippe Mathieu-Daudé authored
      
      Restricting LostTickPolicy to machine.json pulls slightly less
      QAPI-generated code into user-mode.
      
      Acked-by: default avatarMarkus Armbruster <armbru@redhat.com>
      Acked-by: default avatarPaolo Bonzini <pbonzini@redhat.com>
      Signed-off-by: default avatarPhilippe Mathieu-Daudé <philmd@redhat.com>
      Message-Id: <20200913195348.1064154-2-philmd@redhat.com>
      [Add rationale to commit message]
      Signed-off-by: default avatarMarkus Armbruster <armbru@redhat.com>
      8dc007d3
    • Peter Maydell's avatar
      Merge remote-tracking branch 'remotes/mst/tags/for_upstream' into staging · b150cb8f
      Peter Maydell authored
      
      acpi: fixup
      
      My last pull included a ton of useless files by mistake.
      Drop them all.
      
      Signed-off-by: default avatarMichael S. Tsirkin <mst@redhat.com>
      
      # gpg: Signature made Tue 29 Sep 2020 12:12:20 BST
      # gpg:                using RSA key 5D09FD0871C8F85B94CA8A0D281F0DB8D28D5469
      # gpg:                issuer "mst@redhat.com"
      # gpg: Good signature from "Michael S. Tsirkin <mst@kernel.org>" [full]
      # gpg:                 aka "Michael S. Tsirkin <mst@redhat.com>" [full]
      # Primary key fingerprint: 0270 606B 6F3C DF3D 0B17  0970 C350 3912 AFBE 8E67
      #      Subkey fingerprint: 5D09 FD08 71C8 F85B 94CA  8A0D 281F 0DB8 D28D 5469
      
      * remotes/mst/tags/for_upstream:
        tests/acpi: drop unnecessary files
      
      Signed-off-by: default avatarPeter Maydell <peter.maydell@linaro.org>
      b150cb8f
    • Michael S. Tsirkin's avatar
      tests/acpi: drop unnecessary files · f142e4ed
      Michael S. Tsirkin authored
      
      The last pull added a ton of useless files by mistake.
      Drop them all.
      
      Fixes: 0ed93f4c ("update golden master DSDT binary table blobs for q35")
      Signed-off-by: default avatarMichael S. Tsirkin <mst@redhat.com>
      f142e4ed
    • Peter Maydell's avatar
      Merge remote-tracking branch 'remotes/kraxel/tags/vga-20200929-pull-request' into staging · 5663ac2a
      Peter Maydell authored
      
      virtio-vga: reset fix, bigendian fix.
      virtio-vga+spice: set monitor dimension via edid.
      
      # gpg: Signature made Tue 29 Sep 2020 10:57:01 BST
      # gpg:                using RSA key 4CB6D8EED3E87138
      # gpg: Good signature from "Gerd Hoffmann (work) <kraxel@redhat.com>" [full]
      # gpg:                 aka "Gerd Hoffmann <gerd@kraxel.org>" [full]
      # gpg:                 aka "Gerd Hoffmann (private) <kraxel@gmail.com>" [full]
      # Primary key fingerprint: A032 8CFF B93A 17A7 9901  FE7D 4CB6 D8EE D3E8 7138
      
      * remotes/kraxel/tags/vga-20200929-pull-request:
        ppc/pseries: enable big-endian-framebuffer quirk for bochs-display and virtio-vga
        virtio-vga: implement big-endian-framebuffer property
        virtio-gpu: set physical dimensions for EDID
        spice: get monitors physical dimension
        spice: remove the single monitor config logic
        ui: add getter for UIInfo
        edid: use physical dimensions if available
        edid: fix physical display size computation
        virtio-gpu-3d: fix abnormal display after a warm reboot
      
      Signed-off-by: default avatarPeter Maydell <peter.maydell@linaro.org>
      5663ac2a
    • Peter Maydell's avatar
      Merge remote-tracking branch 'remotes/mst/tags/for_upstream' into staging · 21305738
      Peter Maydell authored
      
      virtio,pc,acpi: fixes, tests
      
      Fixes and tests all over the place.
      Batch iommu updates for vdpa.
      Removal of deprecated cpu hotplug commands.
      SMBIOS OEM string support.
      
      Signed-off-by: default avatarMichael S. Tsirkin <mst@redhat.com>
      
      # gpg: Signature made Tue 29 Sep 2020 08:09:21 BST
      # gpg:                using RSA key 5D09FD0871C8F85B94CA8A0D281F0DB8D28D5469
      # gpg:                issuer "mst@redhat.com"
      # gpg: Good signature from "Michael S. Tsirkin <mst@kernel.org>" [full]
      # gpg:                 aka "Michael S. Tsirkin <mst@redhat.com>" [full]
      # Primary key fingerprint: 0270 606B 6F3C DF3D 0B17  0970 C350 3912 AFBE 8E67
      #      Subkey fingerprint: 5D09 FD08 71C8 F85B 94CA  8A0D 281F 0DB8 D28D 5469
      
      * remotes/mst/tags/for_upstream: (48 commits)
        libvhost-user: return on error in vu_log_queue_fill()
        libvhost-user: return early on virtqueue errors
        hw: virtio-pmem: detach the element fromt the virtqueue when error occurs
        tests/acpi: update golden master DSDT binary table blobs for q35
        piix4: don't reserve hw resources when hotplug is off globally
        Add ACPI DSDT tables for q35 that are being updated by the next patch
        tests/acpi: add newly added acpi DSDT table blob for pci bridge hotplug flag
        tests/acpi: unit test for 'acpi-pci-hotplug-with-bridge-support' bridge flag
        tests/acpi: list added acpi table binary file for pci bridge hotplug test
        i440fx/acpi: do not add hotplug related amls for cold plugged bridges
        Fix a gap where acpi_pcihp_find_hotplug_bus() returns a non-hotpluggable bus
        tests/acpi: add a new ACPI table in order to test root pci hotplug on/off
        tests/acpi: add new unit test to test hotplug off/on feature on the root pci bus
        tests/acpi: mark addition of table DSDT.roothp for unit testing root pci hotplug
        vhost-user: save features of multiqueues if chardev is closed
        qemu-options: document SMBIOS type 11 settings
        hw/smbios: report error if table size is too large
        hw/smbios: support loading OEM strings values from a file
        tests: acpi: update acpi blobs with new AML
        x68: acpi: trigger SMI before sending hotplug Notify event to OSPM
        ...
      
      Signed-off-by: default avatarPeter Maydell <peter.maydell@linaro.org>
      21305738
    • Peter Maydell's avatar
      Merge remote-tracking branch 'remotes/dgilbert/tags/pull-migration-20200928a' into staging · 23290e80
      Peter Maydell authored
      
      Migration: Revert one patch for 068 fix
      
      One patch in the last pull broke test 068 which
      does a pair of vmload's.
      
      Signed-off-by: default avatarDr. David Alan Gilbert <dgilbert@redhat.com>
      
      # gpg: Signature made Mon 28 Sep 2020 16:19:17 BST
      # gpg:                using RSA key 45F5C71B4A0CB7FB977A9FA90516331EBC5BFDE7
      # gpg: Good signature from "Dr. David Alan Gilbert (RH2) <dgilbert@redhat.com>" [full]
      # Primary key fingerprint: 45F5 C71B 4A0C B7FB 977A  9FA9 0516 331E BC5B FDE7
      
      * remotes/dgilbert/tags/pull-migration-20200928a:
        Revert "migration: Properly destroy variables on incoming side"
      
      Signed-off-by: default avatarPeter Maydell <peter.maydell@linaro.org>
      23290e80
    • Gerd Hoffmann's avatar
      ppc/pseries: enable big-endian-framebuffer quirk for bochs-display and virtio-vga · 97a0530b
      Gerd Hoffmann authored
      Already done for stdvga and secondary-vga, bochs-display and virtio-vga
      support the big-endian-framebuffer property too.  Fixes blue console
      background at boot (offb firmware console).
      
      Buglink: https://bugzilla.redhat.com/show_bug.cgi?id=1881912
      
      
      Signed-off-by: default avatarGerd Hoffmann <kraxel@redhat.com>
      Message-id: 20200928085335.21961-3-kraxel@redhat.com
      97a0530b
    • Gerd Hoffmann's avatar
      virtio-vga: implement big-endian-framebuffer property · 8be61ce2
      Gerd Hoffmann authored
      
      Allows to switch the (vga mode) framebuffer into bigendian mode
      by setting the property, simliar to stdvga.
      
      Signed-off-by: default avatarGerd Hoffmann <kraxel@redhat.com>
      Message-id: 20200928085335.21961-2-kraxel@redhat.com
      8be61ce2
    • Marc-André Lureau's avatar
      virtio-gpu: set physical dimensions for EDID · 4bf47f36
      Marc-André Lureau authored
      
      Signed-off-by: default avatarMarc-André Lureau <marcandre.lureau@redhat.com>
      Message-id: 20200927145751.365446-7-marcandre.lureau@redhat.com
      Signed-off-by: default avatarGerd Hoffmann <kraxel@redhat.com>
      4bf47f36
    • Marc-André Lureau's avatar
      spice: get monitors physical dimension · 9028ab1f
      Marc-André Lureau authored
      
      With upcoming Spice server version 0.14.4, the monitor configuration can
      contain additional fields for the monitor physical dimensions.
      
      Signed-off-by: default avatarMarc-André Lureau <marcandre.lureau@redhat.com>
      Message-id: 20200927145751.365446-6-marcandre.lureau@redhat.com
      Signed-off-by: default avatarGerd Hoffmann <kraxel@redhat.com>
      9028ab1f
    • Marc-André Lureau's avatar
      spice: remove the single monitor config logic · 6244f988
      Marc-André Lureau authored
      
      Introduced in commit 9c956e64 ("spice:
      prepare for upcoming spice-server change"), the new logic never
      materialized in the spice server source tree. Let's remove it for now,
      until it actually changes in Spice.
      
      Signed-off-by: default avatarMarc-André Lureau <marcandre.lureau@redhat.com>
      Message-id: 20200927145751.365446-5-marcandre.lureau@redhat.com
      Signed-off-by: default avatarGerd Hoffmann <kraxel@redhat.com>
      6244f988
    • Marc-André Lureau's avatar
      ui: add getter for UIInfo · 5eaf1e48
      Marc-André Lureau authored
      
      The following patch is going to introduce extra fields / details to
      UIInfo. Add a getter and keep the current values, instead of memset(0)
      
      Signed-off-by: default avatarMarc-André Lureau <marcandre.lureau@redhat.com>
      Message-id: 20200927145751.365446-4-marcandre.lureau@redhat.com
      Signed-off-by: default avatarGerd Hoffmann <kraxel@redhat.com>
      5eaf1e48
    • Marc-André Lureau's avatar
      edid: use physical dimensions if available · fd36eade
      Marc-André Lureau authored
      
      Replace dpi with width_mm/height_mm in qemu_edid_info.
      
      Use it when set (non-zero) to compute the DPI and generate the EDID.
      
      Signed-off-by: default avatarMarc-André Lureau <marcandre.lureau@redhat.com>
      Message-id: 20200927145751.365446-3-marcandre.lureau@redhat.com
      Signed-off-by: default avatarGerd Hoffmann <kraxel@redhat.com>
      fd36eade
    • Marc-André Lureau's avatar
      edid: fix physical display size computation · 6c8f847a
      Marc-André Lureau authored
      
      Divide the resolution by the DPI, and multiply to mm.
      
      Note the computation done for edid[21/22] is correct (in cm).
      
      Signed-off-by: default avatarMarc-André Lureau <marcandre.lureau@redhat.com>
      Message-id: 20200927145751.365446-2-marcandre.lureau@redhat.com
      Signed-off-by: default avatarGerd Hoffmann <kraxel@redhat.com>
      6c8f847a
    • Guoqing Zhang's avatar
      virtio-gpu-3d: fix abnormal display after a warm reboot · 3745d59e
      Guoqing Zhang authored
      
      When resetting virtio-gpu, virgl_renderer_reset() should be
      called to ensure that the virglrenderer status is correct.
      
      Signed-off-by: default avatarGuoqing Zhang <zhangguoqing.kernel@bytedance.com>
      Reviewed-by: default avatarQi <Liu&lt;liuqi.16@bytedance.com>
      Message-id: 20200918111632.37354-1-zhangguoqing.kernel@bytedance.com
      Signed-off-by: default avatarGerd Hoffmann <kraxel@redhat.com>
      3745d59e
    • Stefan Hajnoczi's avatar
      libvhost-user: return on error in vu_log_queue_fill() · 81384055
      Stefan Hajnoczi authored
      
      vu_panic() is not guaranteed to exit the program. Return early when
      errors are encountered.
      
      Signed-off-by: default avatarStefan Hajnoczi <stefanha@redhat.com>
      Message-Id: <20200921113420.154378-3-stefanha@redhat.com>
      Reviewed-by: default avatarPhilippe Mathieu-Daudé <philmd@redhat.com>
      Reviewed-by: default avatarMichael S. Tsirkin <mst@redhat.com>
      Signed-off-by: default avatarMichael S. Tsirkin <mst@redhat.com>
      81384055
    • Stefan Hajnoczi's avatar
      libvhost-user: return early on virtqueue errors · fd40901c
      Stefan Hajnoczi authored
      
      vu_panic() is not guaranteed to exit the program. Return early when
      errors are encountered.
      
      Note that libvhost-user does not have an "unmap" operation for mapped
      descriptors. Therefore it is correct to return without explicit cleanup.
      
      Signed-off-by: default avatarStefan Hajnoczi <stefanha@redhat.com>
      Message-Id: <20200921113420.154378-2-stefanha@redhat.com>
      Reviewed-by: default avatarPhilippe Mathieu-Daudé <philmd@redhat.com>
      Reviewed-by: default avatarMichael S. Tsirkin <mst@redhat.com>
      Signed-off-by: default avatarMichael S. Tsirkin <mst@redhat.com>
      fd40901c
    • Li Qiang's avatar
      hw: virtio-pmem: detach the element fromt the virtqueue when error occurs · 2bc9e0da
      Li Qiang authored
      
      If error occurs while processing the virtio request we should call
      'virtqueue_detach_element' to detach the element from the virtqueue
      before free the elem.
      
      Signed-off-by: default avatarLi Qiang <liq3ea@163.com>
      Message-Id: <20200813165125.59928-1-liq3ea@163.com>
      Reviewed-by: default avatarMichael S. Tsirkin <mst@redhat.com>
      Signed-off-by: default avatarMichael S. Tsirkin <mst@redhat.com>
      Fixes: 5f503cd9 ("virtio-pmem: add virtio device")
      Reviewed-by: default avatarPankaj Gupta <pankaj.gupta.linux@gmail.com>
      2bc9e0da
    • Ani Sinha's avatar
      tests/acpi: update golden master DSDT binary table blobs for q35 · 0ed93f4c
      Ani Sinha authored
      
      In the previously applied commit ("piix4: don't reserve hw resources when
      hotplug is off globally"), we make changes to the ACPI DSDT tables
      such that some ACPI code are not generated when bsel is absent. Since
      as of this point in time, in q35 machines, we do not use bsel for pci
      buses, we need to update the DSDT table blobs.
      This patch updates the DSDT golden master tables for q35 machines.
      At the same time, we clear bios-tables-test-allowed-diff.h for future
      changes which update tables.
      
      Following is a typical diff between the q35 acpi DSDT table blobs:
      
      @@ -1,30 +1,30 @@
       /*
        * Intel ACPI Component Architecture
        * AML/ASL+ Disassembler version 20180105 (64-bit version)
        * Copyright (c) 2000 - 2018 Intel Corporation
        *
        * Disassembling to symbolic ASL+ operators
        *
      - * Disassembly of tests/data/acpi/q35/DSDT, Tue Sep 15 18:52:47 2020
      + * Disassembly of /tmp/aml-3O0DR0, Tue Sep 15 18:52:47 2020
        *
        * Original Table Header:
        *     Signature        "DSDT"
      - *     Length           0x00001DFE (7678)
      + *     Length           0x00001DF6 (7670)
        *     Revision         0x01 **** 32-bit table (V1), no 64-bit math support
      - *     Checksum         0xAC
      + *     Checksum         0x17
        *     OEM ID           "BOCHS "
        *     OEM Table ID     "BXPCDSDT"
        *     OEM Revision     0x00000001 (1)
        *     Compiler ID      "BXPC"
        *     Compiler Version 0x00000001 (1)
        */
       DefinitionBlock ("", "DSDT", 1, "BOCHS ", "BXPCDSDT", 0x00000001)
       {
           Scope (\)
           {
               OperationRegion (DBG, SystemIO, 0x0402, One)
               Field (DBG, ByteAcc, NoLock, Preserve)
               {
                   DBGB,   8
               }
      
      @@ -3113,24 +3113,20 @@
                       Name (_ADR, 0x00010000)  // _ADR: Address
                       Method (_S1D, 0, NotSerialized)  // _S1D: S1 Device State
                       {
                           Return (Zero)
                       }
      
                       Method (_S2D, 0, NotSerialized)  // _S2D: S2 Device State
                       {
                           Return (Zero)
                       }
      
                       Method (_S3D, 0, NotSerialized)  // _S3D: S3 Device State
                       {
                           Return (Zero)
                       }
                   }
      -
      -            Method (PCNT, 0, NotSerialized)
      -            {
      -            }
               }
           }
       }
      
      Signed-off-by: default avatarAni Sinha <ani@anisinha.ca>
      Acked-by: default avatarIgor Mammedov <imammedo@redhat.com>
      Message-Id: <20200918084111.15339-12-ani@anisinha.ca>
      Reviewed-by: default avatarMichael S. Tsirkin <mst@redhat.com>
      Signed-off-by: default avatarMichael S. Tsirkin <mst@redhat.com>
      0ed93f4c
    • Ani Sinha's avatar
      piix4: don't reserve hw resources when hotplug is off globally · df4008c9
      Ani Sinha authored
      
      When acpi hotplug is turned off for both root pci bus as well as for pci
      bridges, we should not generate the related ACPI code for DSDT table or
      initialize related hw ports or reserve hw resources. This change makes
      sure all those operations are turned off in the case ACPI pci hotplug is
      off globally.
      
      In this change, we also make sure ACPI code for the PCNT method are only
      added when bsel is enabled for the corresponding pci bus or bridge hotplug
      is turned on.
      
      As q35 machines do not use bsel for it's pci buses at this point in time, this
      change affects DSDT acpi table for q35 machines as well. Therefore, we will
      also need to commit the updated golden master DSDT table acpi binary blobs as
      well. Following is the list of blobs which needs updating:
      
       tests/data/acpi/q35/DSDT
       tests/data/acpi/q35/DSDT.acpihmat
       tests/data/acpi/q35/DSDT.bridge
       tests/data/acpi/q35/DSDT.cphp
       tests/data/acpi/q35/DSDT.dimmpxm
       tests/data/acpi/q35/DSDT.ipmibt
       tests/data/acpi/q35/DSDT.memhp
       tests/data/acpi/q35/DSDT.mmio64
       tests/data/acpi/q35/DSDT.numamem
       tests/data/acpi/q35/DSDT.tis
      
      These tables are updated in the following commit. Without the updated table
      blobs, the unit tests would fail with this patch.
      
      Signed-off-by: default avatarAni Sinha <ani@anisinha.ca>
      Reviewed-by: default avatarIgor Mammedov <imammedo@redhat.com>
      Message-Id: <20200918084111.15339-11-ani@anisinha.ca>
      Reviewed-by: default avatarMichael S. Tsirkin <mst@redhat.com>
      Signed-off-by: default avatarMichael S. Tsirkin <mst@redhat.com>
      df4008c9
    • Ani Sinha's avatar
      Add ACPI DSDT tables for q35 that are being updated by the next patch · c4bb646f
      Ani Sinha authored
      
      The following patch ("piix4: don't reserve hw resources when
      hotplug is off globally") modifies certain ACPI tables for q35 machines.
      This patch adds those table names to tests/qtest/bios-tables-test-allowed-diff.h
      so that unit tests continue to pass and bisection is not broken.
      
      Signed-off-by: default avatarAni Sinha <ani@anisinha.ca>
      Reviewed-by: default avatarIgor Mammedov <imammedo@redhat.com>
      Message-Id: <20200918084111.15339-10-ani@anisinha.ca>
      Reviewed-by: default avatarMichael S. Tsirkin <mst@redhat.com>
      Signed-off-by: default avatarMichael S. Tsirkin <mst@redhat.com>
      c4bb646f
    • Ani Sinha's avatar
      tests/acpi: add newly added acpi DSDT table blob for pci bridge hotplug flag · 8b434b03
      Ani Sinha authored
      
      This patch adds a binary blob corresponding to the DSDT acpi table. It is used
      to unit test the flag 'acpi-pci-hotplug-with-bridge-support' used with pci
      bridges.
      
      This change also clears the file tests/qtest/bios-tables-test-allowed-diff.h
      so that future changes which affect the table can be caught.
      
      The following is the diff between files tests/data/acpi/pc/DSDT.bridge and
      tests/data/acpi/pc/DSDT.hpbridge after disassembly :
      
      @@ -1,30 +1,30 @@
       /*
        * Intel ACPI Component Architecture
        * AML/ASL+ Disassembler version 20180105 (64-bit version)
        * Copyright (c) 2000 - 2018 Intel Corporation
        *
        * Disassembling to symbolic ASL+ operators
        *
      - * Disassembly of tests/data/acpi/pc/DSDT.bridge, Fri Sep 11 23:21:34 2020
      + * Disassembly of /tmp/aml-7UURQ0, Fri Sep 11 23:21:34 2020
        *
        * Original Table Header:
        *     Signature        "DSDT"
      - *     Length           0x00001A89 (6793)
      + *     Length           0x0000131F (4895)
        *     Revision         0x01 **** 32-bit table (V1), no 64-bit math support
      - *     Checksum         0x09
      + *     Checksum         0xF9
        *     OEM ID           "BOCHS "
        *     OEM Table ID     "BXPCDSDT"
        *     OEM Revision     0x00000001 (1)
        *     Compiler ID      "BXPC"
        *     Compiler Version 0x00000001 (1)
        */
       DefinitionBlock ("", "DSDT", 1, "BOCHS ", "BXPCDSDT", 0x00000001)
       {
           Scope (\)
           {
               OperationRegion (DBG, SystemIO, 0x0402, One)
               Field (DBG, ByteAcc, NoLock, Preserve)
               {
                   DBGB,   8
               }
      
      @@ -859,522 +859,32 @@
                       }
      
                       Method (_S2D, 0, NotSerialized)  // _S2D: S2 Device State
                       {
                           Return (Zero)
                       }
      
                       Method (_S3D, 0, NotSerialized)  // _S3D: S3 Device State
                       {
                           Return (Zero)
                       }
                   }
      
                   Device (S18)
                   {
                       Name (_ADR, 0x00030000)  // _ADR: Address
      -                Name (BSEL, One)
      -                Device (S00)
      -                {
      -                    Name (_SUN, Zero)  // _SUN: Slot User Number
      -                    Name (_ADR, Zero)  // _ADR: Address
      -                    Method (_EJ0, 1, NotSerialized)  // _EJx: Eject Device
      -                    {
      -                        PCEJ (BSEL, _SUN)
      -                    }
      -                }
      -
      -                Device (S08)
      -                {
      -                    Name (_SUN, One)  // _SUN: Slot User Number
      -                    Name (_ADR, 0x00010000)  // _ADR: Address
      -                    Method (_EJ0, 1, NotSerialized)  // _EJx: Eject Device
      -                    {
      -                        PCEJ (BSEL, _SUN)
      -                    }
      -                }
      -
      -                Device (S10)
      -                {
      -                    Name (_SUN, 0x02)  // _SUN: Slot User Number
      -                    Name (_ADR, 0x00020000)  // _ADR: Address
      -                    Method (_EJ0, 1, NotSerialized)  // _EJx: Eject Device
      -                    {
      -                        PCEJ (BSEL, _SUN)
      -                    }
      -                }
      -
      -                Device (S18)
      -                {
      -                    Name (_SUN, 0x03)  // _SUN: Slot User Number
      -                    Name (_ADR, 0x00030000)  // _ADR: Address
      -                    Method (_EJ0, 1, NotSerialized)  // _EJx: Eject Device
      -                    {
      -                        PCEJ (BSEL, _SUN)
      -                    }
      -                }
      -
      -                Device (S20)
      -                {
      -                    Name (_SUN, 0x04)  // _SUN: Slot User Number
      -                    Name (_ADR, 0x00040000)  // _ADR: Address
      -                    Method (_EJ0, 1, NotSerialized)  // _EJx: Eject Device
      -                    {
      -                        PCEJ (BSEL, _SUN)
      -                    }
      -                }
      -
      -                Device (S28)
      -                {
      -                    Name (_SUN, 0x05)  // _SUN: Slot User Number
      -                    Name (_ADR, 0x00050000)  // _ADR: Address
      -                    Method (_EJ0, 1, NotSerialized)  // _EJx: Eject Device
      -                    {
      -                        PCEJ (BSEL, _SUN)
      -                    }
      -                }
      -
      -                Device (S30)
      -                {
      -                    Name (_SUN, 0x06)  // _SUN: Slot User Number
      -                    Name (_ADR, 0x00060000)  // _ADR: Address
      -                    Method (_EJ0, 1, NotSerialized)  // _EJx: Eject Device
      -                    {
      -                        PCEJ (BSEL, _SUN)
      -                    }
      -                }
      -
      -                Device (S38)
      -                {
      -                    Name (_SUN, 0x07)  // _SUN: Slot User Number
      -                    Name (_ADR, 0x00070000)  // _ADR: Address
      -                    Method (_EJ0, 1, NotSerialized)  // _EJx: Eject Device
      -                    {
      -                        PCEJ (BSEL, _SUN)
      -                    }
      -                }
      -
      -                Device (S40)
      -                {
      -                    Name (_SUN, 0x08)  // _SUN: Slot User Number
      -                    Name (_ADR, 0x00080000)  // _ADR: Address
      -                    Method (_EJ0, 1, NotSerialized)  // _EJx: Eject Device
      -                    {
      -                        PCEJ (BSEL, _SUN)
      -                    }
      -                }
      -
      -                Device (S48)
      -                {
      -                    Name (_SUN, 0x09)  // _SUN: Slot User Number
      -                    Name (_ADR, 0x00090000)  // _ADR: Address
      -                    Method (_EJ0, 1, NotSerialized)  // _EJx: Eject Device
      -                    {
      -                        PCEJ (BSEL, _SUN)
      -                    }
      -                }
      -
      -                Device (S50)
      -                {
      -                    Name (_SUN, 0x0A)  // _SUN: Slot User Number
      -                    Name (_ADR, 0x000A0000)  // _ADR: Address
      -                    Method (_EJ0, 1, NotSerialized)  // _EJx: Eject Device
      -                    {
      -                        PCEJ (BSEL, _SUN)
      -                    }
      -                }
      -
      -                Device (S58)
      -                {
      -                    Name (_SUN, 0x0B)  // _SUN: Slot User Number
      -                    Name (_ADR, 0x000B0000)  // _ADR: Address
      -                    Method (_EJ0, 1, NotSerialized)  // _EJx: Eject Device
      -                    {
      -                        PCEJ (BSEL, _SUN)
      -                    }
      -                }
      -
      -                Device (S60)
      -                {
      -                    Name (_SUN, 0x0C)  // _SUN: Slot User Number
      -                    Name (_ADR, 0x000C0000)  // _ADR: Address
      -                    Method (_EJ0, 1, NotSerialized)  // _EJx: Eject Device
      -                    {
      -                        PCEJ (BSEL, _SUN)
      -                    }
      -                }
      -
      -                Device (S68)
      -                {
      -                    Name (_SUN, 0x0D)  // _SUN: Slot User Number
      -                    Name (_ADR, 0x000D0000)  // _ADR: Address
      -                    Method (_EJ0, 1, NotSerialized)  // _EJx: Eject Device
      -                    {
      -                        PCEJ (BSEL, _SUN)
      -                    }
      -                }
      -
      -                Device (S70)
      -                {
      -                    Name (_SUN, 0x0E)  // _SUN: Slot User Number
      -                    Name (_ADR, 0x000E0000)  // _ADR: Address
      -                    Method (_EJ0, 1, NotSerialized)  // _EJx: Eject Device
      -                    {
      -                        PCEJ (BSEL, _SUN)
      -                    }
      -                }
      -
      -                Device (S78)
      -                {
      -                    Name (_SUN, 0x0F)  // _SUN: Slot User Number
      -                    Name (_ADR, 0x000F0000)  // _ADR: Address
      -                    Method (_EJ0, 1, NotSerialized)  // _EJx: Eject Device
      -                    {
      -                        PCEJ (BSEL, _SUN)
      -                    }
      -                }
      -
      -                Device (S80)
      -                {
      -                    Name (_SUN, 0x10)  // _SUN: Slot User Number
      -                    Name (_ADR, 0x00100000)  // _ADR: Address
      -                    Method (_EJ0, 1, NotSerialized)  // _EJx: Eject Device
      -                    {
      -                        PCEJ (BSEL, _SUN)
      -                    }
      -                }
      -
      -                Device (S88)
      -                {
      -                    Name (_SUN, 0x11)  // _SUN: Slot User Number
      -                    Name (_ADR, 0x00110000)  // _ADR: Address
      -                    Method (_EJ0, 1, NotSerialized)  // _EJx: Eject Device
      -                    {
      -                        PCEJ (BSEL, _SUN)
      -                    }
      -                }
      -
      -                Device (S90)
      -                {
      -                    Name (_SUN, 0x12)  // _SUN: Slot User Number
      -                    Name (_ADR, 0x00120000)  // _ADR: Address
      -                    Method (_EJ0, 1, NotSerialized)  // _EJx: Eject Device
      -                    {
      -                        PCEJ (BSEL, _SUN)
      -                    }
      -                }
      -
      -                Device (S98)
      -                {
      -                    Name (_SUN, 0x13)  // _SUN: Slot User Number
      -                    Name (_ADR, 0x00130000)  // _ADR: Address
      -                    Method (_EJ0, 1, NotSerialized)  // _EJx: Eject Device
      -                    {
      -                        PCEJ (BSEL, _SUN)
      -                    }
      -                }
      -
      -                Device (SA0)
      -                {
      -                    Name (_SUN, 0x14)  // _SUN: Slot User Number
      -                    Name (_ADR, 0x00140000)  // _ADR: Address
      -                    Method (_EJ0, 1, NotSerialized)  // _EJx: Eject Device
      -                    {
      -                        PCEJ (BSEL, _SUN)
      -                    }
      -                }
      -
      -                Device (SA8)
      -                {
      -                    Name (_SUN, 0x15)  // _SUN: Slot User Number
      -                    Name (_ADR, 0x00150000)  // _ADR: Address
      -                    Method (_EJ0, 1, NotSerialized)  // _EJx: Eject Device
      -                    {
      -                        PCEJ (BSEL, _SUN)
      -                    }
      -                }
      -
      -                Device (SB0)
      -                {
      -                    Name (_SUN, 0x16)  // _SUN: Slot User Number
      -                    Name (_ADR, 0x00160000)  // _ADR: Address
      -                    Method (_EJ0, 1, NotSerialized)  // _EJx: Eject Device
      -                    {
      -                        PCEJ (BSEL, _SUN)
      -                    }
      -                }
      -
      -                Device (SB8)
      -                {
      -                    Name (_SUN, 0x17)  // _SUN: Slot User Number
      -                    Name (_ADR, 0x00170000)  // _ADR: Address
      -                    Method (_EJ0, 1, NotSerialized)  // _EJx: Eject Device
      -                    {
      -                        PCEJ (BSEL, _SUN)
      -                    }
      -                }
      -
      -                Device (SC0)
      -                {
      -                    Name (_SUN, 0x18)  // _SUN: Slot User Number
      -                    Name (_ADR, 0x00180000)  // _ADR: Address
      -                    Method (_EJ0, 1, NotSerialized)  // _EJx: Eject Device
      -                    {
      -                        PCEJ (BSEL, _SUN)
      -                    }
      -                }
      -
      -                Device (SC8)
      -                {
      -                    Name (_SUN, 0x19)  // _SUN: Slot User Number
      -                    Name (_ADR, 0x00190000)  // _ADR: Address
      -                    Method (_EJ0, 1, NotSerialized)  // _EJx: Eject Device
      -                    {
      -                        PCEJ (BSEL, _SUN)
      -                    }
      -                }
      -
      -                Device (SD0)
      -                {
      -                    Name (_SUN, 0x1A)  // _SUN: Slot User Number
      -                    Name (_ADR, 0x001A0000)  // _ADR: Address
      -                    Method (_EJ0, 1, NotSerialized)  // _EJx: Eject Device
      -                    {
      -                        PCEJ (BSEL, _SUN)
      -                    }
      -                }
      -
      -                Device (SD8)
      -                {
      -                    Name (_SUN, 0x1B)  // _SUN: Slot User Number
      -                    Name (_ADR, 0x001B0000)  // _ADR: Address
      -                    Method (_EJ0, 1, NotSerialized)  // _EJx: Eject Device
      -                    {
      -                        PCEJ (BSEL, _SUN)
      -                    }
      -                }
      -
      -                Device (SE0)
      -                {
      -                    Name (_SUN, 0x1C)  // _SUN: Slot User Number
      -                    Name (_ADR, 0x001C0000)  // _ADR: Address
      -                    Method (_EJ0, 1, NotSerialized)  // _EJx: Eject Device
      -                    {
      -                        PCEJ (BSEL, _SUN)
      -                    }
      -                }
      -
      -                Device (SE8)
      -                {
      -                    Name (_SUN, 0x1D)  // _SUN: Slot User Number
      -                    Name (_ADR, 0x001D0000)  // _ADR: Address
      -                    Method (_EJ0, 1, NotSerialized)  // _EJx: Eject Device
      -                    {
      -                        PCEJ (BSEL, _SUN)
      -                    }
      -                }
      -
      -                Device (SF0)
      -                {
      -                    Name (_SUN, 0x1E)  // _SUN: Slot User Number
      -                    Name (_ADR, 0x001E0000)  // _ADR: Address
      -                    Method (_EJ0, 1, NotSerialized)  // _EJx: Eject Device
      -                    {
      -                        PCEJ (BSEL, _SUN)
      -                    }
      -                }
      -
      -                Device (SF8)
      -                {
      -                    Name (_SUN, 0x1F)  // _SUN: Slot User Number
      -                    Name (_ADR, 0x001F0000)  // _ADR: Address
      -                    Method (_EJ0, 1, NotSerialized)  // _EJx: Eject Device
      -                    {
      -                        PCEJ (BSEL, _SUN)
      -                    }
      -                }
      -
      -                Method (DVNT, 2, NotSerialized)
      -                {
      -                    If ((Arg0 & One))
      -                    {
      -                        Notify (S00, Arg1)
      -                    }
      -
      -                    If ((Arg0 & 0x02))
      -                    {
      -                        Notify (S08, Arg1)
      -                    }
      -
      -                    If ((Arg0 & 0x04))
      -                    {
      -                        Notify (S10, Arg1)
      -                    }
      -
      -                    If ((Arg0 & 0x08))
      -                    {
      -                        Notify (S18, Arg1)
      -                    }
      -
      -                    If ((Arg0 & 0x10))
      -                    {
      -                        Notify (S20, Arg1)
      -                    }
      -
      -                    If ((Arg0 & 0x20))
      -                    {
      -                        Notify (S28, Arg1)
      -                    }
      -
      -                    If ((Arg0 & 0x40))
      -                    {
      -                        Notify (S30, Arg1)
      -                    }
      -
      -                    If ((Arg0 & 0x80))
      -                    {
      -                        Notify (S38, Arg1)
      -                    }
      -
      -                    If ((Arg0 & 0x0100))
      -                    {
      -                        Notify (S40, Arg1)
      -                    }
      -
      -                    If ((Arg0 & 0x0200))
      -                    {
      -                        Notify (S48, Arg1)
      -                    }
      -
      -                    If ((Arg0 & 0x0400))
      -                    {
      -                        Notify (S50, Arg1)
      -                    }
      -
      -                    If ((Arg0 & 0x0800))
      -                    {
      -                        Notify (S58, Arg1)
      -                    }
      -
      -                    If ((Arg0 & 0x1000))
      -                    {
      -                        Notify (S60, Arg1)
      -                    }
      -
      -                    If ((Arg0 & 0x2000))
      -                    {
      -                        Notify (S68, Arg1)
      -                    }
      -
      -                    If ((Arg0 & 0x4000))
      -                    {
      -                        Notify (S70, Arg1)
      -                    }
      -
      -                    If ((Arg0 & 0x8000))
      -                    {
      -                        Notify (S78, Arg1)
      -                    }
      -
      -                    If ((Arg0 & 0x00010000))
      -                    {
      -                        Notify (S80, Arg1)
      -                    }
      -
      -                    If ((Arg0 & 0x00020000))
      -                    {
      -                        Notify (S88, Arg1)
      -                    }
      -
      -                    If ((Arg0 & 0x00040000))
      -                    {
      -                        Notify (S90, Arg1)
      -                    }
      -
      -                    If ((Arg0 & 0x00080000))
      -                    {
      -                        Notify (S98, Arg1)
      -                    }
      -
      -                    If ((Arg0 & 0x00100000))
      -                    {
      -                        Notify (SA0, Arg1)
      -                    }
      -
      -                    If ((Arg0 & 0x00200000))
      -                    {
      -                        Notify (SA8, Arg1)
      -                    }
      -
      -                    If ((Arg0 & 0x00400000))
      -                    {
      -                        Notify (SB0, Arg1)
      -                    }
      -
      -                    If ((Arg0 & 0x00800000))
      -                    {
      -                        Notify (SB8, Arg1)
      -                    }
      -
      -                    If ((Arg0 & 0x01000000))
      -                    {
      -                        Notify (SC0, Arg1)
      -                    }
      -
      -                    If ((Arg0 & 0x02000000))
      -                    {
      -                        Notify (SC8, Arg1)
      -                    }
      -
      -                    If ((Arg0 & 0x04000000))
      -                    {
      -                        Notify (SD0, Arg1)
      -                    }
      -
      -                    If ((Arg0 & 0x08000000))
      -                    {
      -                        Notify (SD8, Arg1)
      -                    }
      -
      -                    If ((Arg0 & 0x10000000))
      -                    {
      -                        Notify (SE0, Arg1)
      -                    }
      -
      -                    If ((Arg0 & 0x20000000))
      -                    {
      -                        Notify (SE8, Arg1)
      -                    }
      -
      -                    If ((Arg0 & 0x40000000))
      -                    {
      -                        Notify (SF0, Arg1)
      -                    }
      -
      -                    If ((Arg0 & 0x80000000))
      -                    {
      -                        Notify (SF8, Arg1)
      -                    }
      -                }
      -
      -                Method (PCNT, 0, NotSerialized)
      -                {
      -                    BNUM = One
      -                    DVNT (PCIU, One)
      -                    DVNT (PCID, 0x03)
      -                }
                   }
      
                   Device (S20)
                   {
                       Name (_SUN, 0x04)  // _SUN: Slot User Number
                       Name (_ADR, 0x00040000)  // _ADR: Address
                       Method (_EJ0, 1, NotSerialized)  // _EJx: Eject Device
                       {
                           PCEJ (BSEL, _SUN)
                       }
                   }
      
                   Device (S28)
                   {
                       Name (_SUN, 0x05)  // _SUN: Slot User Number
                       Name (_ADR, 0x00050000)  // _ADR: Address
      @@ -1779,22 +1289,21 @@
                       If ((Arg0 & 0x40000000))
                       {
                           Notify (SF0, Arg1)
                       }
      
                       If ((Arg0 & 0x80000000))
                       {
                           Notify (SF8, Arg1)
                       }
                   }
      
                   Method (PCNT, 0, NotSerialized)
                   {
                       BNUM = Zero
                       DVNT (PCIU, One)
                       DVNT (PCID, 0x03)
      -                ^S18.PCNT ()
                   }
               }
           }
       }
      
      Signed-off-by: default avatarAni Sinha <ani@anisinha.ca>
      Acked-by: default avatarIgor Mammedov <imammedo@redhat.com>
      Message-Id: <20200918084111.15339-9-ani@anisinha.ca>
      Reviewed-by: default avatarMichael S. Tsirkin <mst@redhat.com>
      Signed-off-by: default avatarMichael S. Tsirkin <mst@redhat.com>
      8b434b03
    • Ani Sinha's avatar
      tests/acpi: unit test for 'acpi-pci-hotplug-with-bridge-support' bridge flag · 5e3a4862
      Ani Sinha authored
      
      This change adds a new unit test for the global flag
      'acpi-pci-hotplug-with-bridge-support' which is available for cold plugged pci
      bridges in i440fx. The flag can be used to turn off ACPI based hotplug support
      on all pci bridges.
      
      Signed-off-by: default avatarAni Sinha <ani@anisinha.ca>
      Reviewed-by: default avatarIgor Mammedov <imammedo@redhat.com>
      Message-Id: <20200918084111.15339-8-ani@anisinha.ca>
      Reviewed-by: default avatarMichael S. Tsirkin <mst@redhat.com>
      Signed-off-by: default avatarMichael S. Tsirkin <mst@redhat.com>
      5e3a4862
    • Ani Sinha's avatar
      tests/acpi: list added acpi table binary file for pci bridge hotplug test · 0fb41e89
      Ani Sinha authored
      
      The file 'tests/data/acpi/pc/DSDT.hpbridge' is a newly added acpi table file
      for testing the pci bridge option 'acpi-pci-hotplug-with-bridge-support' under
      i440fx. This change documents this fact.
      
      Signed-off-by: default avatarAni Sinha <ani@anisinha.ca>
      Reviewed-by: default avatarIgor Mammedov <imammedo@redhat.com>
      Message-Id: <20200918084111.15339-7-ani@anisinha.ca>
      Reviewed-by: default avatarMichael S. Tsirkin <mst@redhat.com>
      Signed-off-by: default avatarMichael S. Tsirkin <mst@redhat.com>
      0fb41e89
Loading