From patchwork Thu Nov 24 14:16:18 2022 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Patchwork-Submitter: tip-bot2 for Thomas Gleixner X-Patchwork-Id: 25580 Return-Path: Delivered-To: ouuuleilei@gmail.com Received: by 2002:adf:f944:0:0:0:0:0 with SMTP id q4csp3426638wrr; Thu, 24 Nov 2022 06:22:33 -0800 (PST) X-Google-Smtp-Source: AA0mqf6DYcDSzJGBpfEkKdgFSjtJN8A8EDwaKgT3/3Dq0bDm8LY9EC3PTrOie9KWPDMWmzKRaD/m X-Received: by 2002:a17:90a:7344:b0:218:a049:cc0f with SMTP id j4-20020a17090a734400b00218a049cc0fmr23887694pjs.176.1669299753580; Thu, 24 Nov 2022 06:22:33 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1669299753; cv=none; d=google.com; s=arc-20160816; b=vl5+1rvHi1HdoF219qkL4T8DqEMAbXPeqJR+gLRPFr4nSBz6pTXINs4dUr43adzUhN LaJx1mTfU1LDtg0Z0Gm1mEqRgLqQAw5u3jj7CxtFe3WLDtuJEnAq1CQ+IhI1xdL4boON B2mQFWvZXMGP3TNLs7/9sTfLgib4/epoeKTb3ZqjIUGZYTFfetGvzqx/kD4Y9a5DzDeA d8pLqmncMI5Mym0ktNGn0RfV1/ZGZ2Pqe4ZqmAU6mgxS4KA0GsmRSrmZWwzH+D6KVXkG GMZhmx8x8V6ZEJlc81kMC+O6YZJ9eiW1jbk3U8fX1o1ABct179TGgvXtZfvO1cXbF09P 4lkQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:content-transfer-encoding:robot-unsubscribe :robot-id:message-id:mime-version:references:in-reply-to:cc:subject :to:reply-to:sender:from:dkim-signature:dkim-signature:date; bh=ifGPZWbO1ewlaKX2cZyR+nYcHOFN7mKdQoTquUGhQfA=; b=l6vtYjdF4mOMrnpFwB3kfLkkZ5pWp33ngk4hoYSVIZoxH8FNO0bvgJ26ndnXUNH0uJ pvuXQiFZKyBt1aTNaUdXCInB9lz6V3mUiU6+Gm9dz4oz7lBhiMAv6soxrh8Yru/hi7ww fM7We3yJlm+38+UwKiXOnfkeOO6+3f85XfYXMixGNdgmONDMBNdHduhU7Gm7/VN5wBbH 6AxoG0M8Jq/9/qiQQzK4nrijfSNEUDz0lYurgodN2g3rSPddRPsjJgJWmjXlFbJ8ODCs RcHg8p1JBecwThOjnbgK6wTGqTq2ASpS0copjoam+dOKYP8BR6rmyYBGlC6NP1tvJxom bRVA== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@linutronix.de header.s=2020 header.b=1Lvavnnm; dkim=neutral (no key) header.i=@linutronix.de; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=QUARANTINE dis=NONE) header.from=linutronix.de Received: from out1.vger.email (out1.vger.email. [2620:137:e000::1:20]) by mx.google.com with ESMTP id g24-20020a633758000000b00476e21bc1bdsi379243pgn.162.2022.11.24.06.22.19; Thu, 24 Nov 2022 06:22:33 -0800 (PST) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) client-ip=2620:137:e000::1:20; Authentication-Results: mx.google.com; dkim=pass header.i=@linutronix.de header.s=2020 header.b=1Lvavnnm; dkim=neutral (no key) header.i=@linutronix.de; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=QUARANTINE dis=NONE) header.from=linutronix.de Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S229798AbiKXORV (ORCPT + 99 others); Thu, 24 Nov 2022 09:17:21 -0500 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:46058 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S230390AbiKXORA (ORCPT ); Thu, 24 Nov 2022 09:17:00 -0500 Received: from galois.linutronix.de (Galois.linutronix.de [IPv6:2a0a:51c0:0:12e:550::1]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 06A2A10958C; Thu, 24 Nov 2022 06:16:27 -0800 (PST) Date: Thu, 24 Nov 2022 14:16:18 -0000 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linutronix.de; s=2020; t=1669299380; h=from:from:sender:sender:reply-to:reply-to:subject:subject:date:date: message-id:message-id:to:to:cc:cc:mime-version:mime-version: content-type:content-type: content-transfer-encoding:content-transfer-encoding: in-reply-to:in-reply-to:references:references; bh=ifGPZWbO1ewlaKX2cZyR+nYcHOFN7mKdQoTquUGhQfA=; b=1LvavnnmZtgr37icAv8wtiRncR7+K94N2iq1KPl4D5hjo+K58E5I/ULSHOB3PwcnjyKAfQ e8c/irey6AmzJP69VyKNXW7IyU14ckzMTF6yQLp608GkuudFpBLudlb78dhihEKXPSQcxd Od7VPWeQLkN9hnD70oYNbKbBsVbKuHcG5nTMRKHCZMwLSnH5BqPcsntJ6xkaAZh7Yc/ABz npwRQUoIaCuWfiVnt7Jd+yjETPtO/lxr8a5s0+yqKzCh7YpaZtigDV3pHFPHRvInE81Pzo Bg3x8HBF/VXbUh045wmXFST8bgVUrbQeNHc3S+R1lOWZ1hq3C53mtbvNnRTzeg== DKIM-Signature: v=1; a=ed25519-sha256; c=relaxed/relaxed; d=linutronix.de; s=2020e; t=1669299380; h=from:from:sender:sender:reply-to:reply-to:subject:subject:date:date: message-id:message-id:to:to:cc:cc:mime-version:mime-version: content-type:content-type: content-transfer-encoding:content-transfer-encoding: in-reply-to:in-reply-to:references:references; bh=ifGPZWbO1ewlaKX2cZyR+nYcHOFN7mKdQoTquUGhQfA=; b=f5pIUKmnQpXG2temsRv7TYzeiZQ14aYyQmp2zwZ3W2mcqnYAYQjtxmYHdjV+oS0nqY6GoY 9STy8iU4phyvicDQ== From: "tip-bot2 for Thomas Gleixner" Sender: tip-bot2@linutronix.de Reply-to: linux-kernel@vger.kernel.org To: linux-tip-commits@vger.kernel.org Subject: [tip: timers/core] Documentation: Remove bogus claim about del_timer_sync() Cc: Thomas Gleixner , Jacob Keller , "Anna-Maria Behnsen" , x86@kernel.org, linux-kernel@vger.kernel.org In-Reply-To: <20221123201624.452282769@linutronix.de> References: <20221123201624.452282769@linutronix.de> MIME-Version: 1.0 Message-ID: <166929937874.4906.5556735136767567261.tip-bot2@tip-bot2> Robot-ID: Robot-Unsubscribe: Contact to get blacklisted from these emails X-Spam-Status: No, score=-4.4 required=5.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID,DKIM_VALID_AU,DKIM_VALID_EF,RCVD_IN_DNSWL_MED,SPF_HELO_NONE, SPF_PASS autolearn=ham autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on lindbergh.monkeyblade.net Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org X-getmail-retrieved-from-mailbox: =?utf-8?q?INBOX?= X-GMAIL-THRID: =?utf-8?q?1750319636835154798?= X-GMAIL-MSGID: =?utf-8?q?1750387658404223500?= The following commit has been merged into the timers/core branch of tip: Commit-ID: b0b0aa5d858d4d2fe39a5e4486e0550e858108f6 Gitweb: https://git.kernel.org/tip/b0b0aa5d858d4d2fe39a5e4486e0550e858108f6 Author: Thomas Gleixner AuthorDate: Wed, 23 Nov 2022 21:18:31 +01:00 Committer: Thomas Gleixner CommitterDate: Thu, 24 Nov 2022 15:09:10 +01:00 Documentation: Remove bogus claim about del_timer_sync() del_timer_sync() does not return the number of times it tried to delete the timer which rearms itself. It's clearly documented: The function returns whether it has deactivated a pending timer or not. This part of the documentation is from 2003 where del_timer_sync() really returned the number of deletion attempts for unknown reasons. The code was rewritten in 2005, but the documentation was not updated. Signed-off-by: Thomas Gleixner Reviewed-by: Jacob Keller Reviewed-by: Anna-Maria Behnsen Link: https://lore.kernel.org/r/20221123201624.452282769@linutronix.de --- Documentation/kernel-hacking/locking.rst | 3 +-- Documentation/translations/it_IT/kernel-hacking/locking.rst | 4 +--- 2 files changed, 2 insertions(+), 5 deletions(-) diff --git a/Documentation/kernel-hacking/locking.rst b/Documentation/kernel-hacking/locking.rst index 6805ae6..b26e4a3 100644 --- a/Documentation/kernel-hacking/locking.rst +++ b/Documentation/kernel-hacking/locking.rst @@ -1006,8 +1006,7 @@ Another common problem is deleting timers which restart themselves (by calling add_timer() at the end of their timer function). Because this is a fairly common case which is prone to races, you should use del_timer_sync() (``include/linux/timer.h``) to -handle this case. It returns the number of times the timer had to be -deleted before we finally stopped it from adding itself back in. +handle this case. Locking Speed ============= diff --git a/Documentation/translations/it_IT/kernel-hacking/locking.rst b/Documentation/translations/it_IT/kernel-hacking/locking.rst index 51af37f..eddfba8 100644 --- a/Documentation/translations/it_IT/kernel-hacking/locking.rst +++ b/Documentation/translations/it_IT/kernel-hacking/locking.rst @@ -1027,9 +1027,7 @@ Un altro problema è l'eliminazione dei temporizzatori che si riavviano da soli (chiamando add_timer() alla fine della loro esecuzione). Dato che questo è un problema abbastanza comune con una propensione alle corse critiche, dovreste usare del_timer_sync() -(``include/linux/timer.h``) per gestire questo caso. Questa ritorna il -numero di volte che il temporizzatore è stato interrotto prima che -fosse in grado di fermarlo senza che si riavviasse. +(``include/linux/timer.h``) per gestire questo caso. Velocità della sincronizzazione ===============================