linux-mm.kvack.org archive mirror
 help / color / mirror / Atom feed
* [PATCH] mm: thp: correct split_huge_pages file permission
@ 2016-04-15 18:10 Yang Shi
  2016-04-15 18:47 ` Kirill A. Shutemov
  0 siblings, 1 reply; 2+ messages in thread
From: Yang Shi @ 2016-04-15 18:10 UTC (permalink / raw)
  To: akpm, kirill.shutemov, aarcange, hughd, mgorman
  Cc: linux-kernel, linux-mm, linaro-kernel, yang.shi

split_huge_pages doesn't support get method at all, so the read permission
sounds confusing, change the permission to write only.

And, add "\n" to the output of set method to make it more readable.

Signed-off-by: Yang Shi <yang.shi@linaro.org>
---
 mm/huge_memory.c | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

diff --git a/mm/huge_memory.c b/mm/huge_memory.c
index 86f9f8b..8adf3c2 100644
--- a/mm/huge_memory.c
+++ b/mm/huge_memory.c
@@ -3454,7 +3454,7 @@ next:
 		}
 	}
 
-	pr_info("%lu of %lu THP split", split, total);
+	pr_info("%lu of %lu THP split\n", split, total);
 
 	return 0;
 }
@@ -3465,7 +3465,7 @@ static int __init split_huge_pages_debugfs(void)
 {
 	void *ret;
 
-	ret = debugfs_create_file("split_huge_pages", 0644, NULL, NULL,
+	ret = debugfs_create_file("split_huge_pages", 0200, NULL, NULL,
 			&split_huge_pages_fops);
 	if (!ret)
 		pr_warn("Failed to create split_huge_pages in debugfs");
-- 
2.0.2

--
To unsubscribe, send a message with 'unsubscribe linux-mm' in
the body to majordomo@kvack.org.  For more info on Linux MM,
see: http://www.linux-mm.org/ .
Don't email: <a href=mailto:"dont@kvack.org"> email@kvack.org </a>

^ permalink raw reply	[flat|nested] 2+ messages in thread

* Re: [PATCH] mm: thp: correct split_huge_pages file permission
  2016-04-15 18:10 [PATCH] mm: thp: correct split_huge_pages file permission Yang Shi
@ 2016-04-15 18:47 ` Kirill A. Shutemov
  0 siblings, 0 replies; 2+ messages in thread
From: Kirill A. Shutemov @ 2016-04-15 18:47 UTC (permalink / raw)
  To: Yang Shi
  Cc: akpm, aarcange, hughd, mgorman, linux-kernel, linux-mm, linaro-kernel

On Fri, Apr 15, 2016 at 11:10:05AM -0700, Yang Shi wrote:
> split_huge_pages doesn't support get method at all, so the read permission
> sounds confusing, change the permission to write only.
> 
> And, add "\n" to the output of set method to make it more readable.
> 
> Signed-off-by: Yang Shi <yang.shi@linaro.org>

Acked-by: Kirill A. Shutemov <kirill.shutemov@linux.intel.com>

-- 
 Kirill A. Shutemov

--
To unsubscribe, send a message with 'unsubscribe linux-mm' in
the body to majordomo@kvack.org.  For more info on Linux MM,
see: http://www.linux-mm.org/ .
Don't email: <a href=mailto:"dont@kvack.org"> email@kvack.org </a>

^ permalink raw reply	[flat|nested] 2+ messages in thread

end of thread, other threads:[~2016-04-15 18:47 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2016-04-15 18:10 [PATCH] mm: thp: correct split_huge_pages file permission Yang Shi
2016-04-15 18:47 ` Kirill A. Shutemov

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox