Design and Implementation of KTH -based embedded linux kernel thread library
- Author
- XieWei
- Advisor
- WangZhongRen
- School
- University of Electronic Science and Technology
- Major
- Applied Computer Technology
- Classification
- TP316.81
- Degree
- Master's thesis
- Year
- 2005
- Downloads
- 155
- Citations
- 0
Abstract
As an excellent free operating system, Linux has its own strength. Many foreign telecommunication equipment manufacturers have paid close attention to Linux and developed telecommunication equipments and smart mobile phones based on the embedded Linux.After this long time development, Linux has enough qualifications to be applied to the large-scale telecommunication equipments.Now, the R&D of embedded Linux has important significance to lower the cost and improve the security level of products. This paper analyzed the basic concepts of embedded systems and systematically introduced the characteristics of Linux as embedded operating system, such as real-time, network and GUI support etc. With research of the kernel mechanism of embedded Linux, we found the transition between user mode and kernel mode involved in system calls would increase the system cost and affect the system performance. Based upon this discovery, this paper proposed the KTH library in the Linux kernel mode to enable applications to run in kernel mode.It also explained the function and performance that the kernel thread library should achieve, as well as the system structure of KTH.Then, this paper introduced and analyzed the design and implementation of the KTH modules finished by me, which include the main data structure, algorithm and function flowchart. In the end, we tested the performance of KTH with two benchmarks which are thread processing speed and semaphore processing speed.
Table of contents
Abstract 4-5
Abstract 5-9
first chapter 9-11
1.1 subject background <br / > 1.2 degree completed during papers chapters 9-10
1.3 10-11
Chapter II Embedded Systems Overview 11-16 < br /> 2.1 embedded systems defined 11
2.2 embedded system development process 11-12
2.3 characteristics of embedded systems 12-13 < br /> 2.4 embedded system applications 13-14
2.5 embedded systems development trend 14-16
Chapter embedded linux system Overview 16-21
3.1 Linux history and current status 16
3.2 linux used as an embedded operating system 16-20
3.2.1 embedded processor support 16
3.2.2 Real-time support 16-17
3.2.3 network support the 17-18 3.2.4 the GUI development support
18-19
3.2.5 use of low cost 19-20
3.2.6 Documentation perfect 20
3.3 Summary 20-21
Chapter the KTH system design the 21-26 4.1 requirements analysis
21-22
4.1.1 functional requirements 21
4.1. 2 performance requirements 21-22
4.1.3 Properties demand
4.2 architecture the the 4.2.1 thread management sub-module nbsp 22-26
; 22-23
the the 4.2.3 object management sub-module 23
4.2.4 semaphore management sub-module 4.2.5 Memory Management sub-module 23
to the 23-24
the 4.2.6 log management sub-module 24
of 4.2.7 the Shell sub-module 24-26
Chapter KTH module Design and Implementation 26-59
5.1 the KTH library of initialization 26
5.2 thread management sub-module 26-37
5.2.1 ideological the 5.2.2 thread management initialization nbsp 26-27
; 27-28
5.2.3 main thread processing 28-29
5.2. 4 threads created the 29-31 thread abort
5.2.5 the 31-32
5.2.6 thread hangs 32-33
5.2.7 the thread wake 33
5.2.8 waiting for the end of the specified thread 33-34
the 5.2.9 thread scheduling parameters set and get 34-35 <br / > 5.2.10 thread local storage settings and get the 35-36
the 5.2.11 thread-delay 36
5.2.12 thread management exit 36-37 the
the 5.3 object management sub-module the 37-39 the 5.3.1 main idea
37-39
5.3.2 object application 39
the 5.3.3 object release 39
5.3.4 object traversal the 5.4 semaphore management sub-module of 39
39-48
5.4.1 The main idea the 5.4.2 B semaphore 39-40
the 5.4.3 C semaphore 40-41
41-42
5.4.4 priority the inheritance protocol PIP 42-47
5.4.5 M signal. 47-48
5.5 memory management sub-module nbsp the; 48-53
5.5.1 The structure of the memory management 48-49
the 5.5.2 memory module initialization 49
5.5.3 memory allocation 49-52
5.5. 4 memory release 52-53
5.5.5 memory recovery 53
5.5.6 memory allocation 53
5.6 log management sub-module 53-55
5.6.1 thinking the 53-54 log information generated
5.6.2 54-55
5.6.3 log information filter 55
5.6.4 log processing 55
5.7 Shell sub-module 55-58
5.7.1 Shell process flow 55-58
5.8 KTH library exit the 58-59
sixth chapter. the KTH's test 59-68
6.1 test content 59
6.2 test environment nbsp 59-60
6.3 test method; the test 60-67
6.3.1 thread creation and deletion 60
6.3.2 The end of the waiting thread test 60
6.3.3 thread is forced to end 60-61
6.3.4 thread suspend and wake 61 <br / > 6.3.5 to dynamically change the the KTH threads priority the 61-62
6.3.6 Get KTH thread scheduling parameters 62
6.3.7 to kill all KTH threads of 62-63
6.3.8 delay the current thread 63
6.3.9 semaphore operation test 63-64
6.3.10 thread switching the time 64
6.3.11 test to create and delete threads of time the hang thread (SUSPEND) time of 64
6.3.12 test 64-
6.3.13 testing time to resume running thread (RESUME) 64-65
6.3.14 test time create the semaphore 65-
6.3.15 test delete semaphore time 65
6.3.16 test for semaphore (semaphore can be used) 65
6.3.17 The test time for semaphore (semaphore is unavailable) 65
6.3.18 test release time of the semaphore (semaphore wait queue is not empty) 65
6.3.19 The test release semaphore (semaphore wait queue is empty) 65
6.3.20 for a long time to create the ultimate one thread and then delete the 65-66
6.3.21 for a long time to create the limit a semaphore and then delete 66
6.3.22 long test run limit threads to prevent priority inversion performance 66-67
6.4 test results recorded 67-68
Chapter VII Conclusion 68-69
Reference the 69-71
Acknowledgements 71-72
biographical 72
Related dissertations
- Research and Realization of Video Surveillance and Play Based on ARM9Hardware Platform
- The Study of Remote Video Monitor System Baced on ARM
- Design and Implementation of Intelligent Video Surveillance System Based on Embedded Linux
- Video Surveillance System Based on Embedded Technology Research
- Design of Video Monitoring System Based on the Embedded
- The Design of Embedded Network Video Surveillance System Based on ARM9
- Research and implementation of remote monitor system of ship based on the technology of the Internet of things
- Design of Video Surveillance Software Based on Ti Dm6446Processor
- Data Acquisition System of Cavern Based on Embedded Web Server
- Research and Realization of Embedded Data Acquisition and Recording System for Industrial Process Based on ARM
- Research on the Indoor Air Monitoring System Based on Embedded Linux
- Research and Realization on the Key Technology of Monitoring System about Granary Environment Based on ARM9
- Automatic Switcher Based on Embedded System Design and Implementation of Test Platform
- Research on Meteorological Data Acquisition and Processing System
- The Research of the Design and Application for Embedded Remote Terminal Unit
- Design and Implementation of Magnetic Card Detection System Based on Embedded System
- Design of distributed control system based on embedded platform
- Design and Implementation of Car Embedded Systems to Multimedia Intelligent Terminal
- The Research of CANopen Protocol Based on Embedded Systems
- The Research and Design of Smart Home System Based on Zigbee Technology