The following changes since commit 88dc4c8e38d64db32907e0bd605f8c1ec4c4d1bd:
Ingo Molnar (1):
Merge branch 'tracing/ftrace'
are available in the git repository at:
git://git.kernel.org/pub/scm/linux/kernel/git/jaswinder/linux-2.6-tip.git master
Jaswinder Singh Rajput (3):
x86: mm/numa_32.c calculate_numa_remap_pages should use __init
x86: apic/es7000_32.c find_unisys_acpi_oem_table and es7000_acpi_madt_oem_check should use __init
x86: smpboot.c wakeup_secondary_cpu_via_nmi do not required __devinit
arch/x86/kernel/apic/es7000_32.c | 6 +++---
arch/x86/kernel/smpboot.c | 3 +--
arch/x86/mm/numa_32.c | 2 +-
3 files changed, 5 insertions(+), 6 deletions(-)
Complete diff:
diff --git a/arch/x86/kernel/apic/es7000_32.c b/arch/x86/kernel/apic/es7000_32.c
index 1c11b81..a7a7bbe 100644
--- a/arch/x86/kernel/apic/es7000_32.c
+++ b/arch/x86/kernel/apic/es7000_32.c
@@ -254,7 +254,7 @@ static int parse_unisys_oem(char *oemptr)
}
#ifdef CONFIG_ACPI
-static int find_unisys_acpi_oem_table(unsigned long *oem_addr)
+static int __init find_unisys_acpi_oem_table(unsigned long *oem_addr)
{
struct acpi_table_header *header = NULL;
struct es7000_oem_table *table;
@@ -306,7 +306,7 @@ static int es7000_check_dsdt(void)
static int es7000_acpi_ret;
/* Hook from generic ACPI tables.c */
-static int es7000_acpi_madt_oem_check(char *oem_id, char *oem_table_id)
+static int __init es7000_acpi_madt_oem_check(char *oem_id, char *oem_table_id)
{
unsigned long oem_addr = 0;
int check_dsdt;
@@ -717,7 +717,7 @@ struct apic apic_es7000_cluster = {
.safe_wait_icr_idle = native_safe_apic_wait_icr_idle,
};
-struct apic apic_es7000 = {
+struct apic __initdata apic_es7000 = {
.name = "es7000",
.probe = probe_es7000,
diff --git a/arch/x86/kernel/smpboot.c b/arch/x86/kernel/smpboot.c
index bf8ad63..483c2d3 100644
--- a/arch/x86/kernel/smpboot.c
+++ b/arch/x86/kernel/smpboot.c
@@ -504,8 +504,7 @@ void __inquire_remote_apic(int apicid)
* INIT, INIT, STARTUP sequence will reset the chip hard for us, and this
* won't ... remember to clear down the APIC, etc later.
*/
-int __devinit
-wakeup_secondary_cpu_via_nmi(int logical_apicid, unsigned long start_eip)
+int wakeup_secondary_cpu_via_nmi(int logical_apicid, unsigned long start_eip)
{
unsigned long send_status, accept_status = 0;
int maxlvt;
diff --git a/arch/x86/mm/numa_32.c b/arch/x86/mm/numa_32.c
index 3daefa0..d253006 100644
--- a/arch/x86/mm/numa_32.c
+++ b/arch/x86/mm/numa_32.c
@@ -257,7 +257,7 @@ void resume_map_numa_kva(pgd_t *pgd_base)
}
#endif
-static unsigned long calculate_numa_remap_pages(void)
+static __init unsigned long calculate_numa_remap_pages(void)
{
int nid;
unsigned long size, reserve_pages = 0;
* Jaswinder Singh Rajput <[email protected]> wrote:
> The following changes since commit 88dc4c8e38d64db32907e0bd605f8c1ec4c4d1bd:
> Ingo Molnar (1):
> Merge branch 'tracing/ftrace'
>
> are available in the git repository at:
>
> git://git.kernel.org/pub/scm/linux/kernel/git/jaswinder/linux-2.6-tip.git master
>
> Jaswinder Singh Rajput (3):
> x86: mm/numa_32.c calculate_numa_remap_pages should use __init
> x86: apic/es7000_32.c find_unisys_acpi_oem_table and es7000_acpi_madt_oem_check should use __init
> x86: smpboot.c wakeup_secondary_cpu_via_nmi do not required __devinit
The commit logs lack analysis. The suggestions in the warnings are
advisory and can be wrong. Analysis explaining what happened, maybe
even when it happened, and what should be done about it to fix that
issue is needed in such changelogs.
The commits might be correct - or they might be bogus. The commit
logs dont give us any help in deciding that. I.e. if you did that
work, you should document it. If you _didnt_ do that analysis work,
you shouldnt send patches addressing these types of warnings.
Ingo
On Fri, 2009-04-17 at 18:41 +0200, Ingo Molnar wrote:
> * Jaswinder Singh Rajput <[email protected]> wrote:
>
> > The following changes since commit 88dc4c8e38d64db32907e0bd605f8c1ec4c4d1bd:
> > Ingo Molnar (1):
> > Merge branch 'tracing/ftrace'
> >
> > are available in the git repository at:
> >
> > git://git.kernel.org/pub/scm/linux/kernel/git/jaswinder/linux-2.6-tip.git master
> >
> > Jaswinder Singh Rajput (3):
> > x86: mm/numa_32.c calculate_numa_remap_pages should use __init
> > x86: apic/es7000_32.c find_unisys_acpi_oem_table and es7000_acpi_madt_oem_check should use __init
> > x86: smpboot.c wakeup_secondary_cpu_via_nmi do not required __devinit
>
> The commit logs lack analysis. The suggestions in the warnings are
> advisory and can be wrong. Analysis explaining what happened, maybe
> even when it happened, and what should be done about it to fix that
> issue is needed in such changelogs.
>
> The commits might be correct - or they might be bogus. The commit
> logs dont give us any help in deciding that. I.e. if you did that
> work, you should document it. If you _didnt_ do that analysis work,
> you shouldnt send patches addressing these types of warnings.
>
I was busy in another stuff, So I am sending analysis of first commit.
If you want you can apply this patch and ignore others :
[PATCH-tip] x86: mm/numa_32.c calculate_numa_remap_pages should use __init
calculate_numa_remap_pages() is called only by __init initmem_init()
further calculate_numa_remap_pages is calling:
__init find_e820_area() and __init reserve_early()
So calculate_numa_remap_pages() should be __init calculate_numa_remap_pages().
Impact: fix Section mismatch warnings
WARNING: arch/x86/built-in.o(.text+0x82ea3): Section mismatch in reference from the function calculate_numa_remap_pages() to the function .init.text:find_e820_area()
The function calculate_numa_remap_pages() references
the function __init find_e820_area().
This is often because calculate_numa_remap_pages lacks a __init
annotation or the annotation of find_e820_area is wrong.
WARNING: arch/x86/built-in.o(.text+0x82f5f): Section mismatch in reference from the function calculate_numa_remap_pages() to the function .init.text:reserve_early()
The function calculate_numa_remap_pages() references
the function __init reserve_early().
This is often because calculate_numa_remap_pages lacks a __init
annotation or the annotation of reserve_early is wrong.
Signed-off-by: Jaswinder Singh Rajput <[email protected]>
---
arch/x86/mm/numa_32.c | 2 +-
1 files changed, 1 insertions(+), 1 deletions(-)
diff --git a/arch/x86/mm/numa_32.c b/arch/x86/mm/numa_32.c
index 3daefa0..d253006 100644
--- a/arch/x86/mm/numa_32.c
+++ b/arch/x86/mm/numa_32.c
@@ -257,7 +257,7 @@ void resume_map_numa_kva(pgd_t *pgd_base)
}
#endif
-static unsigned long calculate_numa_remap_pages(void)
+static __init unsigned long calculate_numa_remap_pages(void)
{
int nid;
unsigned long size, reserve_pages = 0;
--
1.6.0.6
* Jaswinder Singh Rajput <[email protected]> wrote:
> On Fri, 2009-04-17 at 18:41 +0200, Ingo Molnar wrote:
> > * Jaswinder Singh Rajput <[email protected]> wrote:
> >
> > > The following changes since commit 88dc4c8e38d64db32907e0bd605f8c1ec4c4d1bd:
> > > Ingo Molnar (1):
> > > Merge branch 'tracing/ftrace'
> > >
> > > are available in the git repository at:
> > >
> > > git://git.kernel.org/pub/scm/linux/kernel/git/jaswinder/linux-2.6-tip.git master
> > >
> > > Jaswinder Singh Rajput (3):
> > > x86: mm/numa_32.c calculate_numa_remap_pages should use __init
> > > x86: apic/es7000_32.c find_unisys_acpi_oem_table and es7000_acpi_madt_oem_check should use __init
> > > x86: smpboot.c wakeup_secondary_cpu_via_nmi do not required __devinit
> >
> > The commit logs lack analysis. The suggestions in the warnings are
> > advisory and can be wrong. Analysis explaining what happened, maybe
> > even when it happened, and what should be done about it to fix that
> > issue is needed in such changelogs.
> >
> > The commits might be correct - or they might be bogus. The commit
> > logs dont give us any help in deciding that. I.e. if you did that
> > work, you should document it. If you _didnt_ do that analysis work,
> > you shouldnt send patches addressing these types of warnings.
> >
>
> I was busy in another stuff, So I am sending analysis of first
> commit. If you want you can apply this patch and ignore others :
>
> [PATCH-tip] x86: mm/numa_32.c calculate_numa_remap_pages should use __init
>
> calculate_numa_remap_pages() is called only by __init initmem_init()
> further calculate_numa_remap_pages is calling:
> __init find_e820_area() and __init reserve_early()
>
> So calculate_numa_remap_pages() should be __init calculate_numa_remap_pages().
>
> Impact: fix Section mismatch warnings
> WARNING: arch/x86/built-in.o(.text+0x82ea3): Section mismatch in reference from the function calculate_numa_remap_pages() to the function .init.text:find_e820_area()
> The function calculate_numa_remap_pages() references
> the function __init find_e820_area().
> This is often because calculate_numa_remap_pages lacks a __init
> annotation or the annotation of find_e820_area is wrong.
>
> WARNING: arch/x86/built-in.o(.text+0x82f5f): Section mismatch in reference from the function calculate_numa_remap_pages() to the function .init.text:reserve_early()
> The function calculate_numa_remap_pages() references
> the function __init reserve_early().
> This is often because calculate_numa_remap_pages lacks a __init
> annotation or the annotation of reserve_early is wrong.
>
> Signed-off-by: Jaswinder Singh Rajput <[email protected]>
Yes, this one is perfect, it contains precisely the information we
need. It's also helpful for other reasons: people looking at such
commit logs will learn how to do section warning analysis correct.
Btw., the impact line i added is slightly different:
[ Impact: save memory, address Section mismatch warning ]
Note that the main impact is that we now save a little bit of RAM,
by marking one more function __init.
Below is the full commit.
Thanks,
Ingo
-------------------->
>From 445b9e51e9ebd7eb1b9ba724b38342015769b48e Mon Sep 17 00:00:00 2001
From: Jaswinder Singh Rajput <[email protected]>
Date: Fri, 17 Apr 2009 23:31:20 +0530
Subject: [PATCH] x86: mm/numa_32.c calculate_numa_remap_pages should use __init
calculate_numa_remap_pages() is called only by __init initmem_init()
further calculate_numa_remap_pages is calling:
__init find_e820_area() and __init reserve_early()
So calculate_numa_remap_pages() should be __init calculate_numa_remap_pages().
WARNING: arch/x86/built-in.o(.text+0x82ea3): Section mismatch in reference from the function calculate_numa_remap_pages() to the function .init.text:find_e820_area()
The function calculate_numa_remap_pages() references
the function __init find_e820_area().
This is often because calculate_numa_remap_pages lacks a __init
annotation or the annotation of find_e820_area is wrong.
WARNING: arch/x86/built-in.o(.text+0x82f5f): Section mismatch in reference from the function calculate_numa_remap_pages() to the function .init.text:reserve_early()
The function calculate_numa_remap_pages() references
the function __init reserve_early().
This is often because calculate_numa_remap_pages lacks a __init
annotation or the annotation of reserve_early is wrong.
[ Impact: save memory, address Section mismatch warning ]
Signed-off-by: Jaswinder Singh Rajput <[email protected]>
Cc: Sam Ravnborg <[email protected]>
LKML-Reference: <[email protected]>
Signed-off-by: Ingo Molnar <[email protected]>
---
arch/x86/mm/numa_32.c | 2 +-
1 files changed, 1 insertions(+), 1 deletions(-)
diff --git a/arch/x86/mm/numa_32.c b/arch/x86/mm/numa_32.c
index 3daefa0..d253006 100644
--- a/arch/x86/mm/numa_32.c
+++ b/arch/x86/mm/numa_32.c
@@ -257,7 +257,7 @@ void resume_map_numa_kva(pgd_t *pgd_base)
}
#endif
-static unsigned long calculate_numa_remap_pages(void)
+static __init unsigned long calculate_numa_remap_pages(void)
{
int nid;
unsigned long size, reserve_pages = 0;
Commit-ID: f3ebb04784182f7c3d7dfc037a292201ce0c6ac9
Gitweb: http://git.kernel.org/tip/f3ebb04784182f7c3d7dfc037a292201ce0c6ac9
Author: Jaswinder Singh Rajput <[email protected]>
AuthorDate: Fri, 17 Apr 2009 23:31:20 +0530
Committer: Ingo Molnar <[email protected]>
CommitDate: Fri, 17 Apr 2009 21:04:31 +0200
x86: mm/numa_32.c calculate_numa_remap_pages should use __init
calculate_numa_remap_pages() is called only by __init initmem_init()
further calculate_numa_remap_pages is calling:
__init find_e820_area() and __init reserve_early()
So calculate_numa_remap_pages() should be __init calculate_numa_remap_pages().
WARNING: arch/x86/built-in.o(.text+0x82ea3): Section mismatch in reference from the function calculate_numa_remap_pages() to the function .init.text:find_e820_area()
The function calculate_numa_remap_pages() references
the function __init find_e820_area().
This is often because calculate_numa_remap_pages lacks a __init
annotation or the annotation of find_e820_area is wrong.
WARNING: arch/x86/built-in.o(.text+0x82f5f): Section mismatch in reference from the function calculate_numa_remap_pages() to the function .init.text:reserve_early()
The function calculate_numa_remap_pages() references
the function __init reserve_early().
This is often because calculate_numa_remap_pages lacks a __init
annotation or the annotation of reserve_early is wrong.
[ Impact: save memory, address Section mismatch warning ]
Signed-off-by: Jaswinder Singh Rajput <[email protected]>
Cc: Sam Ravnborg <[email protected]>
LKML-Reference: <[email protected]>
Signed-off-by: Ingo Molnar <[email protected]>
---
arch/x86/mm/numa_32.c | 2 +-
1 files changed, 1 insertions(+), 1 deletions(-)
diff --git a/arch/x86/mm/numa_32.c b/arch/x86/mm/numa_32.c
index 3daefa0..d253006 100644
--- a/arch/x86/mm/numa_32.c
+++ b/arch/x86/mm/numa_32.c
@@ -257,7 +257,7 @@ void resume_map_numa_kva(pgd_t *pgd_base)
}
#endif
-static unsigned long calculate_numa_remap_pages(void)
+static __init unsigned long calculate_numa_remap_pages(void)
{
int nid;
unsigned long size, reserve_pages = 0;
Commit-ID: a81b6314e0aa480b8ac6dd02779d44cd0bee0a34
Gitweb: http://git.kernel.org/tip/a81b6314e0aa480b8ac6dd02779d44cd0bee0a34
Author: Jaswinder Singh Rajput <[email protected]>
AuthorDate: Fri, 17 Apr 2009 23:31:20 +0530
Committer: Ingo Molnar <[email protected]>
CommitDate: Fri, 17 Apr 2009 22:43:13 +0200
x86: mm/numa_32.c calculate_numa_remap_pages should use __init
calculate_numa_remap_pages() is called only by __init initmem_init()
further calculate_numa_remap_pages is calling:
__init find_e820_area() and __init reserve_early()
So calculate_numa_remap_pages() should be __init calculate_numa_remap_pages().
WARNING: arch/x86/built-in.o(.text+0x82ea3): Section mismatch in reference from the function calculate_numa_remap_pages() to the function .init.text:find_e820_area()
The function calculate_numa_remap_pages() references
the function __init find_e820_area().
This is often because calculate_numa_remap_pages lacks a __init
annotation or the annotation of find_e820_area is wrong.
WARNING: arch/x86/built-in.o(.text+0x82f5f): Section mismatch in reference from the function calculate_numa_remap_pages() to the function .init.text:reserve_early()
The function calculate_numa_remap_pages() references
the function __init reserve_early().
This is often because calculate_numa_remap_pages lacks a __init
annotation or the annotation of reserve_early is wrong.
[ Impact: save memory, address Section mismatch warning ]
Signed-off-by: Jaswinder Singh Rajput <[email protected]>
Cc: Sam Ravnborg <[email protected]>
LKML-Reference: <[email protected]>
Signed-off-by: Ingo Molnar <[email protected]>
---
arch/x86/mm/numa_32.c | 2 +-
1 files changed, 1 insertions(+), 1 deletions(-)
diff --git a/arch/x86/mm/numa_32.c b/arch/x86/mm/numa_32.c
index 3daefa0..d253006 100644
--- a/arch/x86/mm/numa_32.c
+++ b/arch/x86/mm/numa_32.c
@@ -257,7 +257,7 @@ void resume_map_numa_kva(pgd_t *pgd_base)
}
#endif
-static unsigned long calculate_numa_remap_pages(void)
+static __init unsigned long calculate_numa_remap_pages(void)
{
int nid;
unsigned long size, reserve_pages = 0;