[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-Id: <1384447393-13838-10-git-send-email-bergwolf@gmail.com>
Date: Fri, 15 Nov 2013 00:42:56 +0800
From: Peng Tao <bergwolf@...il.com>
To: Greg Kroah-Hartman <gregkh@...uxfoundation.org>
Cc: linux-kernel@...r.kernel.org,
Jinshan Xiong <jinshan.xiong@...el.com>,
Peng Tao <bergwolf@...il.com>,
Andreas Dilger <andreas.dilger@...el.com>
Subject: [PATCH 09/26] staging/lustre/llite: error setting max_cache_mb at mount time
From: Jinshan Xiong <jinshan.xiong@...el.com>
The root cause is that when max_cache_mb conf parameter is applied,
the client isn't connected to the OST yet so that sbi->ll_dt_exp is
NULL. However, it's not necessary to shrink the cache memory in this
case so success should be returned.
Lustre-change: http://review.whamcloud.com/7194
Intel-bug-id: https://jira.hpdd.intel.com/browse/LU-3676
Signed-off-by: Jinshan Xiong <jinshan.xiong@...el.com>
Reviewed-by: Andreas Dilger <andreas.dilger@...el.com>
Reviewed-by: Bobi Jam <bobijam@...il.com>
Signed-off-by: Peng Tao <bergwolf@...il.com>
Signed-off-by: Andreas Dilger <andreas.dilger@...el.com>
---
drivers/staging/lustre/lustre/llite/lproc_llite.c | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
diff --git a/drivers/staging/lustre/lustre/llite/lproc_llite.c b/drivers/staging/lustre/lustre/llite/lproc_llite.c
index 18a5998c..17d3911 100644
--- a/drivers/staging/lustre/lustre/llite/lproc_llite.c
+++ b/drivers/staging/lustre/lustre/llite/lproc_llite.c
@@ -393,8 +393,8 @@ static ssize_t ll_max_cached_mb_seq_write(struct file *file, const char *buffer,
return -ERANGE;
}
- if (sbi->ll_dt_exp == NULL)
- return -ENODEV;
+ if (sbi->ll_dt_exp == NULL) /* being initialized */
+ GOTO(out, rc = 0);
spin_lock(&sbi->ll_lock);
diff = pages_number - cache->ccc_lru_max;
--
1.7.9.5
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/
Powered by blists - more mailing lists