Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1751964AbdI0ROS (ORCPT ); Wed, 27 Sep 2017 13:14:18 -0400 Received: from aserp1040.oracle.com ([141.146.126.69]:26302 "EHLO aserp1040.oracle.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1751333AbdI0ROR (ORCPT ); Wed, 27 Sep 2017 13:14:17 -0400 Subject: Re: [PATCH v6 1/4] sched/clock: interface to allow timestamps early in boot To: Dou Liyang , Peter Zijlstra Cc: linux@armlinux.org.uk, schwidefsky@de.ibm.com, heiko.carstens@de.ibm.com, john.stultz@linaro.org, sboyd@codeaurora.org, x86@kernel.org, linux-kernel@vger.kernel.org, mingo@redhat.com, tglx@linutronix.de, hpa@zytor.com References: <1504116205-355281-1-git-send-email-pasha.tatashin@oracle.com> <1504116205-355281-2-git-send-email-pasha.tatashin@oracle.com> <20170927125857.yvwefpejzskiduwu@hirez.programming.kicks-ass.net> <20170927131003.dxbvu7frcqgtiwaz@hirez.programming.kicks-ass.net> <4a62156c-ea0f-749f-e21b-37919dfda1df@cn.fujitsu.com> From: Pasha Tatashin Message-ID: <56b59905-1d64-dca4-775a-925cbe9e7092@oracle.com> Date: Wed, 27 Sep 2017 13:13:15 -0400 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:52.0) Gecko/20100101 Thunderbird/52.3.0 MIME-Version: 1.0 In-Reply-To: <4a62156c-ea0f-749f-e21b-37919dfda1df@cn.fujitsu.com> Content-Type: text/plain; charset=utf-8; format=flowed Content-Language: en-US Content-Transfer-Encoding: 7bit X-Source-IP: aserv0021.oracle.com [141.146.126.233] Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Content-Length: 1464 Lines: 43 Hi Dou, This makes sense. The current sched_clock_early() approach does not break it because with notsc TSC is used early in boot, and later stopped. But, notsc must stay. Peter, So, we could either expend sched_clock() with another static branch for early clock, or use what I proposed. IMO, the later is better, but either way works for me. Thank you, Pasha On 09/27/2017 09:52 AM, Dou Liyang wrote: > Hi Pasha, Peter > > At 09/27/2017 09:16 PM, Pasha Tatashin wrote: >> Hi Peter, >> >> I am totally happy with removing notsc. This certainly simplifies the >> sched_clock code. Are there any issues with removing existing kernel >> parameters that I should be aware of? >> > > We do not want to do that. Because, we use "notsc" to support Dynamic > Reconfiguration[1]. > > AFAIK, this feature enables hot-add system board which contains CPUs > and memories. But the CPUs in different board may have different TSCs > which are not consistent with the TSC from the existing CPUs. If we > hot-add a board directly, the machine may happen the inconsistency of > TSC. > > We make our effort to specify the same TSC value as existing one through > hardware and firmware, but it is hard. So we recommend to specify > "notsc" option in command line for users who want to use Dynamic > Reconfiguration. > > [1] > http://www.fujitsu.com/global/products/computing/servers/mission-critical/primequest/technology/availability/dynamic-reconfiguration.html >