[glsdk/meta-ti-glsdk.git] / recipes-kernel / linux / linux-ti33x-psp-3.2 / 3.2.24 / 0011-NFSv4-Rate-limit-the-state-manager-for-lock-reclaim-.patch
1 From 9c6259f9486461da338a097ae1655d55b7bead3a Mon Sep 17 00:00:00 2001
2 From: William Dauchy <wdauchy@gmail.com>
3 Date: Wed, 14 Mar 2012 12:32:04 +0100
4 Subject: [PATCH 011/109] NFSv4: Rate limit the state manager for lock reclaim
5 warning messages
7 commit 96dcadc2fdd111dca90d559f189a30c65394451a upstream.
9 Adding rate limit on `Lock reclaim failed` messages since it could fill
10 up system logs
11 Signed-off-by: William Dauchy <wdauchy@gmail.com>
12 Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>
13 [bwh: Backported to 3.2: add the 'NFS:' prefix at the same time]
14 Signed-off-by: Ben Hutchings <ben@decadent.org.uk>
15 ---
16 fs/nfs/nfs4state.c | 5 +++--
17 1 files changed, 3 insertions(+), 2 deletions(-)
19 diff --git a/fs/nfs/nfs4state.c b/fs/nfs/nfs4state.c
20 index 66020ac..07354b7 100644
21 --- a/fs/nfs/nfs4state.c
22 +++ b/fs/nfs/nfs4state.c
23 @@ -1186,8 +1186,9 @@ restart:
24 spin_lock(&state->state_lock);
25 list_for_each_entry(lock, &state->lock_states, ls_locks) {
26 if (!(lock->ls_flags & NFS_LOCK_INITIALIZED))
27 - printk("%s: Lock reclaim failed!\n",
28 - __func__);
29 + pr_warn_ratelimited("NFS: "
30 + "%s: Lock reclaim "
31 + "failed!\n", __func__);
32 }
33 spin_unlock(&state->state_lock);
34 nfs4_put_open_state(state);
35 --
36 1.7.7.6