Skip to content

blk-cgroup: wait for blkcg cleanup before initializing new disk#625

Open
blktests-ci[bot] wants to merge 1 commit intolinus-master_basefrom
series/1063567=>linus-master
Open

blk-cgroup: wait for blkcg cleanup before initializing new disk#625
blktests-ci[bot] wants to merge 1 commit intolinus-master_basefrom
series/1063567=>linus-master

Conversation

@blktests-ci
Copy link

@blktests-ci blktests-ci bot commented Mar 10, 2026

Pull request for series with
subject: blk-cgroup: wait for blkcg cleanup before initializing new disk
version: 1
url: https://patchwork.kernel.org/project/linux-block/list/?series=1063567

@blktests-ci
Copy link
Author

blktests-ci bot commented Mar 10, 2026

Upstream branch: 1f318b9
series: https://patchwork.kernel.org/project/linux-block/list/?series=1063567
version: 1

@blktests-ci
Copy link
Author

blktests-ci bot commented Mar 11, 2026

Upstream branch: 1f318b9
series: https://patchwork.kernel.org/project/linux-block/list/?series=1064766
version: 2

@blktests-ci blktests-ci bot added V2 and removed V1 V1-ci-fail labels Mar 11, 2026
@blktests-ci blktests-ci bot force-pushed the series/1063567=>linus-master branch from b5dff09 to 87822d8 Compare March 11, 2026 03:38
@blktests-ci blktests-ci bot force-pushed the linus-master_base branch from 1f19ba6 to e79276a Compare March 11, 2026 08:02
@blktests-ci
Copy link
Author

blktests-ci bot commented Mar 11, 2026

Upstream branch: None
series: https://patchwork.kernel.org/project/linux-block/list/?series=1064766
version: 2

@blktests-ci blktests-ci bot force-pushed the series/1063567=>linus-master branch from 87822d8 to 106f9e2 Compare March 11, 2026 08:03
@blktests-ci
Copy link
Author

blktests-ci bot commented Mar 11, 2026

Upstream branch: None
series: https://patchwork.kernel.org/project/linux-block/list/?series=1064766
version: 2

@blktests-ci blktests-ci bot force-pushed the series/1063567=>linus-master branch from 106f9e2 to 9860114 Compare March 11, 2026 09:48
@blktests-ci blktests-ci bot force-pushed the linus-master_base branch from e79276a to 0dd9afc Compare March 12, 2026 01:40
@blktests-ci
Copy link
Author

blktests-ci bot commented Mar 12, 2026

Upstream branch: 80234b5
series: https://patchwork.kernel.org/project/linux-block/list/?series=1064766
version: 2

@blktests-ci blktests-ci bot force-pushed the series/1063567=>linus-master branch from 9860114 to a8dcfd3 Compare March 12, 2026 01:41
@blktests-ci blktests-ci bot force-pushed the linus-master_base branch from 0dd9afc to 2e598ed Compare March 13, 2026 07:29
When a queue is shared across disk rebind (e.g., SCSI unbind/bind), the
previous disk's blkcg state is cleaned up asynchronously via
disk_release() -> blkcg_exit_disk(). If the new disk's blkcg_init_disk()
runs before that cleanup finishes, we may overwrite q->root_blkg while
the old one is still alive, and radix_tree_insert() in blkg_create()
fails with -EEXIST because the old blkg entries still occupy the same
queue id slot in blkcg->blkg_tree. This causes the sd probe to fail
with -ENOMEM.

Fix it by waiting in blkcg_init_disk() for root_blkg to become NULL,
which indicates the previous disk's blkcg cleanup has completed.

Fixes: 1059699 ("block: move blkcg initialization/destroy into disk allocation/release handler")
Cc: Yi Zhang <yi.zhang@redhat.com>
Signed-off-by: Ming Lei <ming.lei@redhat.com>
Reviewed-by: Christoph Hellwig <hch@lst.de>
@blktests-ci
Copy link
Author

blktests-ci bot commented Mar 13, 2026

Upstream branch: 0257f64
series: https://patchwork.kernel.org/project/linux-block/list/?series=1064766
version: 2

@blktests-ci blktests-ci bot force-pushed the series/1063567=>linus-master branch from a8dcfd3 to fd75f1f Compare March 13, 2026 07:30
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

0 participants