1. 09 1月, 2017 3 次提交
  2. 21 12月, 2016 1 次提交
    • T
      Move target-* CPU file into a target/ folder · fcf5ef2a
      Thomas Huth 提交于
      We've currently got 18 architectures in QEMU, and thus 18 target-xxx
      folders in the root folder of the QEMU source tree. More architectures
      (e.g. RISC-V, AVR) are likely to be included soon, too, so the main
      folder of the QEMU sources slowly gets quite overcrowded with the
      target-xxx folders.
      To disburden the main folder a little bit, let's move the target-xxx
      folders into a dedicated target/ folder, so that target-xxx/ simply
      becomes target/xxx/ instead.
      
      Acked-by: Laurent Vivier <laurent@vivier.eu> [m68k part]
      Acked-by: Bastian Koppelmann <kbastian@mail.uni-paderborn.de> [tricore part]
      Acked-by: Michael Walle <michael@walle.cc> [lm32 part]
      Acked-by: Cornelia Huck <cornelia.huck@de.ibm.com> [s390x part]
      Reviewed-by: Christian Borntraeger <borntraeger@de.ibm.com> [s390x part]
      Acked-by: Eduardo Habkost <ehabkost@redhat.com> [i386 part]
      Acked-by: Artyom Tarasenko <atar4qemu@gmail.com> [sparc part]
      Acked-by: Richard Henderson <rth@twiddle.net> [alpha part]
      Acked-by: Max Filippov <jcmvbkbc@gmail.com> [xtensa part]
      Reviewed-by: David Gibson <david@gibson.dropbear.id.au> [ppc part]
      Acked-by: Edgar E. Iglesias <edgar.iglesias@xilinx.com> [cris&microblaze part]
      Acked-by: Guan Xuetao <gxt@mprc.pku.edu.cn> [unicore32 part]
      Signed-off-by: NThomas Huth <thuth@redhat.com>
      fcf5ef2a
  3. 30 11月, 2016 1 次提交
    • L
      loader: fix handling of custom address spaces when adding ROM blobs · aa6c6ae8
      Laszlo Ersek 提交于
      * Commit 3e76099a ("loader: Allow a custom AddressSpace when loading
        ROMs") introduced the "Rom.as" field:
      
        (1) It modified the utility callers of rom_insert() to take "as" as a
            new parameter from *their* callers, and set "rom->as" from that
            parameter. The functions covered were rom_add_file() and
            rom_add_elf_program().
      
        (2) It also modified rom_insert() itself, to auto-assign
            "&address_space_memory", in case the external caller passed -- and
            the utility caller forwarded -- as=NULL.
      
        Except, commit 3e76099a forgot to update the third utility caller of
        rom_insert(), under point (1), namely rom_add_blob().
      
      * Later, commit 5e774eb3 ("loader: Add AddressSpace loading support
        to uImages") added the load_uimage_as() function, and the
        rom_add_blob_fixed_as() function-like macro, with the necessary changes
        elsewhere to propagate the new "as" parameter to rom_add_blob():
      
          load_uimage_as()
            load_uboot_image()
              rom_add_blob_fixed_as()
                rom_add_blob()
      
        At this point, the signature (and workings) of rom_add_blob() had been
        broken already, and the rom_add_blob_fixed_as() macro passed its "_as"
        parameter to rom_add_blob() as "callback_opaque". Given that the
        "fw_callback" parameter itself was set to NULL (correctly), this did no
        additional damage (the opaque arg would never be used), but ultimately
        it broke the new functionality of load_uimage_as().
      
      * The load_uimage_as() function would be put to use in one of the later
        patches, commit e481a1f6 ("generic-loader: Add a generic loader").
      
      * We can fix this only in a unified patch now. Append "AddressSpace *as"
        to the signature of rom_add_blob(), and handle the new parameter. Pass
        NULL from all current callers, except from rom_add_blob_fixed_as(),
        where "_as" has to be bumped to the proper position.
      
      * Note that rom_add_file() rejects the case when both "mr" and "as" are
        passed in as non-NULL. The action that this is apparently supposed to
        prevent is the
      
          rom->mr = mr;
      
        assignment (that's the only place where the "mr" parameter is used in
        rom_add_file()). In rom_add_blob() though, we have no "mr" parameter,
        and the actions done on the fw_cfg branch:
      
          if (fw_file_name && fw_cfg) {
              if (mc->rom_file_has_mr) {
                  data = rom_set_mr(rom, OBJECT(fw_cfg), devpath);
                  mr = rom->mr;
              } else {
                  data = rom->data;
              }
      
        reflect those that are performed by rom_add_file() too (with mr==NULL):
      
          if (rom->fw_file && fw_cfg) {
              if ((!option_rom || mc->option_rom_has_mr) &&
                  mc->rom_file_has_mr) {
                  data = rom_set_mr(rom, OBJECT(fw_cfg), devpath);
              } else {
                  data = rom->data;
              }
      
        Hence we need no additional restrictions in rom_add_blob().
      
      * Stable is not affected as both problematic commits appeared first in
        v2.8.0-rc0.
      
      Cc: "Michael S. Tsirkin" <mst@redhat.com>
      Cc: Alistair Francis <alistair.francis@xilinx.com>
      Cc: Igor Mammedov <imammedo@redhat.com>
      Cc: Michael Walle <michael@walle.cc>
      Cc: Paolo Bonzini <pbonzini@redhat.com>
      Cc: Peter Maydell <peter.maydell@linaro.org>
      Cc: Shannon Zhao <zhaoshenglong@huawei.com>
      Cc: qemu-arm@nongnu.org
      Cc: qemu-devel@nongnu.org
      Fixes: 3e76099a
      Fixes: 5e774eb3Signed-off-by: NLaszlo Ersek <lersek@redhat.com>
      Reviewed-by: NAlistair Francis <alistair.francis@xilinx.com>
      Reviewed-by: NMichael S. Tsirkin <mst@redhat.com>
      Reviewed-by: NMichael S. Tsirkin <mst@redhat.com>
      Signed-off-by: NMichael S. Tsirkin <mst@redhat.com>
      aa6c6ae8
  4. 28 10月, 2016 1 次提交
  5. 24 10月, 2016 1 次提交
  6. 18 10月, 2016 2 次提交
  7. 10 10月, 2016 1 次提交
  8. 04 10月, 2016 1 次提交
  9. 07 9月, 2016 1 次提交
  10. 17 6月, 2016 1 次提交
  11. 14 6月, 2016 1 次提交
  12. 07 6月, 2016 4 次提交
  13. 06 6月, 2016 1 次提交
  14. 12 5月, 2016 1 次提交
  15. 23 3月, 2016 1 次提交
    • M
      include/qemu/osdep.h: Don't include qapi/error.h · da34e65c
      Markus Armbruster 提交于
      Commit 57cb38b3 included qapi/error.h into qemu/osdep.h to get the
      Error typedef.  Since then, we've moved to include qemu/osdep.h
      everywhere.  Its file comment explains: "To avoid getting into
      possible circular include dependencies, this file should not include
      any other QEMU headers, with the exceptions of config-host.h,
      compiler.h, os-posix.h and os-win32.h, all of which are doing a
      similar job to this file and are under similar constraints."
      qapi/error.h doesn't do a similar job, and it doesn't adhere to
      similar constraints: it includes qapi-types.h.  That's in excess of
      100KiB of crap most .c files don't actually need.
      
      Add the typedef to qemu/typedefs.h, and include that instead of
      qapi/error.h.  Include qapi/error.h in .c files that need it and don't
      get it now.  Include qapi-types.h in qom/object.h for uint16List.
      
      Update scripts/clean-includes accordingly.  Update it further to match
      reality: replace config.h by config-target.h, add sysemu/os-posix.h,
      sysemu/os-win32.h.  Update the list of includes in the qemu/osdep.h
      comment quoted above similarly.
      
      This reduces the number of objects depending on qapi/error.h from "all
      of them" to less than a third.  Unfortunately, the number depending on
      qapi-types.h shrinks only a little.  More work is needed for that one.
      Signed-off-by: NMarkus Armbruster <armbru@redhat.com>
      [Fix compilation without the spice devel packages. - Paolo]
      Signed-off-by: NPaolo Bonzini <pbonzini@redhat.com>
      da34e65c
  16. 08 3月, 2016 1 次提交
  17. 23 2月, 2016 1 次提交
  18. 07 2月, 2016 2 次提交
  19. 03 2月, 2016 2 次提交
  20. 19 1月, 2016 1 次提交
  21. 15 1月, 2016 1 次提交
  22. 23 12月, 2015 3 次提交
  23. 17 12月, 2015 5 次提交
  24. 15 12月, 2015 1 次提交
    • G
      fw_cfg: remove offset argument from callback prototype · 3f8752b4
      Gabriel L. Somlo 提交于
      Read callbacks are now only invoked at item selection, before any
      data is read. As such, the value of the offset argument passed to
      the callback will always be 0. Also, the two callback instances
      currently in use both leave their offset argument unused.
      
      This patch removes the offset argument from the fw_cfg read callback
      prototype, and from the currently available instances. The unused
      (write) callback prototype is also removed (write support was removed
      earlier, in commit 023e3148).
      
      Cc: Laszlo Ersek <lersek@redhat.com>
      Cc: Gerd Hoffmann <kraxel@redhat.com>
      Cc: Marc Marí <markmb@redhat.com>
      Signed-off-by: NGabriel Somlo <somlo@cmu.edu>
      Reviewed-by: NLaszlo Ersek <lersek@redhat.com>
      Message-id: 1446733972-1602-4-git-send-email-somlo@cmu.edu
      Signed-off-by: NGerd Hoffmann <kraxel@redhat.com>
      3f8752b4
  25. 03 11月, 2015 2 次提交