public inbox for linux-arch@vger.kernel.org
 help / color / mirror / Atom feed
From: Ralf Baechle <ralf@linux-mips.org>
To: Martin Schwidefsky <schwidefsky@de.ibm.com>
Cc: linux-arch@vger.kernel.org
Subject: Re: Unknown traps.
Date: Mon, 22 Nov 2004 15:29:21 +0100	[thread overview]
Message-ID: <20041122142921.GB3230@linux-mips.org> (raw)
In-Reply-To: <OFE35549E9.20C1C2B2-ON42256F50.00448A0C-42256F50.0049E9FE@de.ibm.com>

On Thu, Nov 18, 2004 at 03:27:20PM +0200, Martin Schwidefsky wrote:

> Hi,
> while working on a deficiency in the illegal operation handler for
> s390 (only emits a force_sig instead of a force_sig_info) I stumbled
> over something odd: How are unknown traps handled properly?
> 
> Of the architectures where I have some clue what they are doing:
> 
> i386: doesn't handle unknown traps (idt_table entries with {0,0})
> ia64: does a force_sig with SIGILL.
> parisc: does a force_sig_info with SIGBUS/BUS_OBJERR.
> ppc: doesn't handle unknown traps (?).
> s390: does a force_sig with SIGSEGV.
> sparc: does a force_sig_info with SIGILL/ILL_ILLTRP.
> x86_64: doesn't handle unknown traps (idt_table entries with {0,0})
> 
> What is correct? For s390 I'd like to do a force_sig_info of some
> kind, SIGBUS/BUS_OBJERR is a likely choice.

I'm reacting a bit harsher on MIPS:

asmlinkage void do_reserved(struct pt_regs *regs)
{
        /*
         * Game over - no way to handle this if it ever occurs.  Most probably
         * caused by a new unknown cpu type or after another deadly
         * hard/software error.
         */
        show_regs(regs);
        panic("Caught reserved exception %ld - should not happen.",
              (regs->cp0_cause & 0x7f) >> 2);
}

If this is happening it's a severe kernel or hardware problem and it's not
clear if continuing is safe or how to recover, so game over.

  Ralf

  reply	other threads:[~2004-11-22 14:29 UTC|newest]

Thread overview: 4+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2004-11-18 13:27 Unknown traps Martin Schwidefsky
2004-11-22 14:29 ` Ralf Baechle [this message]
2004-11-24 15:07   ` Martin Schwidefsky
2004-11-24 18:29     ` Ralf Baechle

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=20041122142921.GB3230@linux-mips.org \
    --to=ralf@linux-mips.org \
    --cc=linux-arch@vger.kernel.org \
    --cc=schwidefsky@de.ibm.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