mirror of https://lore.kernel.org/lkml/
 help / color / mirror / Atom feed
From: Christoph Lameter <christoph@graphe.net>
To: akpm@osdl.org
Cc: linux-kernel@vger.kernel.org
Subject: Support HPET with a single timer for system time
Date: Mon, 7 Mar 2005 11:47:26 -0800 (PST)	[thread overview]
Message-ID: <Pine.LNX.4.58.0503071146070.7840@server.graphe.net> (raw)

This patch removes the check for the existence of multiple HPET timers.
It allows the use of HPET with only a single timer for system time if
HPET_EMULATE_RTC is not set.

Signed-off-by: Christoph Lameter <christoph@lameter.com>
Signed-off-by: Shai Fultheim <Shai@Scalex86.org>

Index: linux-2.6.10/arch/i386/kernel/time_hpet.c
===================================================================
--- linux-2.6.10.orig/arch/i386/kernel/time_hpet.c	2005-02-28 13:04:28.000000000 -0800
+++ linux-2.6.10/arch/i386/kernel/time_hpet.c	2005-03-01 12:11:18.702195056 -0800
@@ -121,11 +121,16 @@ int __init hpet_enable(void)
 	id = hpet_readl(HPET_ID);

 	/*
-	 * We are checking for value '1' or more in number field.
-	 * So, we are OK with HPET_EMULATE_RTC part too, where we need
-	 * to have atleast 2 timers.
+	 * We are checking for value '1' or more in number field if
+	 * CONFIG_HPET_EMULATE_RTC is set because we will need an
+	 * additional timer for RTC emulation.
+	 * However, we can do with one timer otherwise using the
+	 * the single HPET timer for system time.
 	 */
-	if (!(id & HPET_ID_NUMBER) ||
+	if (
+#ifdef CONFIG_HPET_EMULATE_RTC
+		!(id & HPET_ID_NUMBER) ||
+#endif
 	    !(id & HPET_ID_LEGSUP))
 		return -1;


                 reply	other threads:[~2005-03-08  3:29 UTC|newest]

Thread overview: [no followups] expand[flat|nested]  mbox.gz  Atom feed

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=Pine.LNX.4.58.0503071146070.7840@server.graphe.net \
    --to=christoph@graphe.net \
    --cc=akpm@osdl.org \
    --cc=linux-kernel@vger.kernel.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox

all inboxes | Powered by JetHome®