summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorKOSAKI Motohiro <kosaki.motohiro@jp.fujitsu.com>2010-03-23 13:35:31 -0700
committerGreg Kroah-Hartman <gregkh@suse.de>2010-04-01 15:55:59 -0700
commit6c5e69f3f760bc93eba06eb7776ff205cc129708 (patch)
tree953b616f008e71da6b95208499da6483e9dae3b5
parent4fbd4ab7b17a71132fbf9a21ffeee6e1a25f070e (diff)
tmpfs: handle MPOL_LOCAL mount option properly
commit 12821f5fb942e795f8009ece14bde868893bd811 upstream. commit 71fe804b6d5 (mempolicy: use struct mempolicy pointer in shmem_sb_info) added mpol=local mount option. but its feature is broken since it was born. because such code always return 1 (i.e. mount failure). This patch fixes it. Signed-off-by: KOSAKI Motohiro <kosaki.motohiro@jp.fujitsu.com> Cc: Ravikiran Thirumalai <kiran@scalex86.org> Cc: Christoph Lameter <cl@linux-foundation.org> Cc: Mel Gorman <mel@csn.ul.ie> Acked-by: Lee Schermerhorn <lee.schermerhorn@hp.com> Cc: Hugh Dickins <hugh.dickins@tiscali.co.uk> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
-rw-r--r--mm/mempolicy.c1
1 files changed, 1 insertions, 0 deletions
diff --git a/mm/mempolicy.c b/mm/mempolicy.c
index b2f22557b8ff..7e2bf0d1c8b3 100644
--- a/mm/mempolicy.c
+++ b/mm/mempolicy.c
@@ -2141,6 +2141,7 @@ int mpol_parse_str(char *str, struct mempolicy **mpol, int no_context)
if (nodelist)
goto out;
mode = MPOL_PREFERRED;
+ err = 0;
break;
case MPOL_DEFAULT:
/*