* [PATCH] Honour "panic_on_oops" sysctl on mips arch
@ 2006-07-20 16:52 Maxime Bizon
2006-07-20 19:18 ` Ralf Baechle
0 siblings, 1 reply; 4+ messages in thread
From: Maxime Bizon @ 2006-07-20 16:52 UTC (permalink / raw)
To: linux-mips
Hello all,
The panic_on_oops sysctl has no effect on mips, the following patch
fixes it.
Signed-off-by: Maxime Bizon <mbizon@freebox.fr>
--- linux-2.6.17.6/arch/mips/kernel/traps.c.orig 2006-07-20 18:42:37.000000000 +0200
+++ linux-2.6.17.6/arch/mips/kernel/traps.c 2006-07-20 18:42:56.000000000 +0200
@@ -21,6 +21,7 @@
#include <linux/spinlock.h>
#include <linux/kallsyms.h>
#include <linux/bootmem.h>
+#include <linux/interrupt.h>
#include <asm/bootinfo.h>
#include <asm/branch.h>
@@ -293,6 +294,16 @@
printk("%s[#%d]:\n", str, ++die_counter);
show_registers(regs);
spin_unlock_irq(&die_lock);
+
+ if (in_interrupt())
+ panic("Fatal exception in interrupt");
+
+ if (panic_on_oops) {
+ printk(KERN_EMERG "Fatal exception: panic in 5 seconds\n");
+ ssleep(5);
+ panic("Fatal exception");
+ }
+
do_exit(SIGSEGV);
}
Regards,
--
Maxime
^ permalink raw reply [flat|nested] 4+ messages in thread
* Re: [PATCH] Honour "panic_on_oops" sysctl on mips arch
2006-07-20 16:52 [PATCH] Honour "panic_on_oops" sysctl on mips arch Maxime Bizon
@ 2006-07-20 19:18 ` Ralf Baechle
2006-07-21 9:28 ` reserved pages and zero pages question pulsar
0 siblings, 1 reply; 4+ messages in thread
From: Ralf Baechle @ 2006-07-20 19:18 UTC (permalink / raw)
To: Maxime Bizon; +Cc: linux-mips
On Thu, Jul 20, 2006 at 06:52:02PM +0200, Maxime Bizon wrote:
> The panic_on_oops sysctl has no effect on mips, the following patch
> fixes it.
Applied. thanks,
Ralf
^ permalink raw reply [flat|nested] 4+ messages in thread
* reserved pages and zero pages question
2006-07-20 19:18 ` Ralf Baechle
@ 2006-07-21 9:28 ` pulsar
2006-07-21 10:28 ` Thiemo Seufer
0 siblings, 1 reply; 4+ messages in thread
From: pulsar @ 2006-07-21 9:28 UTC (permalink / raw)
To: linux-mips
Hi,
In my kernel startup I see the memory usage printed as:
Memory: 125312k/131072k available (1977k kernel code, 5648k reserved, 287k
data, 1664k init, 0k highmem)
I wonder where the reserved pages are used for and how we can minimize it
for small memory systems.
In my search I see that in arcm/mips/mm/init.c there are zero-pages
allocated and put to reserved.
Where are the zero pages used for and can we do without ?
thanks in advance,
Niels Sterrenburg
^ permalink raw reply [flat|nested] 4+ messages in thread
* Re: reserved pages and zero pages question
2006-07-21 9:28 ` reserved pages and zero pages question pulsar
@ 2006-07-21 10:28 ` Thiemo Seufer
0 siblings, 0 replies; 4+ messages in thread
From: Thiemo Seufer @ 2006-07-21 10:28 UTC (permalink / raw)
To: pulsar; +Cc: linux-mips
pulsar@kpsws.com wrote:
> Hi,
>
> In my kernel startup I see the memory usage printed as:
>
> Memory: 125312k/131072k available (1977k kernel code, 5648k reserved, 287k
> data, 1664k init, 0k highmem)
>
> I wonder where the reserved pages are used for and how we can minimize it
> for small memory systems.
Most of that is the ramdisk you included. :-) It normally given back
once the ramdisk is decompressed.
> In my search I see that in arcm/mips/mm/init.c there are zero-pages
> allocated and put to reserved.
>
> Where are the zero pages used for and can we do without ?
They provide a clean zeroed page which gets mapped read-only (probably
for copy-on-write). You can't do without.
Thiemo
^ permalink raw reply [flat|nested] 4+ messages in thread
end of thread, other threads:[~2006-07-21 11:15 UTC | newest]
Thread overview: 4+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2006-07-20 16:52 [PATCH] Honour "panic_on_oops" sysctl on mips arch Maxime Bizon
2006-07-20 19:18 ` Ralf Baechle
2006-07-21 9:28 ` reserved pages and zero pages question pulsar
2006-07-21 10:28 ` Thiemo Seufer
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.