All of lore.kernel.org
 help / color / mirror / Atom feed
From: Balbir Singh <balbir@linux.vnet.ibm.com>
To: KAMEZAWA Hiroyuki <kamezawa.hiroyu@jp.fujitsu.com>
Cc: Ingo Molnar <mingo@elte.hu>, Li Zefan <lizf@cn.fujitsu.com>,
	Paul Menage <menage@google.com>,
	Daisuke Nishimura <nishimura@mxp.nes.nec.co.jp>,
	linux-mm@kvack.org, mel@csn.ul.ie
Subject: Re: [memcg BUG] unable to handle kernel NULL pointer derefence at 00000000
Date: Tue, 21 Oct 2008 17:44:40 +0530	[thread overview]
Message-ID: <48FDC7B0.6040704@linux.vnet.ibm.com> (raw)
In-Reply-To: <20081021210015.02c8cacc.kamezawa.hiroyu@jp.fujitsu.com>

KAMEZAWA Hiroyuki wrote:
> On Tue, 21 Oct 2008 16:59:28 +0530
> Balbir Singh <balbir@linux.vnet.ibm.com> wrote:
> 
>> KAMEZAWA Hiroyuki wrote:
>>> On Tue, 21 Oct 2008 13:19:51 +0200
>>> Ingo Molnar <mingo@elte.hu> wrote:
>>>
>>>> * Li Zefan <lizf@cn.fujitsu.com> wrote:
>>>>
>>>>>> Oh! thanks...but it seems pc->page is NULL in the middle of ZONE_NORMAL..
>>>>>> ==
>>>>>>  Normal   0x00001000 -> 0x000373fe
>>>>>> ==
>>>>>> This is appearently in the range of page_cgroup initialization.
>>>>>> (if pgdat->node_page_cgroup is initalized correctly...)
>>>>>>
>>>>>> I think write to page_cgroup->page happens only at initialization.
>>>>>> Hmm ? not initilization failure but curruption ?
>>>>>>
>>>>> Yes, curruption. I didn't find informatation about initialization failure.
>>>>>
>>>>>> What happens if replacing __alloc_bootmem() with vmalloc() in page_cgroup.c init ?
>>>>>>
>>>>> So I did this change, and the box booted up without any problem.
>>>>>
>>>>> diff --git a/mm/page_cgroup.c b/mm/page_cgroup.c
>>>>> index 5d86550..82a30b1 100644
>>>>> --- a/mm/page_cgroup.c
>>>>> +++ b/mm/page_cgroup.c
>>>>> @@ -48,8 +48,7 @@ static int __init alloc_node_page_cgroup(int nid)
>>>>>  
>>>>>  	table_size = sizeof(struct page_cgroup) * nr_pages;
>>>>>  
>>>>> -	base = __alloc_bootmem_node_nopanic(NODE_DATA(nid),
>>>>> -			table_size, PAGE_SIZE, __pa(MAX_DMA_ADDRESS));
>>>>> +	base = vmalloc_node(table_size, nid);
>>>>>  	if (!base)
>>>>>  		return -ENOMEM;
>>>> i have this:
>>>>
>>>>   CONFIG_FAILSLAB=y
>>>>   CONFIG_FAIL_PAGE_ALLOC=y
>>>>   # CONFIG_FAIL_MAKE_REQUEST is not set
>>>>   CONFIG_FAIL_IO_TIMEOUT=y
>>>>
>>>> so the bug was perhaps that the __alloc_bootmem_node_nopanic() failed 
>>>> and this code continued silently? vmalloc_node() probably is more 
>>>> agressive about allocating memory.
>>>>
>>> Sorry. I think I cannot use alloc_bootmem() at this point because
>>> it's too late in init-path. (we can use usual page allocator)
>>> So, just replacing alloc_bootmem() with vmalloc_node() is a fix....
>> Kamezawa-San,
>>
>> I would prefer to use alloc_bootmem() instead of vmalloc_node(). May be we can
>> shift cgroups, so that we use early_init for allocating page_cgroups.  What do
>> you think?
>>
> I got an idea and maybe can send a patch soon. I'm now finding x86-32 box..

Please send it to me, I am able to reproduce the problem with my kvm setup on my
32 bit system. I can do a quick test/verification for you.

-- 
	Balbir

--
To unsubscribe, send a message with 'unsubscribe linux-mm' in
the body to majordomo@kvack.org.  For more info on Linux MM,
see: http://www.linux-mm.org/ .
Don't email: <a href=mailto:"dont@kvack.org"> email@kvack.org </a>

  reply	other threads:[~2008-10-21 12:14 UTC|newest]

Thread overview: 60+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2008-10-17 10:48 [RFC][PATCH -mm 0/5] mem+swap resource controller(trial patch) Daisuke Nishimura
2008-10-17 10:56 ` [PATCH -mm 1/5] memcg: replace res_counter Daisuke Nishimura
2008-10-20 19:53   ` Paul Menage
2008-10-21  1:14     ` KAMEZAWA Hiroyuki
2008-10-21  1:29       ` Paul Menage
2008-10-21  1:49         ` KAMEZAWA Hiroyuki
2008-10-21  2:15           ` Paul Menage
2008-10-21  2:50             ` KAMEZAWA Hiroyuki
2008-10-21  2:20           ` Paul Menage
2008-10-21  3:03             ` KAMEZAWA Hiroyuki
2008-10-21  6:30               ` Paul Menage
2008-10-21  5:30       ` Balbir Singh
2008-10-21  5:39         ` KAMEZAWA Hiroyuki
2008-10-21  6:20           ` [memcg BUG] unable to handle kernel NULL pointer derefence at 00000000 Li Zefan
2008-10-21  6:25             ` KAMEZAWA Hiroyuki
2008-10-21  6:28               ` Li Zefan
2008-10-21  6:38                 ` Daisuke Nishimura
2008-10-21  6:54             ` KAMEZAWA Hiroyuki
2008-10-21  7:04               ` Li Zefan
2008-10-21  7:16                 ` KAMEZAWA Hiroyuki
2008-10-21  7:21                   ` Li Zefan
2008-10-21  8:18                     ` KAMEZAWA Hiroyuki
2008-10-21  8:34                       ` Mel Gorman
2008-10-21  8:38                         ` KAMEZAWA Hiroyuki
2008-10-21  8:35                       ` Li Zefan
2008-10-21  8:36                         ` KAMEZAWA Hiroyuki
2008-10-21  8:57                         ` KAMEZAWA Hiroyuki
2008-10-21  9:13                           ` Li Zefan
2008-10-21  9:25                             ` KAMEZAWA Hiroyuki
2008-10-21  9:54                               ` Li Zefan
2008-10-21 10:14                                 ` KAMEZAWA Hiroyuki
2008-10-21 10:57                                   ` Li Zefan
2008-10-21 11:00                                     ` KAMEZAWA Hiroyuki
2008-10-21 11:09                                       ` KAMEZAWA Hiroyuki
2008-10-21 11:13                                     ` KAMEZAWA Hiroyuki
2008-10-21 11:19                                     ` Ingo Molnar
2008-10-21 11:23                                       ` KAMEZAWA Hiroyuki
2008-10-21 11:28                                         ` Ingo Molnar
2008-10-21 11:32                                           ` KAMEZAWA Hiroyuki
2008-10-21 11:38                                             ` Ingo Molnar
2008-10-22  2:13                                             ` Daisuke Nishimura
2008-10-22  2:31                                               ` KAMEZAWA Hiroyuki
2008-10-21 11:29                                         ` Balbir Singh
2008-10-21 11:34                                           ` KAMEZAWA Hiroyuki
2008-10-21 12:00                                           ` KAMEZAWA Hiroyuki
2008-10-21 12:14                                             ` Balbir Singh [this message]
2008-10-21 13:09                                               ` KAMEZAWA Hiroyuki
2008-10-21 13:25                                                 ` Balbir Singh
2008-10-21 13:34                                                 ` Balbir Singh
2008-10-21 13:44                                                   ` [memcg BUG] unable to handle kernel NULL pointer derefence at00000000 亀澤 寛之
2008-10-21 10:58                                   ` [memcg BUG] unable to handle kernel NULL pointer derefence at 00000000 Balbir Singh
2008-10-21  9:33                           ` Daisuke Nishimura
2008-10-21  9:41                             ` KAMEZAWA Hiroyuki
2008-10-21 10:15                               ` Daisuke Nishimura
2008-10-17 10:59 ` [PATCH -mm 2/5] memcg: mem_cgroup private ID Daisuke Nishimura
2008-10-17 11:01 ` [PATCH -mm 3/5] memcg: mem+swap controller Kconfig Daisuke Nishimura, KAMEZAWA Hiroyuki
2008-10-17 11:04 ` [PATCH -mm 4/5] memcg: mem+swap counter Daisuke Nishimura
2008-10-17 11:06 ` [PATCH -mm 5/5] memcg: mem+swap accounting Daisuke Nishimura
2008-10-20  0:24 ` [RFC][PATCH -mm 0/5] mem+swap resource controller(trial patch) KAMEZAWA Hiroyuki
2008-10-20  2:53   ` Daisuke Nishimura

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=48FDC7B0.6040704@linux.vnet.ibm.com \
    --to=balbir@linux.vnet.ibm.com \
    --cc=kamezawa.hiroyu@jp.fujitsu.com \
    --cc=linux-mm@kvack.org \
    --cc=lizf@cn.fujitsu.com \
    --cc=mel@csn.ul.ie \
    --cc=menage@google.com \
    --cc=mingo@elte.hu \
    --cc=nishimura@mxp.nes.nec.co.jp \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.