diff options
author | Linus Torvalds <torvalds@linux-foundation.org> | 2013-04-17 21:52:02 +0200 |
---|---|---|
committer | Linus Torvalds <torvalds@linux-foundation.org> | 2013-04-17 21:52:02 +0200 |
commit | 96d8683483b7eb194609edd1afe9143a0467b7d3 (patch) | |
tree | 290e5caff3db097e57fb321dcdb5fe7d14463088 /drivers | |
parent | ARM: KVM: fix unbalanced get_cpu() in access_dcsw (diff) | |
parent | rbd: do a safe list traversal in rbd_img_request_submit() (diff) | |
download | linux-96d8683483b7eb194609edd1afe9143a0467b7d3.tar.xz linux-96d8683483b7eb194609edd1afe9143a0467b7d3.zip |
Merge branch 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/sage/ceph-client
Pull Ceph fix from Sage Weil:
"It's a simple fix for a hard to hit race, but low-risk and clearly
correct"
* 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/sage/ceph-client:
rbd: do a safe list traversal in rbd_img_request_submit()
Diffstat (limited to 'drivers')
-rw-r--r-- | drivers/block/rbd.c | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/drivers/block/rbd.c b/drivers/block/rbd.c index f556f8a8b3f9..b7b7a88d9f68 100644 --- a/drivers/block/rbd.c +++ b/drivers/block/rbd.c @@ -1742,9 +1742,10 @@ static int rbd_img_request_submit(struct rbd_img_request *img_request) struct rbd_device *rbd_dev = img_request->rbd_dev; struct ceph_osd_client *osdc = &rbd_dev->rbd_client->client->osdc; struct rbd_obj_request *obj_request; + struct rbd_obj_request *next_obj_request; dout("%s: img %p\n", __func__, img_request); - for_each_obj_request(img_request, obj_request) { + for_each_obj_request_safe(img_request, obj_request, next_obj_request) { int ret; obj_request->callback = rbd_img_obj_callback; |