lkml.org 
[lkml]   [2007]   [Dec]   [23]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
Date
From
SubjectRe: tlb_finish_mmu() bogisity


On Sun, 23 Dec 2007, Al Viro wrote:
>
> tlb->need_flush += &__get_cpu_var(quicklist)[0].nr_pages != 0;
> makes no sense whatsoever. How the hell can you ever get the address of
> __get_cpu_var(quicklist)[0].nr_pages to be NULL? Postfix operators have
> higher precedence than prefix ones, so that's
> &(((__get_cpu_var(quicklist))[0]).nr_pages)
>
> What did you intend here? s/&//, perhaps?

I think that thing is bogus in other ways. It plays games with
"needs_flush", just because it seems to want the generic code to then call
"check_pgt_cache()", not because it actually wants any flushing to take
place.

But we already call "check_pgt_cache()" there in tlb_finish_mmu()
unconditionally, so I think the whole patch was utter crap.

Or is there any other reason going on here? That quicklist stuff has been
totally broken, it's done too many totally invalid things to really be
worth even keeping. We should get rid of that unmaintainable hack, and if
it has a real performance upside, we should make it part of the *native*
mmu-gather infrastructure, instead of maintaining it as some separate and
buggy/unmaintainable piece-of-sh*t code.

Linus


\
 
 \ /
  Last update: 2007-12-23 22:19    [W:0.050 / U:0.348 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site