1. 27 9月, 2018 1 次提交
    • G
      display/stdvga: add edid support. · d46b40fc
      Gerd Hoffmann 提交于
      This patch adds edid support to the qemu stdvga.  It is turned off by
      default and can be enabled with the new edid property.  The patch also
      adds xres and yres properties to specify the video mode you want the
      guest use.  Works only with edid enabled and updated guest driver.
      
      The mmio bar of the stdvga has some unused address space at the start.
      It was reserved just in case it'll be needed for virtio, but it turned
      out to not be needed for that.  So let's use that region to place the
      EDID data block there.
      Signed-off-by: NGerd Hoffmann <kraxel@redhat.com>
      Message-id: 20180925075646.25114-6-kraxel@redhat.com
      d46b40fc
  2. 03 7月, 2018 1 次提交
    • G
      vga: disable global_vmstate for 3.0+ machine types · 1fcfdc43
      Gerd Hoffmann 提交于
      Move global_vmstate from vga_common_init() parameter to VGACommonState
      field.  Set global_vmstate to true for isa vga devices, so nothing
      changes here.  virtio-vga and secondary-vga already set global_vmstate
      to false so no change here either.  All other pci vga devices get a new
      global-vmstate property, defaulting to false.  A compat property flips
      it to true for older machine types.
      
      With this in place you don't get a vmstate section naming conflict any
      more when adding multiple pci vga devices to your vm.
      Signed-off-by: NGerd Hoffmann <kraxel@redhat.com>
      Message-Id: <20180702163345.17892-1-kraxel@redhat.com>
      1fcfdc43
  3. 26 6月, 2018 1 次提交
  4. 24 5月, 2018 1 次提交
  5. 18 12月, 2017 1 次提交
  6. 01 9月, 2017 1 次提交
    • G
      vga: stop passing pointers to vga_draw_line* functions · 3d90c625
      Gerd Hoffmann 提交于
      Instead pass around the address (aka offset into vga memory).
      Add vga_read_* helper functions which apply vbe_size_mask to
      the address, to make sure the address stays within the valid
      range, similar to the cirrus blitter fixes (commits ffaf8577
      and 026aeffc).
      
      Impact:  DoS for privileged guest users.  qemu crashes with
      a segfault, when hitting the guard page after vga memory
      allocation, while reading vga memory for display updates.
      
      Fixes: CVE-2017-13672
      Cc: P J P <ppandit@redhat.com>
      Reported-by: NDavid Buchanan <d@vidbuchanan.co.uk>
      Signed-off-by: NGerd Hoffmann <kraxel@redhat.com>
      Message-id: 20170828122906.18993-1-kraxel@redhat.com
      3d90c625
  7. 12 7月, 2016 2 次提交
  8. 23 5月, 2016 1 次提交
    • G
      vga: add sr_vbe register set · 94ef4f33
      Gerd Hoffmann 提交于
      Commit "fd3c136b vga: make sure vga register setup for vbe stays intact
      (CVE-2016-3712)." causes a regression.  The win7 installer is unhappy
      because it can't freely modify vga registers any more while in vbe mode.
      
      This patch introduces a new sr_vbe register set.  The vbe_update_vgaregs
      will fill sr_vbe[] instead of sr[].  Normal vga register reads and
      writes go to sr[].  Any sr register read access happens through a new
      sr() helper function which will read from sr_vbe[] with vbe active and
      from sr[] otherwise.
      
      This way we can allow guests update sr[] registers as they want, without
      allowing them disrupt vbe video modes that way.
      
      Cc: qemu-stable@nongnu.org
      Reported-by: NThomas Lamprecht <thomas@lamprecht.org>
      Signed-off-by: NGerd Hoffmann <kraxel@redhat.com>
      Message-id: 1463475294-14119-1-git-send-email-kraxel@redhat.com
      94ef4f33
  9. 23 2月, 2016 1 次提交
  10. 12 6月, 2015 1 次提交
  11. 16 12月, 2014 2 次提交
  12. 30 9月, 2014 3 次提交
  13. 04 9月, 2014 1 次提交
  14. 18 8月, 2014 1 次提交
  15. 06 5月, 2014 1 次提交
    • K
      PortioList: Store PortioList in device state · 848696bf
      Kirill Batuzov 提交于
      PortioList is an abstraction used for construction of MemoryRegionPortioList
      from MemoryRegionPortio. It can be used later to unmap created memory regions.
      It also requires proper cleanup because some of the memory inside is allocated
      dynamically.
      
      By moving PortioList ot device state we make it possible to cleanup later and
      avoid leaking memory.
      
      This change spans several target platforms.  The following testcases cover all
      changed lines:
        qemu-system-ppc -M prep
        qemu-system-i386 -vga qxl
        qemu-system-i386 -M isapc -soundhw adlib -device ib700,id=watchdog0,bus=isa.0
      Signed-off-by: NKirill Batuzov <batuzovk@ispras.ru>
      Reviewed-by: NPaolo Bonzini <pbonzini@redhat.com>
      Signed-off-by: NAndreas Färber <afaerber@suse.de>
      848696bf
  16. 28 4月, 2014 1 次提交
  17. 04 7月, 2013 4 次提交
  18. 16 4月, 2013 3 次提交
    • G
      console: add GraphicHwOps · 380cd056
      Gerd Hoffmann 提交于
      Pass a single GraphicHwOps struct pointer to graphic_console_init,
      instead of a bunch of function pointers.
      Signed-off-by: NGerd Hoffmann <kraxel@redhat.com>
      380cd056
    • G
      console: simplify screendump · 2c62f08d
      Gerd Hoffmann 提交于
      Screendumps are alot simpler as we can update non-active
      QemuConsoles now.  So we only need to update the QemuConsole
      we want write out, then dump the DisplaySurface content into
      a ppm file.  Done.
      
      No console switching needed.  No special support code in the
      gfx card emulation needed.  Zap it all.  Also move ppm_save
      out of the vga code and next to the qmp_screendump function.
      
      For now screen dumping is limited to console #0 (like it used
      to be), even though it is dead simple to extend it to other
      consoles.  I wanna finish the console cleanup before setting
      new qapi interfaces into stone.
      Signed-off-by: NGerd Hoffmann <kraxel@redhat.com>
      Tested-by: NIgor Mitsyanko <i.mitsyanko@gmail.com>
      2c62f08d
    • G
      console: rename vga_hw_*, add QemuConsole param · 1dbfa005
      Gerd Hoffmann 提交于
      Add QemuConsole parameter to vga_hw_*, so the interface allows to update
      non-active consoles (the actual code can't handle this yet, see next
      patch).  Passing NULL is allowed and updates the active console, like
      the functions do today.
      
      While touching all vga_hw_* calls anyway rename that to the functions to
      hardware-neutral graphics_hw_*
      Signed-off-by: NGerd Hoffmann <kraxel@redhat.com>
      1dbfa005
  19. 09 4月, 2013 1 次提交
  20. 18 3月, 2013 1 次提交
  21. 19 12月, 2012 3 次提交
  22. 03 11月, 2012 1 次提交
  23. 01 11月, 2012 1 次提交
    • G
      vga: fix text mode updating · 9678aedd
      Gerd Hoffmann 提交于
      With both text (curses) and graphics (vnc/sdl/spice/...) display active
      vga text mode emulation fails to update both correctly.  Depending on
      whenever vga_update_text() or vga_draw_text() happens to be called first
      only the text display or only the graphics display will see display
      resolution changes and full redraws.
      
      Fix it by calling both text/gfx resize functions in both code paths and
      keep track of full screen redraws needed in VGACommonState fields.
      Signed-off-by: NGerd Hoffmann <kraxel@redhat.com>
      9678aedd
  24. 23 10月, 2012 1 次提交
    • A
      Rename target_phys_addr_t to hwaddr · a8170e5e
      Avi Kivity 提交于
      target_phys_addr_t is unwieldly, violates the C standard (_t suffixes are
      reserved) and its purpose doesn't match the name (most target_phys_addr_t
      addresses are not target specific).  Replace it with a finger-friendly,
      standards conformant hwaddr.
      
      Outstanding patchsets can be fixed up with the command
      
        git rebase -i --exec 'find -name "*.[ch]"
                              | xargs s/target_phys_addr_t/hwaddr/g' origin
      Signed-off-by: NAvi Kivity <avi@redhat.com>
      Signed-off-by: NAnthony Liguori <aliguori@us.ibm.com>
      a8170e5e
  25. 20 10月, 2012 2 次提交
  26. 06 9月, 2012 1 次提交
  27. 14 7月, 2012 1 次提交
  28. 22 6月, 2012 1 次提交
    • G
      vga: make vram size configurable · 4a1e244e
      Gerd Hoffmann 提交于
      Zap the global VGA_RAM_SIZE #define, make the vga ram size configurable
      for standard vga and vmware vga.  cirrus and qxl are left with a fixed
      size (and private VGA_RAM_SIZE #define) for now.
      
      qxl needs some non-trivial adjustments in the mode list handling deal
      with a runtime-configurable size, which calls for a separate qxl patch.
      
      cirrus emulates cards which have 2 MB (isa) and 4 MB (pci), so I guess
      it would make sense to use these sizes.  That change would break
      migration though, so I left it fixed at 8 MB size.  Making it
      configurabls is pretty pointless for cirrus as we have to match real
      hardware.
      Signed-off-by: NGerd Hoffmann <kraxel@redhat.com>
      4a1e244e