[lkml]   [2009]   [Jul]   [25]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
Messages in this thread
SubjectRe: [BUG] set_mempolicy(MPOL_INTERLEAV) cause kernel panic
KOSAKI Motohiro wrote:
> 2009/07/25 12:15 に KAMEZAWA Hiroyuki<> さんは
> 書きました:
>> KAMEZAWA Hiroyuki wrote:
>>> KAMEZAWA Hiroyuki wrote:
>>> Then, here is a much easier fix. for trusting cpuset more.
>> just a memo about memory hotplug
>> _Direct_ use of task->mems_allowed is only in cpuset and mempolicy.
>> If no policy is used, it's not checked.
>> (See alloc_pages_current())
>> memory hotplug's notifier just updates top_cpuset's mems_allowed.
>> But it doesn't update each task's ones.
>> Then, task's bahavior is
>> - tasks which don't use mempolicy will use all nodes, N_HIGH_MEMORY.
>> - tasks under cpuset will be controlled under their own cpuset.
>> - tasks under mempolicy will use their own policy.
>> but no new policy is re-calculated and, then, no new mask.
>> Now, even if all memory on nodes a removed, pgdat just remains.
>> Then, cpuset/mempolicy will never access NODE_DATA(nid) which is NULL.
> Umm..
> I don't think this is optimal behavior. but if hotplug guys agree
> this, I agree this too.
This behavior itself is not very bad.
And all hotplug thing is just a side story of this bugfix.

To update nodemask, user's mask should be saved in the policy
even when the mask is not relative and v.node should be calculated
again, at event. IIUC, rather than per-policy update by notifer,
some new implemenation for policy will be necessary.

If you mention about the fact that NODE_DATA(nid) is not removed
at node removal. I have no idea, now. copied zonelist is a problem.


 \ /
  Last update: 2009-07-25 16:43    [W:0.107 / U:8.712 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site