lkml.org 
[lkml]   [2007]   [Jan]   [24]   [last100]   RSS Feed
Views: [more markup]  [less markup]  [headers]  [forward] 
 
Messages in this thread
/
DateWed, 24 Jan 2007 14:41:56 -0800
FromRandy Dunlap <>
SubjectRe: [RFC][PATCH 5/6] per namespace tunables
On Tue, 16 Jan 2007 07:15:21 +0100 Nadia.Derbey@bull.net wrote:

> [PATCH 05/06]
> 
> This patch introduces all that is needed to process per namespace tunables.
> 
> ---
>  include/linux/akt.h   |   12 +++++++
>  kernel/autotune/akt.c |   80 ++++++++++++++++++++++++++++++++++++++------------
>  2 files changed, 73 insertions(+), 19 deletions(-)
> 
> +/*
> + * FUNCTION:    This routine gets the actual auto_tune structure for the
> + *              tunables that are per namespace (presently only ipc ones).
> + *
> + * RETURN VALUE: pointer to the tunable structure for the current namespace
> + */

Please use kernel-doc format for function comment blocks.
(see Documentation/kernel-doc-nano-HOWTO.txt)

> +static struct auto_tune *get_ns_tunable(struct auto_tune *p)
> +{
> +	if (p->flags & TUNABLE_IPC_NS) {
> +		char *shift = (char *) p;
> +		struct ipc_namespace *ns = current->nsproxy->ipc_ns;
> +
> +		shift = (shift - (char *) &init_ipc_ns) + (char *) ns;
> +
> +		return (struct auto_tune *) shift;
> +	}
> +
> +	return p;
> +}
> +
> +
>  EXPORT_SYMBOL_GPL(register_tunable);
>  EXPORT_SYMBOL_GPL(unregister_tunable);

and put EXPORT_SYMBOL/_GPL() immediately after each function
that is being exported.

---
~Randy
-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/
\
 
 \ /
  Last update: 2007-01-25 00:25    [from the cache]
©2003-2008