RTOS, Embedded Linux, Real-Time Operating System and DO-178B: LynuxWorks

Processes and Parent-Child Relationships
The fork() call

THREADS IN POSIX

To find out if an operating system might support the POSIX®.1 specification, ask "Does it support the fork() call?"

Fork() calls are scattered throughout Unix®/Linux® code. To support fork(), an operating system must first support the concept of parent-child relationships between processes. If fork() and other common POSIX.1 calls are not supported, the vast majority of your Unix/Linux code will not port to that operating system without major rewrites.

Understanding fork()

The fork() system call creates a new process called a child. The original process is called the parent, and the child is a near-exact copy of the parent. The child's run time is set to zero and file locks are not inherited.

The child has its own process ID and its own copy of the parent's file descriptors.

A parent process can recover the exit status of a child using the wait() or waitpid() function.


"But is it POSIX-conformant?"
LynuxWorksPOSIX for
embedded developers
O'REILLY PROGRAMMING GUIDES
for LynuxWorks operating systems

THREADS IN POSIX


RTOS and embedded operating systems

Embedded operating systems and development tools

Corporate

Industry solutions

OS Support

OS Training

SynergyWorks: LynuxWorks partners

contact us
ISO9001:2000 Copyright © LynuxWorks™, Inc. All rights reserved. Reproduction in whole or in part in any form or medium without express written permission of LynuxWorks is prohibited. 20 years of embedded excellence