Re: [PATCH v7 1/6] x86/tsc: remove tsc_disabled flag
> > IMO, we already have a message by > > mark_tsc_unstable("boot parameter notsc"); > > and we will use 'notsc' in case of CONFIG_X86_TSC = no > > So, I guess there is no need to print this msg. > OK, removed the warning.
Re: [PATCH v7 1/6] x86/tsc: remove tsc_disabled flag
> > IMO, we already have a message by > > mark_tsc_unstable("boot parameter notsc"); > > and we will use 'notsc' in case of CONFIG_X86_TSC = no > > So, I guess there is no need to print this msg. > OK, removed the warning.
Re: [PATCH v7 1/6] x86/tsc: remove tsc_disabled flag
Hi Pavel, At 11/03/2017 10:23 PM, Pavel Tatashin wrote: Hi Dou, Sure, I can remove the warning, but I think we should print something that is indicating that notsc is not a good parameter anymore: i.e tsc=unstable is better. Perhaps something like: "Kernel parameter \'notsc\' is deprecated, please use \'tsc=unstable\' instead" ? IMO, we already have a message by mark_tsc_unstable("boot parameter notsc"); and we will use 'notsc' in case of CONFIG_X86_TSC = no So, I guess there is no need to print this msg. Thanks, dou. Pasha
Re: [PATCH v7 1/6] x86/tsc: remove tsc_disabled flag
Hi Pavel, At 11/03/2017 10:23 PM, Pavel Tatashin wrote: Hi Dou, Sure, I can remove the warning, but I think we should print something that is indicating that notsc is not a good parameter anymore: i.e tsc=unstable is better. Perhaps something like: "Kernel parameter \'notsc\' is deprecated, please use \'tsc=unstable\' instead" ? IMO, we already have a message by mark_tsc_unstable("boot parameter notsc"); and we will use 'notsc' in case of CONFIG_X86_TSC = no So, I guess there is no need to print this msg. Thanks, dou. Pasha
Re: [PATCH v7 1/6] x86/tsc: remove tsc_disabled flag
Hi Dou, Sure, I can remove the warning, but I think we should print something that is indicating that notsc is not a good parameter anymore: i.e tsc=unstable is better. Perhaps something like: "Kernel parameter \'notsc\' is deprecated, please use \'tsc=unstable\' instead" ? Pasha On Thu, Nov 2, 2017 at 9:58 PM, Dou Liyangwrote: > Hi Pavel, > > > At 11/03/2017 01:26 AM, Pavel Tatashin wrote: >> >> tsc_disabled is set when notsc is passed as kernel parameter. The reason >> we >> have notsc is to avoid timing problems on multi-preccors systems. However, >> we already have a mechanism to detect and resolve these issues by invoking >> tsc unstable path. >> >> Signed-off-by: Pavel Tatashin >> --- >> arch/x86/kernel/tsc.c | 17 +++-- >> 1 file changed, 3 insertions(+), 14 deletions(-) >> >> diff --git a/arch/x86/kernel/tsc.c b/arch/x86/kernel/tsc.c >> index 796d96bb0821..1c4502a2b7b2 100644 >> --- a/arch/x86/kernel/tsc.c >> +++ b/arch/x86/kernel/tsc.c >> @@ -37,11 +37,6 @@ EXPORT_SYMBOL(tsc_khz); >> */ >> static int __read_mostly tsc_unstable; >> >> -/* native_sched_clock() is called before tsc_init(), so >> - we must start with the TSC soft disabled to prevent >> - erroneous rdtsc usage on !boot_cpu_has(X86_FEATURE_TSC) processors */ >> -static int __read_mostly tsc_disabled = -1; >> - >> static DEFINE_STATIC_KEY_FALSE(__use_tsc); >> >> int tsc_clocksource_reliable; >> @@ -248,7 +243,7 @@ EXPORT_SYMBOL_GPL(check_tsc_unstable); >> int __init notsc_setup(char *str) >> { >> pr_warn("Kernel compiled with CONFIG_X86_TSC, cannot disable TSC >> completely\n"); > > > IMO, this warning may make users confused, could we remove it from here? > > Thanks, > dou. > >
Re: [PATCH v7 1/6] x86/tsc: remove tsc_disabled flag
Hi Dou, Sure, I can remove the warning, but I think we should print something that is indicating that notsc is not a good parameter anymore: i.e tsc=unstable is better. Perhaps something like: "Kernel parameter \'notsc\' is deprecated, please use \'tsc=unstable\' instead" ? Pasha On Thu, Nov 2, 2017 at 9:58 PM, Dou Liyang wrote: > Hi Pavel, > > > At 11/03/2017 01:26 AM, Pavel Tatashin wrote: >> >> tsc_disabled is set when notsc is passed as kernel parameter. The reason >> we >> have notsc is to avoid timing problems on multi-preccors systems. However, >> we already have a mechanism to detect and resolve these issues by invoking >> tsc unstable path. >> >> Signed-off-by: Pavel Tatashin >> --- >> arch/x86/kernel/tsc.c | 17 +++-- >> 1 file changed, 3 insertions(+), 14 deletions(-) >> >> diff --git a/arch/x86/kernel/tsc.c b/arch/x86/kernel/tsc.c >> index 796d96bb0821..1c4502a2b7b2 100644 >> --- a/arch/x86/kernel/tsc.c >> +++ b/arch/x86/kernel/tsc.c >> @@ -37,11 +37,6 @@ EXPORT_SYMBOL(tsc_khz); >> */ >> static int __read_mostly tsc_unstable; >> >> -/* native_sched_clock() is called before tsc_init(), so >> - we must start with the TSC soft disabled to prevent >> - erroneous rdtsc usage on !boot_cpu_has(X86_FEATURE_TSC) processors */ >> -static int __read_mostly tsc_disabled = -1; >> - >> static DEFINE_STATIC_KEY_FALSE(__use_tsc); >> >> int tsc_clocksource_reliable; >> @@ -248,7 +243,7 @@ EXPORT_SYMBOL_GPL(check_tsc_unstable); >> int __init notsc_setup(char *str) >> { >> pr_warn("Kernel compiled with CONFIG_X86_TSC, cannot disable TSC >> completely\n"); > > > IMO, this warning may make users confused, could we remove it from here? > > Thanks, > dou. > >
Re: [PATCH v7 1/6] x86/tsc: remove tsc_disabled flag
Hi Pavel, At 11/03/2017 01:26 AM, Pavel Tatashin wrote: tsc_disabled is set when notsc is passed as kernel parameter. The reason we have notsc is to avoid timing problems on multi-preccors systems. However, we already have a mechanism to detect and resolve these issues by invoking tsc unstable path. Signed-off-by: Pavel Tatashin--- arch/x86/kernel/tsc.c | 17 +++-- 1 file changed, 3 insertions(+), 14 deletions(-) diff --git a/arch/x86/kernel/tsc.c b/arch/x86/kernel/tsc.c index 796d96bb0821..1c4502a2b7b2 100644 --- a/arch/x86/kernel/tsc.c +++ b/arch/x86/kernel/tsc.c @@ -37,11 +37,6 @@ EXPORT_SYMBOL(tsc_khz); */ static int __read_mostly tsc_unstable; -/* native_sched_clock() is called before tsc_init(), so - we must start with the TSC soft disabled to prevent - erroneous rdtsc usage on !boot_cpu_has(X86_FEATURE_TSC) processors */ -static int __read_mostly tsc_disabled = -1; - static DEFINE_STATIC_KEY_FALSE(__use_tsc); int tsc_clocksource_reliable; @@ -248,7 +243,7 @@ EXPORT_SYMBOL_GPL(check_tsc_unstable); int __init notsc_setup(char *str) { pr_warn("Kernel compiled with CONFIG_X86_TSC, cannot disable TSC completely\n"); IMO, this warning may make users confused, could we remove it from here? Thanks, dou.
Re: [PATCH v7 1/6] x86/tsc: remove tsc_disabled flag
Hi Pavel, At 11/03/2017 01:26 AM, Pavel Tatashin wrote: tsc_disabled is set when notsc is passed as kernel parameter. The reason we have notsc is to avoid timing problems on multi-preccors systems. However, we already have a mechanism to detect and resolve these issues by invoking tsc unstable path. Signed-off-by: Pavel Tatashin --- arch/x86/kernel/tsc.c | 17 +++-- 1 file changed, 3 insertions(+), 14 deletions(-) diff --git a/arch/x86/kernel/tsc.c b/arch/x86/kernel/tsc.c index 796d96bb0821..1c4502a2b7b2 100644 --- a/arch/x86/kernel/tsc.c +++ b/arch/x86/kernel/tsc.c @@ -37,11 +37,6 @@ EXPORT_SYMBOL(tsc_khz); */ static int __read_mostly tsc_unstable; -/* native_sched_clock() is called before tsc_init(), so - we must start with the TSC soft disabled to prevent - erroneous rdtsc usage on !boot_cpu_has(X86_FEATURE_TSC) processors */ -static int __read_mostly tsc_disabled = -1; - static DEFINE_STATIC_KEY_FALSE(__use_tsc); int tsc_clocksource_reliable; @@ -248,7 +243,7 @@ EXPORT_SYMBOL_GPL(check_tsc_unstable); int __init notsc_setup(char *str) { pr_warn("Kernel compiled with CONFIG_X86_TSC, cannot disable TSC completely\n"); IMO, this warning may make users confused, could we remove it from here? Thanks, dou.