dmi_dell_serial_port
Synopsis
#include <opendmi/entity/dell/serial-port.h>
typedef struct dmi_dell_serial_port {
uint16_t base_address;
uint8_t irq_number;
dmi_dell_serial_port_connector_type_t connector;
dmi_dell_serial_port_caps_t capabilities;
uint32_t maximum_speed;
dmi_dell_port_security_t security;
} dmi_dell_serial_port_t;
Description
The dmi_dell_serial_port_t structure holds the decoded Dell serial port
structure (type 210): the resources, the connector and the capabilities of a
serial port, the highest speed the BIOS supports on it, and the security
setting applied to it.
The structure is returned by dmi_entity_info for the structures of type
DMI_TYPE(dell_serial_port), declared in <opendmi/module/dell.h>, and lives
as long as the context it has been decoded in.
Fields
base_address-
Base I/O address of the port.
irq_number-
IRQ the port uses.
connector-
Connector of the port.
capabilities-
Serial controller the port is compatible with.
maximum_speed-
Highest speed the BIOS supports on the port, in bits per second. The structure carries it in hundreds of bits per second.
security-
Security setting applied to the port.
Examples
dmi_registry_t *registry = dmi_get_registry(context);
dmi_entity_t *entity = dmi_registry_lookup_first(registry,
DMI_TYPE(dell_serial_port), true);
dmi_dell_serial_port_t *port = dmi_entity_info(entity,
DMI_TYPE(dell_serial_port));
if (port != nullptr) {
const char *caps = dmi_dell_serial_port_caps_name(port->capabilities);
printf("Serial port at 0x%04x: %s, up to %u bit/s\n", port->base_address,
caps != nullptr ? caps : "?", (unsigned)port->maximum_speed);
}