Received: by 2002:ac0:e34a:0:0:0:0:0 with SMTP id g10csp36054imn; Wed, 27 Jul 2022 14:26:54 -0700 (PDT) X-Google-Smtp-Source: AGRyM1tcsdwc0x9HrH4SvgeThqI+gTZCadbraiIxJz4vlt4GLe7/0cdxah1HJHs3vn9+MNpIiyGr X-Received: by 2002:a05:6a00:234c:b0:52b:7cb:ed9d with SMTP id j12-20020a056a00234c00b0052b07cbed9dmr23960428pfj.32.1658957214517; Wed, 27 Jul 2022 14:26:54 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1658957214; cv=none; d=google.com; s=arc-20160816; b=Az+TLpdWfSlhdKBkrd2eta9JCS05b1jVzxeK1sU8vd439bmUV2GR0OUEPKaVlgMYRe Udt7Nb7bMQaHcL7zMVqW+BzziFRy+aziJkw3lZMDHIeH4mLGznjBT/KB/9udIeCFyoJ5 CBneFvn0/kN13kJyFzixvVLOYOWkKYLOwWmkISCpMvzP35ZnXk5NvyJWjIocQIKzOO8T mg8k27U77w+J5cvVKCNoyIYnze8AKHOJplnl+Kud7ZqNqglFBXLi5K5NF2lUw7sXVZE4 TNbDccR0MSFxt58I9F+sP89wNyoyIEhHhrme4sy4jUMS8i0S9RnIOe/AcqS8GuWcpsTG uLgg== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:subject:content-transfer-encoding:mime-version :message-id:date:cc:to:from:dkim-signature; bh=pbiuIq9jtjkddiglS5lYviW8nD5Vw/eI1dLbTz+VrxU=; b=RxoC6T6P7Q6kBt6S5aLFRSK2FylxqmaviXNai0X7cnIYGMVkjJySZamhTFvChSFgsR 5nw4NwMC50/dJ0eHfK3y645cYrnUS94fJY4cAZf9rFUnRTC5w+ipQCcIIy0uQB8UgzBm 5Tamjv9R1TKbCPW9faOE3EDPioTCjEh/O7JKPVCN6uQU9/3StwjXvVRPkN57IwdkAh0S 8XGSSErHPX/On5oSL39SabUqecAAFt7MXGxTuVmi37S+8td2MDUm27MLGcuMSMal63WF Jb8LFzXzqEbPGprujVcUQVfatxpRN+t7zC9xYeD6ssVgnjtcw/2YafEU+Oe1G/uyaahz j1cw== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@deltatee.com header.s=20200525 header.b=LbKb5LqY; 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=deltatee.com Return-Path: Received: from out1.vger.email (out1.vger.email. [2620:137:e000::1:20]) by mx.google.com with ESMTP id q4-20020a17090311c400b0016d2c5285e4si23505990plh.413.2022.07.27.14.26.16; Wed, 27 Jul 2022 14:26:54 -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=@deltatee.com header.s=20200525 header.b=LbKb5LqY; 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=deltatee.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S237543AbiG0VIx (ORCPT + 99 others); Wed, 27 Jul 2022 17:08:53 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:55926 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S236522AbiG0VIa (ORCPT ); Wed, 27 Jul 2022 17:08:30 -0400 Received: from ale.deltatee.com (ale.deltatee.com [204.191.154.188]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 68DCB61B0E; Wed, 27 Jul 2022 14:06:22 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=deltatee.com; s=20200525; h=Subject:MIME-Version:Message-Id:Date:Cc:To:From :references:content-disposition:in-reply-to; bh=pbiuIq9jtjkddiglS5lYviW8nD5Vw/eI1dLbTz+VrxU=; b=LbKb5LqYGKVbOT8Nx2rV/kfSpI h50N439y/MEYnB/m9W4ZOEXAmoS4HFGi0CJY6hmF8CmcO+3bR+n7YA+Qq8gI94Tt9Ey3OIwSfa33a ctglrElWde7QZvkuuCc7ogCTP9FLFvTXFHzIx6aJUGo0BMxpzDhaa/QxCMjNZUTYtqksbltEY4PiH vhmw1VUAr3t5RRkrwjNN72+0o2KfKlCv4iVgW34Wv+V12kL7l6y+F+ohwnCvuf+biQqvXOnVP5gZp BkJu5Ti29gyrEfDFH2psv0ZS1lvmmtjFTRO+wKzB+K5olbph9sZaUFeLa2A3ia6p2gnjVteqj2hib EHv54lzg==; Received: from cgy1-donard.priv.deltatee.com ([172.16.1.31]) by ale.deltatee.com with esmtps (TLS1.3) tls TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384 (Exim 4.94.2) (envelope-from ) id 1oGoEG-001pyC-GI; Wed, 27 Jul 2022 15:06:05 -0600 Received: from gunthorp by cgy1-donard.priv.deltatee.com with local (Exim 4.94.2) (envelope-from ) id 1oGoEE-000VHv-II; Wed, 27 Jul 2022 15:06:02 -0600 From: Logan Gunthorpe To: linux-kernel@vger.kernel.org, linux-raid@vger.kernel.org, Song Liu Cc: Christoph Hellwig , Guoqing Jiang , Stephen Bates , Martin Oliveira , David Sloan , Logan Gunthorpe Date: Wed, 27 Jul 2022 15:05:55 -0600 Message-Id: <20220727210600.120221-1-logang@deltatee.com> X-Mailer: git-send-email 2.30.2 MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-SA-Exim-Connect-IP: 172.16.1.31 X-SA-Exim-Rcpt-To: linux-kernel@vger.kernel.org, linux-raid@vger.kernel.org, song@kernel.org, hch@infradead.org, guoqing.jiang@linux.dev, sbates@raithlin.com, Martin.Oliveira@eideticom.com, David.Sloan@eideticom.com, logang@deltatee.com X-SA-Exim-Mail-From: gunthorp@deltatee.com X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on lindbergh.monkeyblade.net X-Spam-Level: X-Spam-Status: No, score=-2.1 required=5.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID,DKIM_VALID_AU,DKIM_VALID_EF,SPF_HELO_PASS,SPF_PASS autolearn=ham autolearn_force=no version=3.4.6 Subject: [PATCH 0/5] Bug fix for recent batching change X-SA-Exim-Version: 4.2.1 (built Sat, 13 Feb 2021 17:57:42 +0000) X-SA-Exim-Scanned: Yes (on ale.deltatee.com) Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Hey, We hit another bug on my recent batching patch. In this case the bug has never been hit with the current md/md-next branch but some other patches we were working on changed the timing such that we hit this bug. It is theoretically possible to hit in the md/md-next batch so this patchset contains a fix. The fix is the last commit. The first four commits are some basic refactoring that makes the final commit a bit easier. A git repo is here and is based on current md/md-next (7a6f9e9cf1): https://github.com/sbates130272/linux-p2pmem raid5_batch_quiesce Thanks, Logan -- Logan Gunthorpe (5): md/raid5: Refactor raid5_get_active_stripe() md/raid5: Make is_inactive_blocked() helper md/raid5: Drop unnecessary call to r5c_check_stripe_cache_usage() md/raid5: Move stripe_request_ctx up md/raid5: Ensure batch_last is released before sleeping for quiesce drivers/md/raid5.c | 162 ++++++++++++++++++++++++++++----------------- drivers/md/raid5.h | 2 +- 2 files changed, 101 insertions(+), 63 deletions(-) base-commit: 7a6f9e9cf1befa0a1578501966d3c9b0cae46727 -- 2.30.2