From: Liu Yuan <tailai.ly at taobao.com> We need to notify underlying store when the recovery ends. Signed-off-by: Liu Yuan <tailai.ly at taobao.com> --- sheep/sheep_priv.h | 1 + sheep/store.c | 5 +++++ 2 files changed, 6 insertions(+), 0 deletions(-) diff --git a/sheep/sheep_priv.h b/sheep/sheep_priv.h index aee865d..8a85db5 100644 --- a/sheep/sheep_priv.h +++ b/sheep/sheep_priv.h @@ -177,6 +177,7 @@ struct store_driver { int (*link)(uint64_t oid, struct siocb *, int tgt_epoch); int (*atomic_put)(uint64_t oid, struct siocb *); int (*begin_recover)(struct siocb *); + int (*end_recover)(struct siocb *); }; extern void register_store_driver(struct store_driver *); diff --git a/sheep/store.c b/sheep/store.c index 35b9851..de1bf63 100644 --- a/sheep/store.c +++ b/sheep/store.c @@ -1568,6 +1568,11 @@ static void do_recover_main(struct work *work, int idx) recovering_work = rw; queue_work(sys->recovery_wqueue, &rw->work); + } else { + if (store.end_recover) { + struct siocb iocb; + store.end_recover(&iocb); + } } resume_pending_requests(); -- 1.7.8.rc3 |