26.02.2014 Views

Getting Started with QNX Neutrino - QNX Software Systems

Getting Started with QNX Neutrino - QNX Software Systems

Getting Started with QNX Neutrino - QNX Software Systems

SHOW MORE
SHOW LESS

Create successful ePaper yourself

Turn your PDF publications into a flip-book with our unique Google optimized e-Paper software.

© 2009, <strong>QNX</strong> <strong>Software</strong> <strong>Systems</strong> GmbH & Co. KG.<br />

blocking<br />

A means for threads to synchronize to other threads or events. In the blocking state (of<br />

which there are about a dozen), a thread doesn’t consume any CPU — it’s waiting on a<br />

list maintained <strong>with</strong>in the kernel. When the event occurs that the thread was waiting<br />

for, the thread is unblocked and is able to consume CPU again.<br />

channel<br />

An abstract object on which a server receives a message. This is the same object to<br />

which a client creates a connection in order to send a message to the server. When<br />

the channel is created via ChannelCreate(), a “channel ID” is returned. This channel<br />

ID (or “chid” for short) is what a resource manager will advertise as part of its<br />

registered mountpoint.<br />

client<br />

<strong>Neutrino</strong>’s message-passing architecture is structured around a client/server<br />

relationship. In the case of the client, it’s the one that is requesting services of a<br />

particular server. The client generally accesses these services using standard<br />

file-descriptor-based function calls (e.g., lseek()), which are synchronous, in that the<br />

client’s call doesn’t return until the request is completed by the server. A thread can<br />

be both a client and a server at the same time.<br />

condition variable<br />

A synchronization object used between multiple threads, characterized by acting as a<br />

rendezvous point where multiple threads can block, waiting for a signal (not to be<br />

confused <strong>with</strong> a UNIX-style signal). When the signal is delivered, one or more of the<br />

threads will unblock.<br />

connection<br />

The concept of a client being attached to a channel. A connection is established by<br />

the client either directly by calling ConnectAttach() or on behalf of the client by the<br />

client’s C library function open(). In either case, the connection ID returned is usable<br />

as a handle for all communications between the client and the server.<br />

connection ID<br />

A “handle” returned by ConnectAttach() (on the client side) and used for all<br />

communications between the client and the server. The connection ID is identical to<br />

the traditional C library’s “file descriptor.” That is to say, when open() returns a file<br />

descriptor, it’s really returning a connection ID.<br />

deadlock<br />

A failure condition reached when two threads are mutually blocked on each other,<br />

<strong>with</strong> each thread waiting for the other to respond. This condition can be generated<br />

quite easily; simply have two threads send each other a message — at this point, both<br />

threads are waiting for the other thread to reply to the request. Since each thread is<br />

blocked, it will not have a chance to reply, hence deadlock. To avoid deadlock, clients<br />

328 Glossary April 30, 2009

Hooray! Your file is uploaded and ready to be published.

Saved successfully!

Ooh no, something went wrong!