[PATCH] Immediate Values - Architecture Independent Code - kerneldoc for implementation

Mathieu Desnoyers
2007-07-15T23:40:34Z

Immediate Values - Architecture Independent Code - kerneldoc for implementation

Add kerneldoc to Immediate Values API.
It applies after
"Immediate Values - Architecture Independent Code - kerneldoc"

Signed-off-by: Mathieu Desnoyers <mathieu.desnoyers@polymtl.ca>
CC: hch@infradead.org
---
kernel/immediate.c | 24 +++++++++++++++++-------
1 file changed, 17 insertions(+), 7 deletions(-)

Index: linux-2.6-lttng/kernel/immediate.c
===================================================================
--- linux-2.6-lttng.orig/kernel/immediate.c 2007-07-15 19:04:08.000000000 -0400
+++ linux-2.6-lttng/kernel/immediate.c 2007-07-15 19:07:14.000000000 -0400
@@ -54,7 +54,10 @@ static inline void _immediate_update_ran
}

#ifdef CONFIG_MODULES
-/*
+/**
+ * module_immediate_setup - Update immediate values in a module
+ * @mod: pointer to the struct module
+ *
* Setup the immediate according to the variable upon which it depends. Called
* by load_module with module_mutex held. This mutex protects against concurrent
* modifications to modules'immediates. Therefore, since
@@ -89,6 +92,12 @@ static inline void immediate_update_modu
static inline void immediate_update_modules(int lock) { }
#endif

+/**
+ * immediate_update - update all immediate values in the kernel
+ * @lock: should a module_mutex be taken ?
+ *
+ * Iterate on the kernel core and modules to update the immediate values.
+ */
void immediate_update(int lock)
{
/* Core kernel immediates */
@@ -98,11 +107,7 @@ void immediate_update(int lock)
}
EXPORT_SYMBOL_GPL(immediate_update);

-/*
- * Update the immediate values to the state of the variables they refer to. It
- * is done before SMP is active, at the very beginning of start_kernel().
- */
-void __init immediate_update_early_range(const struct __immediate *begin,
+static void __init immediate_update_early_range(const struct __immediate *begin,
const struct __immediate *end)
{
const struct __immediate *iter;
@@ -111,7 +116,12 @@ void __init immediate_update_early_range
arch_immediate_update_early(iter);
}

-
+/**
+ * immediate_update_early - Update immediate values at boot time
+ *
+ * Update the immediate values to the state of the variables they refer to. It
+ * is done before SMP is active, at the very beginning of start_kernel().
+ */
void __init immediate_update_early(void)
{
immediate_update_early_range(__start___immediate, __stop___immediate);