All of lore.kernel.org
 help / color / mirror / Atom feed
From: Ingo Molnar <mingo@kernel.org>
To: Arnd Bergmann <arnd@arndb.de>
Cc: Greg Kroah-Hartman <gregkh@linuxfoundation.org>,
	"K. Y. Srinivasan" <kys@microsoft.com>,
	Haiyang Zhang <haiyangz@microsoft.com>,
	Stephen Hemminger <sthemmin@microsoft.com>,
	Thomas Gleixner <tglx@linutronix.de>,
	Ingo Molnar <mingo@redhat.com>, "H. Peter Anvin" <hpa@zytor.com>,
	x86@kernel.org, Vitaly Kuznetsov <vkuznets@redhat.com>,
	devel@linuxdriverproject.org, linux-kernel@vger.kernel.org
Subject: Re: [PATCH] hv: hide unused label
Date: Wed, 1 Mar 2017 10:26:07 +0100	[thread overview]
Message-ID: <20170301092607.GA7165@gmail.com> (raw)
In-Reply-To: <20170214211736.2641241-1-arnd@arndb.de>


* Arnd Bergmann <arnd@arndb.de> wrote:

> This new 32-bit warning just showed up:
> 
> arch/x86/hyperv/hv_init.c: In function 'hyperv_init':
> arch/x86/hyperv/hv_init.c:167:1: error: label 'register_msr_cs' defined but not used [-Werror=unused-label]
> 
> The easiest solution is to move the label up into the existing #ifdef that
> has the goto.
> 
> Fixes: dee863b571b0 ("hv: export current Hyper-V clocksource")
> Signed-off-by: Arnd Bergmann <arnd@arndb.de>
> ---
>  arch/x86/hyperv/hv_init.c | 2 +-
>  1 file changed, 1 insertion(+), 1 deletion(-)
> 
> diff --git a/arch/x86/hyperv/hv_init.c b/arch/x86/hyperv/hv_init.c
> index db64baf0e500..8bef70e7f3cc 100644
> --- a/arch/x86/hyperv/hv_init.c
> +++ b/arch/x86/hyperv/hv_init.c
> @@ -158,13 +158,13 @@ void hyperv_init(void)
>  		clocksource_register_hz(&hyperv_cs_tsc, NSEC_PER_SEC/100);
>  		return;
>  	}
> +register_msr_cs:
>  #endif
>  	/*
>  	 * For 32 bit guests just use the MSR based mechanism for reading
>  	 * the partition counter.
>  	 */
>  
> -register_msr_cs:

Now the warning triggers upstream:

 arch/x86/hyperv/hv_init.c: In function ‘hyperv_init’:
 arch/x86/hyperv/hv_init.c:167:1: warning: label ‘register_msr_cs’ defined but not used [-Wunused-label]

Thanks,

	Ingo

  parent reply	other threads:[~2017-03-01  9:27 UTC|newest]

Thread overview: 4+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2017-02-14 21:17 [PATCH] hv: hide unused label Arnd Bergmann
2017-02-17 17:03 ` Stephen Hemminger
2017-03-01  9:26 ` Ingo Molnar [this message]
2017-03-01  9:54 ` [tip:x86/urgent] x86/hyperv: Hide " tip-bot for Arnd Bergmann

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=20170301092607.GA7165@gmail.com \
    --to=mingo@kernel.org \
    --cc=arnd@arndb.de \
    --cc=devel@linuxdriverproject.org \
    --cc=gregkh@linuxfoundation.org \
    --cc=haiyangz@microsoft.com \
    --cc=hpa@zytor.com \
    --cc=kys@microsoft.com \
    --cc=linux-kernel@vger.kernel.org \
    --cc=mingo@redhat.com \
    --cc=sthemmin@microsoft.com \
    --cc=tglx@linutronix.de \
    --cc=vkuznets@redhat.com \
    --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.