From patchwork Wed Jun 14 08:47:37 2023 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Li Nan X-Patchwork-Id: 10752 Return-Path: Delivered-To: ouuuleilei@gmail.com Received: by 2002:a59:994d:0:b0:3d9:f83d:47d9 with SMTP id k13csp1101260vqr; Wed, 14 Jun 2023 02:12:20 -0700 (PDT) X-Google-Smtp-Source: ACHHUZ6Z9NFyyFkT7a2/GE8+RTdA42WFItdqUhKGQyZYpTOncIqm2h8Kp8WwVu/Rps+vCDzpxbbv X-Received: by 2002:a2e:9b44:0:b0:2b3:3404:baaf with SMTP id o4-20020a2e9b44000000b002b33404baafmr2620024ljj.19.1686733939917; Wed, 14 Jun 2023 02:12:19 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1686733939; cv=none; d=google.com; s=arc-20160816; b=DAB0sZJAZGtNAsCV2xaJo38rz/z3So5+K1S7q1RR99up2y7LQlMsmdOvcIoK7vT+Ju B6i/ylpEr+lTuhrmy9d647VNIZL/S/zGaB6xCw0x1buqPVK+DomksYkhyN1MTCzy931w +7aBXdNxR7oExHjlnfJVQ6CBe1zjn6CYz5qZABA5kB/A0zcb+iEvpSa2MlNBUV7CcAjG UZsVZ2L2qNCCEoaKVPzhIGQ9gaiD7/4LLCSSCgxrx7A/LWXr4FvNATUcEWBx2RP7fOCE 9IoUhtTamcLQwaoAuFkMqavy90BbPFwpkNGJoVogC7VgwcrSnOtjAHp4hA3UXheU3Elf 8d4g== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:content-transfer-encoding:mime-version :message-id:date:subject:cc:to:from; bh=EAhU2D4N1eR7zQTkNmA9sUcKimPBB5tvEDyz3kGLojg=; b=UA+PYDOJP0y/thKGvqm6AZEBL9IHLmLDQU5LLpL0KE4pl7v87H7Y+jFBwG5camYdnP 1mW9s4h0UuDTnG0u7aDeSyCO6ai1eyhgeNMFqdXYp15RV8+auqBnPgWojQPm1DN1w9F3 WVRwF9m+EmDzaZ3elcLkdSMpcGb+IbEoB0NXdvbCbo8Dx4acZqZGALgIwbWX3zR8l0RV OBqIgWdTkQM6sfCPIKtgEWIp9CKW1c/cUa2e0MV0RORb4W9lGLJ5ADQEyeOXbDlkq3sd hv89bvNFC1zSLI5QKPkP0cf3/N4Z3UUv5iJMjYIso3xH7fCt3vFzME7cWPED+amJDceb fqPQ== ARC-Authentication-Results: i=1; mx.google.com; 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 Received: from out1.vger.email (out1.vger.email. [2620:137:e000::1:20]) by mx.google.com with ESMTP id e18-20020a056402089200b00514a6d05de1si8713841edy.409.2023.06.14.02.11.44; Wed, 14 Jun 2023 02:12:19 -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; 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 Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S243840AbjFNIwu (ORCPT + 99 others); Wed, 14 Jun 2023 04:52:50 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:43134 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S243813AbjFNIwf (ORCPT ); Wed, 14 Jun 2023 04:52:35 -0400 Received: from dggsgout11.his.huawei.com (unknown [45.249.212.51]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 0D5BD271C; Wed, 14 Jun 2023 01:52:16 -0700 (PDT) Received: from mail02.huawei.com (unknown [172.30.67.153]) by dggsgout11.his.huawei.com (SkyGuard) with ESMTP id 4Qgzgw2HXrz4f3prD; Wed, 14 Jun 2023 16:52:12 +0800 (CST) Received: from huaweicloud.com (unknown [10.175.104.67]) by APP4 (Coremail) with SMTP id gCh0CgBnHbG7f4lks7u0Lg--.65484S4; Wed, 14 Jun 2023 16:52:13 +0800 (CST) From: linan666@huaweicloud.com To: song@kernel.org, neilb@suse.de Cc: linux-raid@vger.kernel.org, linux-kernel@vger.kernel.org, linan122@huawei.com, yukuai3@huawei.com, yi.zhang@huawei.com, houtao1@huawei.com, yangerkun@huawei.com Subject: [PATCH 0/3] md/raid10: record rdev/replacement in r10bio Date: Wed, 14 Jun 2023 16:47:37 +0800 Message-Id: <20230614084740.1493969-1-linan666@huaweicloud.com> X-Mailer: git-send-email 2.39.2 MIME-Version: 1.0 X-CM-TRANSID: gCh0CgBnHbG7f4lks7u0Lg--.65484S4 X-Coremail-Antispam: 1UD129KBjvdXoWrKr1fAr17WF45Kr1xtrWUArb_yoWxtrcE9F y0vFy3Jr4Dt3WfCa4jkF1UXF9xua1Uury3Jas0qrWrXF9ruF47Jrn0grWxWw1fWFyvyF1U tr18WryxAr17ZjkaLaAFLSUrUUUUUb8apTn2vfkv8UJUUUU8Yxn0WfASr-VFAUDa7-sFnT 9fnUUIcSsGvfJTRUUUb4kYFVCjjxCrM7AC8VAFwI0_Gr0_Xr1l1xkIjI8I6I8E6xAIw20E Y4v20xvaj40_Wr0E3s1l1IIY67AEw4v_Jr0_Jr4l8cAvFVAK0II2c7xJM28CjxkF64kEwV A0rcxSw2x7M28EF7xvwVC0I7IYx2IY67AKxVW7JVWDJwA2z4x0Y4vE2Ix0cI8IcVCY1x02 67AKxVW8Jr0_Cr1UM28EF7xvwVC2z280aVAFwI0_GcCE3s1l84ACjcxK6I8E87Iv6xkF7I 0E14v26rxl6s0DM2vYz4IE04k24VAvwVAKI4IrM2AIxVAIcxkEcVAq07x20xvEncxIr21l 5I8CrVACY4xI64kE6c02F40Ex7xfMcIj6xIIjxv20xvE14v26r1j6r18McIj6I8E87Iv67 AKxVWUJVW8JwAm72CE4IkC6x0Yz7v_Jr0_Gr1lF7xvr2IYc2Ij64vIr41lw4CEc2x0rVAK j4xxMxAIw28IcxkI7VAKI48JMxC20s026xCaFVCjc4AY6r1j6r4UMI8I3I0E5I8CrVAFwI 0_Jr0_Jr4lx2IqxVCjr7xvwVAFwI0_JrI_JrWlx4CE17CEb7AF67AKxVWUtVW8ZwCIc40Y 0x0EwIxGrwCI42IY6xIIjxv20xvE14v26r1j6r1xMIIF0xvE2Ix0cI8IcVCY1x0267AKxV WUJVW8JwCI42IY6xAIw20EY4v20xvaj40_WFyUJVCq3wCI42IY6I8E87Iv67AKxVWUJVW8 JwCI42IY6I8E87Iv6xkF7I0E14v26r4j6r4UJbIYCTnIWIevJa73UjIFyTuYvjxUwc_TUU UUU X-CM-SenderInfo: polqt0awwwqx5xdzvxpfor3voofrz/ X-CFilter-Loop: Reflected X-Spam-Status: No, score=-1.9 required=5.0 tests=BAYES_00,KHOP_HELO_FCRDNS, SPF_HELO_NONE,SPF_NONE,T_SCC_BODY_TEXT_LINE 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 X-getmail-retrieved-from-mailbox: =?utf-8?q?INBOX?= X-GMAIL-THRID: =?utf-8?q?1768668728037005678?= X-GMAIL-MSGID: =?utf-8?q?1768668728037005678?= From: Li Nan Replacement can replace rdev during replacement io pending. mirror->rdev/replacement might be changed during io pending. Get rdev from it is risky. This patch series record rdev/replacement in r10bio, and get rdev from r10bio to fix bugs in normal write. And I want to do this for each io type later. Li Nan (3): md/raid10: record rdev/replacement in struct r10bio md/raid10: get rdev/replacemenet from r10bio for normal write md/raid10: improve raid10_end_write_request() drivers/md/raid10.c | 96 ++++++++++++++++++++++----------------------- drivers/md/raid10.h | 12 +++--- 2 files changed, 54 insertions(+), 54 deletions(-)