Received: by 2002:a05:6a10:9afc:0:0:0:0 with SMTP id t28csp2069763pxm; Sun, 27 Feb 2022 10:24:10 -0800 (PST) X-Google-Smtp-Source: ABdhPJyej2Y/LbLIbmP/5cFB7RS1+V0iY81RvMxfApfLMqtFdpotT524ocVBHdh9pPO8JVrN053I X-Received: by 2002:a05:6a00:1a92:b0:4f0:edf6:83f5 with SMTP id e18-20020a056a001a9200b004f0edf683f5mr17843705pfv.31.1645986250546; Sun, 27 Feb 2022 10:24:10 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1645986250; cv=none; d=google.com; s=arc-20160816; b=OpOeqJ5q5E+4n1FfaiG0FEHVLXzlcpwN5s1xYHm/1+a3c+EdSIa95/GcOliNpCZkj8 GtGhjI3teyh9BjwI/o4zubvvnmLMOIDY2gP7kxks65HyPECxuK28NKy7RsGqt6kCer8o nPCEBC13yNPC/5Gy1WgYe5kNU9vb7Jsg2Y+NUxCkfrPDE6dMapAx0kRuhpA0j9Pw8ZVT wVQGTopPBJiRhXYJavUz7XKhDMEgwFFxzd6k0Zg4OCkX0re8lLWyWKQ821JC1b25zkuj 6wvX7thZhiF9y9fTaCjqSe1pVYE7CrK/8HaV3efSJkLc3Tk2ZAyrqHAq0DudDgtSDiue y5Fw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:in-reply-to:content-disposition:mime-version :references:message-id:subject:cc:to:from:date:dkim-signature; bh=1+1W3bcZcWwdxZGt68XLVQsJDzEEa3DPMfJ+40hI5ZE=; b=vjk5LWHwGfLRrZIZml7BzclIIt2jXI1e/BkW+2WEa3lj66k5fnZPn+9SHaLn76bUrQ Ehb4nczQjLfm87u62kBqGOpEczhiHVVUp5HZOOg5muR+YI7WhO2nLnPD+QT3469IjnI9 5P1s+MX8ulj9msotjVHKSMwANM8viZ37OSiSn9qu8oev0gNBXggBUE2Ihdo0MdA7fMmL zfMSxxDoWkzgMDI/hVobE/MS0UiG9bbyAhYzy/KzrLsWeBeFNlYPNBUTgbvnx6m4sUvp z/MHaPvqARNLeb2sMtWdT9lrqs+vcH9lUWUt7GgGxG0Lcg+dC/alPKKILjduGFVU/ax2 oanA== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@infradead.org header.s=bombadil.20210309 header.b=Qmk+ArWt; 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 j207-20020a6280d8000000b004e16ae51118si7127604pfd.174.2022.02.27.10.23.54; Sun, 27 Feb 2022 10:24:10 -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=@infradead.org header.s=bombadil.20210309 header.b=Qmk+ArWt; 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 S231416AbiB0RRs (ORCPT + 99 others); Sun, 27 Feb 2022 12:17:48 -0500 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:44150 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S230515AbiB0RRq (ORCPT ); Sun, 27 Feb 2022 12:17:46 -0500 Received: from bombadil.infradead.org (bombadil.infradead.org [IPv6:2607:7c80:54:e::133]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 6484265481; Sun, 27 Feb 2022 09:17:09 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=infradead.org; s=bombadil.20210309; h=In-Reply-To:Content-Type:MIME-Version :References:Message-ID:Subject:Cc:To:From:Date:Sender:Reply-To: Content-Transfer-Encoding:Content-ID:Content-Description; bh=1+1W3bcZcWwdxZGt68XLVQsJDzEEa3DPMfJ+40hI5ZE=; b=Qmk+ArWtToMpl/lfeapZnRuA+i PrpP0ngA7XYmy9Gc6kV2P9n12jrrsV7XUBTZPhKniH/NRJt3xiLUsoQSQ+Ft50Cdcl6W0AOwA+Md5 dC1WO3nZbABs3yFH5hL2CshbLWPfMlFmLXZqG78tLsnQ2fxKSF/2Ox84afzZCXbdfWT4VW8xUIkQI t/m/r7ViW2IaqOCXCC7ZY6Y7CUGw6J831FxUykxsBiYnBFwNAr0OzK+kqsTxY69VgvQ0hwZHWdsW7 W6qFUCswdr+I2WSzWlPThBAJ9S1pEht19lBh0nZGUPujtoVBKBtTMr6mBKnDLxkby0ZjFP7t8BMmz IxzPFXzA==; Received: from hch by bombadil.infradead.org with local (Exim 4.94.2 #2 (Red Hat Linux)) id 1nONAE-009roj-8J; Sun, 27 Feb 2022 17:16:54 +0000 Date: Sun, 27 Feb 2022 09:16:54 -0800 From: Christoph Hellwig To: Yu Kuai Cc: ming.lei@redhat.com, tj@kernel.org, axboe@kernel.dk, cgroups@vger.kernel.org, linux-block@vger.kernel.org, linux-kernel@vger.kernel.org, yi.zhang@huawei.com Subject: Re: [PATCH v9] block: cancel all throttled bios in del_gendisk() Message-ID: References: <20220210115637.1074927-1-yukuai3@huawei.com> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <20220210115637.1074927-1-yukuai3@huawei.com> X-SRS-Rewrite: SMTP reverse-path rewritten from by bombadil.infradead.org. See http://www.infradead.org/rpr.html 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_NONE,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 Thu, Feb 10, 2022 at 07:56:37PM +0800, Yu Kuai wrote: > Throttled bios can't be issued after del_gendisk() is done, thus > it's better to cancel them immediately rather than waiting for > throttle is done. > > For example, if user thread is throttled with low bps while it's > issuing large io, and the device is deleted. The user thread will > wait for a long time for io to return. FYI, this crashed left rigt and center when running xfstests with traces pointing to throtl_pending_timer_fn.