Received: by 2002:a05:6a10:6d10:0:0:0:0 with SMTP id gq16csp1028361pxb; Fri, 15 Apr 2022 18:52:22 -0700 (PDT) X-Google-Smtp-Source: ABdhPJyMgEao/wERNxr+lzAkKJuW4kURNGC38rLJJpVbUXdIlm/AiOCrR3yX4EXvlWZpZXQGCGGH X-Received: by 2002:a17:90a:430d:b0:1bc:f340:8096 with SMTP id q13-20020a17090a430d00b001bcf3408096mr1670095pjg.93.1650073941853; Fri, 15 Apr 2022 18:52:21 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1650073941; cv=none; d=google.com; s=arc-20160816; b=VOvunDyDxRNXjiINEDLFFQ8OWfXjPBERxEAiq8Bc5Ouu9CjG2WzV2WMRRWZhsYGPyq KWW2cCwGd/p/xg0cVuMmrBalPHx73y6aClRriaom0IKWMTz0yeUZkhzNwtIVZGjQ6yXF TvR+gjgXsGi4l+6DV3sUK20RQKAV9eumGZU48l3C9Kn7bx9lsyAnjsW7d0q1fyhr4I74 VBQnXrQMN000/+h0129eist/NnPt20Iffi/2WMltlNrJrytSn/J9tEV7sa732nJShK7L DlZuC6hlVD6sl0qbQPV4g+ED4ZPxKU9yiLe5KxL4/Jk9Wteovrmv1JXpaiZoKb6J4P16 FgEw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:message-id:date:content-id:mime-version:subject :cc:to:references:in-reply-to:from:organization:dkim-signature; bh=mOtKwh35pM24cRsOHUqNHS8xyukFMTImg3mtxCkuSPU=; b=wiZvBYt3UHO0FdnbH00BUyg1vKgVjduqScS+UacYBeMTEfqi6/rnuJ4E+taPVkIzPz 93Wlgo860Qm1vp8Eg+3cVSaXZ58My/seeJGMoPRH0ViwXQg/wy/APUON4IHUKrXfnVWp SEN/vN3+Bsid6J7UbZgBBExnLYEogsg9YPWd/GyTQXdo1nx2Kqx3V/Rk9YS8GA51mH11 r9uleMOKnfhfeepFM3fPyu6ug9zFOIX2ctjPasBE+/PXHKlTKamNxm97lbazu4SkFfvt 2gg/o4E+dBmFE9wRUFRIUDU2FGgesMN4diT4PnCFbKoAZ/4sa0fNWeJIvVgXT3SsG3f3 B4NQ== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@redhat.com header.s=mimecast20190719 header.b=iWpToYk0; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=redhat.com Return-Path: Received: from lindbergh.monkeyblade.net (lindbergh.monkeyblade.net. [2620:137:e000::1:18]) by mx.google.com with ESMTPS id f2-20020a63de02000000b003816043eedbsi2922540pgg.208.2022.04.15.18.52.20 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Fri, 15 Apr 2022 18:52:21 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:18 as permitted sender) client-ip=2620:137:e000::1:18; Authentication-Results: mx.google.com; dkim=pass header.i=@redhat.com header.s=mimecast20190719 header.b=iWpToYk0; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=redhat.com Received: from vger.kernel.org (vger.kernel.org [23.128.96.18]) by lindbergh.monkeyblade.net (Postfix) with ESMTP id 703AE197AD1; Fri, 15 Apr 2022 18:14:05 -0700 (PDT) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S237123AbiDMRns (ORCPT + 99 others); Wed, 13 Apr 2022 13:43:48 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:49906 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S232829AbiDMRnr (ORCPT ); Wed, 13 Apr 2022 13:43:47 -0400 Received: from us-smtp-delivery-124.mimecast.com (us-smtp-delivery-124.mimecast.com [170.10.133.124]) by lindbergh.monkeyblade.net (Postfix) with ESMTP id 649826CA47 for ; Wed, 13 Apr 2022 10:41:19 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=redhat.com; s=mimecast20190719; t=1649871678; 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=mOtKwh35pM24cRsOHUqNHS8xyukFMTImg3mtxCkuSPU=; b=iWpToYk0b7ov44UyBhypSWwmPAgd2W5nQ7lX5XpLvwn7oYgqe81J+dMht5QEK0MRg12ow/ Er9NQQQRg+Urzz3xraXrZru165p2fuH34e9vs65+HLVuij/DYHErve8DKEP8hM38MK0YiS lN5jsqimEDX095LH7KKVi665jD+62mc= Received: from mimecast-mx02.redhat.com (mx3-rdu2.redhat.com [66.187.233.73]) by relay.mimecast.com with ESMTP with STARTTLS (version=TLSv1.2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id us-mta-112-zZZBnxM1PH6p-aj--as1kQ-1; Wed, 13 Apr 2022 13:41:14 -0400 X-MC-Unique: zZZBnxM1PH6p-aj--as1kQ-1 Received: from smtp.corp.redhat.com (int-mx02.intmail.prod.int.rdu2.redhat.com [10.11.54.2]) (using TLSv1.2 with cipher AECDH-AES256-SHA (256/256 bits)) (No client certificate requested) by mimecast-mx02.redhat.com (Postfix) with ESMTPS id 572C73802AC7; Wed, 13 Apr 2022 17:41:14 +0000 (UTC) Received: from warthog.procyon.org.uk (unknown [10.33.37.45]) by smtp.corp.redhat.com (Postfix) with ESMTP id 4DD8640D282A; Wed, 13 Apr 2022 17:41:13 +0000 (UTC) Organization: Red Hat UK Ltd. Registered Address: Red Hat UK Ltd, Amberley Place, 107-111 Peascod Street, Windsor, Berkshire, SI4 1TE, United Kingdom. Registered in England and Wales under Company Registration No. 3798903 From: David Howells In-Reply-To: References: <164984498582.2000115.4023190177137486137.stgit@warthog.procyon.org.uk> To: Eric Dumazet Cc: dhowells@redhat.com, netdev@vger.kernel.org, Marc Dionne , linux-afs@lists.infradead.org, linux-kernel@vger.kernel.org Subject: Re: [PATCH net] rxrpc: Restore removed timer deletion MIME-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-ID: <2419531.1649871672.1@warthog.procyon.org.uk> Date: Wed, 13 Apr 2022 18:41:12 +0100 Message-ID: <2419532.1649871672@warthog.procyon.org.uk> X-Scanned-By: MIMEDefang 2.84 on 10.11.54.2 X-Spam-Status: No, score=-2.0 required=5.0 tests=BAYES_00,DKIMWL_WL_HIGH, DKIM_SIGNED,DKIM_VALID,DKIM_VALID_AU,HEADER_FROM_DIFFERENT_DOMAINS, MAILING_LIST_MULTI,RDNS_NONE,SPF_HELO_NONE,T_SCC_BODY_TEXT_LINE autolearn=no 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 Eric Dumazet wrote: > ok... so we have a timer and a work queue, both activating each other > in kind of a ping pong ? Yes. I want to emit regular keepalive pokes. > Any particular reason not using delayed works ? Because there's a race between starting the keepalive timer when a new peer is added and when the keepalive worker is resetting the timer for the next peer in the list. This is why I'm using timer_reduce(). delayed_work doesn't currently have such a facility. It's not simple to add because try_to_grab_pending() as called from mod_delayed_work_on() cancels the timer - which is not what I want it to do. David