From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from mail.kernel.org (mail.kernel.org [198.145.29.99]) by smtp.lore.kernel.org (Postfix) with ESMTP id 4F7F6C433F5 for ; Tue, 2 Nov 2021 10:29:59 +0000 (UTC) Received: from bombadil.infradead.org (bombadil.infradead.org [198.137.202.133]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mail.kernel.org (Postfix) with ESMTPS id 1414A60E78 for ; Tue, 2 Nov 2021 10:29:59 +0000 (UTC) DMARC-Filter: OpenDMARC Filter v1.4.1 mail.kernel.org 1414A60E78 Authentication-Results: mail.kernel.org; dmarc=fail (p=none dis=none) header.from=arm.com Authentication-Results: mail.kernel.org; spf=none smtp.mailfrom=lists.infradead.org DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=lists.infradead.org; s=bombadil.20210309; h=Sender: Content-Transfer-Encoding:Content-Type:List-Subscribe:List-Help:List-Post: List-Archive:List-Unsubscribe:List-Id:In-Reply-To:MIME-Version:References: Message-ID:Subject:Cc:To:From:Date:Reply-To:Content-ID:Content-Description: Resent-Date:Resent-From:Resent-Sender:Resent-To:Resent-Cc:Resent-Message-ID: List-Owner; bh=LSGstTxaGS2KzmvqM/uYp+lmsm18HsNu1XHiKlnaqpE=; b=mpWxfkVwxTn4Y2 v4DUpzGDEMmm4BfLaEc3fgPb0i2hVgln3RFFZb7QV+CgtNiKW+725fOnVdjMMZ7edhicM6sVcMw2p qtK6hNbx2kb1e2gDT67PrEes4XvdCaSzOM3WVuTnWj+aWnkVAbm/u3g8LFm7It/BGqUpHPK53yanK fQfhk2YS+/5lXgircKaiyGWSPh/7wri0CwDlr66ylv5GKvhC0Ykd5SxPPRKGPvyqD+8FOpYksHcYA fRUgH74G57QKBCCm9Q7BL7wby600Cy34wzbhFFZGuloDhARf4yE+6mNVCJw9Zrovf7w6aPsX6Q6Tz NtZ1OIGT7Yf+GNYjQ5Vw==; Received: from localhost ([::1] helo=bombadil.infradead.org) by bombadil.infradead.org with esmtp (Exim 4.94.2 #2 (Red Hat Linux)) id 1mhr1r-001KqI-KZ; Tue, 02 Nov 2021 10:28:31 +0000 Received: from foss.arm.com ([217.140.110.172]) by bombadil.infradead.org with esmtp (Exim 4.94.2 #2 (Red Hat Linux)) id 1mhr1o-001Kov-8I for linux-arm-kernel@lists.infradead.org; Tue, 02 Nov 2021 10:28:29 +0000 Received: from usa-sjc-imap-foss1.foss.arm.com (unknown [10.121.207.14]) by usa-sjc-mx-foss1.foss.arm.com (Postfix) with ESMTP id 29F341FB; Tue, 2 Nov 2021 03:28:25 -0700 (PDT) Received: from C02TD0UTHF1T.local (unknown [10.57.75.232]) by usa-sjc-imap-foss1.foss.arm.com (Postfix) with ESMTPSA id A206B3F719; Tue, 2 Nov 2021 03:28:22 -0700 (PDT) Date: Tue, 2 Nov 2021 10:28:10 +0000 From: Mark Rutland To: Youngmin Nam Cc: krzysztof.kozlowski@canonical.com, will@kernel.org, daniel.lezcano@linaro.org, tglx@linutronix.de, linux-kernel@vger.kernel.org, linux-arm-kernel@lists.infradead.org, linux-samsung-soc@vger.kernel.org, pullip.cho@samsung.com, hoony.yu@samsung.com, hajun.sung@samsung.com, myung-su.cha@samsung.com, kgene@kernel.org Subject: Re: [PATCH v2 1/2] clocksource/drivers/exynos_mct_v2: introduce Exynos MCT version 2 driver for next Exynos SoC Message-ID: <20211102102802.GA16545@C02TD0UTHF1T.local> References: <20211102001122.27516-1-youngmin.nam@samsung.com> <20211102001122.27516-2-youngmin.nam@samsung.com> MIME-Version: 1.0 Content-Disposition: inline In-Reply-To: <20211102001122.27516-2-youngmin.nam@samsung.com> X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20211102_032828_386975_AC1D4B49 X-CRM114-Status: GOOD ( 13.89 ) X-BeenThere: linux-arm-kernel@lists.infradead.org X-Mailman-Version: 2.1.34 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit Sender: "linux-arm-kernel" Errors-To: linux-arm-kernel-bounces+linux-arm-kernel=archiver.kernel.org@lists.infradead.org On Tue, Nov 02, 2021 at 09:11:21AM +0900, Youngmin Nam wrote: > Exynos MCT version 2 is composed of 1 FRC and 12 comparators. > There are no global timer and local timer anymore. > The 1 of 64bit FRC serves as "up-counter"(not "comparators"). > The 12 comaprators(not "counter") can be used as per-cpu event timer > so that it can support upto 12 cores. > And a RTC source can be used as backup clock source. [...] > +static int exynos_mct_starting_cpu(unsigned int cpu) > +{ > + struct mct_clock_event_device *mevt = per_cpu_ptr(&percpu_mct_tick, cpu); > + struct clock_event_device *evt = &mevt->evt; > + > + snprintf(mevt->name, sizeof(mevt->name), "mct_comp%d", cpu); > + > + evt->name = mevt->name; > + evt->cpumask = cpumask_of(cpu); > + evt->set_next_event = exynos_comp_set_next_event; > + evt->set_state_periodic = mct_set_state_periodic; > + evt->set_state_shutdown = mct_set_state_shutdown; > + evt->set_state_oneshot = mct_set_state_shutdown; > + evt->set_state_oneshot_stopped = mct_set_state_shutdown; > + evt->tick_resume = mct_set_state_shutdown; > + evt->features = CLOCK_EVT_FEAT_PERIODIC | CLOCK_EVT_FEAT_ONESHOT; > + evt->rating = 500; /* use value higher than ARM arch timer */ Previously Will asked you to try CLOCK_EVT_FEAT_PERCPU here, and to set the C3STOP flag on the arch timer via the DT when necessary, rather than trying to override the arch timer like this: https://lore.kernel.org/r/20211027073458.GA22231@willie-the-truck There are a bunch of things that depend on the architected timer working as a clocksource (e.g. vdso, kvm), and it *should* work as a lock clockevent_device if configured correctly, and it's much more consistent with *everyone else* to use the arhcitected timer by default. Please try as Will suggested above, so that this works from day one. Thanks, Mark. _______________________________________________ linux-arm-kernel mailing list linux-arm-kernel@lists.infradead.org http://lists.infradead.org/mailman/listinfo/linux-arm-kernel