Received: by 2002:a25:1104:0:0:0:0:0 with SMTP id 4csp92089ybr; Fri, 22 May 2020 01:40:29 -0700 (PDT) X-Google-Smtp-Source: ABdhPJyQsQnf4WBNNaYOPnveidgQP57IwgnG7BWUgkBhSqA0CzpctKAotpkn1vE06jHzxgxw8s0M X-Received: by 2002:a17:906:a441:: with SMTP id cb1mr7093778ejb.45.1590136829166; Fri, 22 May 2020 01:40:29 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1590136829; cv=none; d=google.com; s=arc-20160816; b=yeXDEz8H43FqKJDc/ey9aDznOztdQnDRgvei/aJUD14WsnJUs1+l28GluOIBIxNRvS yPkdqgo+vtdFj+SGgAWczXCSZJOFUW2+M9E7uT9lkEa7pUd9vYM4L9d0CN4EJZCHSiW+ fmLVSVTiH7uFMRVsXtaDSTM0IEfDKeuqgh9fWfck3LwPTIIcVeVnaOPbVdbYtFTHkojd CNuwGjs2u8pQNM9wsfveWURXnBVFLzGR+0dkVAWJnTc1Rh5Z5lHH26IQpQRkT3Dd2xWn +WsD+eB7KGAi4Z4uwirL2IxkX2YgUr9z30D13oVxArWF60hJ6SicNJoZ7FpuN2KkD+nw Gg2w== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:references:in-reply-to:message-id:date :subject:cc:to:from; bh=gSbtXwuWdTOVwVTEXnSsz2LQPPFt4aa/jt8BAE4as7o=; b=Utna/9arWqFyrbij4LO2BAJufIKEDXgTIJbzrePfM8Fgi7rAkitjXNNFKCmeAGE+Z8 ng2faz0rizrQR8/G+eH8BOIAXtQVj4tHIoQtY0ryVe7vkV6dAptoV4O6RW7GySzntr5B NVXo7LXzFy3QVkvuyCyrK7GYJHzXxgq7W5uA4Ak5yg6KdOFahoQxLM+7PFngb+Cp8KU7 nmfGx8cZf0matDeVQGV08dizg6A0v1R7gvDrSAhvQDbrsgPEwQE0VWp2JHx/Y52MGqCQ SrbbxAuBCdLD+SpyhWDEfy7WrgYgEmYmQXc2049fjrYpKrpcpfI35X5KvKl2YXGpiB4b jQvQ== ARC-Authentication-Results: i=1; mx.google.com; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [23.128.96.18]) by mx.google.com with ESMTP id rk18si4519488ejb.715.2020.05.22.01.40.06; Fri, 22 May 2020 01:40:29 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) client-ip=23.128.96.18; Authentication-Results: mx.google.com; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1729847AbgEVIiV (ORCPT + 99 others); Fri, 22 May 2020 04:38:21 -0400 Received: from foss.arm.com ([217.140.110.172]:59398 "EHLO foss.arm.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1729072AbgEVIiS (ORCPT ); Fri, 22 May 2020 04:38:18 -0400 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 4C36E1042; Fri, 22 May 2020 01:38:18 -0700 (PDT) Received: from entos-d05.shanghai.arm.com (entos-d05.shanghai.arm.com [10.169.40.35]) by usa-sjc-imap-foss1.foss.arm.com (Postfix) with ESMTPA id 9F60C3F52E; Fri, 22 May 2020 01:38:12 -0700 (PDT) From: Jianyong Wu To: netdev@vger.kernel.org, yangbo.lu@nxp.com, john.stultz@linaro.org, tglx@linutronix.de, pbonzini@redhat.com, sean.j.christopherson@intel.com, maz@kernel.org, richardcochran@gmail.com, Mark.Rutland@arm.com, will@kernel.org, suzuki.poulose@arm.com, steven.price@arm.com Cc: linux-kernel@vger.kernel.org, linux-arm-kernel@lists.infradead.org, kvmarm@lists.cs.columbia.edu, kvm@vger.kernel.org, Steve.Capper@arm.com, Kaly.Xin@arm.com, justin.he@arm.com, Wei.Chen@arm.com, jianyong.wu@arm.com, nd@arm.com Subject: [RFC PATCH v12 06/11] clocksource: Add clocksource id for arm arch counter Date: Fri, 22 May 2020 16:37:19 +0800 Message-Id: <20200522083724.38182-7-jianyong.wu@arm.com> X-Mailer: git-send-email 2.17.1 In-Reply-To: <20200522083724.38182-1-jianyong.wu@arm.com> References: <20200522083724.38182-1-jianyong.wu@arm.com> Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Add clocksource id for arm arch counter to let it be identified easily and elegantly in ptp_kvm implementation for arm. Signed-off-by: Jianyong Wu --- drivers/clocksource/arm_arch_timer.c | 2 ++ include/linux/clocksource_ids.h | 1 + 2 files changed, 3 insertions(+) diff --git a/drivers/clocksource/arm_arch_timer.c b/drivers/clocksource/arm_arch_timer.c index 2204a444e801..0f44f296ed17 100644 --- a/drivers/clocksource/arm_arch_timer.c +++ b/drivers/clocksource/arm_arch_timer.c @@ -16,6 +16,7 @@ #include #include #include +#include #include #include #include @@ -191,6 +192,7 @@ static u64 arch_counter_read_cc(const struct cyclecounter *cc) static struct clocksource clocksource_counter = { .name = "arch_sys_counter", + .id = CSID_ARM_ARCH_COUNTER, .rating = 400, .read = arch_counter_read, .mask = CLOCKSOURCE_MASK(56), diff --git a/include/linux/clocksource_ids.h b/include/linux/clocksource_ids.h index 4d8e19e05328..16775d7d8f8d 100644 --- a/include/linux/clocksource_ids.h +++ b/include/linux/clocksource_ids.h @@ -5,6 +5,7 @@ /* Enum to give clocksources a unique identifier */ enum clocksource_ids { CSID_GENERIC = 0, + CSID_ARM_ARCH_COUNTER, CSID_MAX, }; -- 2.17.1