mirror of
https://git.FreeBSD.org/src.git
synced 2024-10-19 02:29:40 +00:00
Don't pre-reserve resources for CPU devices when they are set.
CPUs can use shared (RF_SHAREABLE) resources for the I/O port used for entering and exiting C states. If this I/O port is included in an ACPI system resource device, then this happens to still work, but if the port wasn't part of a system resource device, only the first CPU could allocate the I/O port and use C states since resource_list_reserve() was always allocating the resource from nexus0 without RF_SHAREABLE. By avoiding the reservation, the flags from the bus_alloc_resource() in the CPU driver (which include RF_SHAREABLE) are honored. PR: 236513 Reported by: stockhausen@collogia.de Sleuthing by: avg Reviewed by: avg MFC after: 2 weeks
This commit is contained in:
parent
2a508645b4
commit
1fe39413c4
Notes:
svn2git
2020-12-20 02:59:44 +00:00
svn path=/head/; revision=346063
@ -1352,6 +1352,14 @@ acpi_set_resource(device_t dev, device_t child, int type, int rid,
|
||||
if (type == SYS_RES_IRQ)
|
||||
return (0);
|
||||
|
||||
/*
|
||||
* Don't reserve resources for CPU devices. Some of these
|
||||
* resources need to be allocated as shareable, but reservations
|
||||
* are always non-shareable.
|
||||
*/
|
||||
if (device_get_devclass(child) == devclass_find("cpu"))
|
||||
return (0);
|
||||
|
||||
/*
|
||||
* Reserve the resource.
|
||||
*
|
||||
|
Loading…
Reference in New Issue
Block a user