From patchwork Fri Feb 15 12:52:27 2019 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Marek Szyprowski X-Patchwork-Id: 10814921 Return-Path: Received: from mail.wl.linuxfoundation.org (pdx-wl-mail.web.codeaurora.org [172.30.200.125]) by pdx-korg-patchwork-2.web.codeaurora.org (Postfix) with ESMTP id E060913B4 for ; Fri, 15 Feb 2019 12:53:37 +0000 (UTC) Received: from mail.wl.linuxfoundation.org (localhost [127.0.0.1]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id CBDBB2F1CA for ; Fri, 15 Feb 2019 12:53:37 +0000 (UTC) Received: by mail.wl.linuxfoundation.org (Postfix, from userid 486) id BEC6D2F1DE; Fri, 15 Feb 2019 12:53:37 +0000 (UTC) X-Spam-Checker-Version: SpamAssassin 3.3.1 (2010-03-16) on pdx-wl-mail.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-5.2 required=2.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID,MAILING_LIST_MULTI,RCVD_IN_DNSWL_MED autolearn=ham version=3.3.1 Received: from bombadil.infradead.org (bombadil.infradead.org [198.137.202.133]) (using TLSv1.2 with cipher AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mail.wl.linuxfoundation.org (Postfix) with ESMTPS id 663AD2F1CA for ; Fri, 15 Feb 2019 12:53:37 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=lists.infradead.org; s=bombadil.20170209; h=Sender: Content-Transfer-Encoding:Content-Type:MIME-Version:Cc:List-Subscribe: List-Help:List-Post:List-Archive:List-Unsubscribe:List-Id:References: In-reply-to:Message-id:Date:Subject:To:From:Reply-To:Content-ID: Content-Description:Resent-Date:Resent-From:Resent-Sender:Resent-To:Resent-Cc :Resent-Message-ID:List-Owner; bh=34i3p5SKUbOUPoI26ALpMJTwSsojEYztHh9gGTy4zIY=; b=OagGjGnjYE3FqoZmfWtqXk923F pAYf98OZSr9vw/WS5fn/df/6PJ4B1SiluAWd6VlD6rYRUaBGCXznVL/Cbxni2atJcYShVeJwSetc5 QHDq026lchkUn0y4WMe135EJAvjwjB1tseGuyVwhhnH//qkP53tGKpbcNJvBsg9+3Oxd/Ru845+T7 TRk700Tw/+EajeO5gNCyckIk98rbMAjsnkeY0WitLG7gWi90DBtX0Qp2u2Q8YAe5RSOCryWF0wB6d v8u+1eHDtUF0VfwuF+Fii/BXQdnVjGeHKs2RQCO7hgKYoAEsf1X0YKCm+/KEfXXh2i+ota4x9TXZS noW/mgJg==; Received: from localhost ([127.0.0.1] helo=bombadil.infradead.org) by bombadil.infradead.org with esmtp (Exim 4.90_1 #2 (Red Hat Linux)) id 1guczn-00071I-N2; Fri, 15 Feb 2019 12:53:35 +0000 Received: from mailout2.w1.samsung.com ([210.118.77.12]) by bombadil.infradead.org with esmtps (Exim 4.90_1 #2 (Red Hat Linux)) id 1gucyy-00062f-Kx for linux-arm-kernel@lists.infradead.org; Fri, 15 Feb 2019 12:52:48 +0000 Received: from eucas1p1.samsung.com (unknown [182.198.249.206]) by mailout2.w1.samsung.com (KnoxPortal) with ESMTP id 20190215125240euoutp02d1a5efa36947d21e2ce06a387213e33d~DiqpWbX8W0825108251euoutp022; Fri, 15 Feb 2019 12:52:40 +0000 (GMT) DKIM-Filter: OpenDKIM Filter v2.11.0 mailout2.w1.samsung.com 20190215125240euoutp02d1a5efa36947d21e2ce06a387213e33d~DiqpWbX8W0825108251euoutp022 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=samsung.com; s=mail20170921; t=1550235160; bh=S3nzVWc9y2XxWLwNUeI00lq0MvjHBGxxHnEHRZdYmK4=; h=From:To:Cc:Subject:Date:In-reply-to:References:From; b=hqgVt0yGgPw+g4Q4+rFIjWKkkdgG+uDPwZSntVkn54fzU8/53FZ8Ah7h1WW8SG6iL MW2g1IZ2Vy8Kj2AdTd8y3qf7rdxVF+9DUHwLx9GtqqRwpbyGRnKQZOcWL1eaUuc6Vo p29gMOYd3h/l7j4FJmUcmq5i9Fi4b5n2JjnuShlc= Received: from eusmges2new.samsung.com (unknown [203.254.199.244]) by eucas1p1.samsung.com (KnoxPortal) with ESMTP id 20190215125240eucas1p1753129627de7da88667853b51eed2acd~Diqo-40Zo1088510885eucas1p11; Fri, 15 Feb 2019 12:52:40 +0000 (GMT) Received: from eucas1p2.samsung.com ( [182.198.249.207]) by eusmges2new.samsung.com (EUCPMTA) with SMTP id 53.AB.04294.816B66C5; Fri, 15 Feb 2019 12:52:40 +0000 (GMT) Received: from eusmgms2.samsung.com (unknown [182.198.249.180]) by eucas1p2.samsung.com (KnoxPortal) with ESMTP id 20190215125239eucas1p2d9167af42f2d04e462c56a070c3371c2~DiqoSl1Fg2398823988eucas1p2s; Fri, 15 Feb 2019 12:52:39 +0000 (GMT) X-AuditID: cbfec7f4-84fff700000010c6-de-5c66b61851c7 Received: from eusync4.samsung.com ( [203.254.199.214]) by eusmgms2.samsung.com (EUCPMTA) with SMTP id B4.C7.04128.716B66C5; Fri, 15 Feb 2019 12:52:39 +0000 (GMT) Received: from AMDC2765.digital.local ([106.116.147.25]) by eusync4.samsung.com (Oracle Communications Messaging Server 7.0.5.31.0 64bit (built May 5 2014)) with ESMTPA id <0PMY00LS8X3MCB70@eusync4.samsung.com>; Fri, 15 Feb 2019 12:52:39 +0000 (GMT) From: Marek Szyprowski To: linux-samsung-soc@vger.kernel.org, linux-arm-kernel@lists.infradead.org Subject: [PATCH 3/5] clocksource: exynos_mct: Increase priority over ARM arch timer Date: Fri, 15 Feb 2019 13:52:27 +0100 Message-id: <20190215125229.30180-4-m.szyprowski@samsung.com> X-Mailer: git-send-email 2.17.1 In-reply-to: <20190215125229.30180-1-m.szyprowski@samsung.com> X-Brightmail-Tracker: H4sIAAAAAAAAA+NgFlrGIsWRmVeSWpSXmKPExsWy7djP87oS29JiDM6u4rfYOGM9q8X1L89Z LeZ9lrU4f34Du8Wmx9dYLWac38dksf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wgKhEhvezwRrYBFQlXiytYEVxOYVsJU4NmcLM8Q6eYnVGw6A2ZwCdhJr1vSA2UJANZdX PWCcwMizgJFhFaNIamlxbnpusZFecWJucWleul5yfu4mRmA4bTv2c8sOxq53wYcYBTgYlXh4 V2SkxgixJpYVV+YeYpTgYFYS4eVckxYjxJuSWFmVWpQfX1Sak1p8iFGag0VJnPe8QWWUkEB6 YklqdmpqQWoRTJaJg1OqgZGV6TE3bzGD39k9KxNWzMkPXxaj6logn73MWXbphBlt16a9Zzmm 3nM6r22C+qmu+oNF0l+tKp69vKOfG+8U+fa0p88jQ63yD3OufVjyO070P8/eCVbJ6intfZm+ f+q03LWOppUvkDMU06gMPdprt8VCXy3uRnKE17yyy74KD99ue7C+e++nk0osxRmJhlrMRcWJ ACekzJMjAgAA X-CMS-MailID: 20190215125239eucas1p2d9167af42f2d04e462c56a070c3371c2 CMS-TYPE: 201P X-CMS-RootMailID: 20190215125239eucas1p2d9167af42f2d04e462c56a070c3371c2 References: <20190215125229.30180-1-m.szyprowski@samsung.com> X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20190215_045245_060277_AC3D48BB X-CRM114-Status: GOOD ( 15.06 ) X-BeenThere: linux-arm-kernel@lists.infradead.org X-Mailman-Version: 2.1.21 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: Bartlomiej Zolnierkiewicz , Daniel Lezcano , Krzysztof Kozlowski , Chanwoo Choi , Thomas Gleixner , Marek Szyprowski MIME-Version: 1.0 Sender: "linux-arm-kernel" Errors-To: linux-arm-kernel-bounces+patchwork-linux-arm=patchwork.kernel.org@lists.infradead.org X-Virus-Scanned: ClamAV using ClamSMTP Exynos Multi-Core Timer driver (exynos_mct) must be started before ARM Architected Timers (arch_timer), because they both share some common hardware blocks (global system counter) and turning on MCT is needed to get ARM Architected Timer working properly. Increase MCT timer rating and hotplug priority over ARM Archictected timer driver to achieve that. Signed-off-by: Marek Szyprowski Reviewed-by: Krzysztof Kozlowski --- drivers/clocksource/exynos_mct.c | 4 ++-- include/linux/cpuhotplug.h | 2 +- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/drivers/clocksource/exynos_mct.c b/drivers/clocksource/exynos_mct.c index 49413900b24c..58090f57ada3 100644 --- a/drivers/clocksource/exynos_mct.c +++ b/drivers/clocksource/exynos_mct.c @@ -211,7 +211,7 @@ static void exynos4_frc_resume(struct clocksource *cs) static struct clocksource mct_frc = { .name = "mct-frc", - .rating = 400, + .rating = 450, .read = exynos4_frc_read, .mask = CLOCKSOURCE_MASK(32), .flags = CLOCK_SOURCE_IS_CONTINUOUS, @@ -465,7 +465,7 @@ static int exynos4_mct_starting_cpu(unsigned int cpu) evt->set_state_oneshot_stopped = set_state_shutdown; evt->tick_resume = set_state_shutdown; evt->features = CLOCK_EVT_FEAT_PERIODIC | CLOCK_EVT_FEAT_ONESHOT; - evt->rating = 450; + evt->rating = 500; exynos4_mct_write(TICK_BASE_CNT, mevt->base + MCT_L_TCNTB_OFFSET); diff --git a/include/linux/cpuhotplug.h b/include/linux/cpuhotplug.h index fd586d0301e7..bdd544f21102 100644 --- a/include/linux/cpuhotplug.h +++ b/include/linux/cpuhotplug.h @@ -115,10 +115,10 @@ enum cpuhp_state { CPUHP_AP_PERF_ARM_ACPI_STARTING, CPUHP_AP_PERF_ARM_STARTING, CPUHP_AP_ARM_L2X0_STARTING, + CPUHP_AP_EXYNOS4_MCT_TIMER_STARTING, CPUHP_AP_ARM_ARCH_TIMER_STARTING, CPUHP_AP_ARM_GLOBAL_TIMER_STARTING, CPUHP_AP_JCORE_TIMER_STARTING, - CPUHP_AP_EXYNOS4_MCT_TIMER_STARTING, CPUHP_AP_ARM_TWD_STARTING, CPUHP_AP_QCOM_TIMER_STARTING, CPUHP_AP_ARMADA_TIMER_STARTING,