lkml.org 
[lkml]   [2011]   [Nov]   [18]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
Date
From
SubjectRe: [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


\
 
 \ /
  Last update: 2011-11-18 19:49    [W:0.141 / U:0.408 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site