Received: by 2002:ac0:e350:0:0:0:0:0 with SMTP id g16csp133567imn; Fri, 29 Jul 2022 02:06:42 -0700 (PDT) X-Google-Smtp-Source: AGRyM1sL6l7vfEQOi0BIZ7uTD48d9VsoilnrQW37yMOg3q3d5gUG8Mgnul/qjot8uM+BPQjG+Me8 X-Received: by 2002:a17:907:75d7:b0:72b:307d:fb60 with SMTP id jl23-20020a17090775d700b0072b307dfb60mr2271880ejc.22.1659085602013; Fri, 29 Jul 2022 02:06:42 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1659085602; cv=none; d=google.com; s=arc-20160816; b=Gv38FDx3Rg0YFelqpzAYq1eAsF5qyhYIQ67mitZrX5dVtdk4b6gwUI0HY2byMuE8aT vbUTbtX0ukHz7WHmk48cqAafS+FaAKE5nTKyCE3Qh2epcFVyzcpqI88NXAU0ty/JoB7y XQJJMnQhHv0EArDLqYoA2EJfsJYDXN0m7R8/hdEZoJlKQ7rMA6rKtRt5HHPm7EpN9jpz pkhrpAL+r48zuE3m4lQNCGiSTCUoij8wkdHbOhB5VQoyNGfYijwRUH/efqgSpt4vUKrf 6nHsHpKnCzhcwZHC8jrKVmWOGNrg4bTU35bNCmYhhp1Dc3Tj54raiFVKd4vUJ5cmhoim nz8g== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:references:cms-type:content-transfer-encoding :in-reply-to:from:cc:to:content-language:subject:user-agent :mime-version:date:message-id:dkim-signature:dkim-filter; bh=J7pf8l02sZv1evRPs/g74/E4T+W0WimSo4Amwk96bHc=; b=yR3HzCDUChtXVya9SjjFn8WXbvqIWXQeXkOeL2U5Hc0w8V1k8pL1iM2Ye5evi3+ZBC dKAsO8gREOOnnXMvXhXxya3TVxDEXg1bmaCaKcFF5pLxZoNZHWA2EKP/v3aZ2SxbJGVY O3zhnGyq8pWZXMPbaVczC2vtrhaCVDSGoLhJvbIEPbEM14d8/elC3VCHuubn44gKYG34 zPpMhnPmb4GB7SfPyo1+ib/QPwNVFSYE9YRO/hz+S1bhAdY9efD17QHRqPlcyRVKOOYV DJloe9J4rwlj6voXtKMT+yvpWz+LFFiMWb9wGJSPFV2n2vpo5ifAW+Po2JK03LWTRyX5 bgoQ== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@samsung.com header.s=mail20170921 header.b=runBe9DO; 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 Return-Path: Received: from out1.vger.email (out1.vger.email. [2620:137:e000::1:20]) by mx.google.com with ESMTP id k27-20020a1709061c1b00b0072b87f68d25si2223910ejg.542.2022.07.29.02.06.17; Fri, 29 Jul 2022 02:06:41 -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=runBe9DO; 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 S234896AbiG2IsR (ORCPT + 99 others); Fri, 29 Jul 2022 04:48:17 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:55104 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S234639AbiG2IsQ (ORCPT ); Fri, 29 Jul 2022 04:48:16 -0400 Received: from mailout2.w1.samsung.com (mailout2.w1.samsung.com [210.118.77.12]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 91FC267C82 for ; Fri, 29 Jul 2022 01:48:13 -0700 (PDT) Received: from eucas1p1.samsung.com (unknown [182.198.249.206]) by mailout2.w1.samsung.com (KnoxPortal) with ESMTP id 20220729084811euoutp02ff283f5c2f906a6144ec7322a181ac7f~GQI4X0JMP0702707027euoutp02D for ; Fri, 29 Jul 2022 08:48:11 +0000 (GMT) DKIM-Filter: OpenDKIM Filter v2.11.0 mailout2.w1.samsung.com 20220729084811euoutp02ff283f5c2f906a6144ec7322a181ac7f~GQI4X0JMP0702707027euoutp02D DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=samsung.com; s=mail20170921; t=1659084491; bh=J7pf8l02sZv1evRPs/g74/E4T+W0WimSo4Amwk96bHc=; h=Date:Subject:To:CC:From:In-Reply-To:References:From; b=runBe9DOjcJjKFbe4TBs6r3p6p1GXrjrRvv+v7bR9QSSOEChGy1dzsAmrbOUZPkD+ GDwAieVRhPb2e0MObsJqlPPIdyZ/ttHrU+7pCsD3w+5opko04b7tEzOSaotdQk/7g3 9zIiYjlaSwFKXC9v2PWp7qC/idCmjuU/gDOKJO2U= Received: from eusmges2new.samsung.com (unknown [203.254.199.244]) by eucas1p2.samsung.com (KnoxPortal) with ESMTP id 20220729084811eucas1p29c708be560495e380d2ba54446086657~GQI4AoB3p3148931489eucas1p2D; Fri, 29 Jul 2022 08:48:11 +0000 (GMT) Received: from eucas1p2.samsung.com ( [182.198.249.207]) by eusmges2new.samsung.com (EUCPMTA) with SMTP id 16.90.10067.BCE93E26; Fri, 29 Jul 2022 09:48:11 +0100 (BST) Received: from eusmtrp1.samsung.com (unknown [182.198.249.138]) by eucas1p1.samsung.com (KnoxPortal) with ESMTPA id 20220729084810eucas1p1e495e9f4378f515ddc42e7fb54690c8c~GQI3oGuWO2521325213eucas1p1q; Fri, 29 Jul 2022 08:48:10 +0000 (GMT) Received: from eusmgms1.samsung.com (unknown [182.198.249.179]) by eusmtrp1.samsung.com (KnoxPortal) with ESMTP id 20220729084810eusmtrp1fcf915da651f0bc849b5f10ce7b597ea~GQI3nRaJm3175431754eusmtrp17; Fri, 29 Jul 2022 08:48:10 +0000 (GMT) X-AuditID: cbfec7f4-dc1ff70000002753-4b-62e39ecb5a6f Received: from eusmtip1.samsung.com ( [203.254.199.221]) by eusmgms1.samsung.com (EUCPMTA) with SMTP id 30.AB.09095.ACE93E26; Fri, 29 Jul 2022 09:48:10 +0100 (BST) Received: from CAMSVWEXC01.scsc.local (unknown [106.1.227.71]) by eusmtip1.samsung.com (KnoxPortal) with ESMTPA id 20220729084810eusmtip122adeb7211a38b2523b3a9e055ee2d0e~GQI3b6Uya1554515545eusmtip1y; Fri, 29 Jul 2022 08:48:10 +0000 (GMT) Received: from [192.168.8.130] (106.210.248.8) by CAMSVWEXC01.scsc.local (2002:6a01:e347::6a01:e347) with Microsoft SMTP Server (TLS) id 15.0.1497.2; Fri, 29 Jul 2022 09:48:08 +0100 Message-ID: <7fe560c6-4078-f89a-892d-d79b52664045@samsung.com> Date: Fri, 29 Jul 2022 10:48:06 +0200 MIME-Version: 1.0 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:91.0) Gecko/20100101 Thunderbird/91.11.0 Subject: Re: [PATCH v8 10/11] dm: call dm_zone_endio after the target endio callback for zoned devices Content-Language: en-US To: Damien Le Moal , , , , CC: , , , , , , , , , From: Pankaj Raghav In-Reply-To: <2b1ab4ac-a355-dfb4-6ca4-82fe36a38433@opensource.wdc.com> Content-Type: text/plain; charset="UTF-8" Content-Transfer-Encoding: 7bit X-Originating-IP: [106.210.248.8] X-ClientProxiedBy: CAMSVWEXC01.scsc.local (2002:6a01:e347::6a01:e347) To CAMSVWEXC01.scsc.local (2002:6a01:e347::6a01:e347) X-Brightmail-Tracker: H4sIAAAAAAAAA+NgFrrFKsWRmVeSWpSXmKPExsWy7djP87qn5z1OMth8XcBi9d1+NotpH34y W/w+e57ZYu+72awWexZNYrJYufook8WT9bOYLf523WOy2HtL2+LyrjlsFvOXPWW3mND2ldli zc2nLBYnbkk78HlcvuLtsXPWXXaPy2dLPTat6mTz2Lyk3mP3zQY2j52t91k93u+7ChQ6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pYHX6vxFKckWio xVxUnAgAdiWloqQDAAA= X-CMS-MailID: 20220729084810eucas1p1e495e9f4378f515ddc42e7fb54690c8c X-Msg-Generator: CA X-RootMTR: 20220727162256eucas1p284a15532173cce3eca46eee0cee3acdd X-EPHeader: CA CMS-TYPE: 201P X-CMS-RootMailID: 20220727162256eucas1p284a15532173cce3eca46eee0cee3acdd References: <20220727162245.209794-1-p.raghav@samsung.com> <20220727162245.209794-11-p.raghav@samsung.com> <2b1ab4ac-a355-dfb4-6ca4-82fe36a38433@opensource.wdc.com> X-Spam-Status: No, score=-7.7 required=5.0 tests=BAYES_00,DKIMWL_WL_HIGH, DKIM_SIGNED,DKIM_VALID,DKIM_VALID_AU,DKIM_VALID_EF,NICE_REPLY_A, RCVD_IN_DNSWL_HI,RCVD_IN_MSPIKE_H3,RCVD_IN_MSPIKE_WL,SPF_HELO_PASS, SPF_PASS 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 >> if (endio) { >> int r = endio(ti, bio, &error); >> switch (r) { >> @@ -1155,6 +1151,10 @@ static void clone_endio(struct bio *bio) >> } >> } >> >> + if (static_branch_unlikely(&zoned_enabled) && >> + unlikely(bdev_is_zoned(bio->bi_bdev))) >> + dm_zone_endio(io, bio); >> + >> if (static_branch_unlikely(&swap_bios_enabled) && >> unlikely(swap_bios_limit(ti, bio))) >> up(&md->swap_bios_semaphore); > > This patch seems completely unrelated to the series topic. Is that a bug > fix ? How do you trigger it ? Our tests do not show any issues here... > If this triggers only with non power of 2 zone size devices, then this > should be squashed in patch 8. And patch 9 could also be squashed with > patch 8 too. > The targets that support zoned devices such as dm-zoned, dm-linear, and dm-crypt do not have an endio function, and even if they do (such as dm-flakey), they don't modify the bio->bi_iter.bi_sector of the cloned bio that is used to update the orig_bio's bi_sector in dm_zone_endio function. This path is triggered only for the new target dm-po2zone and not for npo2 zone size devices in general. I will mention this is a prep patch for the new target because I wouldn't call it a bug per se.