[<prev] [next>] [day] [month] [year] [list]
Message-Id: <1244238529-31976-1-git-send-email-slyfox@inbox.ru>
Date: Sat, 6 Jun 2009 00:48:49 +0300
From: Sergei Trofimovich <slyfox@...ox.ru>
To: linux-kernel@...r.kernel.org, trivial@...nel.org
Cc: Sergei Trofimovich <slyfox@...ox.ru>
Subject: [PATCH] cleanup: shmem_file_setup: 'char *' -> 'const char *' for name argument
As function shmem_file_setup does not modify/allocate/free/pass
given filename - mark it as const.
Signed-off-by: Sergei Trofimovich <slyfox@...ox.ru>
---
include/linux/mm.h | 2 +-
mm/shmem.c | 2 +-
2 files changed, 2 insertions(+), 2 deletions(-)
diff --git a/include/linux/mm.h b/include/linux/mm.h
index bff1f0d..e2d8d63 100644
--- a/include/linux/mm.h
+++ b/include/linux/mm.h
@@ -726,7 +726,7 @@ static inline int shmem_lock(struct file *file, int lock,
return 0;
}
#endif
-struct file *shmem_file_setup(char *name, loff_t size, unsigned long flags);
+struct file *shmem_file_setup(const char *name, loff_t size, unsigned long flags);
int shmem_zero_setup(struct vm_area_struct *);
diff --git a/mm/shmem.c b/mm/shmem.c
index b25f95c..a21d60a 100644
--- a/mm/shmem.c
+++ b/mm/shmem.c
@@ -2612,7 +2612,7 @@ int shmem_unuse(swp_entry_t entry, struct page *page)
* @size: size to be set for the file
* @flags: VM_NORESERVE suppresses pre-accounting of the entire object size
*/
-struct file *shmem_file_setup(char *name, loff_t size, unsigned long flags)
+struct file *shmem_file_setup(const char *name, loff_t size, unsigned long flags)
{
int error;
struct file *file;
--
1.6.0.6
--
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