2019-2020-1 20199327 "Linux kernel principle and Analysis" in the fourth week of work

MenuOS construction

The two swords operating system:

Interrupt context switching - Save site and site restoration;
process context switching;

The key directory

  1. arch: the architecture associated with the subdirectory list, store the relevant code CPU architecture;
  2. block: code stored on the storage system Linux block device management;
  3. crypto: C language code stored common encryption algorithm;
  4. Documentation: storage of documents;
  5. firmware: firmware;
  6. drivers: drive directory, categorized storage Linux kernel driver source code to support all hardware devices;
  7. fs: file system, file system, file systems listed to achieve a variety of Linux support;
  8. init: initial initialization means, storing initialization code of the Linux kernel boot time;
  9. include: the header file directory;
  10. ipc: Inter-process communication;
  11. kernel: the kernel, the core code is stored kernel itself needs;
  12. mm: memory management, memory management;
  13. net: network-related code;

experiment

Building Linux systems MenuOS;

Start MenuOS;

Breakpoints View

start_kernel;

rest_init;

to sum up

init_task (0 process) determines the overall system processes, threads gene, after creating init into the city, calling cpu_idle () evolved into the idle process, after performing a scheduling, init process runs. Part of the initialization kernel-init () kernel thread No. 1 is responsible for the implementation of kernel and system configuration, the last call do_execve init program loads, into the init process. kthreadd process created by the process number 0, always running in kernel space, is responsible for scheduling and management of all kernel threads.

Guess you like

Origin www.cnblogs.com/waxxx/p/11627712.html