aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorAndrei Gherzan <andrei@gherzan.com>2021-11-13 23:47:57 +0000
committerAndrei Gherzan <andrei@gherzan.com>2021-11-14 15:39:42 +0000
commitb1570cff2181785e475917932ac09e802d5c8507 (patch)
treeaeac6a52ba4129e379e169db8c69c8182151129a
parent690b4a5e9891f5b16df2d4d41250d51b7ed1ceb2 (diff)
downloadmeta-raspberrypi-b1570cff2181785e475917932ac09e802d5c8507.tar.gz
meta-raspberrypi-b1570cff2181785e475917932ac09e802d5c8507.tar.bz2
meta-raspberrypi-b1570cff2181785e475917932ac09e802d5c8507.zip
rpi-config: Take into consideration ENABLE_UART value of 0
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() {
fi
# UART support
- if [ "${ENABLE_UART}" = "1" ]; then
+ if [ "${ENABLE_UART}" = "1" ] || [ "${ENABLE_UART}" = "0" ] ; then
echo "# Enable UART" >>$CONFIG
- echo "enable_uart=1" >>$CONFIG
+ echo "enable_uart=${ENABLE_UART}" >>$CONFIG
+ else
+ bbfatal "Invalid value for ENABLE_UART [${ENABLE_UART}]. The value for ENABLE_UART can be 0 or 1."
fi
# Infrared support