* mm: various sparse warning fix
@ 2008-11-25 4:24 KOSAKI Motohiro
2008-11-25 4:24 ` [PATCH] mm: make init_section_page_cgroup() static KOSAKI Motohiro
` (6 more replies)
0 siblings, 7 replies; 8+ messages in thread
From: KOSAKI Motohiro @ 2008-11-25 4:24 UTC (permalink / raw)
To: LKML, linux-mm, Andrew Morton; +Cc: kosaki.motohiro
Hi
This patch series doesn't have any functional change.
and I think it is not so serious.
However, many developer often check sparse warnings because
it is required from Documentation/SubmitChecklist.
Therefore, too many warnings can decrease development efficiency.
and, all patch independent each other.
--
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] 8+ messages in thread
* [PATCH] mm: make init_section_page_cgroup() static
2008-11-25 4:24 mm: various sparse warning fix KOSAKI Motohiro
@ 2008-11-25 4:24 ` KOSAKI Motohiro
2008-11-25 4:25 ` [PATCH] mm: make maddr __iomem KOSAKI Motohiro
` (5 subsequent siblings)
6 siblings, 0 replies; 8+ messages in thread
From: KOSAKI Motohiro @ 2008-11-25 4:24 UTC (permalink / raw)
To: LKML, linux-mm, Andrew Morton; +Cc: kosaki.motohiro
Sparse output following warning.
mm/page_cgroup.c:100:15: warning: symbol 'init_section_page_cgroup' was not declared. Should it be static?
cleanup here.
Signed-off-by: KOSAKI Motohiro <kosaki.motohiro@jp.fujitsu.com>
---
mm/page_cgroup.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
Index: b/mm/page_cgroup.c
===================================================================
--- a/mm/page_cgroup.c 2008-11-05 01:11:45.000000000 +0900
+++ b/mm/page_cgroup.c 2008-11-22 22:24:06.000000000 +0900
@@ -97,7 +97,7 @@ struct page_cgroup *lookup_page_cgroup(s
return section->page_cgroup + pfn;
}
-int __meminit init_section_page_cgroup(unsigned long pfn)
+static int __meminit init_section_page_cgroup(unsigned long pfn)
{
struct mem_section *section;
struct page_cgroup *base, *pc;
--
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] 8+ messages in thread
* [PATCH] mm: make maddr __iomem
2008-11-25 4:24 mm: various sparse warning fix KOSAKI Motohiro
2008-11-25 4:24 ` [PATCH] mm: make init_section_page_cgroup() static KOSAKI Motohiro
@ 2008-11-25 4:25 ` KOSAKI Motohiro
2008-11-25 4:26 ` [PATCH] mm: make mem_cgroup_resize_limit() static KOSAKI Motohiro
` (4 subsequent siblings)
6 siblings, 0 replies; 8+ messages in thread
From: KOSAKI Motohiro @ 2008-11-25 4:25 UTC (permalink / raw)
To: LKML, linux-mm, Andrew Morton; +Cc: kosaki.motohiro
sparse output following warnings.
mm/memory.c:2936:8: warning: incorrect type in assignment (different address spaces)
mm/memory.c:2936:8: expected void *maddr
mm/memory.c:2936:8: got void [noderef] <asn:2>
cleanup here.
Signed-off-by: KOSAKI Motohiro <kosaki.motohiro@jp.fujitsu.com>
---
mm/memory.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
Index: b/mm/memory.c
===================================================================
--- a/mm/memory.c 2008-11-05 01:11:44.000000000 +0900
+++ b/mm/memory.c 2008-11-22 21:56:31.000000000 +0900
@@ -2922,7 +2922,7 @@ int generic_access_phys(struct vm_area_s
{
resource_size_t phys_addr;
unsigned long prot = 0;
- void *maddr;
+ void __iomem *maddr;
int offset = addr & (PAGE_SIZE-1);
if (!(vma->vm_flags & (VM_IO | VM_PFNMAP)))
--
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] 8+ messages in thread
* [PATCH] mm: make mem_cgroup_resize_limit() static
2008-11-25 4:24 mm: various sparse warning fix KOSAKI Motohiro
2008-11-25 4:24 ` [PATCH] mm: make init_section_page_cgroup() static KOSAKI Motohiro
2008-11-25 4:25 ` [PATCH] mm: make maddr __iomem KOSAKI Motohiro
@ 2008-11-25 4:26 ` KOSAKI Motohiro
2008-11-25 4:28 ` [PATCH] mm: make scan_all_zones_unevictable_pages() static KOSAKI Motohiro
` (3 subsequent siblings)
6 siblings, 0 replies; 8+ messages in thread
From: KOSAKI Motohiro @ 2008-11-25 4:26 UTC (permalink / raw)
To: LKML, linux-mm, Andrew Morton; +Cc: kosaki.motohiro
Sparse output following warnings.
mm/memcontrol.c:782:5: warning: symbol 'mem_cgroup_resize_limit' was not declared. Should it be static?
cleanup here.
Signed-off-by: KOSAKI Motohiro <kosaki.motohiro@jp.fujitsu.com>
---
mm/memcontrol.c | 3 ++-
1 file changed, 2 insertions(+), 1 deletion(-)
Index: b/mm/memcontrol.c
===================================================================
--- a/mm/memcontrol.c 2008-11-05 01:11:45.000000000 +0900
+++ b/mm/memcontrol.c 2008-11-22 22:23:12.000000000 +0900
@@ -779,7 +779,8 @@ int mem_cgroup_shrink_usage(struct mm_st
return 0;
}
-int mem_cgroup_resize_limit(struct mem_cgroup *memcg, unsigned long long val)
+static int mem_cgroup_resize_limit(struct mem_cgroup *memcg,
+ unsigned long long val)
{
int retry_count = MEM_CGROUP_RECLAIM_RETRIES;
--
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] 8+ messages in thread
* [PATCH] mm: make scan_all_zones_unevictable_pages() static
2008-11-25 4:24 mm: various sparse warning fix KOSAKI Motohiro
` (2 preceding siblings ...)
2008-11-25 4:26 ` [PATCH] mm: make mem_cgroup_resize_limit() static KOSAKI Motohiro
@ 2008-11-25 4:28 ` KOSAKI Motohiro
2008-11-25 4:29 ` [PATCH] mm: make scan_zone_unevictable_pages() static KOSAKI Motohiro
` (2 subsequent siblings)
6 siblings, 0 replies; 8+ messages in thread
From: KOSAKI Motohiro @ 2008-11-25 4:28 UTC (permalink / raw)
To: LKML, linux-mm, Andrew Morton; +Cc: kosaki.motohiro
sparse output following warning.
mm/vmscan.c:2549:6: warning: symbol 'scan_all_zones_unevictable_pages' was not declared. Should it be static?
cleanup here.
Signed-off-by: KOSAKI Motohiro <kosaki.motohiro@jp.fujitsu.com>
---
mm/vmscan.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
Index: b/mm/vmscan.c
===================================================================
--- a/mm/vmscan.c 2008-11-22 21:45:21.000000000 +0900
+++ b/mm/vmscan.c 2008-11-22 21:49:46.000000000 +0900
@@ -2546,7 +2546,7 @@ static void scan_zone_unevictable_pages(
* that has possibly/probably made some previously unevictable pages
* evictable.
*/
-void scan_all_zones_unevictable_pages(void)
+static void scan_all_zones_unevictable_pages(void)
{
struct zone *zone;
--
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] 8+ messages in thread
* [PATCH] mm: make scan_zone_unevictable_pages() static
2008-11-25 4:24 mm: various sparse warning fix KOSAKI Motohiro
` (3 preceding siblings ...)
2008-11-25 4:28 ` [PATCH] mm: make scan_all_zones_unevictable_pages() static KOSAKI Motohiro
@ 2008-11-25 4:29 ` KOSAKI Motohiro
2008-11-25 4:29 ` [PATCH] mm: make setup_per_zone_inactive_ratio() static KOSAKI Motohiro
2008-11-25 4:30 ` [PATCH] mm: make vread() and vwrite() declaration KOSAKI Motohiro
6 siblings, 0 replies; 8+ messages in thread
From: KOSAKI Motohiro @ 2008-11-25 4:29 UTC (permalink / raw)
To: LKML, linux-mm, Andrew Morton; +Cc: kosaki.motohiro
sparse output following warning
mm/vmscan.c:2507:6: warning: symbol 'scan_zone_unevictable_pages' was not declared. Should it be static?
cleanup here.
Signed-off-by: KOSAKI Motohiro <kosaki.motohiro@jp.fujitsu.com>
---
mm/vmscan.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
Index: b/mm/vmscan.c
===================================================================
--- a/mm/vmscan.c 2008-11-05 01:11:44.000000000 +0900
+++ b/mm/vmscan.c 2008-11-22 21:45:21.000000000 +0900
@@ -2504,7 +2504,7 @@ void scan_mapping_unevictable_pages(stru
* back onto @zone's unevictable list.
*/
#define SCAN_UNEVICTABLE_BATCH_SIZE 16UL /* arbitrary lock hold batch size */
-void scan_zone_unevictable_pages(struct zone *zone)
+static void scan_zone_unevictable_pages(struct zone *zone)
{
struct list_head *l_unevictable = &zone->lru[LRU_UNEVICTABLE].list;
unsigned long scan;
--
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] 8+ messages in thread
* [PATCH] mm: make setup_per_zone_inactive_ratio() static
2008-11-25 4:24 mm: various sparse warning fix KOSAKI Motohiro
` (4 preceding siblings ...)
2008-11-25 4:29 ` [PATCH] mm: make scan_zone_unevictable_pages() static KOSAKI Motohiro
@ 2008-11-25 4:29 ` KOSAKI Motohiro
2008-11-25 4:30 ` [PATCH] mm: make vread() and vwrite() declaration KOSAKI Motohiro
6 siblings, 0 replies; 8+ messages in thread
From: KOSAKI Motohiro @ 2008-11-25 4:29 UTC (permalink / raw)
To: LKML, linux-mm, Andrew Morton; +Cc: kosaki.motohiro
Sparse output following warning.
mm/page_alloc.c:4301:6: warning: symbol 'setup_per_zone_inactive_ratio' was not declared. Should it be static?
cleanup here.
Signed-off-by: KOSAKI Motohiro <kosaki.motohiro@jp.fujitsu.com>
---
mm/page_alloc.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
Index: b/mm/page_alloc.c
===================================================================
--- a/mm/page_alloc.c 2008-11-22 22:38:20.000000000 +0900
+++ b/mm/page_alloc.c 2008-11-22 22:38:40.000000000 +0900
@@ -4298,7 +4298,7 @@ void setup_per_zone_pages_min(void)
* 1TB 101 10GB
* 10TB 320 32GB
*/
-void setup_per_zone_inactive_ratio(void)
+static void setup_per_zone_inactive_ratio(void)
{
struct zone *zone;
--
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] 8+ messages in thread
* [PATCH] mm: make vread() and vwrite() declaration
2008-11-25 4:24 mm: various sparse warning fix KOSAKI Motohiro
` (5 preceding siblings ...)
2008-11-25 4:29 ` [PATCH] mm: make setup_per_zone_inactive_ratio() static KOSAKI Motohiro
@ 2008-11-25 4:30 ` KOSAKI Motohiro
6 siblings, 0 replies; 8+ messages in thread
From: KOSAKI Motohiro @ 2008-11-25 4:30 UTC (permalink / raw)
To: LKML, linux-mm, Andrew Morton; +Cc: kosaki.motohiro
Sparse output following warnings.
mm/vmalloc.c:1436:6: warning: symbol 'vread' was not declared. Should it be static?
mm/vmalloc.c:1474:6: warning: symbol 'vwrite' was not declared. Should it be static?
However, it is used by /dev/kmem. fixed here.
Signed-off-by: KOSAKI Motohiro <kosaki.motohiro@jp.fujitsu.com>
---
drivers/char/mem.c | 3 ---
include/linux/vmalloc.h | 4 ++++
2 files changed, 4 insertions(+), 3 deletions(-)
Index: b/drivers/char/mem.c
===================================================================
--- a/drivers/char/mem.c 2008-11-05 01:10:59.000000000 +0900
+++ b/drivers/char/mem.c 2008-11-22 22:09:49.000000000 +0900
@@ -425,9 +425,6 @@ static ssize_t read_oldmem(struct file *
}
#endif
-extern long vread(char *buf, char *addr, unsigned long count);
-extern long vwrite(char *buf, char *addr, unsigned long count);
-
#ifdef CONFIG_DEVKMEM
/*
* This function reads the *virtual* memory as seen by the kernel.
Index: b/include/linux/vmalloc.h
===================================================================
--- a/include/linux/vmalloc.h 2008-11-05 01:11:55.000000000 +0900
+++ b/include/linux/vmalloc.h 2008-11-22 22:09:28.000000000 +0900
@@ -97,6 +97,10 @@ extern void unmap_kernel_range(unsigned
extern struct vm_struct *alloc_vm_area(size_t size);
extern void free_vm_area(struct vm_struct *area);
+/* for /dev/kmem */
+extern long vread(char *buf, char *addr, unsigned long count);
+extern long vwrite(char *buf, char *addr, unsigned long count);
+
/*
* Internals. Dont't use..
*/
--
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] 8+ messages in thread
end of thread, other threads:[~2008-11-25 4:30 UTC | newest]
Thread overview: 8+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2008-11-25 4:24 mm: various sparse warning fix KOSAKI Motohiro
2008-11-25 4:24 ` [PATCH] mm: make init_section_page_cgroup() static KOSAKI Motohiro
2008-11-25 4:25 ` [PATCH] mm: make maddr __iomem KOSAKI Motohiro
2008-11-25 4:26 ` [PATCH] mm: make mem_cgroup_resize_limit() static KOSAKI Motohiro
2008-11-25 4:28 ` [PATCH] mm: make scan_all_zones_unevictable_pages() static KOSAKI Motohiro
2008-11-25 4:29 ` [PATCH] mm: make scan_zone_unevictable_pages() static KOSAKI Motohiro
2008-11-25 4:29 ` [PATCH] mm: make setup_per_zone_inactive_ratio() static KOSAKI Motohiro
2008-11-25 4:30 ` [PATCH] mm: make vread() and vwrite() declaration KOSAKI Motohiro
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox