drivers: dac: update drivers to use devicetree Kconfig symbol
Update dac drivers to use DT_HAS_<compat>_ENABLED Kconfig symbol to expose the driver and enable it by default based on devicetree. We remove 'depend on' Kconfig for symbols that would be implied by the devicetree node existing. Signed-off-by: Martin Jäger <martin@libre.solar>
This commit is contained in:
parent
e1e366c912
commit
c40ec11ab4
9 changed files with 21 additions and 17 deletions
|
@ -2,12 +2,9 @@
|
|||
# SPDX-License-Identifier: Apache-2.0
|
||||
#
|
||||
|
||||
# Workaround for not being able to have commas in macro arguments
|
||||
DT_COMPAT_ATMEL_SAM_DAC := atmel,sam-dac
|
||||
|
||||
config DAC_SAM
|
||||
bool "Atmel SAM DAC driver"
|
||||
default $(dt_compat_enabled,$(DT_COMPAT_ATMEL_SAM_DAC))
|
||||
depends on SOC_FAMILY_SAM
|
||||
default y
|
||||
depends on DT_HAS_ATMEL_SAM_DAC_ENABLED
|
||||
help
|
||||
Enable Atmel SAM MCU Family Digital Audio Converter (DAC) driver.
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue