Received: by 2002:a05:6a10:c604:0:0:0:0 with SMTP id y4csp2115955pxt; Sun, 8 Aug 2021 12:06:47 -0700 (PDT) X-Google-Smtp-Source: ABdhPJx5Pc+xaKDCeGLH1YLuDcnFe4a9MSQCFQIGz4zste9j0xVVMBpa+oZ+9UbkhzpGkwq2KDFf X-Received: by 2002:a17:906:504:: with SMTP id j4mr18812097eja.245.1628449607594; Sun, 08 Aug 2021 12:06:47 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1628449607; cv=none; d=google.com; s=arc-20160816; b=fEpTrdp5iPkP71GeZv4WxMzNpk/nixI1frhWSUkMqubjKoLYcybjqKJOBGr2Tx5NQd HUe3Cv3mpqKW0n9wYXY9oe8l6uYRjFhlK7GxJ0BIm80KoGfH1YShrj3y2dzPEa+uwGfZ Aq0UXhlMFmGA9JZvLdVMXWDQU9OQUazYNw//DfE0FAnBS8XmGtM2A5feMpwXC1hwTilo 5EWlfX4cBOQdrK6NRfyu+QHgX+SFXwdHfXXbLbEAE72pBJBda+tu5KehIEc3GTtjpeZM 6Ixeypr26s7rlqUoXiQh2QYBhj998PEdWJ8mYIfjgP5YpGtS0v4exQRNl2UhI42c1tdL zDZw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:cc:to:subject:message-id:date:from:in-reply-to :references:mime-version:dkim-signature; bh=PjnX2TEMPAPiZ/kp81d0YhSgmUwTPzKGuUQM+YmXs4c=; b=YcQUZGFtk6WUnDGhaf7UCV4tB2/p8t1lYTKoQ+ibnZTsxUj3yfsA3NRpbyPbGkP+9u p23RmcSpkcFiTLDtQdiyjur73vNgs7i2u1XjXi0pESiGVOSpFEKfdgYV528rSreK55xy daZhx/ZoauAGw43oTNC9YcTmPiFDzf1Y1SHvDmTxXapj7+JQtlte2I6sh2cchm3aYEFp FW6HS3OhJ86KNVgXMwI8KMrLjevadG0mbgKhZduOOoia/WyBsPtzgTSLkBZadQ3v+8A6 jf2uLZ+FYSBX8DdpJNDGaXtFvhgLP8xq8g3B7gZ89Lo0woobBnfgrZJKSvKvXVeVldYj lfNA== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@google.com header.s=20161025 header.b=JRpXYGUv; 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; dmarc=pass (p=REJECT sp=REJECT dis=NONE) header.from=google.com Return-Path: Received: from vger.kernel.org (vger.kernel.org. [23.128.96.18]) by mx.google.com with ESMTP id a8si14814356ejs.201.2021.08.08.12.06.25; Sun, 08 Aug 2021 12:06:47 -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; dkim=pass header.i=@google.com header.s=20161025 header.b=JRpXYGUv; 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; dmarc=pass (p=REJECT sp=REJECT dis=NONE) header.from=google.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S232457AbhHHTBp (ORCPT + 99 others); Sun, 8 Aug 2021 15:01:45 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:38834 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S232284AbhHHTBo (ORCPT ); Sun, 8 Aug 2021 15:01:44 -0400 Received: from mail-lj1-x22a.google.com (mail-lj1-x22a.google.com [IPv6:2a00:1450:4864:20::22a]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 17C18C061760 for ; Sun, 8 Aug 2021 12:01:24 -0700 (PDT) Received: by mail-lj1-x22a.google.com with SMTP id h11so5296928ljo.12 for ; Sun, 08 Aug 2021 12:01:24 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=20161025; h=mime-version:references:in-reply-to:from:date:message-id:subject:to :cc; bh=PjnX2TEMPAPiZ/kp81d0YhSgmUwTPzKGuUQM+YmXs4c=; b=JRpXYGUv2G/4ssKII2wJcey4sbrhrFwvQDc2CpNEI3hsE14FBi43tpu/MKvyyPiXxX c0t/C3ROjaZsz+7Lck4xhjiD9o4xAqQtijKSnxuFW2YbUFoyjt0GvUoNM4zWNmK+ETTF AqP6yojgSdFv+8C4QfYzcB+XUK86xx9ERciBYNmSxjJb3KPLgVr6LO2egxKReJALYl6A y2RZS8ZtO2IW5oAxVchiVV36oY8I2Ra3JMZ8uRGcDpqaW3z7SCSEzxOL7W6nQVk9TTHU AGMZguzrOBV+LAb+8qPFjHlXTBJh2W/7QBwC2X6h9PvgUj6KKWtgcHlD4pW90Ps8KGNM waoA== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:mime-version:references:in-reply-to:from:date :message-id:subject:to:cc; bh=PjnX2TEMPAPiZ/kp81d0YhSgmUwTPzKGuUQM+YmXs4c=; b=LXlkmTZpP5jVNaTEF6LKMHh8uZMIK1ZKNTvS25Eq+RYNBpzapMGt2VbE9znyeB7amW oPMk+mlEfEcTh/BxD20VVNLQmWubdNgmRq7cMIKx8mmCTDyZr8DUZWkGWBk28PWRBrAz qFnAP6GzxopC547ffEihHCiIJJ1MiifQmpZoCQ3MHI5O2MniQiHA1TjIonwGFXzW49WG CzRJmeD1JgdCq4gjJhUVMNrhDEfRStAgPMJ9WIerP6G9Gc6irbeQDnZsGQw2j0JOFmXg 1ehNa7Lv36DToTU8CXegryCIPL7KduR8n4wlMTSVC7dfwRjyTL3wgh5SI2gtelkZcuE0 trQg== X-Gm-Message-State: AOAM532E9cgKhqCGgMUMBUVW3pyZRpe5gBZgeRYVLWf7La6TZMSkddDw d9ve2AAd7baBjXX6e5DbsYQluXnD9a3ZLnHXKksuFg== X-Received: by 2002:a05:651c:1119:: with SMTP id d25mr7173477ljo.129.1628449282038; Sun, 08 Aug 2021 12:01:22 -0700 (PDT) MIME-Version: 1.0 References: <20210807191428.3488948-1-oupton@google.com> <87lf5c1aox.wl-maz@kernel.org> In-Reply-To: <87lf5c1aox.wl-maz@kernel.org> From: Oliver Upton Date: Sun, 8 Aug 2021 12:01:10 -0700 Message-ID: Subject: Re: [PATCH v2] clocksource/arm_arch_timer: Fix masking for high freq counters To: Marc Zyngier Cc: Linus Walleij , Linux ARM , linux-kernel , Mark Rutland , Daniel Lezcano , Thomas Gleixner , Peter Shier , Raghavendra Rao Ananta , Ricardo Koller Content-Type: text/plain; charset="UTF-8" Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Sun, Aug 8, 2021 at 3:40 AM Marc Zyngier wrote: > > On Sun, 08 Aug 2021 02:14:35 +0100, > Oliver Upton wrote: > > > The only other sane idea that I could come up with is providing this > > information to the kernel through DT, although that would leave ACPI > > systems behind. > > It also has the disadvantage that a large number of DT timer nodes are > a mess of cargo-culted, copy-pasted idioms, and that adding another > property would only make it worse. Agreed, this does seem like the best solution, short of the architecture actually providing something to determine the counter width. On that note, I wonder how (if ever) we will be able to move away from unnecessarily masking a 64 bit counter, i.e. a v8.6 or above implementation. With this patch, one such counter would wrap after 36.56 years, short of the 40 year guarantee we have from the architecture for < v8.6 implementations. Getting it to 64 bits would squarely make it someone else's problem ~585 years from now :) -- Thanks, Oliver