mirror of
https://github.com/AuxXxilium/linux_dsm_epyc7002.git
synced 2024-11-26 04:30:56 +07:00
ACPICA: acpi_reset: Bypass port validation mechanism
Allow writes to reserved ports. This change may eventually be driven down in to acpi_write and acpi_read. Signed-off-by: Bob Moore <robert.moore@intel.com> Signed-off-by: Lin Ming <ming.m.lin@intel.com> Signed-off-by: Len Brown <len.brown@intel.com>
This commit is contained in:
parent
1872bbc94b
commit
8a96423680
@ -78,9 +78,22 @@ acpi_status acpi_reset(void)
|
||||
return_ACPI_STATUS(AE_NOT_EXIST);
|
||||
}
|
||||
|
||||
/* Write the reset value to the reset register */
|
||||
if (reset_reg->space_id == ACPI_ADR_SPACE_SYSTEM_IO) {
|
||||
/*
|
||||
* For I/O space, write directly to the OSL. This bypasses the port
|
||||
* validation mechanism, which may block a valid write to the reset
|
||||
* register.
|
||||
*/
|
||||
status =
|
||||
acpi_os_write_port((acpi_io_address) reset_reg->address,
|
||||
acpi_gbl_FADT.reset_value,
|
||||
reset_reg->bit_width);
|
||||
} else {
|
||||
/* Write the reset value to the reset register */
|
||||
|
||||
status = acpi_hw_write(acpi_gbl_FADT.reset_value, reset_reg);
|
||||
}
|
||||
|
||||
status = acpi_hw_write(acpi_gbl_FADT.reset_value, reset_reg);
|
||||
return_ACPI_STATUS(status);
|
||||
}
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user