Re: [PATCH 13/33] readahead: state based method - aging accounting

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On Fri, May 26, 2006 at 10:04:26AM -0700, Andrew Morton wrote:
> 
> (hey, I haven't finished reading the last batch yet)
> 
> Wu Fengguang <[email protected]> wrote:
> >
> >  /*
> >  + * The node's effective length of inactive_list(s).
> >  + */
> >  +static unsigned long node_free_and_cold_pages(void)
> >  +{
> >  +	unsigned int i;
> >  +	unsigned long sum = 0;
> >  +	struct zone *zones = NODE_DATA(numa_node_id())->node_zones;
> >  +
> >  +	for (i = 0; i < MAX_NR_ZONES; i++)
> >  +		sum += zones[i].nr_inactive +
> >  +			zones[i].free_pages - zones[i].pages_low;
> >  +
> >  +	return sum;
> >  +}
> 
> I guess this should go into page_alloc.c along with all the similar functions.

Moved as adviced.

> Is this function well-named?  Why does it have "cold" in the name?

Because it only sums `nr_inactive', leaving out `nr_active'.
-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to [email protected]
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/

[Index of Archives]     [Kernel Newbies]     [Netfilter]     [Bugtraq]     [Photo]     [Stuff]     [Gimp]     [Yosemite News]     [MIPS Linux]     [ARM Linux]     [Linux Security]     [Linux RAID]     [Video 4 Linux]     [Linux for the blind]     [Linux Resources]
  Powered by Linux