Skip to contentSkip to conversation

init.h: Document the existence of __initconst

PATCH New Geert Uytterhoeven 1 participant 1 message Sep 15, 2013

lore
Share & tools
lore
#0 lore raw

PATCH 1/1 init.h: Document the existence of __initconst

Initdata can be const since more than 5 years, using the __initconst keyword.

---
 include/linux/init.h |    6 ++----
 1 file changed, 2 insertions(+), 4 deletions(-)
include/linux/init.h +2 -4
index f1c27a7..8e68a64 100644
@@ -26,8 +26,8 @@
  * extern int initialize_foobar_device(int, int, int) __init;
  *
  * For initialized data:
- * You should insert __initdata between the variable name and equal
- * sign followed by value, e.g.:
+ * You should insert __initdata or __initconst between the variable name
+ * and equal sign followed by value, e.g.:
  *
  * static int init_variable __initdata = 0;
  * static const char linux_logo[] __initconst = { 0x32, 0x36, ... };
@@ -35,8 +35,6 @@
  * Don't forget to initialize data not at file scope, i.e. within a function,
  * as gcc otherwise puts the data into the bss section and not into the init
  * section.
- * 
- * Also note, that this data cannot be "const".
  */
 
 /* These are for everybody (although not all archs will actually
Signature · 1 line
1.7.9.5