All of lore.kernel.org
 help / color / mirror / Atom feed
From: Ingo Molnar <mingo@elte.hu>
To: Jaswinder Singh Rajput <jaswinder@kernel.org>
Cc: Andrew Morton <akpm@linux-foundation.org>,
	x86 maintainers <x86@kernel.org>,
	LKML <linux-kernel@vger.kernel.org>
Subject: Re: [PATCH -tip] x86: mm/init_32.c fix style problems
Date: Sun, 21 Jun 2009 13:35:05 +0200	[thread overview]
Message-ID: <20090621113505.GA25243@elte.hu> (raw)
In-Reply-To: <1245583492.3052.5.camel@localhost.localdomain>


* Jaswinder Singh Rajput <jaswinder@kernel.org> wrote:

> 
> Impact: cleanup
> 
> Fix :
> 
> WARNING: Use #include <linux/uaccess.h> instead of <asm/uaccess.h>
> ERROR: do not initialise externals to 0 or NULL
> ERROR: code indent should use tabs where possible
> ERROR: space required after that ',' (ctx:VxV)
> ERROR: spaces required around that ':' (ctx:ExV) X 3
> 
> total: 6 errors, 1 warning
> 
> Signed-off-by: Jaswinder Singh Rajput <jaswinderrajput@gmail.com>
> ---
>  arch/x86/mm/init_32.c |   14 +++++++-------
>  1 files changed, 7 insertions(+), 7 deletions(-)

Just like with hugetlbpage.c, this file too has other problems 
beyond trivial style issues:

 - one_page_table_init() logic should be restructured to have its 
   branch condition inverted into a goto out pattern, to get rid of 
   the ugly linebreaks.

 - that ugly check in page_table_kmap_check() should be factored out
   into a helper inline

 - kernel_physical_mapping_init() is too large and should have its 
   innards factored out into one or more helper inlines.

 - there's too many #idefs obscuring the easy readability of the 
   code. Could some be eliminated?

Some style issues as well:

 - printk(KERN_* should be converted to pr_*(

 - the #include files section looks unstructured and ugly. Please 
   take a look at arch/x86/mm/fault.c and try to eliminate all 
   unnecessary include lines and follow the format of fault.c.

These (and other issues) should be addressed as well, so that we 
have a single act of churn there, followed by a quality end result.

Thanks,

	Ingo

      reply	other threads:[~2009-06-21 11:35 UTC|newest]

Thread overview: 2+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2009-06-21 11:24 [PATCH -tip] x86: mm/init_32.c fix style problems Jaswinder Singh Rajput
2009-06-21 11:35 ` Ingo Molnar [this message]

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=20090621113505.GA25243@elte.hu \
    --to=mingo@elte.hu \
    --cc=akpm@linux-foundation.org \
    --cc=jaswinder@kernel.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=x86@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 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.