Generic page_is_ram: use __weak
A message that is not in the archive (sent off-list or not yet received): [email protected]
Andrew Morton
maintainerQuoted 23 lines · On Tue, 2 Feb 2010 01:00:51 GMT tip-bot for Andrew Morton…
Commit-ID: e52730071567ec5b6f57e21d6693b112e01e1d0e Gitweb: http://git.kernel.org/tip/e52730071567ec5b6f57e21d6693b112e01e1d0e Author: Andrew Morton <[email protected]> AuthorDate: Tue, 26 Jan 2010 16:31:19 -0800 Committer: H. Peter Anvin <[email protected]> CommitDate: Mon, 1 Feb 2010 16:58:17 -0800Generic
page_is_ram: use__weakUse
__weakinstead of __attribute__((weak)).Cc Wu Fengguang <[email protected]>Signed-off-by Andrew Morton <[email protected]>Signed-off-by H. Peter Anvin <[email protected]>--- kernel/resource.c | 2 +- 1 files changed, 1 insertions(+), 1 deletions(-)kernel/resource.c +0
-0
kernel/resource.c static int __is_ram(unsigned long pfn, unsigned long nr_pages, void *arg) · line 311
Quoted 8 lines
kernel/resource.c +1
-1@@ -305,7 +305,7 @@ static int __is_ram(unsigned long pfn, unsigned long nr_pages, void *arg)* This generic page_is_ram() returns true if specified address is * registered as "System RAM" in iomem_resource list. */ -int __attribute__((weak))page_is_ram (unsigned long pfn) +int __weak page_is_ram (unsigned long pfn) {return walk_system_ram_range (pfn,1 ,NULL , __is_ram) ==1 ; }
hm, it's strange to do this as two separate commits?
There was another fixlet:
From: Wu Fengguang <[email protected]>
ioport.h didn't seem like the right place to declare page_is_ram().
---
include/linux/ioport.h | 2 -- include/linux/mm.h | 2 ++ 2 files changed, 2 insertions(+), 2 deletions(-)
include/linux/ioport.h renamed from include/linux/ioport.h~resources-introduce-generic-page_is_ram-fix-2 +0 -2
@@ -191,7 +191,5 @@ extern int walk_system_ram_range(unsigned long start_pfn, unsigned long nr_pages, void *arg, int (*func)(unsigned long, unsigned long, void *)); -extern int page_is_ram (unsigned long pfn); -#endif /* __ASSEMBLY__ */ #endif /* _LINUX_IOPORT_H */
include/linux/mm.h renamed from include/linux/mm.h~resources-introduce-generic-page_is_ram-fix-2 +2 -0
@@ -265,6 +265,8 @@ static inline int get_page_unless_zero(sreturn atomic_inc_not_zero (&page->_count); } +extern int page_is_ram (unsigned long pfn); +/* Support for virtually mapped pages */ struct page *vmalloc_to_page (const void *addr);unsigned long vmalloc_to_pfn (const void *addr);
_
Quoted 17 lines · Andrew Morton
Quoted 6 lines
kernel/resource.c +0
-0kernel/resource.c static int __is_ram(unsigned long pfn, unsigned long nr_pages, void *arg) · line 311
Quoted 8 lines
kernel/resource.c +1
-1@@ -305,7 +305,7 @@ static int __is_ram(unsigned long pfn, unsigned long nr_pages, void *arg)* This generic page_is_ram() returns true if specified address is * registered as "System RAM" in iomem_resource list. */ -int __attribute__((weak))page_is_ram (unsigned long pfn) +int __weak page_is_ram (unsigned long pfn) {return walk_system_ram_range (pfn,1 ,NULL , __is_ram) ==1 ; }hm, it's strange to do this as two separate commits?
You had it as a separate fix patch, and I generally don't want to fold patches which have different authorship, especially if the original code doesn't actually break anything.
Quoted 7 lines
There was another fixlet:
From: Wu Fengguang <[email protected]>
ioport.hdidn't seem like the right place to declarepage_is_ram().Signed-off-by Andrew Morton <[email protected]>
Yes, I have that one too.
-hpa
Andrew Morton
maintainerQuoted 19 lines · On Mon, 01 Feb 2010 17:37:23 -0800 "H. Peter Anvin" <[email protected]> wrote:
Quoted 17 lines · Andrew Morton
Quoted 6 lines
kernel/resource.c +0
-0kernel/resource.c static int __is_ram(unsigned long pfn, unsigned long nr_pages, void *arg) · line 311
Quoted 8 lines
kernel/resource.c +1
-1@@ -305,7 +305,7 @@ static int __is_ram(unsigned long pfn, unsigned long nr_pages, void *arg)* This generic page_is_ram() returns true if specified address is * registered as "System RAM" in iomem_resource list. */ -int __attribute__((weak))page_is_ram (unsigned long pfn) +int __weak page_is_ram (unsigned long pfn) {return walk_system_ram_range (pfn,1 ,NULL , __is_ram) ==1 ; }hm, it's strange to do this as two separate commits?
Quoted 3 lines
You had it as a separate fix patch, and I generally don't want to fold patches which have different authorship, especially if the original code doesn't actually break anything.
Nobody's complained so far:
y:/usr/src/git26> git log | grep '\[.*@.*:' | wc -l 2434
It's a tradeoff between being nice to authors versus tree-cleanliness and bisectability.
Quoted 9 lines · Andrew Morton
Nobody's complained so far:
y:/usr/src/git26> git log | grep '\[.*@.*:' | wc -l 2434
It's a tradeoff between being nice to authors versus tree-cleanliness and bisectability.
Yes, if it had broken the tree in between the patches I would have folded them.
-hpa