]> git.dujemihanovic.xyz Git - u-boot.git/commit
rockchip: boot_mode: fix rockchip_dnl_key_pressed requiring ADC support
authorQuentin Schulz <quentin.schulz@theobroma-systems.com>
Thu, 14 Mar 2024 09:36:29 +0000 (10:36 +0100)
committerKever Yang <kever.yang@rock-chips.com>
Thu, 14 Mar 2024 10:20:04 +0000 (18:20 +0800)
commit12bc1a5462a22f6dc5b91ecbf092cbaf94e66820
tree4d7248af62ba20ca4dec0a8bd9d4c500bb4e4f38
parent759ae818ba760e97a895bdaa1cd7a86f8972ea93
rockchip: boot_mode: fix rockchip_dnl_key_pressed requiring ADC support

ADC support is implied by the Rockchip arch Kconfig but that means it
should be possible to disable ADC support and still be able to build.

However the weak implementation of rockchip_dnl_key_pressed() currently
blindly use functions from the ADC subsystem which do not exist when ADC
is not enabled, failing the build.

Therefore, let's encapsulate this logic with a check on the ADC symbol
being selected.

Cc: Quentin Schulz <foss+uboot@0leil.net>
Reviewed-by: Kever Yang <kever.yang@rock-chips.com>
Signed-off-by: Quentin Schulz <quentin.schulz@theobroma-systems.com>
arch/arm/mach-rockchip/boot_mode.c