pub struct Spcr {
pub header: SdtHeader,
pub parity: u8,
pub stop_bits: u8,
pub language: u8,
pub pci_flags: u32,
pub pci_segment: u8,
/* private fields */
}Expand description
Serial Port Console Redirection (SPCR) Table.
The table provides information about the configuration and use of the serial port or non-legacy UART interface. On a system where the BIOS or system firmware uses the serial port for console input/output, this table should be used to convey information about the settings.
For more information, see the official documentation.
Fields§
§header: SdtHeader§parity: u8§stop_bits: u8§language: u8Language which the BIOS was redirecting. Must be 0.
pci_flags: u32§pci_segment: u8PCI segment number. systems with fewer than 255 PCI buses, this number will be 0.
Implementations§
Source§impl Spcr
impl Spcr
Sourcepub fn interface_type(&self) -> SpcrInterfaceType
pub fn interface_type(&self) -> SpcrInterfaceType
Gets the type of the register interface.
Sourcepub fn base_address(&self) -> Option<AcpiResult<GenericAddress>>
pub fn base_address(&self) -> Option<AcpiResult<GenericAddress>>
The base address of the Serial Port register set, if if console redirection is enabled.
Sourcepub fn baud_rate(&self) -> Option<NonZeroU32>
pub fn baud_rate(&self) -> Option<NonZeroU32>
The baud rate the BIOS used for redirection, if configured.
Sourcepub fn flow_control(&self) -> SpcrFlowControl
pub fn flow_control(&self) -> SpcrFlowControl
Flow control flags for the UART.
Sourcepub fn interrupt_type(&self) -> SpcrInterruptType
pub fn interrupt_type(&self) -> SpcrInterruptType
Interrupt type(s) used by the UART.
Sourcepub fn irq(&self) -> Option<u8>
pub fn irq(&self) -> Option<u8>
The PC-AT-compatible IRQ used by the UART, if the UART supports it.
Support is indicated by the interrupt_type.
Sourcepub fn global_system_interrupt(&self) -> Option<u32>
pub fn global_system_interrupt(&self) -> Option<u32>
The Global System Interrupt (GSIV) used by the UART, if the UART
supports it. Support is indicated by the
interrupt_type.
Sourcepub fn terminal_type(&self) -> SpcrTerminalType
pub fn terminal_type(&self) -> SpcrTerminalType
The terminal protocol the BIOS was using for console redirection.
Sourcepub fn pci_device_id(&self) -> Option<u16>
pub fn pci_device_id(&self) -> Option<u16>
If the UART is a PCI device, returns its Device ID.
Sourcepub fn pci_vendor_id(&self) -> Option<u16>
pub fn pci_vendor_id(&self) -> Option<u16>
If the UART is a PCI device, returns its Vendor ID.
Sourcepub fn pci_bus_number(&self) -> Option<NonZeroU8>
pub fn pci_bus_number(&self) -> Option<NonZeroU8>
If the UART is a PCI device, returns its bus number.
Sourcepub fn pci_device_number(&self) -> Option<NonZeroU8>
pub fn pci_device_number(&self) -> Option<NonZeroU8>
If the UART is a PCI device, returns its device number.
Sourcepub fn pci_function_number(&self) -> Option<NonZeroU8>
pub fn pci_function_number(&self) -> Option<NonZeroU8>
If the UART is a PCI device, returns its function number.
Sourcepub const fn uart_clock_frequency(&self) -> Option<NonZeroU32>
pub const fn uart_clock_frequency(&self) -> Option<NonZeroU32>
The UART clock frequency in Hz, if it can be determined.
Sourcepub fn namespace_string(&self) -> Result<&str, Utf8Error>
pub fn namespace_string(&self) -> Result<&str, Utf8Error>
An ASCII string to uniquely identify this device. This string consists of a fully qualified reference to the object that represents this device in the ACPI namespace. If no namespace device exists, the namespace string must only contain a single ‘.’.