qemu-commits
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[Qemu-commits] [qemu/qemu] ddf2d9: qemu-iotests: reduce chance of races


From: GitHub
Subject: [Qemu-commits] [qemu/qemu] ddf2d9: qemu-iotests: reduce chance of races in 185
Date: Thu, 17 May 2018 05:18:27 -0700

  Branch: refs/heads/master
  Home:   https://github.com/qemu/qemu
  Commit: ddf2d98a94c8a98a661a217fb629cfd15f4dcec7
      
https://github.com/qemu/qemu/commit/ddf2d98a94c8a98a661a217fb629cfd15f4dcec7
  Author: Stefan Hajnoczi <address@hidden>
  Date:   2018-05-16 (Wed, 16 May 2018)

  Changed paths:
    M tests/qemu-iotests/185

  Log Message:
  -----------
  qemu-iotests: reduce chance of races in 185

Commit 8565c3ab537e78f3e69977ec2c609dc9417a806e ("qemu-iotests: fix
185") identified a race condition in a sub-test.

Similar issues also affect the other sub-tests.  If disk I/O completes
quickly, it races with the QMP 'quit' command.  This causes spurious
test failures because QMP events are emitted in an unpredictable order.

This test relies on QEMU internals and there is no QMP API for getting
deterministic behavior needed to make this test 100% reliable.  At the
same time, the test is useful and it would be a shame to remove it.

Add sleep 0.5 to reduce the chance of races.  This is not a real fix but
appears to reduce spurious failures in practice.

Cc: Vladimir Sementsov-Ogievskiy <address@hidden>
Signed-off-by: Stefan Hajnoczi <address@hidden>
Reviewed-by: Eric Blake <address@hidden>
Message-id: address@hidden
Reviewed-by: Jeff Cody <address@hidden>
Signed-off-by: Jeff Cody <address@hidden>


  Commit: 4c7e813ce964e230bb55cf4afc862ccb091ca3a3
      
https://github.com/qemu/qemu/commit/4c7e813ce964e230bb55cf4afc862ccb091ca3a3
  Author: Stefan Hajnoczi <address@hidden>
  Date:   2018-05-16 (Wed, 16 May 2018)

  Changed paths:
    M blockjob.c
    M tests/qemu-iotests/185
    M tests/qemu-iotests/185.out

  Log Message:
  -----------
  blockjob: do not cancel timer in resume

Currently the timer is cancelled and the block job is entered by
block_job_resume().  This behavior causes drain to run extra blockjob
iterations when the job was sleeping due to the ratelimit.

This patch leaves the job asleep when block_job_resume() is called.
Jobs can still be forcibly woken up using block_job_enter(), which is
used to cancel jobs.

After this patch drain no longer runs extra blockjob iterations.  This
is the expected behavior that qemu-iotests 185 used to rely on.  We
temporarily changed the 185 test output to make it pass for the QEMU
2.12 release but now it's time to address this issue.

Cc: QingFeng Hao <address@hidden>
Signed-off-by: Stefan Hajnoczi <address@hidden>
Reviewed-by: Eric Blake <address@hidden>
Reviewed-by: QingFeng Hao <address@hidden>
Message-id: address@hidden
Reviewed-by: Jeff Cody <address@hidden>
Signed-off-by: Jeff Cody <address@hidden>


  Commit: 54b7af4369a37afbd82573d0dcfb27febdb6dd24
      
https://github.com/qemu/qemu/commit/54b7af4369a37afbd82573d0dcfb27febdb6dd24
  Author: Kevin Wolf <address@hidden>
  Date:   2018-05-16 (Wed, 16 May 2018)

  Changed paths:
    M block/nfs.c

  Log Message:
  -----------
  nfs: Fix error path in nfs_options_qdict_to_qapi()

Don't throw away local_err, but propagate it to errp.

Signed-off-by: Kevin Wolf <address@hidden>
Message-id: address@hidden
Reviewed-by: Eric Blake <address@hidden>
Reviewed-by: Jeff Cody <address@hidden>
Signed-off-by: Jeff Cody <address@hidden>


  Commit: c82be42cc803b36fd7aed5dceec68312c7056fd5
      
https://github.com/qemu/qemu/commit/c82be42cc803b36fd7aed5dceec68312c7056fd5
  Author: Kevin Wolf <address@hidden>
  Date:   2018-05-16 (Wed, 16 May 2018)

  Changed paths:
    M block/nfs.c

  Log Message:
  -----------
  nfs: Remove processed options from QDict

Commit c22a03454 QAPIfied option parsing in the NFS block driver, but
forgot to remove all the options we processed. Therefore, we get an
error in bdrv_open_inherit(), which thinks the remaining options are
invalid. Trying to open an NFS image will result in an error like this:

    Block protocol 'nfs' doesn't support the option 'server.host'

Remove all options from the QDict to make the NFS driver work again.

Cc: address@hidden
Signed-off-by: Kevin Wolf <address@hidden>
Message-id: address@hidden
Reviewed-by: Eric Blake <address@hidden>
Reviewed-by: Jeff Cody <address@hidden>
Signed-off-by: Jeff Cody <address@hidden>


  Commit: a4207e3b00e89f934adb231057dcf9a75ac2ae45
      
https://github.com/qemu/qemu/commit/a4207e3b00e89f934adb231057dcf9a75ac2ae45
  Author: Peter Maydell <address@hidden>
  Date:   2018-05-17 (Thu, 17 May 2018)

  Changed paths:
    M block/nfs.c
    M blockjob.c
    M tests/qemu-iotests/185
    M tests/qemu-iotests/185.out

  Log Message:
  -----------
  Merge remote-tracking branch 'remotes/cody/tags/block-pull-request' into 
staging

# gpg: Signature made Wed 16 May 2018 18:38:15 BST
# gpg:                using RSA key BDBE7B27C0DE3057
# gpg: Good signature from "Jeffrey Cody <address@hidden>"
# gpg:                 aka "Jeffrey Cody <address@hidden>"
# gpg:                 aka "Jeffrey Cody <address@hidden>"
# Primary key fingerprint: 9957 4B4D 3474 90E7 9D98  D624 BDBE 7B27 C0DE 3057

* remotes/cody/tags/block-pull-request:
  nfs: Remove processed options from QDict
  nfs: Fix error path in nfs_options_qdict_to_qapi()
  blockjob: do not cancel timer in resume
  qemu-iotests: reduce chance of races in 185

Signed-off-by: Peter Maydell <address@hidden>


Compare: https://github.com/qemu/qemu/compare/eb7514ae10d1...a4207e3b00e8
      **NOTE:** This service been marked for deprecation: 
https://developer.github.com/changes/2018-04-25-github-services-deprecation/

      Functionality will be removed from GitHub.com on January 31st, 2019.

reply via email to

[Prev in Thread] Current Thread [Next in Thread]