travelmate: update 2.4.9-4

* fix false-positive ntp time sync, e.g. at boot with the
  sysfixtime clock, no uplink
* ntp hotplug: reject events with an invalid stratum
* remove the synthetic hotplug trigger from f_system

Signed-off-by: Dirk Brenken <dev@brenken.org>
(cherry picked from commit 607b3dd1b5)
This commit is contained in:
Dirk Brenken committed 2026-10-08 16:37:31 +02:00
1 parent d27367596b
commit 705e1cc3be
3 files changed
+9 -10

No files matched your search

+1 -1
View File
@@ -7,7 +7,7 @@ include $(TOPDIR)/rules.mk
PKG_NAME:=travelmate
PKG_VERSION:=2.4.9
PKG_RELEASE:=3
PKG_RELEASE:=4
PKG_LICENSE:=GPL-3.0-or-later
PKG_MAINTAINER:=Dirk Brenken <dev@brenken.org>
+8 -3
View File
@@ -16,9 +16,14 @@ trm_ntplock="/var/run/travelmate/travelmate.ntp.lock"
# check for ntp hotplug event and travelmate service autostart condition
#
if mkdir "${trm_ntplock}" 2>/dev/null; then
if [ "${ACTION}" = "stratum" ] && "${trm_init}" enabled; then
case "${stratum}" in
"") ;;
*[!0-9]*) exit 0 ;;
*) [ "${stratum}" -lt "16" ] || exit 0 ;;
esac
if [ "${ACTION}" = "stratum" ] && "${trm_init}" enabled; then
if mkdir "${trm_ntplock}" 2>/dev/null; then
. "${trm_funlib}"
f_log "info" "get ntp time sync"
f_log "info" "get ntp time sync (stratum: ${stratum:-"-"})"
fi
fi
@@ -75,12 +75,6 @@ f_system() {
#
[ -z "${trm_cores}" ] && trm_cores="$("${trm_grepcmd}" -cm16 '^processor' /proc/cpuinfo 2>/dev/null)"
case "${trm_cores}" in "" | 0 | *[!0-9]*) trm_cores="1" ;; esac
# trigger ntp sync if no lock file exists (to avoid multiple concurrent calls)
#
if [ ! -d "${trm_ntplock}" ]; then
"${trm_ubuscmd}" -S call hotplug.ntp call '{ "env": [ "ACTION=stratum" ] }' >/dev/null 2>&1
fi
}
# command selector