1. 11 5月, 2017 1 次提交
  2. 25 4月, 2017 1 次提交
  3. 14 3月, 2017 1 次提交
  4. 07 10月, 2016 1 次提交
  5. 23 9月, 2016 2 次提交
  6. 15 9月, 2016 1 次提交
  7. 18 5月, 2016 1 次提交
  8. 04 4月, 2016 1 次提交
  9. 23 3月, 2016 2 次提交
  10. 01 3月, 2016 1 次提交
  11. 08 2月, 2016 1 次提交
  12. 17 12月, 2015 2 次提交
    • E
      qapi: Change munging of CamelCase enum values · d20a580b
      Eric Blake 提交于
      When munging enum values, the fact that we were passing the entire
      prefix + value through camel_to_upper() meant that enum values
      spelled with CamelCase could be turned into CAMEL_CASE.  However,
      this provides a potential collision (both OneTwo and One-Two would
      munge into ONE_TWO) for enum types, when the same two names are
      valid side-by-side as QAPI member names.  By changing the generation
      of enum constants to always be prefix + '_' + c_name(value,
      False).upper(), and ensuring that there are no case collisions (in
      the next patches), we no longer have to worry about names that
      would be distinct as QAPI members but collide as variant tag names,
      without having to think about what munging the heuristics in
      camel_to_upper() will actually perform on an enum value.
      
      Making the change will affect enums that did not follow coding
      conventions, using 'CamelCase' rather than desired 'lower-case'.
      
      Thankfully, there are only two culprits: InputButton and ErrorClass.
      We already tweaked ErrorClass to make it an alias of QapiErrorClass,
      where only the alias needs changing rather than the whole tree.  So
      the bulk of this change is modifying INPUT_BUTTON_WHEEL_UP to the
      new INPUT_BUTTON_WHEELUP (and likewise for WHEELDOWN).  That part
      of this commit may later need reverting if we rename the enum
      constants from 'WheelUp' to 'wheel-up' as part of moving
      x-input-send-event to a stable interface; but at least we have
      documentation bread crumbs in place to remind us (commit 513e7cdb),
      and it matches the fact that SDL constants are also spelled
      SDL_BUTTON_WHEELUP.
      
      Suggested by: Markus Armbruster <armbru@redhat.com>
      Signed-off-by: NEric Blake <eblake@redhat.com>
      Message-Id: <1447836791-369-27-git-send-email-eblake@redhat.com>
      [Commit message tweaked]
      Signed-off-by: NMarkus Armbruster <armbru@redhat.com>
      d20a580b
    • E
      qapi: Don't let implicit enum MAX member collide · 7fb1cf16
      Eric Blake 提交于
      Now that we guarantee the user doesn't have any enum values
      beginning with a single underscore, we can use that for our
      own purposes.  Renaming ENUM_MAX to ENUM__MAX makes it obvious
      that the sentinel is generated.
      
      This patch was mostly generated by applying a temporary patch:
      
      |diff --git a/scripts/qapi.py b/scripts/qapi.py
      |index e6d014b..b862ec9 100644
      |--- a/scripts/qapi.py
      |+++ b/scripts/qapi.py
      |@@ -1570,6 +1570,7 @@ const char *const %(c_name)s_lookup[] = {
      |     max_index = c_enum_const(name, 'MAX', prefix)
      |     ret += mcgen('''
      |     [%(max_index)s] = NULL,
      |+// %(max_index)s
      | };
      | ''',
      |                max_index=max_index)
      
      then running:
      
      $ cat qapi-{types,event}.c tests/test-qapi-types.c |
          sed -n 's,^// \(.*\)MAX,s|\1MAX|\1_MAX|g,p' > list
      $ git grep -l _MAX | xargs sed -i -f list
      
      The only things not generated are the changes in scripts/qapi.py.
      
      Rejecting enum members named 'MAX' is now useless, and will be dropped
      in the next patch.
      Signed-off-by: NEric Blake <eblake@redhat.com>
      Message-Id: <1447836791-369-23-git-send-email-eblake@redhat.com>
      Reviewed-by: NJuan Quintela <quintela@redhat.com>
      [Rebased to current master, commit message tweaked]
      Signed-off-by: NMarkus Armbruster <armbru@redhat.com>
      7fb1cf16
  13. 02 12月, 2015 1 次提交
  14. 11 11月, 2015 2 次提交
  15. 16 10月, 2015 2 次提交
  16. 14 10月, 2015 1 次提交
  17. 26 9月, 2015 3 次提交
  18. 19 9月, 2015 1 次提交
  19. 19 6月, 2015 3 次提交
  20. 19 5月, 2015 9 次提交
  21. 22 9月, 2014 1 次提交
    • S
      block: delete cow block driver · 550830f9
      Stefan Hajnoczi 提交于
      This patch removes support for the cow file format.
      
      Normally we do not break backwards compatibility but in this case there
      is no impact and it is the most logical option.  Extraordinary claims
      require extraordinary evidence so I will show why removing the cow block
      driver is the right thing to do.
      
      The cow file format is the disk image format for Usermode Linux, a way
      of running a Linux system in userspace.  The performance of UML was
      never great and it was hacky, but it enjoyed some popularity before
      hardware virtualization support became mainstream.
      
      QEMU's block/cow.c is supposed to read this image file format.
      Unfortunately the file format was underspecified:
      
      1. Earlier Linux versions used the MAXPATHLEN constant for the backing
         filename field.  The value of MAXPATHLEN can change, so Linux
         switched to a 4096 literal but QEMU has a 1024 literal.
      
      2. Padding was not used on the header struct (both in the Linux kernel
         and in QEMU) so the struct layout varied across architectures.  In
         particular, i386 and x86_64 were different due to int64_t alignment
         differences.  Linux now uses __attribute__((packed)), QEMU does not.
      
      Therefore:
      
      1. QEMU cow images do not conform to the Linux cow image file format.
      
      2. cow images cannot be shared between different host architectures.
      
      This means QEMU cow images are useless and QEMU has not had bug reports
      from users actually hitting these issues.
      
      Let's get rid of this thing, it serves no purpose and no one will be
      affected.
      Signed-off-by: NStefan Hajnoczi <stefanha@redhat.com>
      Reviewed-by: NMarkus Armbruster <armbru@redhat.com>
      Message-id: 1410877464-20481-1-git-send-email-stefanha@redhat.com
      Signed-off-by: NStefan Hajnoczi <stefanha@redhat.com>
      550830f9
  22. 30 6月, 2014 2 次提交
    • P
      ui/cocoa: Honour -show-cursor command line option · 13aefd30
      Peter Maydell 提交于
      Honour the -show-cursor command line option (which forces the mouse pointer
      to always be displayed even when input is grabbed) in the Cocoa UI backend.
      Signed-off-by: NPeter Maydell <peter.maydell@linaro.org>
      Message-id: 1403516125-14568-5-git-send-email-peter.maydell@linaro.org
      13aefd30
    • P
      ui/cocoa: Fix handling of absolute positioning devices · f61c387e
      Peter Maydell 提交于
      Fix handling of absolute positioning devices, which were basically
      unusable for two separate reasons:
       (1) as soon as you pressed the left mouse button we would call
           CGAssociateMouseAndMouseCursorPosition(FALSE), which means that
           the absolute coordinates of the mouse events are never updated
       (2) we didn't account for MacOSX coordinate origin being bottom left
           rather than top right, and so all the Y values sent to the guest
           were inverted
      
      We fix (1) by aligning our behaviour with the SDL UI backend for
      absolute devices:
       * when the mouse moves into the window we do a grab (which means
         hiding the host cursor and sending special keys to the guest)
       * when the mouse moves out of the window we un-grab
      and fix (2) by doing the correct transformation in the call to
      qemu_input_queue_abs().
      Signed-off-by: NPeter Maydell <peter.maydell@linaro.org>
      Message-id: 1403516125-14568-4-git-send-email-peter.maydell@linaro.org
      f61c387e