arm64: Kconfig: Add SYS_SUPPORTS_APM_EMULATION
Subsystems (2)
PATCH 1/1 arm64: Kconfig: Add SYS_SUPPORTS_APM_EMULATION
From: "Lecopzer Chen" <[email protected]>
Although most of modern devices use ACPI, there still has combination of APM + ARM64.
In order to select CONFIG_APM_EMULATION, make SYS_SUPPORTS_APM_EMULATION default is y if ACPI isn't configured.
--- arch/arm64/Kconfig | 3 +++ 1 file changed, 3 insertions(+)
arch/arm64/Kconfig +3 -0
@@ -260,6 +260,9 @@ config NO_IOPORT_MAP config STACKTRACE_SUPPORT def_bool y +config SYS_SUPPORTS_APM_EMULATION + def_bool y if !ACPI + config ILLEGAL_POINTER_VALUE hex default 0xdead000000000000
Signature · 5 lines
2.18.0 _______________________________________________ Linux-mediatek mailing list [email protected] http://lists.infradead.org/mailman/listinfo/linux-mediatek
Mark Rutland
reviewerQuoted 7 lines · Lecopzer Chen
From: "Lecopzer Chen" <[email protected]>
Although most of modern devices use ACPI, there still has combination of APM + ARM64.
In order to select
CONFIG_APM_EMULATION, makeSYS_SUPPORTS_APM_EMULATIONdefault is y if ACPI isn't configured.
I'm a bit confused why this should be enabled for !ACPI. Which DT platforms need this, and how do they use it? Why should this only be enabled for kernels without ACPI support, and not for kernels that support both ACPI and DT?
Thanks,
Mark.
Quoted 24 lines
Signed-off-by Lecopzer Chen <[email protected]>Suggested-by YJ Chiang <[email protected]>--- arch/arm64/Kconfig | 3 +++ 1 file changed, 3 insertions(+)arch/arm64/Kconfig +3
-0@@ -260,6 +260,9 @@ config NO_IOPORT_MAP config STACKTRACE_SUPPORT def_bool y +config SYS_SUPPORTS_APM_EMULATION + def_bool y if !ACPI + config ILLEGAL_POINTER_VALUE hex default 0xdead000000000000Signature · 1 line
2.18.0
Quoted 8 lines
Quoted 7 lines
From: "Lecopzer Chen" <[email protected]>
Although most of modern devices use ACPI, there still has combination of APM + ARM64.
In order to select
CONFIG_APM_EMULATION, makeSYS_SUPPORTS_APM_EMULATIONdefault is y if ACPI isn't configured.
Quoted 7 lines
I'm a bit confused why this should be enabled for !ACPI. Which DT platforms need this, and how do they use it? Why should this only be enabled for kernels without ACPI support, and not for kernels that support both ACPI and DT?
Thanks,
Mark.
Hi Mark,
In our internal patch has no !ACPI here,
the reason I add here is that in kernel document[1] it mention:
Quoted 1 line
No, sorry, you cannot have both ACPI and APM enabled and running at once.
Thus, I try to limit the scope for who don't use the ACPI because I'm not sure they could exist at the same time or not.
But I think it should be fine without !ACPI if APM and APCI config won't conflict with each other.
So if it's better to remove !ACPI I'll send v2 for this.
BTW, The platform is for our internal kernel drivers, they utilize APM interface, /dev/apm_bios to do their works in arm64.
[1] APM or ACPI?:
https://www.kernel.org/doc/html/latest/power/apm-acpi.html
Thanks,
Lecopzer
Quoted 24 lines
Quoted 24 lines
Signed-off-by Lecopzer Chen <[email protected]>Suggested-by YJ Chiang <[email protected]>--- arch/arm64/Kconfig | 3 +++ 1 file changed, 3 insertions(+)arch/arm64/Kconfig +3
-0@@ -260,6 +260,9 @@ config NO_IOPORT_MAP config STACKTRACE_SUPPORT def_bool y +config SYS_SUPPORTS_APM_EMULATION + def_bool y if !ACPI + config ILLEGAL_POINTER_VALUE hex default 0xdead000000000000Signature · 1 line
2.18.0
Catalin Marinas
maintainerQuoted 14 lines · Lecopzer Chen
Quoted 7 lines
Quoted 2 lines
In order to select
CONFIG_APM_EMULATION, makeSYS_SUPPORTS_APM_EMULATIONdefault is y if ACPI isn't configured.I'm a bit confused why this should be enabled for !ACPI. Which DT platforms need this, and how do they use it? Why should this only be enabled for kernels without ACPI support, and not for kernels that support both ACPI and DT?
In our internal patch has no !ACPI here,
the reason I add here is that in kernel document[1] it mention:Quoted 1 line
No, sorry, you cannot have both ACPI and APM enabled and running at once.
Thus, I try to limit the scope for who don't use the ACPI because I'm not sure they could exist at the same time or not.
Quoted 7 lines
But I think it should be fine without !ACPI if APM and APCI config won't conflict with each other.
So if it's better to remove !ACPI I'll send v2 for this.
BTW, The platform is for our internal kernel drivers, they utilize APM interface,
/dev/apm_biosto do their works in arm64.
Sorry, I don't think the APM interface makes sense on an arm64 kernel (and it's also used by an out of tree driver).
Signature · 6 lines
Catalin _______________________________________________ Linux-mediatek mailing list [email protected] http://lists.infradead.org/mailman/listinfo/linux-mediatek
Hi Catalin,
Thanks for your reply.
so there is two points
1. out-of-tree function can't be approved
I totally agree with this :) so we may have a driver upstream in the future.
2. APM not make sense on arm64
Could you please let me konw the reason why APM on ARM64 doesn't make sense?
thanks!
BRs,
Lecopzer
Quoted 18 lines · Lecopzer Chen
Quoted 17 lines
Quoted 7 lines
Quoted 2 lines
In order to select
CONFIG_APM_EMULATION, makeSYS_SUPPORTS_APM_EMULATIONdefault is y if ACPI isn't configured.I'm a bit confused why this should be enabled for !ACPI. Which DT platforms need this, and how do they use it? Why should this only be enabled for kernels without ACPI support, and not for kernels that support both ACPI and DT?
In our internal patch has no !ACPI here,
the reason I add here is that in kernel document[1] it mention:Quoted 1 line
No, sorry, you cannot have both ACPI and APM enabled and running at once.
Thus, I try to limit the scope for who don't use the ACPI because I'm not sure they could exist at the same time or not.
But I think it should be fine without !ACPI if APM and APCI config won't conflict with each other.
Quoted 7 lines
Quoted 4 lines
So if it's better to remove !ACPI I'll send v2 for this.
BTW, The platform is for our internal kernel drivers, they utilize APM interface,
/dev/apm_biosto do their works in arm64.Sorry, I don't think the APM interface makes sense on an arm64 kernel (and it's also used by an out of tree driver).
_______________________________________________
Linux-mediatek mailing list
[email protected]
http://lists.infradead.org/mailman/listinfo/linux-mediatek
Catalin Marinas
maintainerQuoted 3 lines · Lecopzer Chen
so there is two points
1. out-of-tree function can't be approved
I totally agree with this :) so we may have a driver upstream in the future.
It may not be upstreamable if it relies on the old APM interface ;).
Quoted 2 lines
2. APM not make sense on arm64
Could you please let me konw the reason why APM on ARM64 doesn't make sense?
It's a very old interface, even on x86 it is disabled in the distro kernels. There are more modern alternatives and you should update your driver and user space to use them (e.g. /sys/power/).
Signature · 6 lines
Catalin _______________________________________________ Linux-mediatek mailing list [email protected] http://lists.infradead.org/mailman/listinfo/linux-mediatek
Hi Catalin,
Thanks for your explanation.
Quoted 4 lines
Quoted 3 lines
so there is two points
1. out-of-tree function can't be approved
I totally agree with this :) so we may have a driver upstream in the future.
Quoted 8 lines
It may not be upstreamable if it relies on the old APM interface ;).
Quoted 2 lines
2. APM not make sense on arm64
Could you please let me konw the reason why APM on ARM64 doesn't make sense?It's a very old interface, even on x86 it is disabled in the distro kernels. There are more modern alternatives and you should update your driver and user space to use them (e.g.
/sys/power/).
Got it! I will disscuss with our internal team to update their drivers.
thanks a lot!
BRs,
Lecopzer
_______________________________________________
Linux-mediatek mailing list
[email protected]
http://lists.infradead.org/mailman/listinfo/linux-mediatek
Hi,
Could any maintainer help review this?
Thanks a lot for your help,
BRs,
Lecopzer
Quoted 17 lines
Although most of modern devices use ACPI, there still has combination of APM + ARM64.
In order to select
CONFIG_APM_EMULATION, makeSYS_SUPPORTS_APM_EMULATIONdefault is y if ACPI isn't configured.Signed-off-by Lecopzer Chen <[email protected]>Suggested-by YJ Chiang <[email protected]>--- arch/arm64/Kconfig | 3 +++ 1 file changed, 3 insertions(+)arch/arm64/Kconfig +0
-0
arch/arm64/Kconfig config NO_IOPORT_MAP · line 268
Quoted 9 lines
arch/arm64/Kconfig +3
-0@@ -260,6 +260,9 @@ config NO_IOPORT_MAP config STACKTRACE_SUPPORT def_bool y +config SYS_SUPPORTS_APM_EMULATION + def_bool y if !ACPI + config ILLEGAL_POINTER_VALUE hex default 0xdead000000000000
_______________________________________________
Linux-mediatek mailing list
[email protected]
http://lists.infradead.org/mailman/listinfo/linux-mediatek