From: Srikar Dronamraju <srikar@linux.vnet.ibm.com>
To: john mathew <john.mathew@unikie.com>
Cc: linux-doc@vger.kernel.org, linux-kernel@vger.kernel.org,
corbet@lwn.net, mingo@redhat.com, peterz@infradead.org,
juri.lelli@redhat.com, vincent.guittot@linaro.org,
dietmar.eggemann@arm.com, rostedt@goodmis.org,
bsegall@google.com, mgorman@suse.de, bristot@redhat.com,
tsbogend@alpha.franken.de, lukas.bulwahn@gmail.com,
x86@kernel.org, linux-mips@vger.kernel.org, tglx@linutronix.de,
mostafa.chamanara@gmail.com, willy@infradead.org,
valentin.schneider@arm.com, rdunlap@infradead.org,
Mostafa Chamanara <mostafa.chamanara@basemark.com>,
Oleg Tsymbal <oleg.tsymbal@unikie.com>
Subject: Re: [RFC PATCH v5 3/3] docs: scheduler: Add introduction to scheduler context-switch
Date: Tue, 26 May 2020 15:55:11 +0530 [thread overview]
Message-ID: <20200526102511.GA5681@linux.vnet.ibm.com> (raw)
In-Reply-To: <20200514092637.15684-4-John.Mathew@unikie.com>
* john mathew <john.mathew@unikie.com> [2020-05-14 12:26:37]:
> +
> +Context Switching
> +-----------------
> +
> +Context switching, the switching from a running task to another,
> +is done by the context_switch() function defined in kernel/sched.c.
context_switch is defined in kernel/sched/core.c
> +It is called by __schedule() when a new process has been selected to run.
> +The execution flow is as follows:
> +
> +
> + For a kernel task switching to a user task, switch_mm_irqs_off()
> + replaces the address space of prev kernel task with the next from the user
> + task. Same as for exiting process in this case, the context_switch()
Did you mean existing instead of exiting?
> + function saves the pointer to the memory descriptor used by prev in the
> + runqueue???s prev_mm field and resets prev task active address space.
> +
--
Thanks and Regards
Srikar Dronamraju
next prev parent reply other threads:[~2020-05-26 10:27 UTC|newest]
Thread overview: 14+ messages / expand[flat|nested] mbox.gz Atom feed top
2020-05-14 9:26 [RFC PATCH v5 0/3] Add scheduler overview documentation john mathew
2020-05-14 9:26 ` [RFC PATCH v5 1/3] docs: scheduler: Restructure scheduler documentation john mathew
2020-05-14 9:26 ` [RFC PATCH v5 2/3] docs: scheduler: Add scheduler overview documentation john mathew
2020-05-29 11:00 ` Peter Zijlstra
2020-05-29 14:10 ` Jonathan Corbet
2020-06-05 9:40 ` John Mathew
2020-06-23 7:17 ` John Mathew
2020-05-29 14:48 ` Vincent Guittot
2020-06-05 9:42 ` John Mathew
2020-05-14 9:26 ` [RFC PATCH v5 3/3] docs: scheduler: Add introduction to scheduler context-switch john mathew
2020-05-26 10:25 ` Srikar Dronamraju [this message]
2020-05-27 8:17 ` John Mathew
2020-05-25 16:35 ` [RFC PATCH v5 0/3] Add scheduler overview documentation Jonathan Corbet
2020-05-29 3:39 ` John Mathew
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=20200526102511.GA5681@linux.vnet.ibm.com \
--to=srikar@linux.vnet.ibm.com \
--cc=bristot@redhat.com \
--cc=bsegall@google.com \
--cc=corbet@lwn.net \
--cc=dietmar.eggemann@arm.com \
--cc=john.mathew@unikie.com \
--cc=juri.lelli@redhat.com \
--cc=linux-doc@vger.kernel.org \
--cc=linux-kernel@vger.kernel.org \
--cc=linux-mips@vger.kernel.org \
--cc=lukas.bulwahn@gmail.com \
--cc=mgorman@suse.de \
--cc=mingo@redhat.com \
--cc=mostafa.chamanara@basemark.com \
--cc=mostafa.chamanara@gmail.com \
--cc=oleg.tsymbal@unikie.com \
--cc=peterz@infradead.org \
--cc=rdunlap@infradead.org \
--cc=rostedt@goodmis.org \
--cc=tglx@linutronix.de \
--cc=tsbogend@alpha.franken.de \
--cc=valentin.schneider@arm.com \
--cc=vincent.guittot@linaro.org \
--cc=willy@infradead.org \
--cc=x86@kernel.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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).