sm: Rework the Kconfig logic here

The symbol "SM" is a library symbol and should not be prompted for. It
should be selected by the drivers that use it. In this case we need to
add a SANDBOX_SM symbol for the sandbox driver. The meson SM driver
cannot build on other platforms, so add the appropriate dependency.

Reviewed-by: Peter Robinson <pbrobinson@gmail.com>
Signed-off-by: Tom Rini <trini@konsulko.com>
This commit is contained in:
Tom Rini 2025-08-04 15:51:11 -06:00
parent d68db76b95
commit e2837ecddc
3 changed files with 13 additions and 4 deletions

View File

@ -324,7 +324,7 @@ CONFIG_RTC_RV8803=y
CONFIG_RTC_HT1380=y CONFIG_RTC_HT1380=y
CONFIG_SCSI=y CONFIG_SCSI=y
CONFIG_SANDBOX_SERIAL=y CONFIG_SANDBOX_SERIAL=y
CONFIG_SM=y CONFIG_SANDBOX_SM=y
CONFIG_SMEM=y CONFIG_SMEM=y
CONFIG_SANDBOX_SMEM=y CONFIG_SANDBOX_SMEM=y
CONFIG_SOUND=y CONFIG_SOUND=y

View File

@ -1,8 +1,17 @@
config SM config SM
bool "Enable Secure Monitor driver support" bool
config MESON_SM config MESON_SM
bool "Amlogic Secure Monitor driver" bool "Amlogic Secure Monitor driver"
depends on ARCH_MESON
select SM select SM
help help
Say y here to enable the Amlogic secure monitor driver. Say y here to enable the Amlogic secure monitor driver.
config SANDBOX_SM
bool "Sandbox Secure Monitor driver"
depends on SANDBOX
select SM
help
Say y here to enable the Sandbox driver for the secure monitor
uclass.

View File

@ -1,5 +1,5 @@
# SPDX-License-Identifier: GPL-2.0-only # SPDX-License-Identifier: GPL-2.0-only
obj-y += sm-uclass.o obj-$(CONFIG_SM) += sm-uclass.o
obj-$(CONFIG_SANDBOX) += sandbox-sm.o obj-$(CONFIG_SANDBOX_SM) += sandbox-sm.o
obj-$(CONFIG_MESON_SM) += meson-sm.o obj-$(CONFIG_MESON_SM) += meson-sm.o