diff options
author | YueHaibing <yuehaibing@huawei.com> | 2019-05-28 05:06:52 -0400 |
---|---|---|
committer | J. Bruce Fields <bfields@redhat.com> | 2019-07-03 17:52:09 -0400 |
commit | 291adeb25481d6d515d1bafbcbddbf2cf5f74574 (patch) | |
tree | c71ac1ea78a3feae4364001dbb20bc1a1f683190 | |
parent | f85d93385e9fe6886a751f647f6812a89bf6bee3 (diff) |
lockd: Make two symbols static
Fix sparse warnings:
fs/lockd/clntproc.c:57:6: warning: symbol 'nlmclnt_put_lockowner' was not declared. Should it be static?
fs/lockd/svclock.c:409:35: warning: symbol 'nlmsvc_lock_ops' was not declared. Should it be static?
Reported-by: Hulk Robot <hulkci@huawei.com>
Signed-off-by: YueHaibing <yuehaibing@huawei.com>
Signed-off-by: J. Bruce Fields <bfields@redhat.com>
-rw-r--r-- | fs/lockd/clntproc.c | 2 | ||||
-rw-r--r-- | fs/lockd/svclock.c | 2 |
2 files changed, 2 insertions, 2 deletions
diff --git a/fs/lockd/clntproc.c b/fs/lockd/clntproc.c index 0ff8ad42c9da..b11f2afa84f1 100644 --- a/fs/lockd/clntproc.c +++ b/fs/lockd/clntproc.c | |||
@@ -54,7 +54,7 @@ nlmclnt_get_lockowner(struct nlm_lockowner *lockowner) | |||
54 | return lockowner; | 54 | return lockowner; |
55 | } | 55 | } |
56 | 56 | ||
57 | void nlmclnt_put_lockowner(struct nlm_lockowner *lockowner) | 57 | static void nlmclnt_put_lockowner(struct nlm_lockowner *lockowner) |
58 | { | 58 | { |
59 | if (!refcount_dec_and_lock(&lockowner->count, &lockowner->host->h_lock)) | 59 | if (!refcount_dec_and_lock(&lockowner->count, &lockowner->host->h_lock)) |
60 | return; | 60 | return; |
diff --git a/fs/lockd/svclock.c b/fs/lockd/svclock.c index 5f9f19b81754..61d3cc2283dc 100644 --- a/fs/lockd/svclock.c +++ b/fs/lockd/svclock.c | |||
@@ -406,7 +406,7 @@ static void nlmsvc_locks_release_private(struct file_lock *fl) | |||
406 | nlmsvc_put_lockowner((struct nlm_lockowner *)fl->fl_owner); | 406 | nlmsvc_put_lockowner((struct nlm_lockowner *)fl->fl_owner); |
407 | } | 407 | } |
408 | 408 | ||
409 | const struct file_lock_operations nlmsvc_lock_ops = { | 409 | static const struct file_lock_operations nlmsvc_lock_ops = { |
410 | .fl_copy_lock = nlmsvc_locks_copy_lock, | 410 | .fl_copy_lock = nlmsvc_locks_copy_lock, |
411 | .fl_release_private = nlmsvc_locks_release_private, | 411 | .fl_release_private = nlmsvc_locks_release_private, |
412 | }; | 412 | }; |