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.129.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 8DD2FC433FE for ; Wed, 23 Nov 2022 12:53:15 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=redhat.com; s=mimecast20190719; t=1669207994; 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=nm8U8DWYu86kDcUYOjJw8NyZQpKvdK32VS0n6pmnI6U=; b=HbE/WaSqDuL+MIMDT+51x460W4xRgIv1mGHtQs1M12jgnOjHxDhhSwjR6gTuuKIrlT4X7o X01x01tIxys+fYDUUg4qw3Lpzj9Szn0RirfET04fFGPBmw6SuahKd9Y16ShsuEqgqKokd2 kEt6uwafd5ZrH8lfTKREEXpZbO6/TmU= 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-507-5F8m1zvEMiembcZHVi0pAQ-1; Wed, 23 Nov 2022 07:53:10 -0500 X-MC-Unique: 5F8m1zvEMiembcZHVi0pAQ-1 Received: from smtp.corp.redhat.com (int-mx03.intmail.prod.int.rdu2.redhat.com [10.11.54.3]) (using TLSv1.2 with cipher AECDH-AES256-SHA (256/256 bits)) (No client certificate requested) by mimecast-mx02.redhat.com (Postfix) with ESMTPS id A6E8C185A7A9; Wed, 23 Nov 2022 12:53:08 +0000 (UTC) Received: from mm-prod-listman-01.mail-001.prod.us-east-1.aws.redhat.com (mm-prod-listman-01.mail-001.prod.us-east-1.aws.redhat.com [10.30.29.100]) by smtp.corp.redhat.com (Postfix) with ESMTP id 7454F111CB81; Wed, 23 Nov 2022 12:53:08 +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 470F21946589; Wed, 23 Nov 2022 12:53:08 +0000 (UTC) Received: from smtp.corp.redhat.com (int-mx03.intmail.prod.int.rdu2.redhat.com [10.11.54.3]) by mm-prod-listman-01.mail-001.prod.us-east-1.aws.redhat.com (Postfix) with ESMTP id A160E1946587 for ; Wed, 23 Nov 2022 12:45:37 +0000 (UTC) Received: by smtp.corp.redhat.com (Postfix) id 769FF111E410; Wed, 23 Nov 2022 12:45:37 +0000 (UTC) Received: from mimecast-mx02.redhat.com (mimecast10.extmail.prod.ext.rdu2.redhat.com [10.11.55.26]) by smtp.corp.redhat.com (Postfix) with ESMTPS id 6EFE7111E413 for ; Wed, 23 Nov 2022 12:45:37 +0000 (UTC) Received: from us-smtp-1.mimecast.com (us-smtp-2.mimecast.com [205.139.110.61]) (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 51A6B1C08973 for ; Wed, 23 Nov 2022 12:45:37 +0000 (UTC) Received: from dfw.source.kernel.org (dfw.source.kernel.org [139.178.84.217]) by relay.mimecast.com with ESMTP with STARTTLS (version=TLSv1.2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id us-mta-306-ZZj1Hfy4PCqpRbFv6MpIvA-1; Wed, 23 Nov 2022 07:45:35 -0500 X-MC-Unique: ZZj1Hfy4PCqpRbFv6MpIvA-1 Received: from smtp.kernel.org (relay.kernel.org [52.25.139.140]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by dfw.source.kernel.org (Postfix) with ESMTPS id 13EFA61CB4; Wed, 23 Nov 2022 12:45:35 +0000 (UTC) Received: by smtp.kernel.org (Postfix) with ESMTPSA id 0F824C43144; Wed, 23 Nov 2022 12:45:33 +0000 (UTC) From: Sasha Levin To: linux-kernel@vger.kernel.org, stable@vger.kernel.org Date: Wed, 23 Nov 2022 07:45:16 -0500 Message-Id: <20221123124520.266643-8-sashal@kernel.org> In-Reply-To: <20221123124520.266643-1-sashal@kernel.org> References: <20221123124520.266643-1-sashal@kernel.org> MIME-Version: 1.0 X-stable: review X-Patchwork-Hint: Ignore 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.3 Subject: [dm-devel] [PATCH AUTOSEL 4.14 08/10] dm-integrity: set dma_alignment limit in io_hints 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 , Sasha Levin , Mike Snitzer , dm-devel@redhat.com, Keith Busch , agk@redhat.com Errors-To: dm-devel-bounces@redhat.com Sender: "dm-devel" X-Scanned-By: MIMEDefang 3.1 on 10.11.54.3 X-Mimecast-Spam-Score: 0 X-Mimecast-Originator: redhat.com Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit From: Keith Busch [ Upstream commit 29aa778bb66795e6a78b1c99beadc83887827868 ] This device mapper needs bio vectors to be sized and memory aligned to the logical block size. Set the minimum required queue limit accordingly. Signed-off-by: Keith Busch Reviewed-by: Mike Snitzer Link: https://lore.kernel.org/r/20221110184501.2451620-5-kbusch@meta.com Signed-off-by: Jens Axboe Signed-off-by: Sasha Levin --- drivers/md/dm-integrity.c | 1 + 1 file changed, 1 insertion(+) diff --git a/drivers/md/dm-integrity.c b/drivers/md/dm-integrity.c index 6579aa46f544..e7e44c1d5553 100644 --- a/drivers/md/dm-integrity.c +++ b/drivers/md/dm-integrity.c @@ -2297,6 +2297,7 @@ static void dm_integrity_io_hints(struct dm_target *ti, struct queue_limits *lim limits->logical_block_size = ic->sectors_per_block << SECTOR_SHIFT; limits->physical_block_size = ic->sectors_per_block << SECTOR_SHIFT; blk_limits_io_min(limits, ic->sectors_per_block << SECTOR_SHIFT); + limits->dma_alignment = limits->logical_block_size - 1; } } -- 2.35.1 -- 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 736E9C3A59F for ; Wed, 23 Nov 2022 12:58:22 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S238457AbiKWM6V (ORCPT ); Wed, 23 Nov 2022 07:58:21 -0500 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:60932 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S238549AbiKWM5H (ORCPT ); Wed, 23 Nov 2022 07:57:07 -0500 Received: from dfw.source.kernel.org (dfw.source.kernel.org [139.178.84.217]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id BA62A97081; Wed, 23 Nov 2022 04:45:54 -0800 (PST) Received: from smtp.kernel.org (relay.kernel.org [52.25.139.140]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by dfw.source.kernel.org (Postfix) with ESMTPS id 713DE61CBE; Wed, 23 Nov 2022 12:45:35 +0000 (UTC) Received: by smtp.kernel.org (Postfix) with ESMTPSA id 0F824C43144; Wed, 23 Nov 2022 12:45:33 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=k20201202; t=1669207534; bh=WBGwpN8H4Au8TbVPENHv73V/7wZNnXN8yLSCVRzJ2NY=; h=From:To:Cc:Subject:Date:In-Reply-To:References:From; b=BcZVkxI3jUt/4i5AAWdVFdS5JuneCHwoZcqCBdyWzlBq8Vf61x7VaH6W+LBNL9B2H WbI+uNqMhoaf2KQUzP8vNNafTXODpJf9S4CO7mEleHSSOT+etpH8LOeIOyMgLwqiID o9J0JvI/+WaqWjGJLHnzmbhUl+2ljt9B6inY3F8dhl2y8h8HSbKf08+dwwm/mWNsik 6CGd53n62TXfMffyeHktYlJsEs0qY2MddET1+A+tc9+cjC6w2BWswtY+1Y33doBcYJ TOjqVUww1YLnxxIN6gb2wn820eve0aUO5cWNByhmVEj4xaUm6rF7RO4aWCTfOp1xqR Z5Ppsq49Kt4Vg== From: Sasha Levin To: linux-kernel@vger.kernel.org, stable@vger.kernel.org Cc: Keith Busch , Mike Snitzer , Jens Axboe , Sasha Levin , agk@redhat.com, dm-devel@redhat.com Subject: [PATCH AUTOSEL 4.14 08/10] dm-integrity: set dma_alignment limit in io_hints Date: Wed, 23 Nov 2022 07:45:16 -0500 Message-Id: <20221123124520.266643-8-sashal@kernel.org> X-Mailer: git-send-email 2.35.1 In-Reply-To: <20221123124520.266643-1-sashal@kernel.org> References: <20221123124520.266643-1-sashal@kernel.org> MIME-Version: 1.0 X-stable: review X-Patchwork-Hint: Ignore Content-Transfer-Encoding: 8bit Precedence: bulk List-ID: X-Mailing-List: stable@vger.kernel.org From: Keith Busch [ Upstream commit 29aa778bb66795e6a78b1c99beadc83887827868 ] This device mapper needs bio vectors to be sized and memory aligned to the logical block size. Set the minimum required queue limit accordingly. Signed-off-by: Keith Busch Reviewed-by: Mike Snitzer Link: https://lore.kernel.org/r/20221110184501.2451620-5-kbusch@meta.com Signed-off-by: Jens Axboe Signed-off-by: Sasha Levin --- drivers/md/dm-integrity.c | 1 + 1 file changed, 1 insertion(+) diff --git a/drivers/md/dm-integrity.c b/drivers/md/dm-integrity.c index 6579aa46f544..e7e44c1d5553 100644 --- a/drivers/md/dm-integrity.c +++ b/drivers/md/dm-integrity.c @@ -2297,6 +2297,7 @@ static void dm_integrity_io_hints(struct dm_target *ti, struct queue_limits *lim limits->logical_block_size = ic->sectors_per_block << SECTOR_SHIFT; limits->physical_block_size = ic->sectors_per_block << SECTOR_SHIFT; blk_limits_io_min(limits, ic->sectors_per_block << SECTOR_SHIFT); + limits->dma_alignment = limits->logical_block_size - 1; } } -- 2.35.1