Skip to content
Snippets Groups Projects
  1. Mar 12, 2018
  2. Mar 05, 2018
  3. Feb 09, 2018
  4. Feb 06, 2018
  5. Jan 16, 2018
    • Eric Blake's avatar
      maint: Fix macros with broken 'do/while(0); ' usage · 2562755e
      Eric Blake authored
      
      The point of writing a macro embedded in a 'do { ... } while (0)'
      loop (particularly if the macro has multiple statements or would
      otherwise end with an 'if' statement) is so that the macro can be
      used as a drop-in statement with the caller supplying the
      trailing ';'.  Although our coding style frowns on brace-less 'if':
        if (cond)
          statement;
        else
          something else;
      that is the classic case where failure to use do/while(0) wrapping
      would cause the 'else' to pair with any embedded 'if' in the macro
      rather than the intended outer 'if'.  But conversely, if the macro
      includes an embedded ';', then the same brace-less coding style
      would now have two statements, making the 'else' a syntax error
      rather than pairing with the outer 'if'.  Thus, even though our
      coding style with required braces is not impacted, ending a macro
      with ';' makes our code harder to port to projects that use
      brace-less styles.
      
      The change should have no semantic impact.  I was not able to
      fully compile-test all of the changes (as some of them are
      examples of the ugly bit-rotting debug print statements that are
      completely elided by default, and I didn't want to recompile
      with the necessary -D witnesses - cleaning those up is left as a
      bite-sized task for another day); I did, however, audit that for
      all files touched, all callers of the changed macros DID supply
      a trailing ';' at the callsite, and did not appear to be used
      as part of a brace-less conditional.
      
      Found mechanically via: $ git grep -B1 'while (0);' | grep -A1 \\\\
      
      Signed-off-by: default avatarEric Blake <eblake@redhat.com>
      Acked-by: default avatarCornelia Huck <cohuck@redhat.com>
      Reviewed-by: default avatarMichael S. Tsirkin <mst@redhat.com>
      Acked-by: default avatarDr. David Alan Gilbert <dgilbert@redhat.com>
      Message-Id: <20171201232433.25193-7-eblake@redhat.com>
      Reviewed-by: default avatarJuan Quintela <quintela@redhat.com>
      Signed-off-by: default avatarPaolo Bonzini <pbonzini@redhat.com>
      2562755e
  6. Sep 22, 2017
  7. Aug 01, 2017
  8. Jul 31, 2017
  9. Jul 17, 2017
  10. May 04, 2017
  11. Mar 01, 2017
    • Thomas Huth's avatar
      audio/sdlaudio: Allow audio playback with SDL2 · bcf19777
      Thomas Huth authored
      
      When compiling with SDL2, the semaphore trick used in sdlaudio.c
      does not work - QEMU locks up completely in this case. To avoid
      the hang and get at least some audio playback up and running (it's
      a little bit crackling, but better than nothing), we can use the
      SDL locking functions SDL_LockAudio() and SDL_UnlockAudio() to sync
      with the sound playback thread instead.
      
      Signed-off-by: default avatarThomas Huth <thuth@redhat.com>
      Message-id: 1485852398-2327-1-git-send-email-thuth@redhat.com
      Signed-off-by: default avatarGerd Hoffmann <kraxel@redhat.com>
      bcf19777
    • Pavel Dovgaluk's avatar
      audio: make audio poll timer deterministic · 1ffc2665
      Pavel Dovgaluk authored
      
      This patch changes resetting strategy of the audio polling timer.
      It does not change expiration time if the timer is already set.
      This patch is needed to make this timer deterministic and to use execution
      record/replay for audio devices.
      
      audio_reset_timer is used in the function audio_vm_change_state_handler.
      Therefore every time VM is stopped or restarted the timer will be reset
      to new timeout. Virtual clock does not proceed while VM is stopped.
      Therefore there is no need in resetting the timeout when VM restarts.
      
      v2: updated commit message
      v3: now using timer_mod_anticipate function (as suggested by Yurii Zubrytskyi)
      
      Signed-off-by: default avatarPavel Dovgalyuk <pavel.dovgaluk@ispras.ru>
      Message-id: 20170214071510.6112.76764.stgit@PASHA-ISP
      Signed-off-by: default avatarGerd Hoffmann <kraxel@redhat.com>
      1ffc2665
    • Pavel Dovgaluk's avatar
      replay: add record/replay for audio passthrough · 3d4d16f4
      Pavel Dovgaluk authored
      
      This patch adds recording and replaying audio data. Is saves synchronization
      information for audio out and inputs from the microphone.
      
      v2: removed unneeded whitespace change
      
      Signed-off-by: default avatarPavel Dovgalyuk <pavel.dovgaluk@ispras.ru>
      Message-id: 20170202055054.4848.94901.stgit@PASHA-ISP.lan02.inno
      
      [ kraxel: add qemu/error-report.h include to fix osx build failure ]
      
      Signed-off-by: default avatarGerd Hoffmann <kraxel@redhat.com>
      3d4d16f4
  12. Aug 12, 2016
  13. Aug 08, 2016
  14. Jul 12, 2016
  15. Jun 20, 2016
  16. Jun 16, 2016
  17. Jun 03, 2016
  18. May 19, 2016
  19. May 18, 2016
  20. Mar 22, 2016
  21. Feb 23, 2016
  22. Feb 02, 2016
  23. Jan 13, 2016
  24. Dec 15, 2015
Loading