Skip to content

Commit d8455a6

Browse files
debox1ij-intel
authored andcommitted
platform/x86: intel_pmc_ipc: add option to build without ACPI
Introduce a configuration option that allows users to build the intel_pmc_ipc driver without ACPI support. This is useful for systems where ACPI is not available or desired. Based on the discussion from the patch [1], it was necessary to provide this option to accommodate specific use cases. Link: https://patchwork.kernel.org/project/netdevbpf/patch/[email protected]/#26280764 [1] Signed-off-by: David E. Box <[email protected]> Co-developed-by: Choong Yong Liang <[email protected]> Signed-off-by: Choong Yong Liang <[email protected]> Reviewed-by: Andy Shevchenko <[email protected]> Link: https://lore.kernel.org/r/[email protected] Reviewed-by: Ilpo Järvinen <[email protected]> Signed-off-by: Ilpo Järvinen <[email protected]>
1 parent 0af2f6b commit d8455a6

File tree

1 file changed

+4
-0
lines changed

1 file changed

+4
-0
lines changed

include/linux/platform_data/x86/intel_pmc_ipc.h

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -36,6 +36,7 @@ struct pmc_ipc_rbuf {
3636
*/
3737
static inline int intel_pmc_ipc(struct pmc_ipc_cmd *ipc_cmd, struct pmc_ipc_rbuf *rbuf)
3838
{
39+
#ifdef CONFIG_ACPI
3940
struct acpi_buffer buffer = { ACPI_ALLOCATE_BUFFER, NULL };
4041
union acpi_object params[PMC_IPCS_PARAM_COUNT] = {
4142
{.type = ACPI_TYPE_INTEGER,},
@@ -89,6 +90,9 @@ static inline int intel_pmc_ipc(struct pmc_ipc_cmd *ipc_cmd, struct pmc_ipc_rbuf
8990
}
9091

9192
return 0;
93+
#else
94+
return -ENODEV;
95+
#endif /* CONFIG_ACPI */
9296
}
9397

9498
#endif /* INTEL_PMC_IPC_H */

0 commit comments

Comments
 (0)