All of lore.kernel.org
 help / color / mirror / Atom feed
* [PATCH 21/23] Make register values available to UM panic notifiers
@ 2010-04-12  6:04 David VomLehn
  0 siblings, 0 replies; 3+ messages in thread
From: David VomLehn @ 2010-04-12  6:04 UTC (permalink / raw)
  To: to, linux_arch, linux_arch; +Cc: akpm, linux-kernel, maint_arch

Changes for User Mode Linux. Not clear whether this needs save_ptregs()
or not.

Signed-off-by: David VomLehn <dvomlehn@cisco.com>
---
 arch/um/kernel/trap.c |    9 +++++----
 1 files changed, 5 insertions(+), 4 deletions(-)

diff --git a/arch/um/kernel/trap.c b/arch/um/kernel/trap.c
index 637c650..c917f26 100644
--- a/arch/um/kernel/trap.c
+++ b/arch/um/kernel/trap.c
@@ -168,7 +168,7 @@ unsigned long segv(struct faultinfo fi, unsigned long ip, int is_user,
 	}
 	else if (current->mm == NULL) {
 		show_regs(container_of(regs, struct pt_regs, regs));
-		panic("Segfault with no mm");
+		panic_with_regs(regs, "Segfault with no mm");
 	}
 
 	if (SEGV_IS_FIXABLE(&fi) || SEGV_MAYBE_FIXABLE(&fi))
@@ -192,13 +192,14 @@ unsigned long segv(struct faultinfo fi, unsigned long ip, int is_user,
 		UML_LONGJMP(catcher, 1);
 	}
 	else if (current->thread.fault_addr != NULL)
-		panic("fault_addr set but no fault catcher");
+		panic_with_regs(regs, "fault_addr set but no fault catcher");
 	else if (!is_user && arch_fixup(ip, regs))
 		return 0;
 
 	if (!is_user) {
 		show_regs(container_of(regs, struct pt_regs, regs));
-		panic("Kernel mode fault at addr 0x%lx, ip 0x%lx",
+		panic_with_regs(regs,
+			"Kernel mode fault at addr 0x%lx, ip 0x%lx",
 		      address, ip);
 	}
 
@@ -225,7 +226,7 @@ void relay_signal(int sig, struct uml_pt_regs *regs)
 		if (sig == SIGBUS)
 			printk(KERN_ERR "Bus error - the host /dev/shm or /tmp "
 			       "mount likely just ran out of space\n");
-		panic("Kernel mode signal %d", sig);
+		panic_with_regs(regs, "Kernel mode signal %d", sig);
 	}
 
 	arch_examine_signal(sig, regs);

^ permalink raw reply related	[flat|nested] 3+ messages in thread

* [PATCH 21/23] Make register values available to UM panic notifiers
@ 2010-04-12  6:07 ` David VomLehn
  0 siblings, 0 replies; 3+ messages in thread
From: David VomLehn @ 2010-04-12  6:07 UTC (permalink / raw)
  To: to, linux-arch@vger.kernel.org, linux-arch; +Cc: akpm, linux-kernel, maint_arch

Changes for User Mode Linux. Not clear whether this needs save_ptregs()
or not.

Signed-off-by: David VomLehn <dvomlehn@cisco.com>
---
 arch/um/kernel/trap.c |    9 +++++----
 1 files changed, 5 insertions(+), 4 deletions(-)

diff --git a/arch/um/kernel/trap.c b/arch/um/kernel/trap.c
index 637c650..c917f26 100644
--- a/arch/um/kernel/trap.c
+++ b/arch/um/kernel/trap.c
@@ -168,7 +168,7 @@ unsigned long segv(struct faultinfo fi, unsigned long ip, int is_user,
 	}
 	else if (current->mm == NULL) {
 		show_regs(container_of(regs, struct pt_regs, regs));
-		panic("Segfault with no mm");
+		panic_with_regs(regs, "Segfault with no mm");
 	}
 
 	if (SEGV_IS_FIXABLE(&fi) || SEGV_MAYBE_FIXABLE(&fi))
@@ -192,13 +192,14 @@ unsigned long segv(struct faultinfo fi, unsigned long ip, int is_user,
 		UML_LONGJMP(catcher, 1);
 	}
 	else if (current->thread.fault_addr != NULL)
-		panic("fault_addr set but no fault catcher");
+		panic_with_regs(regs, "fault_addr set but no fault catcher");
 	else if (!is_user && arch_fixup(ip, regs))
 		return 0;
 
 	if (!is_user) {
 		show_regs(container_of(regs, struct pt_regs, regs));
-		panic("Kernel mode fault at addr 0x%lx, ip 0x%lx",
+		panic_with_regs(regs,
+			"Kernel mode fault at addr 0x%lx, ip 0x%lx",
 		      address, ip);
 	}
 
@@ -225,7 +226,7 @@ void relay_signal(int sig, struct uml_pt_regs *regs)
 		if (sig == SIGBUS)
 			printk(KERN_ERR "Bus error - the host /dev/shm or /tmp "
 			       "mount likely just ran out of space\n");
-		panic("Kernel mode signal %d", sig);
+		panic_with_regs(regs, "Kernel mode signal %d", sig);
 	}
 
 	arch_examine_signal(sig, regs);

^ permalink raw reply related	[flat|nested] 3+ messages in thread

* [PATCH 21/23] Make register values available to UM panic notifiers
@ 2010-04-12  6:07 ` David VomLehn
  0 siblings, 0 replies; 3+ messages in thread
From: David VomLehn @ 2010-04-12  6:07 UTC (permalink / raw)
  To: to, linux-arch@vger.kernel.org; +Cc: akpm, linux-kernel, maint_arch

Changes for User Mode Linux. Not clear whether this needs save_ptregs()
or not.

Signed-off-by: David VomLehn <dvomlehn@cisco.com>
---
 arch/um/kernel/trap.c |    9 +++++----
 1 files changed, 5 insertions(+), 4 deletions(-)

diff --git a/arch/um/kernel/trap.c b/arch/um/kernel/trap.c
index 637c650..c917f26 100644
--- a/arch/um/kernel/trap.c
+++ b/arch/um/kernel/trap.c
@@ -168,7 +168,7 @@ unsigned long segv(struct faultinfo fi, unsigned long ip, int is_user,
 	}
 	else if (current->mm == NULL) {
 		show_regs(container_of(regs, struct pt_regs, regs));
-		panic("Segfault with no mm");
+		panic_with_regs(regs, "Segfault with no mm");
 	}
 
 	if (SEGV_IS_FIXABLE(&fi) || SEGV_MAYBE_FIXABLE(&fi))
@@ -192,13 +192,14 @@ unsigned long segv(struct faultinfo fi, unsigned long ip, int is_user,
 		UML_LONGJMP(catcher, 1);
 	}
 	else if (current->thread.fault_addr != NULL)
-		panic("fault_addr set but no fault catcher");
+		panic_with_regs(regs, "fault_addr set but no fault catcher");
 	else if (!is_user && arch_fixup(ip, regs))
 		return 0;
 
 	if (!is_user) {
 		show_regs(container_of(regs, struct pt_regs, regs));
-		panic("Kernel mode fault at addr 0x%lx, ip 0x%lx",
+		panic_with_regs(regs,
+			"Kernel mode fault at addr 0x%lx, ip 0x%lx",
 		      address, ip);
 	}
 
@@ -225,7 +226,7 @@ void relay_signal(int sig, struct uml_pt_regs *regs)
 		if (sig == SIGBUS)
 			printk(KERN_ERR "Bus error - the host /dev/shm or /tmp "
 			       "mount likely just ran out of space\n");
-		panic("Kernel mode signal %d", sig);
+		panic_with_regs(regs, "Kernel mode signal %d", sig);
 	}
 
 	arch_examine_signal(sig, regs);

^ permalink raw reply related	[flat|nested] 3+ messages in thread

end of thread, other threads:[~2010-04-12  6:08 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2010-04-12  6:04 [PATCH 21/23] Make register values available to UM panic notifiers David VomLehn
2010-04-12  6:07 David VomLehn
2010-04-12  6:07 ` David VomLehn

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.