Received: by 2002:ac0:cd04:0:0:0:0:0 with SMTP id w4csp262789imn; Fri, 1 Jul 2022 14:41:24 -0700 (PDT) X-Google-Smtp-Source: AGRyM1tOe5exUTbvXXURkZu1MeIT+8O8MM/f2802WOPV7uFkmG6rouxPMBcM4z2A1beuxg92ov8D X-Received: by 2002:a05:6a00:2986:b0:528:3886:5612 with SMTP id cj6-20020a056a00298600b0052838865612mr3822648pfb.65.1656711684398; Fri, 01 Jul 2022 14:41:24 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1656711684; cv=none; d=google.com; s=arc-20160816; b=Mqs7wAD5pahEJZfjgVJLoKV7A8qvxbaHRhB1HqwMpKgjHZ0O41gFOBRtrcsW3r8nTY DqiGH7Y0E7eon/l0JyjJTVgt02GkfYt4fusYEWF3nBdnTuE3KErxDpW0z0G21bQBqHuV 0x4WYgB9YosD56j69+Br3LTGSSJPPT5htfKLSWd2KF39Yr3+hfW1Sd7Dv8WQR7IIi7Xr 9t+oheBWGZF56fIfRhjldvDOvwzefuTLHTLUE7wnbnrSr4QtTV2sQeQWDtSpWAa8lttc vjk4qRAawFJiM2LsV7zeq2SoNOnF2+PFUohzQ8Q/b61XKwwTngxfb6vwhx0CVVtf+vpH WjFg== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:in-reply-to:content-disposition :mime-version:references:message-id:subject:cc:to:from:date :dkim-signature; bh=ds8jh0l5EsIdliBH9eqhr4U5uNb1IBs028DxPs3Imn4=; b=CizpSTX9am+eOZJe7SMYnSEJDS2HA8+WnCA5XRBXzeELQBkl+JZDZQ+Y20ldbZyrnQ diN9VyGlD27tAf4ZM8MPI/IOXKF6GwPKkOdAtmUahOR1flfAvVvC8EZyharx7YIcbXCb DqTGnYEpTXa/Ha9RnY3ZrQd4oEyuxQc8RHL2z+Cqcu+evAgmXSkTvx5cJx991xlxdEsq q0+f39u8DHj2cFyrodUMqgzjD7cns0yBxuhbpFlv/k09tz78Zb57UJAl2sjxZEzFAHXs q/2c3jXOzvGFjDa8sGatSNE0g4nJT7swZTjkTLyk/d1SMxKZjdU+SQRu230J/RZfumCd E6Lg== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@infradead.org header.s=bombadil.20210309 header.b=wIcgEjKx; 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=NONE dis=NONE) header.from=kernel.org Return-Path: Received: from out1.vger.email (out1.vger.email. [2620:137:e000::1:20]) by mx.google.com with ESMTP id j12-20020a63e74c000000b0040d40aa9827si31765698pgk.533.2022.07.01.14.41.11; Fri, 01 Jul 2022 14:41:24 -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=@infradead.org header.s=bombadil.20210309 header.b=wIcgEjKx; 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=NONE dis=NONE) header.from=kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S230296AbiGAVZa (ORCPT + 99 others); Fri, 1 Jul 2022 17:25:30 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:47848 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S229911AbiGAVZ2 (ORCPT ); Fri, 1 Jul 2022 17:25:28 -0400 Received: from bombadil.infradead.org (bombadil.infradead.org [IPv6:2607:7c80:54:3::133]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 7D2E443AE0; Fri, 1 Jul 2022 14:25:27 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=infradead.org; s=bombadil.20210309; h=Sender:In-Reply-To:Content-Type: MIME-Version:References:Message-ID:Subject:Cc:To:From:Date:Reply-To: Content-Transfer-Encoding:Content-ID:Content-Description; bh=ds8jh0l5EsIdliBH9eqhr4U5uNb1IBs028DxPs3Imn4=; b=wIcgEjKxGgxSrUuF95csVmK7Fp ZsEMWiv26PKR8MZ2CSFW+5VIWA3Lok6BkGdPfvOKkkA2AksPa/25NKv2bgF69NAtKzfgqwboKzDIv VI0Dfa7L4oDaNbMB0uRn3PKbTJZQ9fkk3qfPhNczpRyqPu+Pkkw4Xj58N+fGeJvl7NSYZswMS+gNp MGGrCCwdqxDW4ylfkqtibSKmy+3Vz7kXVIhqZ0YByyhDevTCjZ2oAPqvcFDWGiUNhALYv0kruTTdz yJnomGQ1WxLTR7p83++BUUCGMr1VuI/1vVnW+wDaemK2tgQI+cHdu/sjDhMcX5FB27nByAR/oVabP /Vm+35lA==; Received: from mcgrof by bombadil.infradead.org with local (Exim 4.94.2 #2 (Red Hat Linux)) id 1o7O8l-0070Lt-4u; Fri, 01 Jul 2022 21:25:27 +0000 Date: Fri, 1 Jul 2022 14:25:27 -0700 From: Luis Chamberlain To: Lucas De Marchi Cc: linux-modules , lkml Subject: Re: [ANNOUNCE] kmod 30 Message-ID: References: <20220630153621.3fggpqrbyvunhwfu@ldmartin-desk2> <20220630223323.2hko2imx62embtsj@ldmartin-desk2> <20220701181321.zgzxv7p3zrbzkuf6@ldmartin-desk2> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <20220701181321.zgzxv7p3zrbzkuf6@ldmartin-desk2> Sender: Luis Chamberlain X-Spam-Status: No, score=-1.8 required=5.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID,DKIM_VALID_EF,HEADER_FROM_DIFFERENT_DOMAINS, RCVD_IN_DNSWL_NONE,SPF_HELO_NONE,SPF_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 On Fri, Jul 01, 2022 at 11:13:21AM -0700, Lucas De Marchi wrote: > On Fri, Jul 01, 2022 at 10:49:10AM -0700, Luis Chamberlain wrote: > > On Thu, Jun 30, 2022 at 03:33:23PM -0700, Lucas De Marchi wrote: > > > On Thu, Jun 30, 2022 at 03:09:32PM -0700, Luis Chamberlain wrote: > > > > Sorry for the super late review, I was swamped. OK so the only issue > > > > I can think of is that rmmod *used* to support the kernel wait support > > > > with $(rmmod --wait) so wouldn't this be odd? > > > > > > any reason not to use modprobe -r? > > > > I was referring to old scripts which may have used $(rmmod --wait) before. > > But since support for that was ripped, then yeah I can see that should > > not be an issue. > > > > However I can think of *one* issue, did we ever support `modprobe--wait`? > > no > > > > > Because the way fstests / blktests would implement this feature > > detection is with something like this now: > > > > _has_modprobe_patient() > > { > > modprobe --help >& /dev/null || return 1 > > modprobe --help | grep -q -1 "remove-patiently" || return 1 > > return 0 > > } > > the grep would need to be changed to something like "-w, --wait" Yes of course, that's easy, but we modprobe ever supportedl "--wait" this would be a problem. Since it did not, we are good then! > > > > It is why I had gone with: > > > > > > > > -p | --remove-patiently patiently removes the module > > > > -t | --timeout timeout in ms to remove the module > > > > > > > > You would know better though. > > > > > > > > Also just curious, is it really terrible to just support waiting > > > > forever? > > > > > > is there a use case for that? If we are trying to cover some races, I > > > imagine a small timeout would be sufficient. Also notice that if the > > > timeout is too big, so will be the interval between the retries. On > > > your v2 I had suggested polling the refcnt so we would get notificed > > > on changes, but as you also noticed, that didn't work very well. So I > > > went back to a time-based retry solution. > > > > > > if there is a use-case, should we cap the interval between retries? > > > > I really can't think of a use case except for catching glaring > > unexpected bugs in test suites where the kernel developer would > > really like to know something really bad happened, but even then > > a timeout is likely desirable. > > yeah... if developer wants to possibly wait for a long time, `--wait -1` > is available to wait for years. :) good call > > So just a heads up the timeout I'll use for fstests / blktests will be > > of 100 seconds. > > yeah... 100 seconds still make more sense than -1 IMO Great we'll go with that. Hopefully this will put a nail on the flaky modules issue for good! Luis