The Process/Kernel Model

  • A program usually executes in user mode and switches to kernel when requesting kernel services using system calls.
  • Kernel creates, eliminates, and syncs processes.  It is a process MANAGER not a process itself.
  • Kernel Threads: Run in kernel address space, do not interact with users, created during startup

Example of execution flow on a uniprocessor system

  • System call by user program runs something in kernel mode
  • Scheduler interrupts process 1 because it ran too long and allows process 2 to run
  • An interrupt was received by the system (eg. keyboard press) and processes tat before returning to process 2

 

Ways to activate kernel routines

  • System calls invoked by user programs
  • CPU raises an exception (error)
  • Interrupt by something like an I/O device (processed by interrupt handler)
  • Kernel threads

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s