Received: by 2002:a05:6358:4e97:b0:b3:742d:4702 with SMTP id ce23csp1926322rwb; Fri, 19 Aug 2022 11:50:08 -0700 (PDT) X-Google-Smtp-Source: AA6agR79rMNRv+/87KOvl+6Flpz26U7rpRmJWglHyNCuH2PlMJe3T3j7PbIEqiMFhkw3Ro0u13dl X-Received: by 2002:a17:906:6d98:b0:715:76eb:9e33 with SMTP id h24-20020a1709066d9800b0071576eb9e33mr5716904ejt.729.1660935008361; Fri, 19 Aug 2022 11:50:08 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1660935008; cv=none; d=google.com; s=arc-20160816; b=XNCIyuK3PyHwvxXWK1MsK95d9jxZ/g9y0Xx4oYNHQtuiDuCHMYtPMijn+fGKtqBGXL 7Q5F/sivxmOoy77TAe23wg4PjcBy25ONx/DDhzfxor+rmdG+Wob1WMiIscGSVn6ocyrA UyFANv4zdxaYFElww2jXAWVi9HVyZKAWJGkAex2d5HOLs6FsvgckqUNFKtd5AsU+WGnv anmUShPGTypSD/FpriuhwlMkhWkZN0tF3sOR5Lt1KyId/n8b2cXpoUvkShpgAPCSpRJC /9pv6wanjJJjF+FMIqvQGCxE71ELkX9DWPqBhZ3wwxATrMSdUvpENxQR6Vh+Z3IMdEBd NXtw== 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=0N+aGlpvF5n2BpgF0PUXQA/veXWFFa+QNzcAxMqjXwY=; b=FZv0pXudXPlYXyEZeq0OdZGA7ZPZmioFfSy2y4JWHnsN3XQgo0wH9zZOamYhr6IbLl 8oNKj/tMokM69P53UpgLruNSR2q7EG/zgXXEOD9IdxFnNqdgVf5W3ShrcF3dOfTmwvdx GhNaGc9F6PWLl3afe/0xjfPDuN94oOMuCH5rY5FMJFHkEhb3anZz3hWjG3qLktqA3OCU 6+40G60vtQH7KSkR9uQA2NX6FnOwUBGiuvZBcQXDwk/Uh59lBuqa2TNbpAlTbd+1QuWn vnsHzOC32AdBEnR1LOD3F+KCLFK3Uo04/ZIlC2OhA4/JB95960i9sKek2gdSnu3f/70Z PjTw== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@joelfernandes.org header.s=google header.b=Bfi1w1xU; 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 f15-20020a170906084f00b0072b12db5f1csi2986699ejd.451.2022.08.19.11.49.43; Fri, 19 Aug 2022 11:50:08 -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=Bfi1w1xU; 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 S1349792AbiHSSRq (ORCPT + 99 others); Fri, 19 Aug 2022 14:17:46 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:57516 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1349783AbiHSSRp (ORCPT ); Fri, 19 Aug 2022 14:17:45 -0400 Received: from mail-io1-xd36.google.com (mail-io1-xd36.google.com [IPv6:2607:f8b0:4864:20::d36]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 47FF2B4B6 for ; Fri, 19 Aug 2022 11:17:44 -0700 (PDT) Received: by mail-io1-xd36.google.com with SMTP id 10so3906239iou.2 for ; Fri, 19 Aug 2022 11:17:44 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=joelfernandes.org; s=google; h=cc:to:subject:message-id:date:from:in-reply-to:references :mime-version:from:to:cc; bh=0N+aGlpvF5n2BpgF0PUXQA/veXWFFa+QNzcAxMqjXwY=; b=Bfi1w1xU6UkNJragDtxZi5Zg/Lw+a7nqgU6c598ghTQUesRRoZxA5lXbi0AL380OlK a/Ckw/Z86Y82FXXOyduEcphMLQjXNWaqULg05UUm0LLjdNRo//VF3S+2omqQBUPEc2iG IKAy2RJ9lbBcVAxxfQhQw7d2elim+10uw740E= X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; h=cc:to:subject:message-id:date:from:in-reply-to:references :mime-version:x-gm-message-state:from:to:cc; bh=0N+aGlpvF5n2BpgF0PUXQA/veXWFFa+QNzcAxMqjXwY=; b=Nb5u0e5YjzRS03ht/pUWG7E40NwceNAZzLbBPVM7+rfIYB7G0dHDffRNQrzqhJMQhr Puk/uvhYc0Rx3O8oPDC+3SRxl/UGpDVTNiVCqbGKBNYlwBT/y5TdPSLoAzf4ARNkm2/F Cc+9IlhTZqj/IDOC8aR3h64q6goJ2EDrtkqceCjqullz12pZV/1+3f8Ufvv95kr858JR F5U6Qy+Aprb9Pw/FvsNEH6xNXWrgUtRcULTi3w2u4Zq75SCl5/Q3uESN3pNu49R0rIDo 2JyJtM3qULsCAzH0vx5SdLiu76NbbTNkZJto+S8XqFpPu9lcmP90C2feza+iA8S+ZvKq NILQ== X-Gm-Message-State: ACgBeo36/Mb8DYzchrPgtgLMU+ktSWKzA/ynwR+6IV6PI6q9wTTiE/qz QnAStkXyBheJs7jNz3J1E3OcbpJLD3RyNoC8BJM+FVp3SsU= X-Received: by 2002:a05:6638:4982:b0:342:39e0:1d44 with SMTP id cv2-20020a056638498200b0034239e01d44mr3908539jab.213.1660933063633; Fri, 19 Aug 2022 11:17:43 -0700 (PDT) MIME-Version: 1.0 References: <20220809034517.3867176-1-joel@joelfernandes.org> <20220809034517.3867176-5-joel@joelfernandes.org> <20220819023550.GN2125313@paulmck-ThinkPad-P17-Gen-1> <4deb7354-bac7-b530-47ba-54cf50cfce58@joelfernandes.org> <2d56e4ad-7d6e-2abb-461f-15f20128d42b@joelfernandes.org> <20220819171249.GP2125313@paulmck-ThinkPad-P17-Gen-1> In-Reply-To: From: Joel Fernandes Date: Fri, 19 Aug 2022 14:17:32 -0400 Message-ID: Subject: Re: [PATCH v3 resend 4/6] fs: Move call_rcu() to call_rcu_lazy() in some paths To: "Paul E. McKenney" Cc: LKML , Rushikesh S Kadam , "Uladzislau Rezki (Sony)" , Neeraj upadhyay , Frederic Weisbecker , Steven Rostedt , rcu Content-Type: text/plain; charset="UTF-8" X-Spam-Status: No, score=-2.1 required=5.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID,DKIM_VALID_AU,DKIM_VALID_EF,RCVD_IN_DNSWL_NONE, SPF_HELO_NONE,SPF_PASS,T_SCC_BODY_TEXT_LINE 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 On Fri, Aug 19, 2022 at 2:14 PM Joel Fernandes wrote: [..] > >> Things are much better with the following change. However, this brings > >> me to a question about lock-contention based or any deferring and boot time. > >> > >> If you have a path like selinux doing a synchronize_rcu(), shouldn't we > >> skip the jiffie waiting for the bypass timer? Otherwise things > >> synchronously waiting will slow down more than usual. Maybe bypassing > >> should not be done for any case until boot up is done. I'm curious to > >> see if that improves boot time. > > > > Why not simply disable laziness at boot time and enable it only after > > booting is complete? The exiting rcupdate.rcu_normal_after_boot kernel > > boot parameter uses a similar scheme. > > That sounds like the right thing to good, but unfortunately it wont help > this problem. The boot time issue happens after init has started. So the > OS is still "booting" even though the kernel has. > > Also the problem can happen after boot as well, like if RCU > lazy/non-lazy callbacks come back to back quickly, or so. > > But yes nonetheless, I can see the value of disabling it till the > in-kernel boot completets. My mail client is acting weird. I meant to add to this, I wonder if there is a way other subsystems detect when userspace boots using some heuristic? Thanks, - Joel