Definitions in outpipe.h

Preprocessor macro definitions for the outpipe.h header file in the qvm library

Nomenclature

The figure below presents the composition of outpipe messages.

Figure 1. Message attributes

Four-byte attributes

The four-byte attributes are identified as follows:

Returnable code

Returnable code values can be used as the return code when terminating a process. Supported codes include:

“NoRes” indicates that a required resource is either not found or insufficient to complete the required task.

Labels

Label definitions are named as follows: QVM_OUTtype_source, where type is the message type, and source is the source of the message. For example, QVM_OUTN_QVM means that the qvm process has encountered a fatal internal error: N indicates that the error was iNternal, and _QVM indicates that the error was in the qvm process.

Note: Message types are not like verbosity levels, where each verbosity level outputs increasingly trivial messages. You must specify every type of message you want to output (see the discussion of the logger filter option in the QNX Hypervisor User's Guide “Configuration” chapter).

The labels identify the sources of the outputs as follows:

Definitions:

#include <qvm/outpipe.h>

Label in the four-byte attribute

#define QVM_OUTAL_OFFSET 24

Bit-offset of the label in the four-byte attribute

#define QVM_OUTAL_MASK (0xffu << QVM_OUTAL_OFFSET)

Mask to get the label

#define QVM_OUTAL_TRIM (((attr) & QVM_OUTAL_MASK) >> QVM_OUTAL_OFFSET)

Trim the irrelevant bits from the label

See Predefined labels below.

Return code in the four-byte attribute

#define QVM_OUTAC_OFFSET 16

Bit-offset of the return code in the four-byte attribute

#define QVM_OUTAC_MASK (0xffu << QVM_OUTAC_OFFSET)

Mask to get the return code

#define QVM_OUTAC_TRIM (((attr) & QVM_OUTAC_MASK) >> QVM_OUTAC_OFFSET)

Trim the irrelevant bits from the return code

#define QVM_OUTAC_SRC_MASK ((0xf0u << QVM_OUTAC_OFFSET) & QVM_OUTAC_MASK)

Mask the to get the source in the return code

#define QVM_OUTAC_INT_MASK ((0x80u << QVM_OUTAC_OFFSET) & QVM_OUTAC_SRC_MASK)

Mask to get the high four-bit internal return code (supplied by qvm)

#define QVM_OUTAC_EXT_MASK ((0x70u << QVM_OUTAC_OFFSET) & QVM_OUTAC_SRC_MASK)

Mask to get the high four-bit external return code (supplied by the configuration)

#define QVM_OUTAC_CODE_MASK ((0x0fu << QVM_OUTAC_OFFSET) & QVM_OUTAC_MASK)

Mask to get the return code

User-defined code in the four-byte attribute

#define QVM_OUTAU_OFFSET 0

Bit-offset of optional user-defined code

#define QVM_OUTAU_MASK ((0xffffu << QVM_OUTAU_OFFSET))

Mask to get the optional user-defined code

Predefined labels

#define QVM_OUTF_CNF (qvm_outattr(QVM_OUTAL_FATAL, QVM_OUTAC_XCONF, QVM_OUTAC_UNEXPECTED, 0))

Fatal error originating in the user-specified configuration

#define QVM_OUTE_CNF (qvm_outattr(QVM_OUTAL_ERROR, QVM_OUTAC_XCONF, QVM_OUTAC_UNEXPECTED, 0))

Error originating in the user-specified configuration

#define QVM_OUTW_CNF (qvm_outattr(QVM_OUTAL_WARN, QVM_OUTAC_XCONF, QVM_OUTAC_UNEXPECTED, 0))

Warning originating in the user-specified configuration

#define QVM_OUTN_QVM (qvm_outattr(QVM_OUTAL_INTERNAL, QVM_OUTAC_INT, QVM_OUTAC_UNEXPECTED, 0))

Internal message from qvm

#define QVM_OUTF_QVM (qvm_outattr(QVM_OUTAL_FATAL, QVM_OUTAC_INT, QVM_OUTAC_UNEXPECTED, 0))

Fatal error message from qvm

#define QVM_OUTE_QVM (qvm_outattr(QVM_OUTAL_ERROR, QVM_OUTAC_INT, QVM_OUTAC_UNEXPECTED, 0))

Error from qvm

#define QVM_OUTW_QVM (qvm_outattr(QVM_OUTAL_WARN, QVM_OUTAC_INT, QVM_OUTAC_UNEXPECTED, 0))

Warning from qvm

#define QVM_OUTI_QVM (qvm_outattr(QVM_OUTAL_INFO, QVM_OUTAC_INT, QVM_OUTAC_OK, 0))

Information-level output from qvm

#define QVM_OUTD_QVM (qvm_outattr(QVM_OUTAL_DEBUG, QVM_OUTAC_INT, QVM_OUTAC_OK, 0))

Debug-level output from qvm

#define QVM_OUTV_QVM (qvm_outattr(QVM_OUTAL_VERBOSE, 0, QVM_OUTAC_OK, 0))

Verbose output from qvm

#define QVM_OUTE_GST (qvm_outattr(QVM_OUTAL_ERROR, QVM_OUTAC_GST, QVM_OUTAC_UNEXPECTED, 0))

Error message originating in a guest

Library:

qvm