mirror of https://lore.kernel.org/lkml/
 help / color / mirror / Atom feed
From: Alok Kataria <akataria@vmware.com>
To: Jeff Hansen <x@jeffhansen.com>
Cc: Chris Snook <csnook@redhat.com>,
	Alok kataria <alokkataria1@gmail.com>,
	Thomas Gleixner <tglx@linutronix.de>,
	"torvalds@linux-foundation.org" <torvalds@linux-foundation.org>,
	"linux-kernel@vger.kernel.org" <linux-kernel@vger.kernel.org>,
	"mingo@elte.hu" <mingo@elte.hu>
Subject: Re: [PATCH] Re: x86_32 tsc/pit and hrtimers
Date: Thu, 09 Oct 2008 15:03:36 -0700	[thread overview]
Message-ID: <1223589816.32639.35.camel@alok-dev1> (raw)
In-Reply-To: <Pine.LNX.4.64.0810091517200.28336@ren>

On Thu, 2008-10-09 at 14:18 -0700, Jeff Hansen wrote:
> [X86] Add tsc=stable option for marking TSC as stable
> 
> This enables legacy hardware or VMs without HPET, LAPIC, or ACPI
> timers to enter high-resolution timer mode.
> 
> Signed-off-by: Jeff Hansen <jhansen@cardaccess-inc.com>
> ---
>   Documentation/kernel-parameters.txt |    4 ++++
>   arch/x86/kernel/tsc_32.c            |   12 +++++++++++-
>   arch/x86/kernel/tsc_64.c            |    9 +++++++++
>   3 files changed, 24 insertions(+), 1 deletions(-)

Hi Jeff,

I see that these changes are not for the mainline tree. Do you plan to
do something of this sought for mainline (.28/tip) ?

My comments below are mainly for generalizing this stuff, don't know how
useful these (my comments) will be for 26.5


> diff --git a/Documentation/kernel-parameters.txt b/Documentation/kernel-parameters.txt
> index 9611505..8488074 100644
> --- a/Documentation/kernel-parameters.txt
> +++ b/Documentation/kernel-parameters.txt
> @@ -2084,6 +2084,10 @@ and is between 256 and 4096 characters. It is defined in the file
>                         Format:
>                         <io>,<irq>,<dma>,<dma2>,<sb_io>,<sb_irq>,<sb_dma>,<mpu_io>,<mpu_irq>
> 
> +       tsc=            [X86-32,X86-64]
> +                       tsc=stable: Mark TSC clocksource as stable, enabling
> +                               high-resolution timer mode on older hardware.
> +
>         turbografx.map[2|3]=    [HW,JOY]
>                         TurboGraFX parallel port interface
>                         Format:
> diff --git a/arch/x86/kernel/tsc_32.c b/arch/x86/kernel/tsc_32.c
> index 65b7063..f6e8f71 100644
> --- a/arch/x86/kernel/tsc_32.c
> +++ b/arch/x86/kernel/tsc_32.c
> @@ -49,6 +49,17 @@ static int __init tsc_setup(char *str)
> 
>   __setup("notsc", tsc_setup);
> 
> +static struct clocksource clocksource_tsc;
> +
> +static int __init tscx_setup(char *str)
> +{
> +       if (!strcmp(str, "stable"))
> +               clocksource_tsc.flags &= ~CLOCK_SOURCE_MUST_VERIFY;

Should we add a flag here instead, say tsc_reliable ? or whatever else
you want to call that. 

Also, there is code in check_geode_tsc_reliable which too sets this flag
for the TSC clocksource. 
Maybe you can just set the tsc_reliable flag from tscx_setup and
check_geode_tsc_reliable, and then check "tsc_reliable" value and set
the verify flag in init_tsc_clocksource. 

Thanks,
Alok




  reply	other threads:[~2008-10-09 22:03 UTC|newest]

Thread overview: 23+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2008-10-07 22:41 Jeff Hansen
2008-10-08 18:41 ` Chris Snook
2008-10-08 19:46   ` Jeff Hansen
2008-10-08 20:25     ` Chris Snook
2008-10-08 21:43       ` [PATCH] " Jeff Hansen
2008-10-08 21:47         ` Randy.Dunlap
2008-10-08 21:47         ` Chris Snook
2008-10-08 21:56           ` Jeff Hansen
2008-10-09  7:14             ` Thomas Gleixner
2008-10-09 18:39               ` Chris Snook
2008-10-09 19:18                 ` Thomas Gleixner
2008-10-09 19:45                   ` Jeff Hansen
2008-10-09 19:53                     ` Thomas Gleixner
2008-10-09 20:45                       ` Alok kataria
2008-10-09 21:03                         ` Chris Snook
2008-10-09 21:18                           ` Jeff Hansen
2008-10-09 22:03                             ` Alok Kataria [this message]
2008-10-09 21:53                           ` Alok Kataria
2008-10-09 22:50                             ` Chris Snook
2008-10-09 23:22                               ` Alok Kataria
2008-10-09 23:37                                 ` Chris Snook
2008-10-10 14:24                                   ` Jeff Hansen
2008-10-09 17:20   ` Pavel Machek

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=1223589816.32639.35.camel@alok-dev1 \
    --to=akataria@vmware.com \
    --cc=alokkataria1@gmail.com \
    --cc=csnook@redhat.com \
    --cc=linux-kernel@vger.kernel.org \
    --cc=mingo@elte.hu \
    --cc=tglx@linutronix.de \
    --cc=torvalds@linux-foundation.org \
    --cc=x@jeffhansen.com \
    /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

Powered by JetHome