lkml.org 
[lkml]   [2001]   [Dec]   [6]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
Date
From
SubjectRe: shrink_caches inconsistancy
  Hello,

> This patch makes the comments match for icache,dcache,dqcache shrink
> functions. Initially the comment stated that a priority of 0 could be used,
> but after looking into mm/vmscan.c::shrink_caches this cannot be true. So
> the comment now states that 1 is the highest priority. This appears __really
> true as at priority 1 all of the cache possible is removed.
>
> Also shrink_dqcache_memory now uses the count variable like everyone else.
>
> Possibly incorrect __GFP_FS check added to the dqcache function. but again
> consistancy is my goal.
This check really isn't needed for shrink_dqcache() function. This function can
never recurse into fs so there's no need to have __GFP_FS set.

> Another dqcache issue in that the dqcache was being shrunk at priority+1
> rather than at priority, this looked suspect, and with no comment around the
> code, it to has been remanded to consistancy.
OK :). If I remeber well I saw 'priority' could be 0 somewhere in the comment
and so I added +1 to avoid division by zero. But you're right that code in vmscan.c
actually never calls the functions with priority == 0.

Honza
-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@vger.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/

\
 
 \ /
  Last update: 2005-03-22 13:13    [W:0.039 / U:24.700 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site