WARNING - OLD ARCHIVES

This is an archived copy of the Xen.org mailing list, which we have preserved to ensure that existing links to archives are not broken. The live archive, which contains the latest emails, can be found at http://lists.xen.org/
   
 
 
Xen 
 
Home Products Support Community News
 
   
 

xen-devel

[Xen-devel] [PATCH] fix the time issue on x86_64

To: <xen-devel@xxxxxxxxxxxxxxxxxxx>
Subject: [Xen-devel] [PATCH] fix the time issue on x86_64
From: "Li, Xin B" <xin.b.li@xxxxxxxxx>
Date: Fri, 10 Jun 2005 02:45:09 +0800
Delivery-date: Thu, 09 Jun 2005 18:44:25 +0000
Envelope-to: www-data@xxxxxxxxxxxxxxxxxxx
List-help: <mailto:xen-devel-request@lists.xensource.com?subject=help>
List-id: Xen developer discussion <xen-devel.lists.xensource.com>
List-post: <mailto:xen-devel@lists.xensource.com>
List-subscribe: <http://lists.xensource.com/cgi-bin/mailman/listinfo/xen-devel>, <mailto:xen-devel-request@lists.xensource.com?subject=subscribe>
List-unsubscribe: <http://lists.xensource.com/cgi-bin/mailman/listinfo/xen-devel>, <mailto:xen-devel-request@lists.xensource.com?subject=unsubscribe>
Sender: xen-devel-bounces@xxxxxxxxxxxxxxxxxxx
Thread-index: AcVtI1x3eQgDUdsLSn++5MV/gDwwzQ==
Thread-topic: [PATCH] fix the time issue on x86_64
For x86_64, we must have a RTC driver compiled in kernel.
I compiled a native x86_64 Linux kernel without any RTC driver support,
and the native Linux kernel also has the same time issue.
If we run hwclock, we get
        Cannot access the Hardware Clock via any known method.
        Use the --debug option to see the details of our search for an
access method.
If this command fails, /etc/rc.d/rc.sysinit can not set kernel time (by
calling syscall settimeofday()) correctly.

And after adding CONFIG_RTC to xeno64 default config file, the time
issue is gone.
But for i386, this is not a must, for it has some other way to get the
RTC time.

Following is the patch:

# This is a BitKeeper generated diff -Nru style patch.
#
# ChangeSet
#   2005/06/08 23:59:01-07:00 xin@xxxxxxxxxxxxxxxxxxxxxx
#   fix time issue bug on x86_64
#   Signed-off-by: Li B Xin <li.b.xin@xxxxxxxxx>
#   Signed-off-by: Jun Nakajima <jun.nakajima@xxxxxxxxx>
#
# linux-2.6.11-xen-sparse/arch/xen/configs/xen0_defconfig_x86_64
#   2005/06/08 23:59:00-07:00 xin@xxxxxxxxxxxxxxxxxxxxxx +1 -1
#   fix time issue bug by adding RTC driver support.
#   x86_64 must have a RTC driver support, or we can not run hwclock
successfully, so we can not set a correct time to kernel.
#   Signed-off-by: Li B Xin <li.b.xin@xxxxxxxxx>
#   Signed-off-by: Jun Nakajima <jun.nakajima@xxxxxxxxx>
#
diff -Nru
a/linux-2.6.11-xen-sparse/arch/xen/configs/xen0_defconfig_x86_64
b/linux-2.6.11-xen-sparse/arch/xen/configs/xen0_defconfig_x86_64
--- a/linux-2.6.11-xen-sparse/arch/xen/configs/xen0_defconfig_x86_64
2005-06-09 00:02:32 -07:00
+++ b/linux-2.6.11-xen-sparse/arch/xen/configs/xen0_defconfig_x86_64
2005-06-09 00:02:32 -07:00
@@ -701,7 +701,7 @@
 # CONFIG_WATCHDOG is not set
 # CONFIG_HW_RANDOM is not set
 # CONFIG_NVRAM is not set
-# CONFIG_RTC is not set
+CONFIG_RTC=y
 # CONFIG_GEN_RTC is not set
 # CONFIG_DTLK is not set
 # CONFIG_R3964 is not set


thanks
-Xin

_______________________________________________
Xen-devel mailing list
Xen-devel@xxxxxxxxxxxxxxxxxxx
http://lists.xensource.com/xen-devel

<Prev in Thread] Current Thread [Next in Thread>