dmi_dell_indexed_io
Synopsis
#include <opendmi/entity/dell/indexed-io.h>
typedef struct dmi_dell_indexed_io {
uint16_t index_port;
uint16_t data_port;
dmi_dell_check_type_t check_type;
uint8_t check_start;
uint8_t check_end;
uint8_t check_index;
size_t token_count;
dmi_dell_indexed_io_token_t *tokens;
} dmi_dell_indexed_io_t;
Description
The dmi_dell_indexed_io_t structure holds the decoded Dell indexed IO
structure (type 212): the pair of I/O ports through which the locations of CMOS
are selected and accessed, the checksum guarding a range of CMOS, and the
tokens, settings of the firmware kept in CMOS.
The structure is returned by dmi_entity_info for the structures of type
DMI_TYPE(dell_indexed_io), declared in <opendmi/module/dell.h>, and lives
as long as the context it has been decoded in.
Fields
index_port-
Address of the I/O port written to select a CMOS location.
data_port-
Address of the I/O port through which the selected CMOS location is read and written.
check_type-
How the checksum of the checked range is computed.
check_start-
CMOS index of the first location of the checked range.
check_end-
CMOS index of the last location of the checked range.
check_index-
CMOS index of the checksum. When
check_start,check_endandcheck_indexare all 0, the CMOS area has no checksum. token_count-
Number of elements of
tokens. tokens-
Tokens, in the order of the structure. Unused records (token identifier
0x0000) and the end-of-table marker (0xFFFF) are left out. May benullptrwhentoken_countis 0.
Examples
dmi_registry_t *registry = dmi_get_registry(context);
dmi_entity_t *entity = dmi_registry_lookup_first(registry,
DMI_TYPE(dell_indexed_io), true);
dmi_dell_indexed_io_t *io = dmi_entity_info(entity,
DMI_TYPE(dell_indexed_io));
if (io != nullptr) {
printf("Ports 0x%04x/0x%04x, %zu tokens\n", io->index_port,
io->data_port, io->token_count);
}