All of lore.kernel.org
 help / color / mirror / Atom feed
From: hschauhan@nulltrace.org (Chauhan, Himanshu)
To: kernelnewbies@lists.kernelnewbies.org
Subject: how does linux restores a thread's stack pointer, program counter and return address.
Date: Tue, 4 Oct 2011 18:20:43 +0530	[thread overview]
Message-ID: <CAOkDQ3UomC4ag9afSQRsqQz0VrvJUqJDwHUP3DcPAEFOFR61Rg@mail.gmail.com> (raw)
In-Reply-To: <D69C90565D53114396BF743585AF5A0912AD48277E@VSHINMSMBX01.vshodc.lntinfotech.com>

Hi Smital,

> I am keen to find out how does linux restores a thread's stack pointer, program counter and return address.

Isn't it that each thread has a different task_struct and at schedule
r29 is reloaded from its own independent task_struct?
Also, while scheduling pc and r31 are stored at the independent stack?

Anyways, I think if you ask this question at Linux MIPS mailing list,
people might shed more light on it.

-Himanshu

  reply	other threads:[~2011-10-04 12:50 UTC|newest]

Thread overview: 3+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2011-10-04  4:20 how does linux restores a thread's stack pointer, program counter and return address Smital Desai
2011-10-04 12:50 ` Chauhan, Himanshu [this message]
2011-10-04 18:33 ` Dave Hylands

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=CAOkDQ3UomC4ag9afSQRsqQz0VrvJUqJDwHUP3DcPAEFOFR61Rg@mail.gmail.com \
    --to=hschauhan@nulltrace.org \
    --cc=kernelnewbies@lists.kernelnewbies.org \
    /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 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.