From 14fe45f06e4b94136c353cb90a2505e27bd95340 Mon Sep 17 00:00:00 2001 From: Chuck Lever Date: Thu, 4 Dec 2008 14:21:38 -0500 Subject: [PATCH] --- yaml --- r: 127453 b: refs/heads/master c: 356c3eb466fd1a12afd6448d90fba3922836e5f1 h: refs/heads/master i: 127451: 736330f2a0d4ebc12b4b47ca696916d76f292686 v: v3 --- [refs] | 2 +- trunk/fs/lockd/mon.c | 15 +++++++++------ trunk/include/linux/lockd/lockd.h | 1 + trunk/include/linux/lockd/sm_inter.h | 1 - 4 files changed, 11 insertions(+), 8 deletions(-) diff --git a/[refs] b/[refs] index 2fe236370a49..dd804925871f 100644 --- a/[refs] +++ b/[refs] @@ -1,2 +1,2 @@ --- -refs/heads/master: c8c23c423dec49cb439697d3dc714e1500ff1610 +refs/heads/master: 356c3eb466fd1a12afd6448d90fba3922836e5f1 diff --git a/trunk/fs/lockd/mon.c b/trunk/fs/lockd/mon.c index 15fab22db028..d61cdc61cb50 100644 --- a/trunk/fs/lockd/mon.c +++ b/trunk/fs/lockd/mon.c @@ -107,15 +107,19 @@ int nsm_monitor(const struct nlm_host *host) return status; } -/* - * Cease to monitor remote host +/** + * nsm_unmonitor - Unregister peer notification + * @host: pointer to nlm_host of peer to stop monitoring + * + * If this peer is monitored, this function sends an upcall to + * tell the local rpc.statd not to send this peer a notification + * when we reboot. */ -int -nsm_unmonitor(struct nlm_host *host) +void nsm_unmonitor(const struct nlm_host *host) { struct nsm_handle *nsm = host->h_nsmhandle; struct nsm_res res; - int status = 0; + int status; if (atomic_read(&nsm->sm_count) == 1 && nsm->sm_monitored && !nsm->sm_sticky) { @@ -128,7 +132,6 @@ nsm_unmonitor(struct nlm_host *host) else nsm->sm_monitored = 0; } - return status; } /* diff --git a/trunk/include/linux/lockd/lockd.h b/trunk/include/linux/lockd/lockd.h index 30a6a9c1ce42..38344bfb814a 100644 --- a/trunk/include/linux/lockd/lockd.h +++ b/trunk/include/linux/lockd/lockd.h @@ -245,6 +245,7 @@ extern void nlm_host_rebooted(const struct sockaddr_in *, const char *, * Host monitoring */ int nsm_monitor(const struct nlm_host *host); +void nsm_unmonitor(const struct nlm_host *host); /* * This is used in garbage collection and resource reclaim diff --git a/trunk/include/linux/lockd/sm_inter.h b/trunk/include/linux/lockd/sm_inter.h index 546b6102b0d7..896a5e303323 100644 --- a/trunk/include/linux/lockd/sm_inter.h +++ b/trunk/include/linux/lockd/sm_inter.h @@ -41,7 +41,6 @@ struct nsm_res { u32 state; }; -int nsm_unmonitor(struct nlm_host *); extern int nsm_local_state; #endif /* LINUX_LOCKD_SM_INTER_H */