Received: by 10.223.176.46 with SMTP id f43csp1243324wra; Fri, 19 Jan 2018 08:48:20 -0800 (PST) X-Google-Smtp-Source: ACJfBotCJEIFoHIRnZ6oV5xjibmqIrbrJJRKxeldREnI4yv2E7s1w6cJ6y/uGIEo5Yg+zXt3qz+/ X-Received: by 10.99.55.66 with SMTP id g2mr15903098pgn.61.1516380499881; Fri, 19 Jan 2018 08:48:19 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1516380499; cv=none; d=google.com; s=arc-20160816; b=cNSzYALixEGAOJlxw2W3dXTdZX5pbWzw11IhiDwXOnn/+3kOUCdc30NOE0fYOiDrKS 6Hya0VvhQv1UVo4Kxq3w+F8Bo08Csx5H4l02ATAkSB/2qAqLNG6b+7B4sq3CkfwJ6Dmt YngBmkbt52ry7e9SK0DCdW1DalnRcSCLM3QhmTSuDZr9B1ognnz86QPtbI5AMaclwGwz p98iPaHa6OcHJoyPvckqijfDPVS7Wtpha3afUMHShfPDxeD7O4h9E4Z2lWnFbygYog1M uM+W4MtekiCMa1bp601J6jDB5BhsNJ+l/bgUnTm8ho2Gqgtj8UDg3qAyTQ09eklDQR3Y kR9w== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:user-agent:in-reply-to :content-disposition:mime-version:references:message-id:subject:cc :to:from:date:arc-authentication-results; bh=l9zJdQOuaFwbeK3syDpmssifQ90sc2SX9WQdWV9Ex/o=; b=hNFgpIehi1fm+tRbh7UWnLhNu3BIJABcA6tdJdb1fZwbAcXQlyoT0EsLEjkRMUUZ4Z jF5LvCj6Yt098O1JVHdiD6VqWsC1zKh2rSOpB9krKjFg5pcZI1cWVy0Ex47+2g6KfwCq BE/hVH92KGdSlpPgAzo95UN02K2nWNFxSFra7RXgaJQQgTQRuCpEz7pLCHO5TYhClPRz ERScA6M+hJJNpyul48RaLiRY21B87hmcUU1brXmCxbxHk0BvLs5blRXXOP1W6E4sARkL ygZasmkSV1yly3xOKlCR7cPZGRpn4GyAENaeGWO9yDlSsjq6DOwUIdY/wXCG1vvemZhc Gs0A== ARC-Authentication-Results: i=1; mx.google.com; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=redhat.com Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id i8si8529165pgt.582.2018.01.19.08.48.06; Fri, 19 Jan 2018 08:48:19 -0800 (PST) Received-SPF: pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) client-ip=209.132.180.67; Authentication-Results: mx.google.com; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=redhat.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1756116AbeASQrg (ORCPT + 99 others); Fri, 19 Jan 2018 11:47:36 -0500 Received: from mx1.redhat.com ([209.132.183.28]:43491 "EHLO mx1.redhat.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1755772AbeASQrb (ORCPT ); Fri, 19 Jan 2018 11:47:31 -0500 Received: from smtp.corp.redhat.com (int-mx01.intmail.prod.int.phx2.redhat.com [10.5.11.11]) (using TLSv1.2 with cipher AECDH-AES256-SHA (256/256 bits)) (No client certificate requested) by mx1.redhat.com (Postfix) with ESMTPS id 8E02AC052450; Fri, 19 Jan 2018 16:47:31 +0000 (UTC) Received: from localhost (unknown [10.18.25.149]) by smtp.corp.redhat.com (Postfix) with ESMTPS id 4ACCA620A6; Fri, 19 Jan 2018 16:47:23 +0000 (UTC) Date: Fri, 19 Jan 2018 11:47:22 -0500 From: Mike Snitzer To: Jens Axboe Cc: Ming Lei , Bart Van Assche , "dm-devel@redhat.com" , "hch@infradead.org" , "linux-kernel@vger.kernel.org" , "linux-block@vger.kernel.org" , "osandov@fb.com" Subject: Re: [RFC PATCH] blk-mq: fixup RESTART when queue becomes idle Message-ID: <20180119164722.GA29449@redhat.com> References: <20180119072623.GB25369@ming.t460p> <047f68ec-f51b-190f-2f89-f413325c2540@kernel.dk> <20180119154047.GB14827@ming.t460p> <540e1239-c415-766b-d4ff-bb0b7f3517a7@kernel.dk> <20180119160518.GC14827@ming.t460p> <4a5c049f-0fab-bbaf-bfe2-eb5bca73f2c8@kernel.dk> <20180119162618.GD14827@ming.t460p> <1f072086-533e-4b75-d0e3-9e621b2120d8@kernel.dk> <20180119163736.GE14827@ming.t460p> <26833249-cadf-ba9c-1128-0bcb70ceb9e1@kernel.dk> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <26833249-cadf-ba9c-1128-0bcb70ceb9e1@kernel.dk> User-Agent: Mutt/1.5.21 (2010-09-15) X-Scanned-By: MIMEDefang 2.79 on 10.5.11.11 X-Greylist: Sender IP whitelisted, not delayed by milter-greylist-4.5.16 (mx1.redhat.com [10.5.110.32]); Fri, 19 Jan 2018 16:47:31 +0000 (UTC) Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Fri, Jan 19 2018 at 11:41am -0500, Jens Axboe wrote: > On 1/19/18 9:37 AM, Ming Lei wrote: > > On Fri, Jan 19, 2018 at 09:27:46AM -0700, Jens Axboe wrote: > >> On 1/19/18 9:26 AM, Ming Lei wrote: > >>> On Fri, Jan 19, 2018 at 09:19:24AM -0700, Jens Axboe wrote: > >> > >> There are no pending requests for this case, nothing to restart the > >> queue. When you fail that blk_get_request(), you are idle, nothing > >> is pending. > > > > I think we needn't worry about that, once a device is attached to > > dm-rq, it can't be mounted any more, and usually user don't use the device > > directly and by dm-mpath at the same time. > > Even if it doesn't happen for a normal dm setup, it is a case that > needs to be handled. The request allocation is just one example of > a wider scope resource that can be unavailable. If the driver returns > NO_DEV_RESOURCE (or whatever name), it will be a possibility that > the device itself is currently idle. How would a driver's resources be exhausted yet the device is idle (so as not to be able to benefit from RESTART)?