mirror of https://lore.kernel.org/lkml/
 help / color / mirror / Atom feed
From: Randy Dunlap <randy.dunlap@oracle.com>
To: Bernhard Kaindl <bk@suse.de>
Cc: Andrew Morton <akpm@linux-foundation.org>,
	linux-kernel@vger.kernel.org, Andi Kleen <ak@suse.de>,
	Dave Jones <davej@codemonkey.org.uk>
Subject: Re: [PATCH 1/4] Adds mtrr_save_fixed_ranges() for use in two later patches.
Date: Fri, 13 Apr 2007 09:13:58 -0700	[thread overview]
Message-ID: <20070413091358.cf8c426e.randy.dunlap@oracle.com> (raw)
In-Reply-To: <Pine.LNX.4.64.0704131735570.17956@jbgna.fhfr.qr>

On Fri, 13 Apr 2007 17:50:50 +0200 (CEST) Bernhard Kaindl wrote:

> ---
>  arch/i386/kernel/cpu/mtrr/generic.c |   16 +++++++++++++++-
>  include/asm-i386/mtrr.h             |    2 ++
>  include/asm-x86_64/proto.h          |    2 ++
>  3 files changed, 19 insertions(+), 1 deletion(-)
> 
> Index: 2.6.21-rc6-mm1/arch/i386/kernel/cpu/mtrr/generic.c
> ===================================================================
> --- 2.6.21-rc6-mm1.orig/arch/i386/kernel/cpu/mtrr/generic.c
> +++ 2.6.21-rc6-mm1/arch/i386/kernel/cpu/mtrr/generic.c
> @@ -37,7 +37,11 @@ get_mtrr_var_range(unsigned int index, s
>  	rdmsr(MTRRphysMask_MSR(index), vr->mask_lo, vr->mask_hi);
>  }
> 
> -static void __cpuinit
> +/**
> + * Retrieves the current fixed-range MTRRs from the current CPU
> + * \param frs address where to write the current MTRR contents
> + */

Please use correct kernel-doc notation.
See Documentation/kernel-doc-nano-HOWTO.txt for details.

Briefly:  "/**" begins a kernel-doc comment block.
Next line is "function short description" (when it's a function).
Parameters are referred to as @param, not \param.

Please check the entire patch series for this.

> +static void
>  get_fixed_ranges(mtrr_type * frs)
>  {
>  	unsigned int *p = (unsigned int *) frs;
> @@ -51,6 +55,16 @@ get_fixed_ranges(mtrr_type * frs)
>  		rdmsr(MTRRfix4K_C0000_MSR + i, p[6 + i * 2], p[7 + i * 2]);
>  }
> 
> +/**
> + * Updates our copy of the state of the fixed-range MTRR values
> + * with the current fixed-range MTRR contents from the current CPU
> + * \param info dummy needed for use by smp_call_function_single()
> + */
> +void mtrr_save_fixed_ranges(void *info)
> +{
> +	get_fixed_ranges(mtrr_state.fixed_ranges);
> +}
> +
>  static void __cpuinit print_fixed(unsigned base, unsigned step, const mtrr_type*types)
>  {
>  	unsigned i;
> Index: 2.6.21-rc6-mm1/include/asm-i386/mtrr.h
> ===================================================================
> --- 2.6.21-rc6-mm1.orig/include/asm-i386/mtrr.h
> +++ 2.6.21-rc6-mm1/include/asm-i386/mtrr.h
> @@ -69,6 +69,7 @@ struct mtrr_gentry
> 
>  /*  The following functions are for use by other drivers  */
>  # ifdef CONFIG_MTRR
> +extern void mtrr_save_fixed_ranges(void *);

We prefer to have a variable name in the prototype (cf. below).


>  extern int mtrr_add (unsigned long base, unsigned long size,
>  		     unsigned int type, char increment);
>  extern int mtrr_add_page (unsigned long base, unsigned long size,


---
~Randy
*** Remember to use Documentation/SubmitChecklist when testing your code ***

  reply	other threads:[~2007-04-13 16:13 UTC|newest]

Thread overview: 5+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
     [not found] <20070413121533.082325752@mahler.suse.de>
2007-04-13 15:50 ` Bernhard Kaindl
2007-04-13 16:13   ` Randy Dunlap [this message]
2007-04-13 15:51 ` [PATCH 2/4] Save the MTRRs of the BSP before booting an AP Bernhard Kaindl
2007-04-13 15:52 ` [PATCH 3/4] Save and restore the fixed-range MTRRs of the BSP when suspending Bernhard Kaindl
2007-04-13 16:04 ` [PATCH 4/4] Enable support for fixed-range IORRs to keep RdMem & WrMem in sync Bernhard Kaindl

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=20070413091358.cf8c426e.randy.dunlap@oracle.com \
    --to=randy.dunlap@oracle.com \
    --cc=ak@suse.de \
    --cc=akpm@linux-foundation.org \
    --cc=bk@suse.de \
    --cc=davej@codemonkey.org.uk \
    --cc=linux-kernel@vger.kernel.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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox

all inboxes | Powered by JetHome®