static u32_t pci_inl(u16_t port) {
	u32_t value;
	int s;
	if ((s=sys_inl(port, &value)) !=OK)
		printf("ACPI: warning, sys_inl failed: %d\n", s);
	return value;
}
Пример #2
0
PUBLIC unsigned pci_inl(U16_t port) {
	U32_t value;
	int s;
	if ((s=sys_inl(port, &value)) !=OK)
		printf("%s: warning, sys_inl failed: %d\n", DRIVER_NAME, s);
	return value;
}
Пример #3
0
static unsigned my_inl(u16_t port)
{
	u32_t value;
	int s;
	if ((s = sys_inl(port, &value)) != OK)
		printf("RTL8169: warning, sys_inl failed: %d\n", s);
	return value;
}
Пример #4
0
ACPI_STATUS
AcpiOsReadPort (
    ACPI_IO_ADDRESS         Address,
    UINT32                  *Value,
    UINT32                  Width)
{
	*Value = 0;
	switch (Width) {
		case 8:
			sys_inb(Address, Value);
			break;
		case 16:
			sys_inw(Address, Value);
			break;
		case 32:
			sys_inl(Address, Value);
			break;
	}
	return AE_OK;
}
ACPI_STATUS
AcpiOsReadPort (
    ACPI_IO_ADDRESS         Address,
    UINT32                  *Value,
    UINT32                  Width)
{
	*Value = 0;
	switch (Width) {
		case 8:
			sys_inb(Address, Value);
			break;
		case 16:
			sys_inw(Address, Value);
			break;
		case 32:
			sys_inl(Address, Value);
			break;
		default:
			panic("unsupported width: %d", Width);
	}
	return AE_OK;
}