1. 26 4月, 2012 1 次提交
    • G
      usb: add serial number generator · 9d55d1ad
      Gerd Hoffmann 提交于
      This patch adds a function which creates unique serial numbers for usb
      devices and puts it into use.  Windows guests tend to become unhappy if
      they find two identical usb devices in the system.  Effects range from
      non-functional devices (with yellow exclamation mark in device manager)
      to BSODs.  Handing out unique serial numbers to devices fixes this.
      
      With this patch applied almost all emulated devices get a generated,
      unique serial number.  There are two exceptions:
      
       * usb-storage devices will prefer a user-specified serial number
         and will only get a generated number in case the serial property
         is unset.
       * usb-hid devices keep the fixed serial number "42" as it is used
         to signal "remote wakeup actually works".
         See commit 7b074a22Signed-off-by: NGerd Hoffmann <kraxel@redhat.com>
      9d55d1ad
  2. 17 4月, 2012 5 次提交
  3. 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
  4. 27 2月, 2012 1 次提交
    • A
      usb-desc: fix user trigerrable segfaults (!config) · 8db36e9d
      Alon Levy 提交于
      Check for dev->config being NULL in two places:
       USB_REQ_GET_CONFIGURATION and USB_REQ_GET_STATUS.
      
      The behavior of USB_REQ_GET_STATUS is unspecified in the Default state,
      that corresponds to dev->config being NULL (it defaults to NULL and is
      reset whenever a SET_CONFIGURATION with value 0, or attachment). I
      implemented it to correspond with the state before
      ed5a83dd, the commit moving SET_STATUS
      to usb-desc; if dev->config is not set we return whatever is in the
      first configuration.
      
      The behavior of USB_REQ_GET_CONFIGURATION is also undefined before any
      SET_CONFIGURATION, but here we just return 0 (same as specified for the
      Address state).
      
      A win7 guest failed to initialize the device before this patch,
      segfaulting when GET_STATUS was called with dev->config == NULL. With
      this patch the passthrough device still doesn't work but the failure is
      unrelated.
      Signed-off-by: NAlon Levy <alevy@redhat.com>
      Signed-off-by: NGerd Hoffmann <kraxel@redhat.com>
      8db36e9d
  5. 28 1月, 2012 1 次提交
  6. 17 1月, 2012 2 次提交
  7. 13 1月, 2012 3 次提交
  8. 21 8月, 2011 1 次提交
  9. 23 6月, 2011 2 次提交
  10. 26 5月, 2011 3 次提交
  11. 12 1月, 2011 2 次提交
  12. 11 1月, 2011 5 次提交