lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <PU1P153MB0169807BF9CE60FC3CA51B31BF700@PU1P153MB0169.APCP153.PROD.OUTLOOK.COM>
Date:   Fri, 15 Nov 2019 06:48:45 +0000
From:   Dexuan Cui <decui@...rosoft.com>
To:     Michael Kelley <mikelley@...rosoft.com>,
        "linux-kernel@...r.kernel.org" <linux-kernel@...r.kernel.org>,
        "tglx@...utronix.de" <tglx@...utronix.de>,
        "daniel.lezcano@...aro.org" <daniel.lezcano@...aro.org>,
        vkuznets <vkuznets@...hat.com>,
        KY Srinivasan <kys@...rosoft.com>,
        Stephen Hemminger <sthemmin@...rosoft.com>,
        "sashal@...nel.org" <sashal@...nel.org>,
        "mingo@...hat.com" <mingo@...hat.com>,
        "bp@...en8.de" <bp@...en8.de>, "hpa@...or.com" <hpa@...or.com>,
        "x86@...nel.org" <x86@...nel.org>,
        "will@...nel.org" <will@...nel.org>,
        "Ganapatrao.Kulkarni@...ium.com" <Ganapatrao.Kulkarni@...ium.com>,
        "james.morse@....com" <james.morse@....com>,
        "steven.price@....com" <steven.price@....com>,
        "josephl@...dia.com" <josephl@...dia.com>,
        "m.szyprowski@...sung.com" <m.szyprowski@...sung.com>,
        "linux-hyperv@...r.kernel.org" <linux-hyperv@...r.kernel.org>
Subject: RE: [PATCH v2 1/1] x86/hyperv: Initialize clockevents earlier in CPU
 onlining

> From: Michael Kelley <mikelley@...rosoft.com>
> Sent: Tuesday, November 12, 2019 5:12 PM
> ...
> @@ -190,14 +278,20 @@ void hv_stimer_free(void)
>  void hv_stimer_global_cleanup(void)
>  {
>  	int	cpu;
>  ...
> +	/*
> +	 * hv_stime_legacy_cleanup() will stop the stimer if Direct
> +	 * Mode is not enabled, and fallback to the LAPIC timer.
> +	 */
> +	for_each_present_cpu(cpu) {
> +		hv_stimer_legacy_cleanup(cpu);
>  	}
> +
> +	/*
> +	 * If Direct Mode is enabled, the cpuhp teardown callback
> +	 * (hv_stimer_cleanup) will be run on all CPUs to stop the
> +	 * stimers.
> +	 */
>  	hv_stimer_free();
>  }

In the case of direct_mode_enabled == true: When hv_vmbus unloads,
vmbus_exit() -> hv_stimer_global_cleanup() -> hv_stimer_free() ->
cpuhp_remove_state() disables the direct mode timers.

This does not look symmetric since hv_stimer_alloc() is called before
hv_vmbus loads, but I suppose this is not a real issue because hv_vmbus
should never unload in practice. :-)

Tested-by: Dexuan Cui <decui@...rosoft.com>
Reviewed-by: Dexuan Cui <decui@...rosoft.com>

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ