Received: by 2002:a05:6358:bb9e:b0:b9:5105:a5b4 with SMTP id df30csp5134533rwb; Tue, 6 Sep 2022 19:54:07 -0700 (PDT) X-Google-Smtp-Source: AA6agR5Q++fMEssRfuMPucXeDInuyI7io/oxrzf4sLEOJxnLjPIZQAP4+4KFoHovWPSQjW50Gyky X-Received: by 2002:a05:6402:3507:b0:448:b672:55ee with SMTP id b7-20020a056402350700b00448b67255eemr1252138edd.107.1662519246762; Tue, 06 Sep 2022 19:54:06 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1662519246; cv=none; d=google.com; s=arc-20160816; b=qgNXlzmmnWTFRy2GJUFRXob6KRLVh0QY8eKdc7XtRszS25b6AX4c0p7ljOu9ZnVKpm /wq+8Fg3OpHEqv/6obxUDkRTkLY6By7HBqfdApG79Uj6dmEukiNTRK/Av4QVygYAxx/N W/eRf/k95FipdNsR4qTFWdcLeDLxPOpEKQ7M+lh767Gcb8y7ueV9CwHXn9O5pQk8QDy2 iLIfYBwdGnwD9k6Jdg2ZGhCOvuKj7lm5q2RM5e9S5ruMkXR1/RSPuHw9VsUtVoPcqtCL e6NlxWhceEXPnjzSZktF9gUUoqgytXAjD+zlrM81DtZKWUqpDg/qGUXm4zvVyP2IZGL4 IoiQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:content-transfer-encoding:in-reply-to:from :references:cc:to:content-language:subject:user-agent:mime-version :date:message-id:dkim-signature; bh=HV15brfmijT3wQpdJQzUr20Idn6RQgfVceZTRDNZ2RA=; b=nJJcDs3QpXxED1hUYRdksw1XPZFbYyVSbTdpT53qhMHOzz39MDPVX+XwvIMtVvrCP9 ILJPw1VXuN0U+EVnfxtYvh7UiH1UFgaFjDYEIMRYHVuSxAN2oi3fLA56rAzKA8IDotH6 o8Fx05vl/M+OCkoSqBMzTLrLsBqnG0O85fgBaSA8oS+Zx7koNXh2t4/nIEE0rCFVMxD+ xXJVz1djYxkc90SNqf71+UiHxHKQsyiikICgSkOE/DBE9wG6+P4r83knSGA47/3ZihU/ leRrrNXtp3fQghT2unIsbwjfTZ9ECFxnZtswJYqjqe21d8HrSX9OAKjNOUWycp5ZAZ5C Tdzg== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@joelfernandes.org header.s=google header.b=xSduQWMC; 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 Return-Path: Received: from out1.vger.email (out1.vger.email. [2620:137:e000::1:20]) by mx.google.com with ESMTP id hr12-20020a1709073f8c00b00730c9a41812si11765340ejc.723.2022.09.06.19.53.41; Tue, 06 Sep 2022 19:54:06 -0700 (PDT) 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=@joelfernandes.org header.s=google header.b=xSduQWMC; 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 Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S229876AbiIGCn1 (ORCPT + 99 others); Tue, 6 Sep 2022 22:43:27 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:42128 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S229862AbiIGCnZ (ORCPT ); Tue, 6 Sep 2022 22:43:25 -0400 Received: from mail-qt1-x82c.google.com (mail-qt1-x82c.google.com [IPv6:2607:f8b0:4864:20::82c]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id D6E097B28F for ; Tue, 6 Sep 2022 19:43:24 -0700 (PDT) Received: by mail-qt1-x82c.google.com with SMTP id c20so9483011qtw.8 for ; Tue, 06 Sep 2022 19:43:24 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=joelfernandes.org; s=google; h=content-transfer-encoding:in-reply-to:from:references:cc:to :content-language:subject:user-agent:mime-version:date:message-id :from:to:cc:subject:date; bh=HV15brfmijT3wQpdJQzUr20Idn6RQgfVceZTRDNZ2RA=; b=xSduQWMCYeluZayNSc/ZHmsirDlb9V9NS3hqmtpoPmuCjOI6hsnymMlm4dMQTQDGPD J4T0+VqM2skudfqpfnDEGffA6LwWX9ZtfksqaBf8mewmSP1nOEi35pcZO/f3PgmlKhHl hw2/IvrXMUi65QTYz6e377fymvUm0PBmBkNQk= X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; h=content-transfer-encoding:in-reply-to:from:references:cc:to :content-language:subject:user-agent:mime-version:date:message-id :x-gm-message-state:from:to:cc:subject:date; bh=HV15brfmijT3wQpdJQzUr20Idn6RQgfVceZTRDNZ2RA=; b=FHp577SCLQvBpirtENWtTN687ytqFmVOz83t/YaaBz3/+rzADpRY7P8lKyUFTkVL8l 7x/9NOPkmcfM9AiUFsbV9cJyI1XefCZqBQOaG2HBBSpJRTlUe9JUuDpyhPella5gVTD1 AY6ha9++7G24/0vMSksgeSYKb0Tez66MASdOvIpcddknYDvN9h8Mf0oVfzoBwIu38qe/ Fpy/3ppAL004db7PQT19X26/WQyXFW2b9cd4QZwuS9FGmwBcYhlK0e6PJleGR2+rZIvF YhRc+OtDxminFJFcNq0yObH5F6FpijtqS37LgXdwEhaT9KkLjCsqCVm4zbo2o94UM5QN pkgA== X-Gm-Message-State: ACgBeo2IMCJjbmfzJBgglC8ufrQZ7UpL5ndE/MBGt6RzPmq/5w3ZSEVB 59ogdKPC0z4Bs2AAWALOP4je/Q== X-Received: by 2002:ac8:5a0d:0:b0:344:de4f:b187 with SMTP id n13-20020ac85a0d000000b00344de4fb187mr1431577qta.136.1662518604011; Tue, 06 Sep 2022 19:43:24 -0700 (PDT) Received: from [10.0.0.40] (c-73-148-104-166.hsd1.va.comcast.net. [73.148.104.166]) by smtp.gmail.com with ESMTPSA id bb9-20020a05622a1b0900b00354e5b8bba3sm6629847qtb.29.2022.09.06.19.43.23 (version=TLS1_3 cipher=TLS_AES_128_GCM_SHA256 bits=128/128); Tue, 06 Sep 2022 19:43:23 -0700 (PDT) Message-ID: Date: Tue, 6 Sep 2022 22:43:22 -0400 MIME-Version: 1.0 User-Agent: Mozilla/5.0 (Windows NT 10.0; Win64; x64; rv:102.0) Gecko/20100101 Thunderbird/102.2.1 Subject: Re: [PATCH v5 04/18] rcu: Fix late wakeup when flush of bypass cblist happens Content-Language: en-US To: Frederic Weisbecker Cc: rcu@vger.kernel.org, linux-kernel@vger.kernel.org, rushikesh.s.kadam@intel.com, urezki@gmail.com, neeraj.iitr10@gmail.com, paulmck@kernel.org, rostedt@goodmis.org, vineeth@bitbyteword.org, boqun.feng@gmail.com References: <20220901221720.1105021-1-joel@joelfernandes.org> <20220901221720.1105021-5-joel@joelfernandes.org> <20220906094852.GA174244@lothringen> From: Joel Fernandes In-Reply-To: <20220906094852.GA174244@lothringen> Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 7bit X-Spam-Status: No, score=-3.9 required=5.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID,DKIM_VALID_AU,DKIM_VALID_EF,NICE_REPLY_A,RCVD_IN_DNSWL_NONE, SPF_HELO_NONE,SPF_PASS,T_SCC_BODY_TEXT_LINE autolearn=unavailable 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 On 9/6/2022 5:48 AM, Frederic Weisbecker wrote: >> } >> - rcu_nocb_unlock_irqrestore(rdp, flags); >> + >> + // The flush succeeded and we moved CBs into the ->cblist. >> + // However, the bypass timer might still be running. Wakeup the > That part of the comment mentioning the bypass timer looks strange... > > >> + // GP thread by calling a helper with was_all_done set so that >> + // wake up happens (needed if main CB list was empty before). > How about: > > // The flush succeeded and we moved CBs into the regular list. > // Don't wait for the wake up timer as it may be too far ahead. > // Wake up now GP thread instead if the cblist was empty > > Thanks. > > Other than that the patch looks good, thanks! > I updated it accordingly and will send it for next revision, thank you! - Joel