All of lore.kernel.org
 help / color / mirror / Atom feed
From: Don Zickus <dzickus@redhat.com>
To: Kulikov Vasiliy <segooon@gmail.com>
Cc: Kernel Janitors <kernel-janitors@vger.kernel.org>,
	Frederic Weisbecker <fweisbec@gmail.com>,
	Ingo Molnar <mingo@elte.hu>,
	linux-kernel@vger.kernel.org
Subject: Re: [PATCH] kernel/watchdog: Initialize 'result'
Date: Tue, 06 Jul 2010 13:23:19 +0000	[thread overview]
Message-ID: <20100706132319.GT5381@redhat.com> (raw)
In-Reply-To: <1278316854-28442-1-git-send-email-segooon@gmail.com>

On Mon, Jul 05, 2010 at 12:00:54PM +0400, Kulikov Vasiliy wrote:
> Variable on the stack is not initialized to zero, do it explicitly.
> 
> This patch silences a compiler warning:
> kernel/watchdog.c:463: warning: ‘result’ may be used uninitialized in this function

Hmm, I thought I fixed that.  oh well.

ACK.

> 
> Signed-off-by: Kulikov Vasiliy <segooon@gmail.com>
> ---
>  kernel/watchdog.c |    2 +-
>  1 files changed, 1 insertions(+), 1 deletions(-)
> 
> diff --git a/kernel/watchdog.c b/kernel/watchdog.c
> index 91b0b26..613bc1f 100644
> --- a/kernel/watchdog.c
> +++ b/kernel/watchdog.c
> @@ -460,7 +460,7 @@ static void watchdog_disable(int cpu)
>  static void watchdog_enable_all_cpus(void)
>  {
>  	int cpu;
> -	int result;
> +	int result = 0;
>  
>  	for_each_online_cpu(cpu)
>  		result += watchdog_enable(cpu);
> -- 
> 1.7.0.4
> 

WARNING: multiple messages have this Message-ID (diff)
From: Don Zickus <dzickus@redhat.com>
To: Kulikov Vasiliy <segooon@gmail.com>
Cc: Kernel Janitors <kernel-janitors@vger.kernel.org>,
	Frederic Weisbecker <fweisbec@gmail.com>,
	Ingo Molnar <mingo@elte.hu>,
	linux-kernel@vger.kernel.org
Subject: Re: [PATCH] kernel/watchdog: Initialize 'result'
Date: Tue, 6 Jul 2010 09:23:19 -0400	[thread overview]
Message-ID: <20100706132319.GT5381@redhat.com> (raw)
In-Reply-To: <1278316854-28442-1-git-send-email-segooon@gmail.com>

On Mon, Jul 05, 2010 at 12:00:54PM +0400, Kulikov Vasiliy wrote:
> Variable on the stack is not initialized to zero, do it explicitly.
> 
> This patch silences a compiler warning:
> kernel/watchdog.c:463: warning: ‘result’ may be used uninitialized in this function

Hmm, I thought I fixed that.  oh well.

ACK.

> 
> Signed-off-by: Kulikov Vasiliy <segooon@gmail.com>
> ---
>  kernel/watchdog.c |    2 +-
>  1 files changed, 1 insertions(+), 1 deletions(-)
> 
> diff --git a/kernel/watchdog.c b/kernel/watchdog.c
> index 91b0b26..613bc1f 100644
> --- a/kernel/watchdog.c
> +++ b/kernel/watchdog.c
> @@ -460,7 +460,7 @@ static void watchdog_disable(int cpu)
>  static void watchdog_enable_all_cpus(void)
>  {
>  	int cpu;
> -	int result;
> +	int result = 0;
>  
>  	for_each_online_cpu(cpu)
>  		result += watchdog_enable(cpu);
> -- 
> 1.7.0.4
> 

  reply	other threads:[~2010-07-06 13:23 UTC|newest]

Thread overview: 5+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2010-07-05  8:00 [PATCH] kernel/watchdog: Initialize 'result' Kulikov Vasiliy
2010-07-05  8:00 ` Kulikov Vasiliy
2010-07-06 13:23 ` Don Zickus [this message]
2010-07-06 13:23   ` Don Zickus
2010-07-07  8:03 ` [tip:perf/nmi] " tip-bot for Kulikov Vasiliy

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=20100706132319.GT5381@redhat.com \
    --to=dzickus@redhat.com \
    --cc=fweisbec@gmail.com \
    --cc=kernel-janitors@vger.kernel.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=mingo@elte.hu \
    --cc=segooon@gmail.com \
    /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.