ceph: properly queue cap snap for newly created snap realm
authorYan, Zheng <zyan@redhat.com>
Fri, 22 Sep 2017 01:26:57 +0000 (09:26 +0800)
committerIlya Dryomov <idryomov@gmail.com>
Mon, 2 Oct 2017 14:18:01 +0000 (16:18 +0200)
commit9f4057fc937f200f000dbc378c5c3e37d45e31dc
tree7437f82c8565c8e404df28bb84c1a53ef159d4d7
parent9e66317d3c92ddaab330c125dfe9d06eee268aff
ceph: properly queue cap snap for newly created snap realm

commit 3ae0bebc "ceph: queue cap snap only when snap realm's
context changes" introduced a regression: we may not call
queue_realm_cap_snaps() for newly created snap realm. This
regression allows unflushed snapshot data to be overwritten.

Link: http://tracker.ceph.com/issues/21483
Signed-off-by: "Yan, Zheng" <zyan@redhat.com>
Signed-off-by: Ilya Dryomov <idryomov@gmail.com>
fs/ceph/snap.c