Re: [PATCH] refine for_each_pgdat() [1/4] refine for_each_pgdat

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

 



KAMEZAWA Hiroyuki <[email protected]> wrote:
>
> This patch makes for_each_pgdat() use node_online_map.
> 
> Now, online nodes are managed by node_online_map. But 
> for_each_pgdat() uses pgdat_link to traverse all nodes(pgdat).
> This means management structure is duplicated.
> 
> I think using node_online_map for for_each_pgdat() is simple and
> sane implementation rather than pgdat_link.

We have a bit of a mess here.

for_each_pgdat() iterates over online nodes.

for_each_cpu() iterates over possible CPUs.

It's confusing and asymmetric.  If you have time, it would be nice to later
remove for_each_pgdat() and for_each_cpu() from the kernel altogether, use
for_each_online_cpu(), for_each_possible_cpu(), for_each_online_node(),
for_each_possible_node().
-
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