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 vger.kernel.org (vger.kernel.org [23.128.96.18]) by smtp.lore.kernel.org (Postfix) with ESMTP id 0615CC0015E for ; Thu, 29 Jun 2023 18:44:16 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S232865AbjF2SoO (ORCPT ); Thu, 29 Jun 2023 14:44:14 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:57694 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S232786AbjF2Sn5 (ORCPT ); Thu, 29 Jun 2023 14:43:57 -0400 Received: from galois.linutronix.de (Galois.linutronix.de [IPv6:2a0a:51c0:0:12e:550::1]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 4881A2D55 for ; Thu, 29 Jun 2023 11:43:56 -0700 (PDT) From: Thomas Gleixner DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linutronix.de; s=2020; t=1688064234; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:cc:mime-version:mime-version:content-type:content-type: in-reply-to:in-reply-to:references:references; bh=6C/4O6IMGQUkL614VBtPLgXvHc0T28BWHO32tO50Ymk=; b=KiO0NgWW8uR98f2mOLYwWVmqt8zvXtXXlnU/8uxNNvbKQ54r8eRRDsVGUpPTfsyYFop+5H LcRVweK62Z7MuGHbE1PdLj/X/LNxM9gQ950CsRJjuXPNvUVdlhaSZ54m6go1o5dqifZjN7 WJkO3zw7tSUVPru/tEID0LnGS/FXn8yde+TCdon70KPSlW856tzJeSyZzMI+1DHD+HtZzI nr3adWMRWb1mtxGSM2cAkMmugN3oiiJBN4nn5PlvEAFjPqQ3uIrQN4TcFcPIzWcQUlojwA DtdwPN0xrcSVdyhmq2TIEbzHiJhN/mEB24IzjU64BZU6yRNfxjgVjqktA4yk+w== DKIM-Signature: v=1; a=ed25519-sha256; c=relaxed/relaxed; d=linutronix.de; s=2020e; t=1688064234; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:cc:mime-version:mime-version:content-type:content-type: in-reply-to:in-reply-to:references:references; bh=6C/4O6IMGQUkL614VBtPLgXvHc0T28BWHO32tO50Ymk=; b=pg0yRGlXFPZr3rSZQsAOOSS/CRnGJFi3pQj8wDhb+kKJCjAIP1Nzqvu7QbO8QIOaX4tM83 mKl9tNaFZ3YqMMBg== To: Frederic Weisbecker Cc: LKML , Anna-Maria Behnsen , John Stultz , Peter Zijlstra , Ingo Molnar , Stephen Boyd , Eric Biederman , Oleg Nesterov Subject: Re: [patch 12/45] posix-cpu-timers: Simplify posix_cpu_timer_set() In-Reply-To: References: <20230606132949.068951363@linutronix.de> <20230606142031.705286109@linutronix.de> Date: Thu, 29 Jun 2023 20:43:54 +0200 Message-ID: <87y1k2153p.ffs@tglx> MIME-Version: 1.0 Content-Type: text/plain Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Tue, Jun 27 2023 at 12:51, Frederic Weisbecker wrote: > On Tue, Jun 06, 2023 at 04:37:37PM +0200, Thomas Gleixner wrote: >> Avoid the late sighand lock/unlock dance when a timer is not armed to >> enforce reevaluation of the timer base so that the process wide CPU timer >> sampling can be disabled. >> + * SIGEV_NONE timers are never armed. In case the timer is not >> + * armed, enforce the reevaluation of the timer base so that the >> + * process wide cputime counter can be disabled eventually. >> */ >> if (!sigev_none && new_expires && now < new_expires) >> arm_timer(timer, p); >> + else >> + trigger_base_recalc_expires(timer, p); > > We don't need a recalc if sigev_none, right? Correct.