libceph: don't use rb_init_node() in ceph_osdc_alloc_request()
authorAlex Elder <elder@inktank.com>
Mon, 17 Dec 2012 18:23:48 +0000 (12:23 -0600)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Thu, 17 Jan 2013 16:51:19 +0000 (08:51 -0800)
commit1d2522a000b6f6a0c836d586bbb39bacaae9b390
tree6c70bf7705fbcb354e327d9a88afdd8549818595
parent76fb865bcfeba57652edf054fd36aeed38ba5ceb
libceph: don't use rb_init_node() in ceph_osdc_alloc_request()

The red-black node in the ceph osd request structure is initialized
in ceph_osdc_alloc_request() using rbd_init_node().  We do need to
initialize this, because in __unregister_request() we call
RB_EMPTY_NODE(), which expects the node it's checking to have
been initialized.  But rb_init_node() is apparently overkill, and
may in fact be on its way out.  So use RB_CLEAR_NODE() instead.

For a little more background, see this commit:
    4c199a93 rbtree: empty nodes have no color"

Signed-off-by: Alex Elder <elder@inktank.com>
Reviewed-by: Sage Weil <sage@inktank.com>
(cherry picked from commit a978fa20fb657548561dddbfb605fe43654f0825)
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
net/ceph/osd_client.c