]> Pileus Git - ~andy/linux/commitdiff
rbd: fix rbd_dev_remove_parent()
authorAlex Elder <elder@inktank.com>
Fri, 26 Apr 2013 20:44:36 +0000 (15:44 -0500)
committerSage Weil <sage@inktank.com>
Thu, 2 May 2013 04:19:54 +0000 (21:19 -0700)
In certain error paths, it is possible for an rbd device to have a
parent spec but no parent rbd_dev.  In rbd_dev_remove_parent() use
the parent field rather than parent_spec in determining whether to
try to remove any parent devices.  Use assertions to indicate that
any non-null parent pointer has parent_spec associated with it.

Signed-off-by: Alex Elder <elder@inktank.com>
Reviewed-by: Josh Durgin <josh.durgin@inktank.com>

No differences found