summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorAndrei Gherzan <andrei@gherzan.com>2021-11-13 23:47:57 +0000
committerAndrei Gherzan <andrei@gherzan.com>2021-11-13 23:53:03 +0000
commitecc31a594c9f467d8b6eb5f0f94d9f749b862519 (patch)
tree23f9a2ce70c97da5fb906ddccaf206f6011bdd7d
parent0d0879dc37a84645213a2daef51fbe4c8ee86f09 (diff)
downloadmeta-raspberrypi-enableuart0.tar.gz
rpi-config: Take into consideration ENABLE_UART value of 0enableuart0
Also, validate if the value of it is not 0 or 1. Fixes: https://github.com/agherzan/meta-raspberrypi/issues/567 Signed-off-by: Andrei Gherzan <andrei@gherzan.com>
-rw-r--r--recipes-bsp/bootfiles/rpi-config_git.bb6
1 files changed, 4 insertions, 2 deletions
diff --git a/recipes-bsp/bootfiles/rpi-config_git.bb b/recipes-bsp/bootfiles/rpi-config_git.bb
index 13a0714..fe18884 100644
--- a/recipes-bsp/bootfiles/rpi-config_git.bb
+++ b/recipes-bsp/bootfiles/rpi-config_git.bb
@@ -174,9 +174,11 @@ do_deploy() {
174 fi 174 fi
175 175
176 # UART support 176 # UART support
177 if [ "${ENABLE_UART}" = "1" ]; then 177 if [ "${ENABLE_UART}" = "1" ] || [ "${ENABLE_UART}" = "0" ] ; then
178 echo "# Enable UART" >>$CONFIG 178 echo "# Enable UART" >>$CONFIG
179 echo "enable_uart=1" >>$CONFIG 179 echo "enable_uart=${ENABLE_UART}" >>$CONFIG
180 else
181 bbfatal "Invalid value for ENABLE_UART [${ENABLE_UART}]. The value for ENABLE_UART can be 0 or 1."
180 fi 182 fi
181 183
182 # Infrared support 184 # Infrared support