Re: [PATCH for mmotm 0414] vmscan,memcg: reintroduce sc->may_swap
From: KOSAKI Motohiro
Date: Sun Apr 19 2009 - 07:39:34 EST
2009/4/19 KOSAKI Motohiro <kosaki.motohiro@xxxxxxxxxxxxxx>:
> Hi
>
> Hi
>
>>> @@ -1724,6 +1728,7 @@ unsigned long try_to_free_mem_cgroup_pag
>>> struct scan_control sc = {
>>> .may_writepage = !laptop_mode,
>>> .may_unmap = 1,
>>> + .may_swap = 1,
>>> .swap_cluster_max = SWAP_CLUSTER_MAX,
>>> .swappiness = swappiness,
>>> .order = 0,
>>> @@ -1734,7 +1739,7 @@ unsigned long try_to_free_mem_cgroup_pag
>>> struct zonelist *zonelist;
>>>
>>> if (noswap)
>>> - sc.may_unmap = 0;
>>> + sc.may_swap = 0;
>>
>> Can this be directly initialized?
>>
>> struct scan_control sc = {
>> ...
>> .may_swap = !noswap,
>> ...
>> };
>
> your proposal is better coding style. but I also prefer condig style
> consistency.
> I think we should change may_unmap and may_swap at the same time.
> Thus, I'd like to does it by another patch.
Grr, I've misunderstood your comment.
Will fix as your suggestion.
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/