From: Andrea Arcangeli <andrea@suse.de>
To: schwidefsky@de.ibm.com
Cc: Linus Torvalds <torvalds@transmeta.com>,
mingo@chiara.elte.hu, linux-kernel@vger.kernel.org
Subject: Re: Memory management bug
Date: Fri, 17 Nov 2000 16:44:22 +0100 [thread overview]
Message-ID: <20001117164422.B27098@athlon.random> (raw)
In-Reply-To: <C125699A.003D4D6A.00@d12mta07.de.ibm.com>
In-Reply-To: <C125699A.003D4D6A.00@d12mta07.de.ibm.com>; from schwidefsky@de.ibm.com on Fri, Nov 17, 2000 at 11:41:58AM +0100
On Fri, Nov 17, 2000 at 11:41:58AM +0100, schwidefsky@de.ibm.com wrote:
> [..] But low on memory
> does mean low on real memory + swap space, doesn't it ? [..]
No. Low on memory here means that `grep MemFree </proc/meminfo' says
you still have only a few mbytes.
> enough swap space but it isn't using any of it when the BUG hits. I think
This is normal.
> the "if (!order)" statements before the "goto try_again" in __alloc_pages
> have something to do with it. To test this assumption I removed the ifs and
The right way to make allocation of order > 0 to work (when not impossible) is
to pass the "order" information from allocator to memory balancing code so you
don't waste resources by freeing and swapping pages that aren't physically
consecutive. We'll need to teach the memory balancing about freeing only
physically consecutive worthwhile pages.
Actually memory balancing in 2.4.x doesn't get any information, not even the
information about which _classzone_ where to free the memory (NOTE: both 2.2.x
and 2.0.x _always_ got the classzone where to free memory at least). This
classzone missing information causes resources wastage indeed and I just fixed
it several times, BTW.
> I didn't see any "__alloc_pages: %lu-order allocation failed." message
So you probably didn't triggered the out-of-order-2-multipages problem, and
the bug you triggered is going to be another one. But still the above order > 1
thoguths applies to both 2.2.x and 2.4.x since once you'll fix the other
problem, you'll sure run into the failed order 2 allocations.
> before I hit yet another BUG in swap_state.c:60.
The bug in swap_state:60 shows a kernel bug in the VM or random memory
corruption. Make sure you can reproduce on x86 to be sure it's not a s390
that is randomly corrupting memory. If you read the oops after the BUG message
with asm at hand you will see in the registers the value of page->mapping and
you can guess if it's random memory corruption or bug in VM this way (for
example if `reg & 3 != 0' it's memory corruption for sure, you should also
if it's pointing to a suitable kernel-heap address).
> Whats the reasoning behind these ifs ?
To catch memory corruption or things running out of control in the kernel.
Andrea
-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@vger.kernel.org
Please read the FAQ at http://www.tux.org/lkml/
next prev parent reply other threads:[~2000-11-17 16:15 UTC|newest]
Thread overview: 16+ messages / expand[flat|nested] mbox.gz Atom feed top
2000-11-17 10:41 Memory management bug schwidefsky
2000-11-17 15:44 ` Andrea Arcangeli [this message]
2000-11-17 19:12 ` Rik van Riel
-- strict thread matches above, loose matches on Subject: below --
2000-11-21 19:55 schwidefsky
2000-11-17 16:35 schwidefsky
2000-11-17 16:42 ` Linus Torvalds
2000-11-17 18:11 ` Andrea Arcangeli
2000-11-17 19:15 ` Rik van Riel
2000-11-16 16:12 schwidefsky
2000-11-16 17:01 ` Linus Torvalds
2000-11-16 17:45 ` Andrea Arcangeli
2000-11-16 18:07 ` Linus Torvalds
2000-11-15 13:24 schwidefsky
2000-11-15 12:39 schwidefsky
2000-11-15 13:19 ` Andi Kleen
2000-11-15 16:45 ` Linus Torvalds
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=20001117164422.B27098@athlon.random \
--to=andrea@suse.de \
--cc=linux-kernel@vger.kernel.org \
--cc=mingo@chiara.elte.hu \
--cc=schwidefsky@de.ibm.com \
--cc=torvalds@transmeta.com \
/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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox