1. 19 2月, 2013 1 次提交
  2. 17 1月, 2013 1 次提交
  3. 11 1月, 2013 1 次提交
    • A
      Make all static TypeInfos const · 8c43a6f0
      Andreas Färber 提交于
      Since 39bffca2 (qdev: register all
      types natively through QEMU Object Model), TypeInfo as used in
      the common, non-iterative pattern is no longer amended with information
      and should therefore be const.
      
      Fix the documented QOM examples:
      
       sed -i 's/static TypeInfo/static const TypeInfo/g' include/qom/object.h
      
      Since frequently the wrong examples are being copied by contributors of
      new devices, fix all types in the tree:
      
       sed -i 's/^static TypeInfo/static const TypeInfo/g' */*.c
       sed -i 's/^static TypeInfo/static const TypeInfo/g' */*/*.c
      
      This also avoids to piggy-back these changes onto real functional
      changes or other refactorings.
      Signed-off-by: NAndreas Färber <afaerber@suse.de>
      Signed-off-by: NAnthony Liguori <aliguori@us.ibm.com>
      8c43a6f0
  4. 19 12月, 2012 1 次提交
  5. 04 12月, 2012 1 次提交
    • H
      usb: Don't allow USB_RET_ASYNC for interrupt packets · be41efde
      Hans de Goede 提交于
      It is tempting to use USB_RET_ASYNC for interrupt packets, rather then the
      current NAK + polling approach, but this causes issues for migration, as
      an async completed packet will not getting written back to guest memory until
      the next poll time, and if a migration happens in between it will get lost!
      
      Make an exception for host devices, because:
      1) host-linux actually uses async completion for interrupt endpoints
      2) host devices don't migrate anyways
      
      Ideally we would convert host-linux.c to handle (input) interrupt endpoints in
      a buffered manner like it does for isoc endpoints, keeping multiple urbs
      submitted to ensure the devices timing requirements are met, as well as making
      its interrupt ep handling the same as other usb-devices.
      Signed-off-by: NHans de Goede <hdegoede@redhat.com>
      Signed-off-by: NGerd Hoffmann <kraxel@redhat.com>
      be41efde
  6. 09 11月, 2012 1 次提交
    • H
      usb: split packet result into actual_length + status · 9a77a0f5
      Hans de Goede 提交于
      Since with the ehci and xhci controllers a single packet can be larger
      then maxpacketsize, it is possible for the result of a single packet
      to be both having transferred some data as well as the transfer to have
      an error.
      
      An example would be an input transfer from a bulk endpoint successfully
      receiving 1 or more maxpacketsize packets from the device, followed
      by a packet signalling halt.
      
      While already touching all the devices and controllers handle_packet /
      handle_data / handle_control code, also change the return type of
      these functions to void, solely storing the status in the packet. To
      make the code paths for regular versus async packet handling more
      uniform.
      
      This patch unfortunately is somewhat invasive, since makeing the qemu
      usb core deal with this requires changes everywhere. This patch only
      prepares the usb core for this, all the hcd / device changes are done
      in such a way that there are no functional changes.
      
      This patch has been tested with uhci and ehci hcds, together with usb-audio,
      usb-hid and usb-storage devices, as well as with usb-redir redirection
      with a wide variety of real devices.
      
      Note that there is usually no need to directly set packet->actual_length
      form devices handle_data callback, as that is done by usb_packet_copy()
      Signed-off-by: NHans de Goede <hdegoede@redhat.com>
      Signed-off-by: NGerd Hoffmann <kraxel@redhat.com>
      9a77a0f5
  7. 13 3月, 2012 1 次提交
    • G
      usb: the big rename · f1ae32a1
      Gerd Hoffmann 提交于
      Reorganize usb source files.  Create a new hw/usb/ directory and move
      all usb source code to that place.  Also make filenames a bit more
      descriptive.  Host adapters are prefixed with "hch-" now, usb device
      emulations are prefixed with "dev-".  Fixup paths Makefile and include
      paths to make it compile.  No code changes.
      Signed-off-by: NGerd Hoffmann <kraxel@redhat.com>
      f1ae32a1
  8. 27 2月, 2012 1 次提交
  9. 15 2月, 2012 1 次提交
  10. 10 2月, 2012 2 次提交
    • G
      usb: Set USBEndpoint in usb_packet_setup(). · 079d0b7f
      Gerd Hoffmann 提交于
      With the separation of the device lookup (via usb_find_device) and
      packet processing we can lookup device and endpoint before setting up
      the usb packet.  So we can initialize USBPacket->ep early and keep it
      valid for the whole lifecycle of the USBPacket.  Also the devaddr and
      devep fields are not needed any more.
      Signed-off-by: NGerd Hoffmann <kraxel@redhat.com>
      079d0b7f
    • G
      usb: kill handle_packet callback · 7f74a56b
      Gerd Hoffmann 提交于
      All drivers except usb-hub use usb_generic_handle_packet.  The only
      reason the usb hub has its own function is that it used to be called
      with packets which are intended for downstream devices.  With the new,
      separate device lookup step this doesn't happen any more, so the need
      for a different handle_packet callback is gone.
      
      So we can kill the handle_packet callback and just call
      usb_generic_handle_packet directly.  The special hub handling in
      usb_handle_packet() can go away for the same reason.
      Signed-off-by: NGerd Hoffmann <kraxel@redhat.com>
      7f74a56b
  11. 05 2月, 2012 2 次提交
  12. 28 1月, 2012 1 次提交
  13. 21 8月, 2011 1 次提交
  14. 04 8月, 2011 2 次提交
    • G
      usb: use iovecs in USBPacket · 4f4321c1
      Gerd Hoffmann 提交于
      Zap data pointer from USBPacket, add a QEMUIOVector instead.
      Add a bunch of helper functions to manage USBPacket data.
      Switch over users to the new interface.
      
      Note that USBPacket->len was used for two purposes:  First to
      pass in the buffer size and second to return the number of
      transfered bytes or the status code on async transfers.  There
      is a new result variable for the latter.  A new status code
      was added to catch uninitialized result.
      
      Nobody creates iovecs with more than one element (yet).
      Some users are (temporarely) limited to iovecs with a single
      element to keep the patch size as small as possible.
      Signed-off-by: NGerd Hoffmann <kraxel@redhat.com>
      4f4321c1
    • G
      re-activate usb-host for bsd · fa57ee8e
      Gerd Hoffmann 提交于
      A bunch of code was disabled via #if 0, for a quite long time (since
      Sept 2009).  Surprisingly the code builds just fine when they are
      removed (tested on OpenBSD).  /me wonders nevertheless whenever there
      are any users of those bits when this went unnoticed for almost two
      years ...
      Signed-off-by: NGerd Hoffmann <kraxel@redhat.com>
      fa57ee8e
  15. 23 6月, 2011 1 次提交
    • H
      usb: Add a speedmask to devices · ba3f9bfb
      Hans de Goede 提交于
      This is used to indicate at which speed[s] the device can operate,
      so that this can be checked to match the ports capabilities when it gets
      attached to a bus.
      
      Note that currently all usb1 emulated device claim to be fullspeed, this
      seems to not cause any problems, but still seems wrong, because with real
      hardware keyboards, mice and tablets usually are lo-speed, so reporting these
      as fullspeed devices seems wrong.
      Signed-off-by: NGerd Hoffmann <kraxel@redhat.com>
      ba3f9bfb
  16. 08 6月, 2011 1 次提交
  17. 26 5月, 2011 1 次提交
  18. 04 4月, 2011 1 次提交
  19. 09 1月, 2011 1 次提交
  20. 12 12月, 2009 3 次提交
  21. 30 11月, 2009 1 次提交
  22. 12 9月, 2009 1 次提交
  23. 08 9月, 2009 1 次提交
  24. 08 3月, 2009 1 次提交
  25. 07 3月, 2009 1 次提交
  26. 06 3月, 2009 1 次提交
    • A
      monitor: Rework API (Jan Kiszka) · 376253ec
      aliguori 提交于
      Refactor the monitor API and prepare it for decoupled terminals:
      term_print functions are renamed to monitor_* and all monitor services
      gain a new parameter (mon) that will once refer to the monitor instance
      the output is supposed to appear on. However, the argument remains
      unused for now. All monitor command callbacks are also extended by a mon
      parameter so that command handlers are able to pass an appropriate
      reference to monitor output services.
      
      For the case that monitor outputs so far happen without clearly
      identifiable context, the global variable cur_mon is introduced that
      shall once provide a pointer either to the current active monitor (while
      processing commands) or to the default one. On the mid or long term,
      those use case will be obsoleted so that this variable can be removed
      again.
      
      Due to the broad usage of the monitor interface, this patch mostly deals
      with converting users of the monitor API. A few of them are already
      extended to pass 'mon' from the command handler further down to internal
      functions that invoke monitor_printf.
      
      At this chance, monitor-related prototypes are moved from console.h to
      a new monitor.h. The same is done for the readline API.
      Signed-off-by: NJan Kiszka <jan.kiszka@siemens.com>
      Signed-off-by: NAnthony Liguori <aliguori@us.ibm.com>
      
      
      git-svn-id: svn://svn.savannah.nongnu.org/qemu/trunk@6711 c046a42c-6fe2-441c-8c8c-71466251a162
      376253ec
  27. 06 2月, 2009 1 次提交
  28. 15 1月, 2009 1 次提交
  29. 06 12月, 2008 1 次提交
  30. 23 11月, 2008 1 次提交