From patchwork Fri Aug 11 10:52:53 2023 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Nitesh Shetty X-Patchwork-Id: 134437 Return-Path: Delivered-To: ouuuleilei@gmail.com Received: by 2002:a59:b824:0:b0:3f2:4152:657d with SMTP id z4csp1030199vqi; Fri, 11 Aug 2023 04:53:50 -0700 (PDT) X-Google-Smtp-Source: AGHT+IGEunddF394yED+BspZin0X48Rm67G4e3e6QUakyWz5XcStMaf+otFIgQemBrqEMfKTReek X-Received: by 2002:a05:6870:e394:b0:1bb:5af8:701f with SMTP id x20-20020a056870e39400b001bb5af8701fmr1755952oad.23.1691754830658; Fri, 11 Aug 2023 04:53:50 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1691754830; cv=none; d=google.com; s=arc-20160816; b=i2Dw4UE5A7cJ3MwOTKIwKdC0/GKqf5tyT8yjzLWby2jM1sMdjoLssQsETFFNvO9mpw FboH6dtyYptIljpEQDQHe6VNg0FQJ3qbXU6c3Nlg/q8K6jZgsNYemRQqKvDiidQLzgFF Z14Bx+6MDfAOIg7wYEwqsvTogBswbG52PhVey7BFuEV3LHVjZ/kCNjSX4FHYoglyY/C+ gFBR/K7UzptePoBc/Q48Pu2ZfSMo9hcCoImopo4rEfZQTX+LYMHE2UHMaQlZe0LDjNaH TQa0yOcmps8FfoLCa8Iyg/VQX1LAk2pTRr5XcadVuNZUpfcZH8OGnSiNbdOG6EUJ2sjc 5VZA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:references:dlp-filter:cms-type :content-transfer-encoding:mime-version:in-reply-to:message-id:date :subject:cc:to:from:dkim-signature:dkim-filter; bh=cp2ikyfpBdIhGRYkH19yhVPh/sP+Xdj/kjqikt163DM=; fh=qNr4TGVs+GGK7zFoSJi4oJ4YQRt9Kt5UIeYeRsPCb5w=; b=C25NFnLjzvUvIftL5mDtBISLLt3oINDo92mHoU/M8Fhg4I+s25TcS5iJItZ8Q498xy FgP0ZLiNkaVQTHl2ufzFoKSLqpVs57m/wub5FnM6SZyk5Z909ISuqi8oZaR4e2qzYw/0 g3WpxNJXABDSg7odq5D+h3IolpP82EGvFc4TVrA7kUoGZRZjRp0JzOOwVaeEpu2ZCV1q p1VwYNEUY4hLpK7lisCA6ovQ+jH8cNLDC9xcXJm+he8S540CELTwZhhjF/xcmz6cC2j+ /YY1jsfWjeez19iSTWEsOpcRip9SV47flMp8K+4UkE2FO5BhszpaL7hNLA5wkyrnJTQJ ehOA== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@samsung.com header.s=mail20170921 header.b=dF6zR1eD; 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=samsung.com Received: from out1.vger.email (out1.vger.email. [2620:137:e000::1:20]) by mx.google.com with ESMTP id pg4-20020a17090b1e0400b00263d1729212si5849566pjb.85.2023.08.11.04.53.36; Fri, 11 Aug 2023 04:53:50 -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=@samsung.com header.s=mail20170921 header.b=dF6zR1eD; 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=samsung.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S236452AbjHKLVQ (ORCPT + 99 others); Fri, 11 Aug 2023 07:21:16 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:39076 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S236448AbjHKLU5 (ORCPT ); Fri, 11 Aug 2023 07:20:57 -0400 Received: from mailout1.samsung.com (mailout1.samsung.com [203.254.224.24]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 20C512D52 for ; Fri, 11 Aug 2023 04:20:48 -0700 (PDT) Received: from epcas5p4.samsung.com (unknown [182.195.41.42]) by mailout1.samsung.com (KnoxPortal) with ESMTP id 20230811112043epoutp018751338f7672f182720524afbc50c6aa~6UD_KxLUR2822528225epoutp01k for ; Fri, 11 Aug 2023 11:20:43 +0000 (GMT) DKIM-Filter: OpenDKIM Filter v2.11.0 mailout1.samsung.com 20230811112043epoutp018751338f7672f182720524afbc50c6aa~6UD_KxLUR2822528225epoutp01k DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=samsung.com; s=mail20170921; t=1691752843; bh=cp2ikyfpBdIhGRYkH19yhVPh/sP+Xdj/kjqikt163DM=; h=From:To:Cc:Subject:Date:In-Reply-To:References:From; b=dF6zR1eD2GCylgh35ir+97k7SqRGn4xP8UjuTIBcMbAC5lBone9ptm5wP/Qc7kAkz 8vJQSDw4Ww1wAH1HNtq/0e/Bpb9bMdlDpYNCqCJCg9GSLKgzExdZ/RPvvp3xka0bpw UMw7tOfp+cn8XkoZFDD76UAeGVymnb4YXyHFqYWc= Received: from epsnrtp3.localdomain (unknown [182.195.42.164]) by epcas5p2.samsung.com (KnoxPortal) with ESMTP id 20230811112043epcas5p25d147b9f2216bcf295549d0750a03a75~6UD9abQAJ0760807608epcas5p2k; Fri, 11 Aug 2023 11:20:43 +0000 (GMT) Received: from epsmges5p1new.samsung.com (unknown [182.195.38.175]) by epsnrtp3.localdomain (Postfix) with ESMTP id 4RMhDS4Dsxz4x9Pr; Fri, 11 Aug 2023 11:20:40 +0000 (GMT) Received: from epcas5p2.samsung.com ( [182.195.41.40]) by epsmges5p1new.samsung.com (Symantec Messaging Gateway) with SMTP id 87.7D.55522.88916D46; Fri, 11 Aug 2023 20:20:40 +0900 (KST) Received: from epsmtrp1.samsung.com (unknown [182.195.40.13]) by epcas5p4.samsung.com (KnoxPortal) with ESMTPA id 20230811105819epcas5p40ddff0991c70b6d80d516dfe055bd673~6TwZyFW5P1386113861epcas5p4G; Fri, 11 Aug 2023 10:58:19 +0000 (GMT) Received: from epsmgmcp1.samsung.com (unknown [182.195.42.82]) by epsmtrp1.samsung.com (KnoxPortal) with ESMTP id 20230811105819epsmtrp1cae6dab938a725a7ce3ed467ec718df1~6TwZxHHYy0371503715epsmtrp1C; Fri, 11 Aug 2023 10:58:19 +0000 (GMT) X-AuditID: b6c32a49-67ffa7000000d8e2-10-64d61988985e Received: from epsmtip2.samsung.com ( [182.195.34.31]) by epsmgmcp1.samsung.com (Symantec Messaging Gateway) with SMTP id E2.23.64355.A4416D46; Fri, 11 Aug 2023 19:58:18 +0900 (KST) Received: from green245.sa.corp.samsungelectronics.net (unknown [107.99.41.245]) by epsmtip2.samsung.com (KnoxPortal) with ESMTPA id 20230811105814epsmtip2d7a93644a1886d650dc65130c3e958bb~6TwVB4lIO1103411034epsmtip28; Fri, 11 Aug 2023 10:58:13 +0000 (GMT) From: Nitesh Shetty To: Jens Axboe , Jonathan Corbet , Alasdair Kergon , Mike Snitzer , dm-devel@redhat.com, Keith Busch , Christoph Hellwig , Sagi Grimberg , Chaitanya Kulkarni , Alexander Viro , Christian Brauner Cc: martin.petersen@oracle.com, mcgrof@kernel.org, dlemoal@kernel.org, gost.dev@samsung.com, Nitesh Shetty , linux-block@vger.kernel.org, linux-kernel@vger.kernel.org, linux-doc@vger.kernel.org, linux-nvme@lists.infradead.org, linux-fsdevel@vger.kernel.org Subject: [PATCH v14 10/11] dm: Enable copy offload for dm-linear target Date: Fri, 11 Aug 2023 16:22:53 +0530 Message-Id: <20230811105300.15889-11-nj.shetty@samsung.com> X-Mailer: git-send-email 2.35.1.500.gb896f729e2 In-Reply-To: <20230811105300.15889-1-nj.shetty@samsung.com> MIME-Version: 1.0 X-Brightmail-Tracker: H4sIAAAAAAAAA+NgFvrIJs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IPx8unLNj9K9/27fafnxqlpkW63 o/e+2BHorPBTmXHbJMNlL9ZNmbsrZ8c2i///PvoITWz7ymYQsHGlqbJ9VfX9HzZe0+u5pyzS e//+llVouPdN1q7yt7cj3r9749iwkSnfbv7P8zkLzI9Lv02bvOV21cLMz5pbvyzPTp7xzUFx R/OTJal7c/Y3v8o6xcCVOX0/P1eS7fvGqDm11zTTp8XKO+w0r1c4WRYd/SRKre/YednMeMFV LSIvjx8M/9SY3j4v+sncuMdT5h1jnOCbzyR0rnPdiVXsrTHzlFiKMxINtZiLihMB2tOUUzgD AAA= X-CMS-MailID: 20230811105819epcas5p40ddff0991c70b6d80d516dfe055bd673 X-Msg-Generator: CA X-Sendblock-Type: REQ_APPROVE CMS-TYPE: 105P DLP-Filter: Pass X-CFilter-Loop: Reflected X-CMS-RootMailID: 20230811105819epcas5p40ddff0991c70b6d80d516dfe055bd673 References: <20230811105300.15889-1-nj.shetty@samsung.com> X-Spam-Status: No, score=-2.1 required=5.0 tests=BAYES_00,DKIMWL_WL_HIGH, DKIM_SIGNED,DKIM_VALID,DKIM_VALID_AU,DKIM_VALID_EF, RCVD_IN_DNSWL_BLOCKED,RCVD_IN_MSPIKE_H3,RCVD_IN_MSPIKE_WL, SPF_HELO_PASS,SPF_PASS,URIBL_BLOCKED autolearn=unavailable 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 X-getmail-retrieved-from-mailbox: INBOX X-GMAIL-THRID: 1773933513450936716 X-GMAIL-MSGID: 1773933513450936716 Setting copy_offload_supported flag to enable offload. Signed-off-by: Nitesh Shetty --- drivers/md/dm-linear.c | 1 + 1 file changed, 1 insertion(+) diff --git a/drivers/md/dm-linear.c b/drivers/md/dm-linear.c index f4448d520ee9..1d1ee30bbefb 100644 --- a/drivers/md/dm-linear.c +++ b/drivers/md/dm-linear.c @@ -62,6 +62,7 @@ static int linear_ctr(struct dm_target *ti, unsigned int argc, char **argv) ti->num_discard_bios = 1; ti->num_secure_erase_bios = 1; ti->num_write_zeroes_bios = 1; + ti->copy_offload_supported = 1; ti->private = lc; return 0;