From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from us-smtp-delivery-124.mimecast.com (us-smtp-delivery-124.mimecast.com [170.10.133.124]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.lore.kernel.org (Postfix) with ESMTPS id 933EAC05027 for ; Fri, 17 Feb 2023 17:04:13 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=redhat.com; s=mimecast20190719; t=1676653452; h=from:from:sender:sender:reply-to:subject:subject:date:date: message-id:message-id:to:to:cc:cc:mime-version:mime-version: content-type:content-type: content-transfer-encoding:content-transfer-encoding: in-reply-to:in-reply-to:references:references:list-id:list-help: list-unsubscribe:list-subscribe:list-post; bh=xEhB90NWENFAayAeOjsgeFk3c0q5XPgFcjD4ZodjEDg=; b=Un98maNrYyg9iaP7GtR28evEtrROsqUXDx08hvzBKanJauHKQfbo1/x1t4e3XQGv640N6w gu8qiMWGu0F3yvy9IXA41ywCeHtrQqR8kqkI66RbAbCKycHLe7lgQ1Z2jLzyl0eM0DLax2 4hmjCJ8ZmQ55SWL6/taCatLt7C4kVvY= Received: from mimecast-mx02.redhat.com (mimecast-mx02.redhat.com [66.187.233.88]) by relay.mimecast.com with ESMTP with STARTTLS (version=TLSv1.2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id us-mta-20-CHIHDTDzOza1AeYJaqNA7A-1; Fri, 17 Feb 2023 12:04:09 -0500 X-MC-Unique: CHIHDTDzOza1AeYJaqNA7A-1 Received: from smtp.corp.redhat.com (int-mx10.intmail.prod.int.rdu2.redhat.com [10.11.54.10]) (using TLSv1.2 with cipher AECDH-AES256-SHA (256/256 bits)) (No client certificate requested) by mimecast-mx02.redhat.com (Postfix) with ESMTPS id 282131019CBC; Fri, 17 Feb 2023 17:04:07 +0000 (UTC) Received: from mm-prod-listman-01.mail-001.prod.us-east-1.aws.redhat.com (unknown [10.30.29.100]) by smtp.corp.redhat.com (Postfix) with ESMTP id C43E5492C3E; Fri, 17 Feb 2023 17:04:06 +0000 (UTC) Received: from mm-prod-listman-01.mail-001.prod.us-east-1.aws.redhat.com (localhost [IPv6:::1]) by mm-prod-listman-01.mail-001.prod.us-east-1.aws.redhat.com (Postfix) with ESMTP id 8BE051946589; Fri, 17 Feb 2023 17:04:06 +0000 (UTC) Received: from smtp.corp.redhat.com (int-mx06.intmail.prod.int.rdu2.redhat.com [10.11.54.6]) by mm-prod-listman-01.mail-001.prod.us-east-1.aws.redhat.com (Postfix) with ESMTP id A65E71946588 for ; Fri, 17 Feb 2023 17:04:05 +0000 (UTC) Received: by smtp.corp.redhat.com (Postfix) id 4CBBA2166B31; Fri, 17 Feb 2023 17:04:05 +0000 (UTC) Received: from mimecast-mx02.redhat.com (mimecast03.extmail.prod.ext.rdu2.redhat.com [10.11.55.19]) by smtp.corp.redhat.com (Postfix) with ESMTPS id 460912166B30 for ; Fri, 17 Feb 2023 17:04:05 +0000 (UTC) Received: from us-smtp-1.mimecast.com (us-smtp-delivery-1.mimecast.com [205.139.110.120]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mimecast-mx02.redhat.com (Postfix) with ESMTPS id 2523A85CBCB for ; Fri, 17 Feb 2023 17:04:05 +0000 (UTC) Received: from bombadil.infradead.org (bombadil.infradead.org [198.137.202.133]) by relay.mimecast.com with ESMTP with STARTTLS (version=TLSv1.3, cipher=TLS_AES_128_GCM_SHA256) id us-mta-50-rX4paOTfOgCC74LsQfDGwA-1; Fri, 17 Feb 2023 12:04:03 -0500 X-MC-Unique: rX4paOTfOgCC74LsQfDGwA-1 Received: from hch by bombadil.infradead.org with local (Exim 4.94.2 #2 (Red Hat Linux)) id 1pT3PD-00F0il-Ve; Fri, 17 Feb 2023 16:16:15 +0000 Date: Fri, 17 Feb 2023 08:16:15 -0800 From: Christoph Hellwig To: Uday Shankar Message-ID: References: <20230215201507.494152-1-ushankar@purestorage.com> <20230216192702.GA801590@dev-ushankar.dev.purestorage.com> MIME-Version: 1.0 In-Reply-To: <20230216192702.GA801590@dev-ushankar.dev.purestorage.com> X-SRS-Rewrite: SMTP reverse-path rewritten from by bombadil.infradead.org. See http://www.infradead.org/rpr.html X-Mimecast-Impersonation-Protect: Policy=CLT - Impersonation Protection Definition; Similar Internal Domain=false; Similar Monitored External Domain=false; Custom External Domain=false; Mimecast External Domain=false; Newly Observed Domain=false; Internal User Name=false; Custom Display Name List=false; Reply-to Address Mismatch=false; Targeted Threat Dictionary=false; Mimecast Threat Dictionary=false; Custom Threat Dictionary=false X-Scanned-By: MIMEDefang 3.1 on 10.11.54.6 Subject: Re: [dm-devel] [PATCH] blk-mq: enforce op-specific segment limits in blk_insert_cloned_request X-BeenThere: dm-devel@redhat.com X-Mailman-Version: 2.1.29 Precedence: list List-Id: device-mapper development List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: Jens Axboe , linux-block@vger.kernel.org, Mike Snitzer , Christoph Hellwig , dm-devel@redhat.com, Alasdair Kergon Errors-To: dm-devel-bounces@redhat.com Sender: "dm-devel" X-Scanned-By: MIMEDefang 3.1 on 10.11.54.10 X-Mimecast-Spam-Score: 0 X-Mimecast-Originator: redhat.com Content-Disposition: inline Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit On Thu, Feb 16, 2023 at 12:27:02PM -0700, Uday Shankar wrote: > * Description: > * @rq may have been made based on weaker limitations of upper-level queues > * in request stacking drivers, and it may violate the limitation of @q. > * Since the block layer and the underlying device driver trust @rq > * after it is inserted to @q, it should be checked against @q before > * the insertion using this generic function. > * > * Request stacking drivers like request-based dm may change the queue > * limits when retrying requests on other queues. Those requests need > * to be checked against the new queue limits again during dispatch. > */. > > Is this concern no longer relevant? The concern is still valid, but it does not refer to the debug check. It refers to recalculating nr_phys_segments using blk_recalc_rq_segments, and the fact that any driver using this interface needs to stack its limits properly. -- dm-devel mailing list dm-devel@redhat.com https://listman.redhat.com/mailman/listinfo/dm-devel From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from vger.kernel.org (vger.kernel.org [23.128.96.18]) by smtp.lore.kernel.org (Postfix) with ESMTP id 368DEC05027 for ; Fri, 17 Feb 2023 16:17:05 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S229616AbjBQQRE (ORCPT ); Fri, 17 Feb 2023 11:17:04 -0500 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:47990 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S230383AbjBQQRD (ORCPT ); Fri, 17 Feb 2023 11:17:03 -0500 Received: from bombadil.infradead.org (bombadil.infradead.org [IPv6:2607:7c80:54:3::133]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 3C66C71196 for ; Fri, 17 Feb 2023 08:16:32 -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=HtC79M6gfoTbeYz9ewr/uHjJ5JvDIH+6EYOxmfcgdPs=; b=tJnnwJydWv0tmiRmFs7CyiPk6S jAzXGtFeVlYcJqNcOJkEof0t5OXIw1lcGNjDMlMnXrTk+roEcqlcChPpZd67yXACsZWEyAg1E64+H CQYlBTCpYOXn5Ct1vGHDM92WBwN/C2egAsZShRq8fV9Un13n5CAAy9Ivh81d33nqDPLZ5gISyk47r z5oHYxVrxxMCDIB40H64H+c23CVS/CbpWq70+eqT/6+8ICiI9gAlA+ruNove9P6BRFAMtlwlJ6pws PC8DdnlDum4jC+L+RZbRprZx22EU3R8CEtAAo5899wbKOkt+xLesDjTAyNn0pGH4W615gXzAU2Mle iMqzvSqA==; Received: from hch by bombadil.infradead.org with local (Exim 4.94.2 #2 (Red Hat Linux)) id 1pT3PD-00F0il-Ve; Fri, 17 Feb 2023 16:16:15 +0000 Date: Fri, 17 Feb 2023 08:16:15 -0800 From: Christoph Hellwig To: Uday Shankar Cc: Christoph Hellwig , Jens Axboe , Alasdair Kergon , Mike Snitzer , linux-block@vger.kernel.org, dm-devel@redhat.com Subject: Re: [PATCH] blk-mq: enforce op-specific segment limits in blk_insert_cloned_request Message-ID: References: <20230215201507.494152-1-ushankar@purestorage.com> <20230216192702.GA801590@dev-ushankar.dev.purestorage.com> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <20230216192702.GA801590@dev-ushankar.dev.purestorage.com> X-SRS-Rewrite: SMTP reverse-path rewritten from by bombadil.infradead.org. See http://www.infradead.org/rpr.html Precedence: bulk List-ID: X-Mailing-List: linux-block@vger.kernel.org On Thu, Feb 16, 2023 at 12:27:02PM -0700, Uday Shankar wrote: > * Description: > * @rq may have been made based on weaker limitations of upper-level queues > * in request stacking drivers, and it may violate the limitation of @q. > * Since the block layer and the underlying device driver trust @rq > * after it is inserted to @q, it should be checked against @q before > * the insertion using this generic function. > * > * Request stacking drivers like request-based dm may change the queue > * limits when retrying requests on other queues. Those requests need > * to be checked against the new queue limits again during dispatch. > */. > > Is this concern no longer relevant? The concern is still valid, but it does not refer to the debug check. It refers to recalculating nr_phys_segments using blk_recalc_rq_segments, and the fact that any driver using this interface needs to stack its limits properly.