Messages in this thread | | | Date | Fri, 18 Nov 2011 10:46:31 -0800 (PST) | From | Andrei Warkentin <> | Subject | Re: [PATCH] include/log2.h: Fix rounddown_pow_of_two(1) |
| |
Hi,
----- Original Message ----- > From: "Andrew Morton" <akpm@linux-foundation.org> > To: "Andrei Warkentin" <andreiw@vmware.com> > Cc: linux-kernel@vger.kernel.org, "Rolf Eike Beer" <eike-kernel@sf-tec.de>, opensuse-kernel@opensuse.org, "Sergiu > Iordache" <sergiu@chromium.org>, "Marco Stornelli" <marco.stornelli@gmail.com>, "Eddie Wai" > <eddie.wai@broadcom.com>, "Jayamohan Kallickal" <jayamohan.kallickal@emulex.com>, "Guennadi Liakhovetski" > <g.liakhovetski@gmx.de> > Sent: Thursday, November 17, 2011 6:05:49 PM > Subject: Re: [PATCH] include/log2.h: Fix rounddown_pow_of_two(1) > > > I assume that nobody has gone off and checked whether all current > callers will survive this change. If they had, they'd have looked in > drivers/char/ramoops.c and seen: > > rounddown_pow_of_two(pdata->mem_size); > rounddown_pow_of_two(pdata->record_size); > > These operations are no-ops. It should be > > pdata->mem_size = rounddown_pow_of_two(pdata->mem_size); > pdata->record_size = rounddown_pow_of_two(pdata->record_size); > > Marco or Sergio: please fix, test and send it over sometime?
I did quickly look through for code that expected rounddown_pow_of_two(1) to give 0, but I didn't apparently look close enough for other issues.
A
| |