Re: [PATCH] cpuset: sparse warnings in cpuset.c

2008-02-23 Thread Paul Jackson
akpm wrote: > ^^ I suck. Yeah, right ... and Dolly Parton is flat chested ;). > Sorry, the above code doesn't seem to exist any more. It moved from cpuset.c to cgroup.c. I just sent a reincarnated patch: [PATCH] cgroup: fix sparse warning of shadow symbol in cgroup.c --

Re: [PATCH] cpuset: sparse warnings in cpuset.c

2008-02-23 Thread Andrew Morton
On Sat, 02 Feb 2008 23:42:23 -0800 Harvey Harrison <[EMAIL PROTECTED]> wrote: ^^ I suck. > Don't redeclare p, use a new variable q. > > kernel/cpuset.c:824:23: warning: symbol 'p' shadows an earlier one > kernel/cpuset.c:746:21: originally declared here > kernel/cpuset.c:1272:52: war

Re: [PATCH] cpuset: sparse warnings in cpuset.c

2008-02-02 Thread Paul Jackson
Harvey wrote: > Don't redeclare p, use a new variable q. You dah man! Thanks. Acked-by: Paul Jackson <[EMAIL PROTECTED]> -- I won't rest till it's the best ... Programmer, Linux Scalability Paul Jackson <[EMAIL PROTECTED]> 1.940.382.4214 --

Re: [PATCH] cpuset: sparse warnings in cpuset.c

2008-02-02 Thread Harvey Harrison
Don't redeclare p, use a new variable q. kernel/cpuset.c:824:23: warning: symbol 'p' shadows an earlier one kernel/cpuset.c:746:21: originally declared here kernel/cpuset.c:1272:52: warning: Using plain integer as NULL pointer Signed-off-by: Harvey Harrison <[EMAIL PROTECTED]> --- Paul, used a va

Re: [PATCH] cpuset: sparse warnings in cpuset.c

2008-02-02 Thread Paul Jackson
Harvey wrote: > No need to redeclare p, we have finished with it at this point, > so reuse it in the for loop. Good catch, however I disagree with the fix. It makes the code more brittle. It's not a good idea to reuse a variable for some other purpose just because you "know" the original use is

[PATCH] cpuset: sparse warnings in cpuset.c

2008-02-02 Thread Harvey Harrison
No need to redeclare p, we have finished with it at this point, so reuse it in the for loop. kernel/cpuset.c:824:23: warning: symbol 'p' shadows an earlier one kernel/cpuset.c:746:21: originally declared here kernel/cpuset.c:1272:52: warning: Using plain integer as NULL pointer Signed-off-by: Har