Re: [RFC][PATCH 2/5] mm: Switch mod_state() to __this_cpu_read()

Valdis.Kletnieks
2011-09-20T22:20:43Z

[-- Attachment #1: Type: text/plain, Size: 762 bytes --]

On Tue, 20 Sep 2011 10:54:10 CDT, Christoph Lameter said:
> IT DOES!!!! The memcg bug is caused by someone using this_cpu_read and
> expecting the cpu not to change. this_cpu_xx ops stand on their own and do
> not guarantee access to the same per cpu area.

As most 6 year olds will tell you, "Well, DUH!". Maybe if you had called it
"this_cpu_or_maybe_that_one_over_there_read()", people wouldn't use it wrong.

"If people place a nice chocky in their mouth, they don't want their cheeks
pierced. In any case this is an inadequate description of the sweetmeat. I
shall have to ask you to accompany me to the station." -- Monty Python.

"inadequate description" hardly begins to cover the design of this API, which
definitely needs to be taken to the station.

[-- Attachment #2: Type: application/pgp-signature, Size: 227 bytes --]