Merge branch 'acpi-bus'
* acpi-bus: ACPI: Pass the same capabilities to the _OSC regardless of the query flag
This commit is contained in:
commit
bc8865ab32
@ -330,32 +330,21 @@ static void acpi_bus_osc_negotiate_platform_control(void)
|
||||
if (ACPI_FAILURE(acpi_run_osc(handle, &context)))
|
||||
return;
|
||||
|
||||
capbuf_ret = context.ret.pointer;
|
||||
if (context.ret.length <= OSC_SUPPORT_DWORD) {
|
||||
kfree(context.ret.pointer);
|
||||
return;
|
||||
}
|
||||
|
||||
/*
|
||||
* Now run _OSC again with query flag clear and with the caps
|
||||
* supported by both the OS and the platform.
|
||||
*/
|
||||
capbuf[OSC_QUERY_DWORD] = 0;
|
||||
capbuf[OSC_SUPPORT_DWORD] = capbuf_ret[OSC_SUPPORT_DWORD];
|
||||
kfree(context.ret.pointer);
|
||||
|
||||
/* Now run _OSC again with query flag clear */
|
||||
capbuf[OSC_QUERY_DWORD] = 0;
|
||||
|
||||
if (ACPI_FAILURE(acpi_run_osc(handle, &context)))
|
||||
return;
|
||||
|
||||
capbuf_ret = context.ret.pointer;
|
||||
if (context.ret.length > OSC_SUPPORT_DWORD) {
|
||||
osc_sb_apei_support_acked =
|
||||
capbuf_ret[OSC_SUPPORT_DWORD] & OSC_SB_APEI_SUPPORT;
|
||||
osc_pc_lpi_support_confirmed =
|
||||
capbuf_ret[OSC_SUPPORT_DWORD] & OSC_SB_PCLPI_SUPPORT;
|
||||
osc_sb_native_usb4_support_confirmed =
|
||||
capbuf_ret[OSC_SUPPORT_DWORD] & OSC_SB_NATIVE_USB4_SUPPORT;
|
||||
}
|
||||
osc_sb_apei_support_acked =
|
||||
capbuf_ret[OSC_SUPPORT_DWORD] & OSC_SB_APEI_SUPPORT;
|
||||
osc_pc_lpi_support_confirmed =
|
||||
capbuf_ret[OSC_SUPPORT_DWORD] & OSC_SB_PCLPI_SUPPORT;
|
||||
osc_sb_native_usb4_support_confirmed =
|
||||
capbuf_ret[OSC_SUPPORT_DWORD] & OSC_SB_NATIVE_USB4_SUPPORT;
|
||||
|
||||
kfree(context.ret.pointer);
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user