[<prev] [next>] [<thread-prev] [day] [month] [year] [list]
Message-ID: <20061122061351.GA4046@in.ibm.com>
Date: Wed, 22 Nov 2006 11:43:51 +0530
From: Gautham R Shenoy <ego@...ibm.com>
To: Andrew Morton <akpm@...l.org>
Cc: ego@...ibm.com, torvalds@...l.org, linux-kernel@...r.kernel.org,
vatsa@...ibm.com, dipankar@...ibm.com, davej@...hat.com,
mingo@...e.hu, kiran@...lex86.org
Subject: Re: [PATCH 1/4] Extend notifier_call_chain to count nr_calls made.
Hi Andrew,
On Mon, Nov 20, 2006 at 10:19:41PM -0800, Andrew Morton wrote:
> > +
> > + if (nr_calls)
> > + *nr_calls ++;
>
> This gets
>
> kernel/sys.c: In function 'notifier_call_chain':
> kernel/sys.c:164: warning: value computed is not used
>
>
> And indeed, this code doesn't work.
>
> What happened?
I didn't get the warnings because my test box still has the prehistoric
version 3.4.4 of gcc.
I compiled the code with gcc 4.1.1 and got the warnings.
The code does not work because of my carelessness.
It should have been (*nr_calls)++ in the first place. I apologise.
Thanks for fixing it.
Regards
gautham.
--
Gautham R Shenoy
Linux Technology Center
IBM India.
"Freedom comes with a price tag of responsibility, which is still a bargain,
because Freedom is priceless!"
-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/
Powered by blists - more mailing lists