libceph: fix linger request requeuing
authorSage Weil <sage@newdream.net>
Fri, 16 Sep 2011 18:13:17 +0000 (11:13 -0700)
committerSage Weil <sage@newdream.net>
Fri, 16 Sep 2011 18:13:17 +0000 (11:13 -0700)
commit935b639a049053d0ccbcf7422f2f9cd221642f58
treecee4fa3f82256314393b26bd5857d9564513ee04
parent1cad78932a0d139dceff78e68808e160a224d57a
libceph: fix linger request requeuing

The r_req_lru_item list node moves between several lists, and that cycle
is not directly related (and does not begin) with __register_request().
Initialize it in the request constructor, not __register_request(). This
fixes later badness (below) when OSDs restart underneath an rbd mount.

Crashes we've seen due to this include:

[  213.974288] kernel BUG at net/ceph/messenger.c:2193!

and

[  144.035274] BUG: unable to handle kernel NULL pointer dereference at 0000000000000048
[  144.035278] IP: [<ffffffffa036c053>] con_work+0x1463/0x2ce0 [libceph]

Signed-off-by: Sage Weil <sage@newdream.net>
net/ceph/osd_client.c