From: Franck Bui-Huu <vagabon.xyz@gmail.com>
To: Ralf Baechle <ralf@linux-mips.org>,
"Maciej W. Rozycki" <macro@linux-mips.org>,
Geert Uytterhoeven <geert@linux-m68k.org>
Cc: linux-mips <linux-mips@linux-mips.org>
Subject: [PATCH 1/2] Add .init.bss section
Date: Thu, 11 Oct 2007 11:54:12 +0200 [thread overview]
Message-ID: <470DF2C4.8050604@gmail.com> (raw)
In-Reply-To: <470DF25E.60009@gmail.com>
This patch creates a new init section called .init.bss.
This section is similar to .init.data but doesn't consume
any space in the vmlinux image.
All data marked as part of this section must not be initialized,
of course.
Signed-off-by: Franck Bui-Huu <fbuihuu@gmail.com>
---
include/linux/init.h | 24 ++++++++++++++++--------
1 files changed, 16 insertions(+), 8 deletions(-)
diff --git a/include/linux/init.h b/include/linux/init.h
index 74b1f43..9fda0ec 100644
--- a/include/linux/init.h
+++ b/include/linux/init.h
@@ -43,6 +43,8 @@
#define __init __attribute__ ((__section__ (".init.text"))) __cold
#define __initdata __attribute__ ((__section__ (".init.data")))
#define __exitdata __attribute__ ((__section__(".exit.data")))
+#define __initbss __attribute__ ((__section__ (".init.bss")))
+#define __exitbss __attribute__ ((__section__ (".exit.bss")))
#define __exit_call __attribute_used__ __attribute__ ((__section__ (".exitcall.exit")))
/* modpost check for section mismatches during the kernel build.
@@ -257,10 +259,12 @@ void __init parse_early_param(void);
#define __devexit
#define __devexitdata
#else
-#define __devinit __init
-#define __devinitdata __initdata
-#define __devexit __exit
-#define __devexitdata __exitdata
+#define __devinit __init
+#define __devinitdata __initdata
+#define __devinitbss __initbss
+#define __devexit __exit
+#define __devexitdata __exitdata
+#define __devexitbss __exitbss
#endif
#ifdef CONFIG_HOTPLUG_CPU
@@ -270,9 +274,11 @@ void __init parse_early_param(void);
#define __cpuexitdata
#else
#define __cpuinit __init
-#define __cpuinitdata __initdata
-#define __cpuexit __exit
+#define __cpuinitdata __initdata
+#define __cpuinitbss __initbss
+#define __cpuexit __exit
#define __cpuexitdata __exitdata
+#define __cpuexitbss __exitbss
#endif
#if defined(CONFIG_MEMORY_HOTPLUG) || defined(CONFIG_ACPI_HOTPLUG_MEMORY) \
@@ -283,9 +289,11 @@ void __init parse_early_param(void);
#define __memexitdata
#else
#define __meminit __init
-#define __meminitdata __initdata
-#define __memexit __exit
+#define __meminitdata __initdata
+#define __meminitbss __meminitbss
+#define __memexit __exit
#define __memexitdata __exitdata
+#define __memexitbss __exitbss
#endif
/* Functions marked as __devexit may be discarded at kernel link time, depending
--
1.5.3.3
next prev parent reply other threads:[~2007-10-11 9:55 UTC|newest]
Thread overview: 26+ messages / expand[flat|nested] mbox.gz Atom feed top
2007-10-11 9:52 [RFC] Add __initbss section Franck Bui-Huu
2007-10-11 9:54 ` Franck Bui-Huu [this message]
2007-10-11 9:58 ` [PATCH 2/2] Add .init.bss section for MIPS Franck Bui-Huu
2007-10-11 12:44 ` [RFC] Add __initbss section Ralf Baechle
2007-10-11 13:35 ` Maciej W. Rozycki
2007-10-11 14:00 ` Ralf Baechle
2007-10-11 14:49 ` Maciej W. Rozycki
2007-10-14 19:42 ` Franck Bui-Huu
2007-10-15 16:01 ` Ralf Baechle
2007-10-16 8:33 ` Franck Bui-Huu
2007-10-11 13:19 ` Maciej W. Rozycki
2007-10-14 19:52 ` Franck Bui-Huu
2007-10-15 12:19 ` Maciej W. Rozycki
2007-10-15 20:06 ` Franck Bui-Huu
2007-10-16 10:29 ` Maciej W. Rozycki
2007-10-18 20:28 ` Franck Bui-Huu
2007-10-19 11:59 ` Maciej W. Rozycki
2007-11-04 8:29 ` Franck Bui-Huu
2007-11-05 12:38 ` Maciej W. Rozycki
2007-11-05 20:32 ` Franck Bui-Huu
2007-10-11 15:26 ` Thiemo Seufer
2007-10-11 16:16 ` Maciej W. Rozycki
2007-10-11 16:25 ` Ralf Baechle
2007-10-11 17:07 ` Maciej W. Rozycki
2007-10-11 16:39 ` Thiemo Seufer
2007-10-14 19:53 ` Franck Bui-Huu
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=470DF2C4.8050604@gmail.com \
--to=vagabon.xyz@gmail.com \
--cc=geert@linux-m68k.org \
--cc=linux-mips@linux-mips.org \
--cc=macro@linux-mips.org \
--cc=ralf@linux-mips.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.