]> git.ipfire.org Git - people/ms/linux.git/commitdiff
libceph: assert both regular and lingering lists in __remove_osd()
authorIlya Dryomov <ilya.dryomov@inktank.com>
Wed, 18 Jun 2014 09:02:12 +0000 (13:02 +0400)
committerJiri Slaby <jslaby@suse.cz>
Thu, 5 Mar 2015 14:36:57 +0000 (15:36 +0100)
commit 7c6e6fc53e7335570ed82f77656cedce1502744e upstream.

It is important that both regular and lingering requests lists are
empty when the OSD is removed.

Signed-off-by: Ilya Dryomov <ilya.dryomov@inktank.com>
Reviewed-by: Alex Elder <elder@linaro.org>
Signed-off-by: Jiri Slaby <jslaby@suse.cz>
net/ceph/osd_client.c

index e6b2db68b4fa886c535a5a3bdb276cac9c2ad3db..4e24b73385826be2f425ddb848adc0c5a9a20641 100644 (file)
@@ -976,6 +976,8 @@ static void __remove_osd(struct ceph_osd_client *osdc, struct ceph_osd *osd)
 {
        dout("__remove_osd %p\n", osd);
        BUG_ON(!list_empty(&osd->o_requests));
+       BUG_ON(!list_empty(&osd->o_linger_requests));
+
        rb_erase(&osd->o_node, &osdc->osds);
        list_del_init(&osd->o_osd_lru);
        ceph_con_close(&osd->o_con);