Source-Changes-HG archive
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]
[src/trunk]: src/sys/arch/mac68k/mac68k Adjust GMT bias automatically by usin...
details: https://anonhg.NetBSD.org/src/rev/9bc5a223e37f
branches: trunk
changeset: 1002949:9bc5a223e37f
user: rin <rin%NetBSD.org@localhost>
date: Thu Aug 22 12:47:57 2019 +0000
description:
Adjust GMT bias automatically by using data obtained from Mac OS,
unless RTC_OFFSET is set explicitly.
diffstat:
sys/arch/mac68k/mac68k/clock.c | 12 ++++++++++--
1 files changed, 10 insertions(+), 2 deletions(-)
diffs (33 lines):
diff -r ef779374063f -r 9bc5a223e37f sys/arch/mac68k/mac68k/clock.c
--- a/sys/arch/mac68k/mac68k/clock.c Thu Aug 22 09:16:08 2019 +0000
+++ b/sys/arch/mac68k/mac68k/clock.c Thu Aug 22 12:47:57 2019 +0000
@@ -1,4 +1,4 @@
-/* $NetBSD: clock.c,v 1.49 2011/02/08 20:20:18 rmind Exp $ */
+/* $NetBSD: clock.c,v 1.50 2019/08/22 12:47:57 rin Exp $ */
/*
* Copyright (c) 1988 University of Utah.
@@ -75,7 +75,9 @@
*/
#include <sys/cdefs.h>
-__KERNEL_RCSID(0, "$NetBSD: clock.c,v 1.49 2011/02/08 20:20:18 rmind Exp $");
+__KERNEL_RCSID(0, "$NetBSD: clock.c,v 1.50 2019/08/22 12:47:57 rin Exp $");
+
+#include "opt_rtc_offset.h"
#include <sys/param.h>
#include <sys/device.h>
@@ -391,6 +393,12 @@
mac68k_trust_pram = 0;
}
tvp->tv_sec = timbuf;
+#if !defined(RTC_OFFSET) || RTC_OFFSET == 0
+ /*
+ * Adjust GTM bias unless RTC_OFFSET is set explicitly.
+ */
+ tvp->tv_sec -= macos_gmtbias * 60;
+#endif
tvp->tv_usec = 0;
return 0;
}
Home |
Main Index |
Thread Index |
Old Index