Looking for breakthrough ideas for innovation challenges? Try Patsnap Eureka!

Inner core debug method of Linux operating system

A debugging method and operating system technology, applied in software testing/debugging and other directions, can solve problems affecting the speed of Linux kernel debugging and development, and achieve the effect of improving development and debugging efficiency and shortening development and debugging time.

Inactive Publication Date: 2008-10-08
上海宇梦通信科技有限公司
View PDF0 Cites 35 Cited by
  • Summary
  • Abstract
  • Description
  • Claims
  • Application Information

AI Technical Summary

Problems solved by technology

However, when debugging, it is hoped that the kernel information output is different each time. If the method of modifying the kernel and adding new print statements is used, it must go through a very time-consuming process of recompiling, linking, and downloading the Linux kernel every time, which affects the debugging of the Linux kernel. and the speed of development

Method used

the structure of the environmentally friendly knitted fabric provided by the present invention; figure 2 Flow chart of the yarn wrapping machine for environmentally friendly knitted fabrics and storage devices; image 3 Is the parameter map of the yarn covering machine
View more

Image

Smart Image Click on the blue labels to locate them in the text.
Viewing Examples
Smart Image
  • Inner core debug method of Linux operating system
  • Inner core debug method of Linux operating system
  • Inner core debug method of Linux operating system

Examples

Experimental program
Comparison scheme
Effect test

Embodiment Construction

[0012] The kernel debugging method of the Linux operating system of the present invention depends on two premises, the module mechanism of Linux and the certainty of the symbol address of the Linux kernel.

[0013] The Linux operating system provides a brand new mechanism called an installable module (loadab-le module). Using this mechanism, the installable module can be dynamically inserted into the running kernel and become an organic part of the kernel without recompiling and linking the kernel as needed; or the installed module can be removed from the kernel. It is this mechanism that keeps the memory image of the kernel to a minimum, yet has great flexibility and scalability.

[0014] The determinism of the address of the Linux kernel symbol, that is, in the Linux kernel, the loading address of the kernel symbol has been determined after compilation. The loading address of the Linux kernel symbol can be obtained from the kernel symbol table generated during the Linux ker...

the structure of the environmentally friendly knitted fabric provided by the present invention; figure 2 Flow chart of the yarn wrapping machine for environmentally friendly knitted fabrics and storage devices; image 3 Is the parameter map of the yarn covering machine
Login to View More

PUM

No PUM Login to View More

Abstract

The invention discloses a debugging method for kernel of a Linux operating system, which comprises the following steps: a kernel part needed to be modified or debugged is compiled to a temporary kernel by means of kernel module; the temporary kernel is loaded to the user space of the kernel by using a kernel loading tool, a function jump table is disposed on the entrance of replaced original kernel functions, the calls of original kernel functions are intercepted, when an original kernel functions is called, a replacing function of the temporary kernel is automatically jumped to; the temporary kernel is debugged; when the debug is finished, the temporary kernel is unloaded from the modified kernel by a kernel unloading tool, and the original state of the kernel is restored. The kernel compiling process is only limited to specific related functions, the kernel needs not to be started again, recompiling and relink, loading time and kernel start time in kernel debugging process are avoided; the developing and debugging time of an operating system is shorted, the developing and debugging efficiency is improved.

Description

technical field [0001] The invention relates to a computer software debugging method, in particular to a kernel debugging method suitable for Linux operating systems under various hardware platforms. Background technique [0002] At present, there is no good kernel debugging mechanism on the Linux operating system. Since the kernel-specific debugging tool kgdb often does not work properly, the most commonly used method for debugging the kernel is to add printk (the printing function in the kernel) to the kernel source code, and to check the operation of Linux by obtaining and analyzing the print information. The health of the system kernel. However, when debugging, it is hoped that the kernel information output is different each time. If the method of modifying the kernel and adding new print statements is used, it must go through a very time-consuming process of recompiling, linking, and downloading the Linux kernel every time, which affects the debugging of the Linux kern...

Claims

the structure of the environmentally friendly knitted fabric provided by the present invention; figure 2 Flow chart of the yarn wrapping machine for environmentally friendly knitted fabrics and storage devices; image 3 Is the parameter map of the yarn covering machine
Login to View More

Application Information

Patent Timeline
no application Login to View More
Patent Type & Authority Applications(China)
IPC IPC(8): G06F11/36
Inventor 刘通平韩涛
Owner 上海宇梦通信科技有限公司
Who we serve
  • R&D Engineer
  • R&D Manager
  • IP Professional
Why Patsnap Eureka
  • Industry Leading Data Capabilities
  • Powerful AI technology
  • Patent DNA Extraction
Social media
Patsnap Eureka Blog
Learn More
PatSnap group products