summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorIgor Opaniuk <igor.opaniuk@toradex.com>2020-11-30 15:29:57 +0200
committerMax Krummenacher <max.krummenacher@toradex.com>2020-12-08 15:02:17 +0100
commit8bbb5c7f319504c42537d011294af92bd11ce53d (patch)
tree2a25b2a7b99e0d8e00e033eed444de5e7ac9d2e9
parent186472283cb83de812e8d8c0f7682bd4048edc9a (diff)
connman: clock time/timezone should not be updated by default
NTP client should not update time and timezone by default unless otherwise stated in the settings. Related-to: ELB-2753 Signed-off-by: Igor Opaniuk <igor.opaniuk@toradex.com> (cherry picked from commit 16961c4f190d23d640286b5df73107cbdf27b727)
-rw-r--r--recipes-connectivity/connman/connman/0003-connman-clock-ntp-client-should-not-update-time-time.patch28
-rw-r--r--recipes-connectivity/connman/connman_%.bbappend1
2 files changed, 29 insertions, 0 deletions
diff --git a/recipes-connectivity/connman/connman/0003-connman-clock-ntp-client-should-not-update-time-time.patch b/recipes-connectivity/connman/connman/0003-connman-clock-ntp-client-should-not-update-time-time.patch
new file mode 100644
index 0000000..c570812
--- /dev/null
+++ b/recipes-connectivity/connman/connman/0003-connman-clock-ntp-client-should-not-update-time-time.patch
@@ -0,0 +1,28 @@
+From fcf27214f779478b449ea5ffe6d915fd6057cade Mon Sep 17 00:00:00 2001
+From: Igor Opaniuk <igor.opaniuk@toradex.com>
+Date: Mon, 30 Nov 2020 15:17:30 +0200
+Subject: [PATCH] connman: clock: ntp client should not update time/timezone
+
+NTP client should not update time/timezone unless otherwise stated
+explicitly in the settings.
+
+Signed-off-by: Igor Opaniuk <igor.opaniuk@toradex.com>
+---
+ src/clock.c | 4 ++--
+ 1 file changed, 2 insertions(+), 2 deletions(-)
+
+diff --git a/src/clock.c b/src/clock.c
+index 0fde2c3..c9a26c6 100644
+--- a/src/clock.c
++++ b/src/clock.c
+@@ -35,8 +35,8 @@ enum timezone_updates {
+ TIMEZONE_UPDATES_AUTO = 2,
+ };
+
+-static enum time_updates time_updates_config = TIME_UPDATES_AUTO;
+-static enum timezone_updates timezone_updates_config = TIMEZONE_UPDATES_AUTO;
++static enum time_updates time_updates_config = TIME_UPDATES_MANUAL;
++static enum timezone_updates timezone_updates_config = TIME_UPDATES_MANUAL;
+
+ static char *timezone_config = NULL;
+
diff --git a/recipes-connectivity/connman/connman_%.bbappend b/recipes-connectivity/connman/connman_%.bbappend
index d90d435..330f66e 100644
--- a/recipes-connectivity/connman/connman_%.bbappend
+++ b/recipes-connectivity/connman/connman_%.bbappend
@@ -3,6 +3,7 @@ FILESEXTRAPATHS_prepend := "${THISDIR}/connman:"
SRC_URI += " \
file://0001-connman.service.in-don-t-start-if-nfs-boot.patch \
file://0002-main.conf-blacklist-rndis-nic-s.patch \
+ file://0003-connman-clock-ntp-client-should-not-update-time-time.patch \
"
do_install_append() {