Linux MIPS Architecture development
 help / color / mirror / Atom feed
From: Justin Carlson <justin@cs.cmu.edu>
To: linux-mips@oss.sgi.com
Subject: reenabling interrupts on return from function
Date: 15 Jun 2002 14:49:01 -0700	[thread overview]
Message-ID: <1024177741.1549.4.camel@localhost.localdomain> (raw)

I'm obviously missing something basic here.

Looking at stackframe.h, I see this code as a part of RESTORE_SOME


		mfc0	t0, CP0_STATUS;                  \
		.set	pop;                             \
		ori	t0, 0x1f;                        \
		xori	t0, 0x1f;                        \
		mtc0	t0, CP0_STATUS;                  

Here, we're explicitly clearing the IE bit (among others) in the status
register, and we leave it cleared.  The status register is not touched
again until we do an eret.

First, why do we explicitly clear the IE bit, when we're running with
the EXL bit set?  And where is the black magic that is re-enabling
interrupts for the return to usermode?

I must be missing something really fundamental here.  Anyone care to
point out my obvious gaps of knowledge?  :) 

Thanks,
  Justin

             reply	other threads:[~2002-06-15 21:46 UTC|newest]

Thread overview: 3+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2002-06-15 21:49 Justin Carlson [this message]
2002-06-15 22:22 ` reenabling interrupts on return from function Justin Carlson
2002-06-19 15:16   ` Maciej W. Rozycki

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=1024177741.1549.4.camel@localhost.localdomain \
    --to=justin@cs.cmu.edu \
    --cc=linux-mips@oss.sgi.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