mirror of https://lore.kernel.org/lkml/
 help / color / mirror / Atom feed
From: Ananth N Mavinakayanahalli <ananth@in.ibm.com>
To: Kumar Gala <galak@kernel.crashing.org>
Cc: linux-kernel@vger.kernel.org, Andrew Morton <akpm@osdl.org>,
	prasanna@in.ibm.com, anil.s.keshavamurthy@intel.com,
	davem@davemloft.net, Paul Mackerras <paulus@samba.org>,
	masami.hiramatsu.pt@hitachi.com
Subject: Re: [PATCH] kprobes: Fix compiler warning
Date: Tue, 30 Jan 2007 11:25:56 +0530	[thread overview]
Message-ID: <20070130055556.GA20699@in.ibm.com> (raw)
In-Reply-To: <Pine.LNX.4.64.0701292341070.32393@localhost.localdomain>

On Mon, Jan 29, 2007 at 11:43:33PM -0600, Kumar Gala wrote:
> On ppc the compiler gripes about:
> 
> kernel/kprobes.c: In function 'collect_garbage_slots':
> kernel/kprobes.c:215: warning: comparison is always false due to limited 
> range of data type
> 
> The compiler ends up optimizing away the test since char's are unsigned on 
> ppc.

Kumar,

Masami fixed this last week:

http://marc.theaimsgroup.com/?l=linux-kernel&m=116968723823366&w=2

Patch currently in -mm.

Thanks,
Ananth

> 
> Signed-off-by: Kumar Gala <galak@kernel.crashing.org>
> 
> ---
> commit 1ee2dc5300b1c454f92eeea82da300f72db1b26f
> tree c73cdacb43e154292708d967e11b1cbf7ab4904f
> parent c0d4d573feed199b16094c072e7cb07afb01c598
> author Kumar Gala <galak@kernel.crashing.org> Mon, 29 Jan 2007 23:38:11 
> -0600
> committer Kumar Gala <galak@kernel.crashing.org> Mon, 29 Jan 2007 23:38:11 
> -0600
> 
>  kernel/kprobes.c |    2 +-
>  1 files changed, 1 insertions(+), 1 deletions(-)
> 
> diff --git a/kernel/kprobes.c b/kernel/kprobes.c
> index 17ec4af..514276f 100644
> --- a/kernel/kprobes.c
> +++ b/kernel/kprobes.c
> @@ -212,7 +212,7 @@ static int __kprobes collect_garbage_slots(void)
>  			continue;
>  		kip->ngarbage = 0;	/* we will collect all garbages */
>  		for (i = 0; i < INSNS_PER_PAGE; i++) {
> -			if (kip->slot_used[i] == -1 &&
> +			if (kip->slot_used[i] == (char)-1 &&
>  			    collect_one_slot(kip, i))
>  				break;
>  		}

  reply	other threads:[~2007-01-30  5:56 UTC|newest]

Thread overview: 8+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2007-01-30  5:43 Kumar Gala
2007-01-30  5:55 ` Ananth N Mavinakayanahalli [this message]
2007-01-30  7:05   ` Kumar Gala
2007-01-30  7:12     ` Kumar Gala
2007-01-30  7:41       ` Andrew Morton
2007-01-31  0:04         ` Kumar Gala
2013-07-01 14:33 [PATCH] kprobes: fix " Dong Fang
2013-07-01 14:46 ` Dong Fang

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=20070130055556.GA20699@in.ibm.com \
    --to=ananth@in.ibm.com \
    --cc=akpm@osdl.org \
    --cc=anil.s.keshavamurthy@intel.com \
    --cc=davem@davemloft.net \
    --cc=galak@kernel.crashing.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=masami.hiramatsu.pt@hitachi.com \
    --cc=paulus@samba.org \
    --cc=prasanna@in.ibm.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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox

Powered by JetHome