qemu-commits
[Top][All Lists]
Advanced

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

[Qemu-commits] [qemu/qemu] 34afc5: block/iscsi:use the flags in iscsi_op


From: Peter Maydell
Subject: [Qemu-commits] [qemu/qemu] 34afc5: block/iscsi:use the flags in iscsi_open() prevent ...
Date: Fri, 27 Mar 2020 10:45:17 -0700

  Branch: refs/heads/master
  Home:   https://github.com/qemu/qemu
  Commit: 34afc5c298fd4b4279aeec440603b8a1a13ab8c2
      
https://github.com/qemu/qemu/commit/34afc5c298fd4b4279aeec440603b8a1a13ab8c2
  Author: Chen Qun <address@hidden>
  Date:   2020-03-27 (Fri, 27 Mar 2020)

  Changed paths:
    M block/iscsi.c

  Log Message:
  -----------
  block/iscsi:use the flags in iscsi_open() prevent Clang warning

Clang static code analyzer show warning:
  block/iscsi.c:1920:9: warning: Value stored to 'flags' is never read
        flags &= ~BDRV_O_RDWR;
        ^        ~~~~~~~~~~~~

In iscsi_allocmap_init() only checks BDRV_O_NOCACHE, which
is the same in both of flags and bs->open_flags.
We can use the flags instead bs->open_flags to prevent Clang warning.

Reported-by: Euler Robot <address@hidden>
Signed-off-by: Chen Qun <address@hidden>
Reviewed-by: Kevin Wolf <address@hidden>
Message-Id: <address@hidden>
Signed-off-by: Kevin Wolf <address@hidden>


  Commit: 7a26df203c7b2e4a585fc6014358b57a948fb7e0
      
https://github.com/qemu/qemu/commit/7a26df203c7b2e4a585fc6014358b57a948fb7e0
  Author: Vladimir Sementsov-Ogievskiy <address@hidden>
  Date:   2020-03-27 (Fri, 27 Mar 2020)

  Changed paths:
    M block.c

  Log Message:
  -----------
  block: fix bdrv_root_attach_child forget to unref child_bs

bdrv_root_attach_child promises to drop child_bs reference on failure.
It does it on first handled failure path, but not on the second. Fix
that.

Signed-off-by: Vladimir Sementsov-Ogievskiy <address@hidden>
Message-Id: <address@hidden>
Signed-off-by: Kevin Wolf <address@hidden>


  Commit: 6fcc859fc224b80982c94130a9c0e93554e6cbde
      
https://github.com/qemu/qemu/commit/6fcc859fc224b80982c94130a9c0e93554e6cbde
  Author: Minwoo Im <address@hidden>
  Date:   2020-03-27 (Fri, 27 Mar 2020)

  Changed paths:
    M hw/block/trace-events

  Log Message:
  -----------
  nvme: Print 'cqid' for nvme_del_cq

The given argument for this trace should be cqid, not sqid.

Signed-off-by: Minwoo Im <address@hidden>
Message-Id: <address@hidden>
Reviewed-by: Philippe Mathieu-Daudé <address@hidden>
Reviewed-by: Stefano Garzarella <address@hidden>
Signed-off-by: Kevin Wolf <address@hidden>


  Commit: 9178f4fe5f083064f5c91f04d98c815ce5a5af1c
      
https://github.com/qemu/qemu/commit/9178f4fe5f083064f5c91f04d98c815ce5a5af1c
  Author: Kevin Wolf <address@hidden>
  Date:   2020-03-27 (Fri, 27 Mar 2020)

  Changed paths:
    M block/mirror.c

  Log Message:
  -----------
  Revert "mirror: Don't let an operation wait for itself"

This reverts commit 7e6c4ff792734e196c8ca82564c56b5e7c6288ca.

The fix was incomplete as it only protected against requests waiting for
themselves, but not against requests waiting for each other. We need a
different solution.

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


  Commit: ce8cabbd17cf738ddfc68384440c38e5dd2fdf97
      
https://github.com/qemu/qemu/commit/ce8cabbd17cf738ddfc68384440c38e5dd2fdf97
  Author: Kevin Wolf <address@hidden>
  Date:   2020-03-27 (Fri, 27 Mar 2020)

  Changed paths:
    M block/mirror.c

  Log Message:
  -----------
  mirror: Wait only for in-flight operations

mirror_wait_for_free_in_flight_slot() just picks a random operation to
wait for. However, a MirrorOp is already in s->ops_in_flight when
mirror_co_read() waits for free slots, so if not enough slots are
immediately available, an operation can end up waiting for itself, or
two or more operations can wait for each other to complete, which
results in a hang.

Fix this by adding a flag to MirrorOp that tells us if the request is
already in flight (and therefore occupies slots that it will later
free), and picking only such operations for waiting.

Fixes: https://bugzilla.redhat.com/show_bug.cgi?id=1794692
Signed-off-by: Kevin Wolf <address@hidden>
Message-Id: <address@hidden>
Reviewed-by: Eric Blake <address@hidden>
Signed-off-by: Kevin Wolf <address@hidden>


  Commit: df74b1d3dff80983e7a30db1346a4a05847d65fa
      
https://github.com/qemu/qemu/commit/df74b1d3dff80983e7a30db1346a4a05847d65fa
  Author: Kevin Wolf <address@hidden>
  Date:   2020-03-27 (Fri, 27 Mar 2020)

  Changed paths:
    M block/qcow2.h

  Log Message:
  -----------
  qcow2: Remove unused fields from BDRVQcow2State

These fields were already removed in commit c3c10f72, but then commit
b58deb34 revived them probably due to bad merge conflict resolution.
They are still unused, so remove them again.

Fixes: b58deb344ddff3b9d8b265bf73a65274767ee5f4
Signed-off-by: Kevin Wolf <address@hidden>
Message-Id: <address@hidden>
Reviewed-by: Eric Blake <address@hidden>
Reviewed-by: Philippe Mathieu-Daudé <address@hidden>
Signed-off-by: Kevin Wolf <address@hidden>


  Commit: 77a48a743f9e4cc7482568eb417c2b47b0e558cf
      
https://github.com/qemu/qemu/commit/77a48a743f9e4cc7482568eb417c2b47b0e558cf
  Author: Peter Maydell <address@hidden>
  Date:   2020-03-27 (Fri, 27 Mar 2020)

  Changed paths:
    M block.c
    M block/iscsi.c
    M block/mirror.c
    M block/qcow2.h
    M hw/block/trace-events

  Log Message:
  -----------
  Merge remote-tracking branch 'remotes/kevin/tags/for-upstream' into staging

Block layer patches:

- Fix another case of mirror block job deadlocks
- Minor fixes

# gpg: Signature made Fri 27 Mar 2020 15:18:37 GMT
# gpg:                using RSA key 7F09B272C88F2FD6
# gpg: Good signature from "Kevin Wolf <address@hidden>" [full]
# Primary key fingerprint: DC3D EB15 9A9A F95D 3D74  56FE 7F09 B272 C88F 2FD6

* remotes/kevin/tags/for-upstream:
  qcow2: Remove unused fields from BDRVQcow2State
  mirror: Wait only for in-flight operations
  Revert "mirror: Don't let an operation wait for itself"
  nvme: Print 'cqid' for nvme_del_cq
  block: fix bdrv_root_attach_child forget to unref child_bs
  block/iscsi:use the flags in iscsi_open() prevent Clang warning

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


Compare: https://github.com/qemu/qemu/compare/cfe68ae025f7...77a48a743f9e



reply via email to

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