dmi_intel_rsd_phys_device_mapping
Synopsis
#include <opendmi/entity/intel-rsd/phys-device-mapping.h>
#include <opendmi/module/intel-rsd.h>
typedef struct dmi_intel_rsd_phys_device_mapping {
dmi_intel_rsd_phys_device_type_t device_type;
size_t device_count;
dmi_intel_rsd_phys_device_t *devices;
} dmi_intel_rsd_phys_device_mapping_t;
Description
The dmi_intel_rsd_phys_device_mapping_t structure holds the decoded physical
device mapping information structure (type 200) of Intel Rack Scale Design
(RSD) firmware: where the devices described by other structures physically
are, as socket, riser and slot numbers. A structure lists devices of a single
type; a table may hold several structures for the same type when the devices
do not fit into one.
The structure is returned by dmi_entity_info for the structures of type
DMI_TYPE(intel_rsd_phys_device_mapping), once the Intel RSD extension module
(dmi_intel_rsd_module, declared in <opendmi/module/intel-rsd.h>) has been
enabled in the context with dmi_add_extension(). It lives as long as the
context it has been decoded in.
Fields
device_type-
Type of all the devices of the structure, which tells what their location numbers mean (see
dmi_intel_rsd_phys_device_type). device_count-
Number of elements of
devices: the entries the structure holds completely. devices-
Locations of the devices, an array of
device_countelements (seedmi_intel_rsd_phys_device),nullptrif there are none.
Examples
dmi_registry_t *registry = dmi_get_registry(context);
dmi_entity_t *entity = dmi_registry_lookup_first(registry,
DMI_TYPE(intel_rsd_phys_device_mapping), true);
dmi_intel_rsd_phys_device_mapping_t *mapping =
dmi_entity_info(entity, DMI_TYPE(intel_rsd_phys_device_mapping));
if ((mapping != nullptr) &&
(mapping->device_type == DMI_INTEL_RSD_PHYS_DEVICE_TYPE_MEMORY)) {
for (size_t i = 0; i < mapping->device_count; i++)
printf("Handle 0x%04X: socket %u, DIMM slot %u\n",
(unsigned)mapping->devices[i].handle,
(unsigned)mapping->devices[i].primary_number,
(unsigned)mapping->devices[i].secondary_number);
}