mirror of https://lore.kernel.org/lkml/
 help / color / mirror / Atom feed
From: "Paul E. McKenney" <paulmck@kernel.org>
To: Javier Contreras <contreras.javi.0@gmail.com>
Cc: linux-kernel@vger.kernel.org
Subject: Re: [PATCH] init: init_task.c: fixed two spaces coding style issue
Date: Sat, 27 Feb 2021 09:44:18 -0800	[thread overview]
Message-ID: <20210227174417.GA18947@paulmck-ThinkPad-P72> (raw)
In-Reply-To: <20210227170118.24056-1-contreras.javi.0@gmail.com>

On Sat, Feb 27, 2021 at 06:01:18PM +0100, Javier Contreras wrote:
> Fixed two spaces coding style issue.
> 
> Signed-off-by: Javier Contreras <contreras.javi.0@gmail.com>

I am not maintainer for this code, and also wangjingyu beat you to this
one.  But one question:  Given that this patch would cause "git blame"
to list you as the immediate point of contact for each line changed,
are you ready to answer all questions about each of those lines of code?
For example, given C's default initialization to zero, why is the "mm"
field explicitly set to NULL?

						Thanx, Paul

> ---
>  init/init_task.c | 30 +++++++++++++++---------------
>  1 file changed, 15 insertions(+), 15 deletions(-)
> 
> diff --git a/init/init_task.c b/init/init_task.c
> index 3711cdaafed2..85d6b045ef7a 100644
> --- a/init/init_task.c
> +++ b/init/init_task.c
> @@ -71,24 +71,24 @@ struct task_struct init_task
>  	.thread_info	= INIT_THREAD_INFO(init_task),
>  	.stack_refcount	= REFCOUNT_INIT(1),
>  #endif
> -	.state		= 0,
> -	.stack		= init_stack,
> -	.usage		= REFCOUNT_INIT(2),
> -	.flags		= PF_KTHREAD,
> -	.prio		= MAX_PRIO - 20,
> -	.static_prio	= MAX_PRIO - 20,
> -	.normal_prio	= MAX_PRIO - 20,
> -	.policy		= SCHED_NORMAL,
> -	.cpus_ptr	= &init_task.cpus_mask,
> -	.cpus_mask	= CPU_MASK_ALL,
> -	.nr_cpus_allowed= NR_CPUS,
> -	.mm		= NULL,
> -	.active_mm	= &init_mm,
> -	.restart_block	= {
> +	.state		 = 0,
> +	.stack		 = init_stack,
> +	.usage		 = REFCOUNT_INIT(2),
> +	.flags		 = PF_KTHREAD,
> +	.prio		 = MAX_PRIO - 20,
> +	.static_prio	 = MAX_PRIO - 20,
> +	.normal_prio	 = MAX_PRIO - 20,
> +	.policy		 = SCHED_NORMAL,
> +	.cpus_ptr	 = &init_task.cpus_mask,
> +	.cpus_mask	 = CPU_MASK_ALL,
> +	.nr_cpus_allowed = NR_CPUS,
> +	.mm		 = NULL,
> +	.active_mm	 = &init_mm,
> +	.restart_block	 = {
>  		.fn = do_no_restart_syscall,
>  	},
>  	.se		= {
> -		.group_node 	= LIST_HEAD_INIT(init_task.se.group_node),
> +		.group_node	= LIST_HEAD_INIT(init_task.se.group_node),
>  	},
>  	.rt		= {
>  		.run_list	= LIST_HEAD_INIT(init_task.rt.run_list),
> -- 
> 2.30.1
> 

      reply	other threads:[~2021-02-27 18:05 UTC|newest]

Thread overview: 2+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2021-02-27 17:01 Javier Contreras
2021-02-27 17:44 ` Paul E. McKenney [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=20210227174417.GA18947@paulmck-ThinkPad-P72 \
    --to=paulmck@kernel.org \
    --cc=contreras.javi.0@gmail.com \
    --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®