Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]


Groups > linux.kernel > #1672648

Re: [PATCH RESEND] Calling check_system_tsc_reliable() before unsynchronized_tsc()

From Thomas Gleixner <tglx@linutronix.de>
Newsgroups linux.kernel
Subject Re: [PATCH RESEND] Calling check_system_tsc_reliable() before unsynchronized_tsc()
Date 2017-06-22 16:00 +0200
Message-ID <tVaOl-5tA-1@gated-at.bofh.it> (permalink)
References <tUJbr-3H5-1@gated-at.bofh.it>
Organization linux.* mail to news gateway

Show all headers | View raw


Zhenzhong,

On Wed, 21 Jun 2017, Zhenzhong Duan wrote:

So the patch format is now correct, but the subject line is missing a
proper subsystem prefix. Please use 'git log 'path/to/patched/file' next
time to see what the usually used prefix for a file is.

In this case it's:   x86/tsc

Also please do not use [PATCH RESEND] when your patch is different from the
version you sent before. Please use [PATCH v2] instead.

> unsynchronized_tsc() checks value of tsc_clocksource_reliable which is set by
> check_system_tsc_reliable(). It's better to move check_system_tsc_reliable() at
> front.

Please make your statements affirmative. 'It's better' is a weak expression.

> Though X86_FEATURE_CONSTANT_TSC is usually set for TSC reliable system, just in
> case.

So what you wanted to say here is:

   tsc_clocksource_reliable is initialized in check_system_tsc_reliable(),
   but it is checked in unsynchronized_tsc() which is called before the
   initialization.

   In practice that's not an issue because systems which mark the TSC
   reliable have X86_FEATURE_CONSTANT_TSC set as well, which is evaluated
   in unsynchronized_tsc() before tsc_clocksource_reliable.

   Reorder the calls so initialization happens before usage.

All this information is also documented in Documentation/process/.

No need to resend. I'll fix it up for you this time. 
 
Thanks,

	tglx

Back to linux.kernel | Previous | NextPrevious in thread | Next in thread | Find similar | Unroll thread


Thread

[PATCH RESEND] Calling check_system_tsc_reliable() before  unsynchronized_tsc() Zhenzhong Duan <zhenzhong.duan@oracle.com> - 2017-06-21 10:30 +0200
  Re: [PATCH RESEND] Calling check_system_tsc_reliable() before  unsynchronized_tsc() Thomas Gleixner <tglx@linutronix.de> - 2017-06-22 16:00 +0200
    Re: [PATCH RESEND] Calling check_system_tsc_reliable() before  unsynchronized_tsc() Zhenzhong Duan <zhenzhong.duan@oracle.com> - 2017-06-23 10:40 +0200
  [tip:x86/timers] x86/tsc: Call check_system_tsc_reliable() before  unsynchronized_tsc() tip-bot for Zhenzhong Duan <tipbot@zytor.com> - 2017-06-22 16:10 +0200

csiph-web