基本信息
源码名称:QNX® Neutrino® RTOS System Architecture
源码大小:2.19M
文件格式:.pdf
开发语言:C/C++
更新时间:2021-08-12
   友情提示:(无需注册或充值,赞助后即可获取资源下载链接)

     嘿,亲!知识可是无价之宝呢,但咱这精心整理的资料也耗费了不少心血呀。小小地破费一下,绝对物超所值哦!如有下载和支付问题,请联系我们QQ(微信同号):813200300

本次赞助数额为: 1 元 
   源码介绍



Contents
About This Guide..................................................................................................................................9
Typographical conventions........................................................................................................10
Technical support.....................................................................................................................12
Chapter 1: The Philosophy of the QNX Neutrino RTOS............................................................................13
An embeddable POSIX OS?.......................................................................................................14
Product scaling........................................................................................................................15
Why POSIX for embedded systems?...........................................................................................16
Why QNX Neutrino for embedded systems?.................................................................................18
Microkernel architecture...........................................................................................................19
The OS as a team of processes.......................................................................................20
A true kernel.................................................................................................................21
System processes..........................................................................................................21
Interprocess communication.....................................................................................................23
QNX Neutrino as a message-passing operating system......................................................23
Network distribution of kernels..................................................................................................24
Single-computer model..................................................................................................24
Flexible networking.......................................................................................................24
Chapter 2: The QNX Neutrino Microkernel.............................................................................................27
The implementation of the QNX Neutrino RTOS..........................................................................28
POSIX realtime and thread extensions.............................................................................28
System services.......................................................................................................................29
Threads and processes..............................................................................................................31
Thread attributes...........................................................................................................33
Thread life cycle...........................................................................................................35
Thread scheduling....................................................................................................................38
Scheduling priority........................................................................................................38
Scheduling policies.......................................................................................................40
IPC issues....................................................................................................................44
Thread complexity issues...............................................................................................44
Synchronization services...........................................................................................................46
Mutexes: mutual exclusion locks.....................................................................................46
Condvars: condition variables.........................................................................................48
Barriers........................................................................................................................49
Sleepon locks...............................................................................................................51
Reader/writer locks........................................................................................................51
Semaphores..................................................................................................................52
Synchronization via scheduling policy.............................................................................52
Synchronization via message passing..............................................................................53
Synchronization via atomic operations.............................................................................53
Synchronization services implementation.........................................................................54
Clock and timer services...........................................................................................................55
QNX® Neutrino® RTOS
Time correction.............................................................................................................56
Timers..........................................................................................................................56
Interrupt handling....................................................................................................................59
Interrupt latency...........................................................................................................59
Scheduling latency........................................................................................................60
Nested interrupts..........................................................................................................60
Interrupt calls...............................................................................................................61
Chapter 3: Interprocess Communication (IPC)........................................................................................65
Synchronous message passing...................................................................................................66
Message copying......................................................................................................................68
Simple messages.....................................................................................................................71
Channels and connections........................................................................................................72
Pulses..........................................................................................................................73
Priority inheritance and messages...................................................................................73
Message-passing API................................................................................................................75
Robust implementations with Send/Receive/Reply.......................................................................76
Events....................................................................................................................................78
I/O notification..............................................................................................................78
Signals....................................................................................................................................80
Special signals..............................................................................................................81
Summary of signals.......................................................................................................83
POSIX message queues............................................................................................................85
Why use POSIX message queues?...................................................................................85
File-like interface..........................................................................................................85
Message-queue functions...............................................................................................86
Shared memory........................................................................................................................87
Shared memory with message passing.............................................................................87
Creating a shared-memory object....................................................................................88
mmap().....................................................................................................................89
Typed memory.........................................................................................................................92
Implementation-defined behavior....................................................................................92
Practical examples........................................................................................................96
Pipes and FIFOs......................................................................................................................98
Chapter 4: The Instrumented Microkernel..............................................................................................99
Instrumentation at a glance.....................................................................................................100
Event control.........................................................................................................................101
Modes of emission......................................................................................................101
Ring buffer.................................................................................................................102
Data interpretation.................................................................................................................103
System analysis with the IDE.......................................................................................103
Proactive tracing....................................................................................................................105
Chapter 5: Multicore Processing.........................................................................................................107
Asymmetric multiprocessing (AMP)..........................................................................................108
Contents
Symmetric multiprocessing (SMP)...........................................................................................109
Booting an x86 SMP system.........................................................................................109
How the SMP microkernel works...................................................................................110
Critical sections..........................................................................................................111
Bound multiprocessing (BMP).................................................................................................113
A viable migration strategy...........................................................................................114
Choosing between AMP, SMP, and BMP...................................................................................115
Chapter 6: Process Manager...............................................................................................................117
Process management..............................................................................................................118
Process primitives.......................................................................................................118
Process loading...........................................................................................................122
Memory management.............................................................................................................123
Memory Management Units (MMUs).............................................................................123
Memory protection at run time.....................................................................................124
Quality control............................................................................................................126
Full-protection model..................................................................................................126
Locking memory..........................................................................................................127
Pathname management..........................................................................................................129
Resolving pathnames...................................................................................................129
Symbolic prefixes........................................................................................................133
File descriptor namespace...........................................................................................136
Chapter 7: Dynamic Linking...............................................................................................................139
Statically linked.....................................................................................................................140
Dynamically linked.................................................................................................................141
Augmenting code at runtime...................................................................................................142
How shared objects are used...................................................................................................143
Memory layout for a typical process..............................................................................144
Runtime linker............................................................................................................144
Loading a shared library at runtime...............................................................................145
Symbol name resolution...............................................................................................145
Chapter 8: Resource Managers...........................................................................................................147
What is a resource manager?...................................................................................................148
Why write a resource manager?.....................................................................................148
The types of resource managers....................................................................................149
Communication via native IPC......................................................................................150
Resource manager architecture...............................................................................................152
Message types............................................................................................................152
The resource manager shared library.............................................................................153
Summary..............................................................................................................................158
Chapter 9: Filesystems......................................................................................................................159
Filesystems and pathname resolution.......................................................................................160
Filesystem classes..................................................................................................................161
QNX® Neutrino® RTOS
Filesystems as shared libraries.....................................................................................161
io-blk....................................................................................................................162
Filesystem limitations..................................................................................................165
Image filesystem....................................................................................................................166
RAM “filesystem”..................................................................................................................167
Embedded transaction filesystem (ETFS)..................................................................................168
Power-Safe filesystem.............................................................................................................172
Problems with existing disk filesystems.........................................................................172
Copy-on-write filesystem..............................................................................................172
Performance...............................................................................................................174
Encryption..................................................................................................................175
DOS Filesystem.....................................................................................................................180
FFS3 filesystem.....................................................................................................................183
NFS filesystem......................................................................................................................187
CIFS filesystem......................................................................................................................188
Universal Disk Format (UDF) filesystem...................................................................................189
Apple Macintosh HFS and HFS Plus........................................................................................190
Windows NT filesystem...........................................................................................................191
Inflator pass-through filesystem...............................................................................................192
Merkle filesystem...................................................................................................................193
Filesystem events...................................................................................................................195
Chapter 10: PPS...............................................................................................................................197
Persistence............................................................................................................................198
PPS objects...........................................................................................................................199
Publishing.............................................................................................................................200
Subscribing...........................................................................................................................201
Chapter 11: Character I/O..................................................................................................................203
Driver/io-char communication............................................................................................204
Device control........................................................................................................................206
Input modes..........................................................................................................................207
Raw input mode..........................................................................................................207
Edited input mode......................................................................................................208
Device subsystem performance................................................................................................211
Console devices.....................................................................................................................212
Serial devices........................................................................................................................213
Pseudo terminal devices (ptys)................................................................................................214
Chapter 12: Networking Architecture..................................................................................................215
Network manager (io-pkt*).................................................................................................216
Threading model....................................................................................................................218
Protocol module.....................................................................................................................219
Driver module........................................................................................................................220
Chapter 13: Native Networking (Qnet).................................................................................................221
Contents
QNX Neutrino distributed........................................................................................................222
Name resolution and lookup....................................................................................................224
File descriptor (connection ID).....................................................................................224
Behind a simple open().............................................................................................225
Global Name Service (GNS).........................................................................................226
Network naming..........................................................................................................226
Redundant Qnet: Quality of Service (QoS) and multiple paths....................................................228
QoS policies...............................................................................................................228
Specifying QoS policies...............................................................................................230
Symbolic links............................................................................................................230
Examples..............................................................................................................................231
Chapter 14: TCP/IP Networking..........................................................................................................233
Structure of the TCP/IP manager.............................................................................................234
Socket API............................................................................................................................235
Database routines.......................................................................................................236
Multiple stacks......................................................................................................................238
IP filtering and NAT................................................................................................................239
NTP......................................................................................................................................240
Dynamic host configuration.....................................................................................................241
AutoIP.......................................................................................................................241
PPP over Ethernet..................................................................................................................242
/etc/autoconnect.........................................................................................................243
Chapter 15: High Availability.............................................................................................................245
An OS for HA.........................................................................................................................246
Inherent HA................................................................................................................246
HA-specific modules...................................................................................................246
Custom hardware support........................................................................................................247
Client library..........................................................................................................................248
Recovery example.......................................................................................................248
High Availability Manager........................................................................................................251
HAM and the Guardian................................................................................................251
HAM hierarchy............................................................................................................251
Publishing autonomously detected conditions................................................................254
Subscribing to autonomously published conditions.........................................................255
HAM as a “filesystem”.................................................................................................256
Multistage recovery.....................................................................................................256
HAM API....................................................................................................................256
Chapter 16: Adaptive Partitioning.......................................................................................................261
Why adaptive?.......................................................................................................................263
Benefits of adaptive partitioning..............................................................................................264
Engineering product performance.................................................................................264
Dealing with design complexity.....................................................................................264
Providing security........................................................................................................265
QNX® Neutrino® RTOS
Debugging..................................................................................................................266
Adaptive partitioning thread scheduler.....................................................................................267
Appendix A: Glossary.........................................................................................................................269
Index...............................................................................................................................................285