Received: by 2002:a05:6a10:6d10:0:0:0:0 with SMTP id gq16csp923329pxb; Fri, 22 Apr 2022 14:25:19 -0700 (PDT) X-Google-Smtp-Source: ABdhPJz5RJmoo2fiHvtSH2mIC8icg50x/UKduLPit2C5y0sY/Ywr2kKABsDHZFGWjdF1jCgxZuLs X-Received: by 2002:aa7:8215:0:b0:4f7:125a:c88c with SMTP id k21-20020aa78215000000b004f7125ac88cmr7020888pfi.70.1650662719233; Fri, 22 Apr 2022 14:25:19 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1650662719; cv=none; d=google.com; s=arc-20160816; b=EJM9PN2fe4wDCobdMVLHox4iMEH2hIh3HBLfEMZ4rgHcXZ68hWTI9CslKmvpfrfp+K s2uUn4uoRtPnFeeP0eiJgdYepl8Pp0FpsZadGHuNdzFAaGP+xIJAKR2ArxpHrsGGG+on MGu57z9h2MBaor7uhk/8pqio14Sdszse+2R8v27MwXAS2IujRwQWzLELNaKNIV1Lp9da ElgQ3u6naystXJoqivTf2wq8dZY0ehNZqaNb5cILJtGP2OYSby6PZyZWOvZ8kuLIbP0r QpcuONkpJd9nau9fSvf64R8ymyehrrsA3G2RpjmkV1M96i3tqfKtzZV//9uvGlaa2Zjz 8E6w== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:in-reply-to:content-disposition:mime-version :references:message-id:subject:cc:to:from:date:dkim-signature; bh=xlBQ6DVKGvFJX+Ldx3rdWv/HFspbxlibkRveNNlmLbM=; b=GlGKoo/P4Fb9uSIfQ6PGuN6LpRjRk+l0x2uzRRs5j6uU83ghj8q+C5b/ypMWlZ0CKQ 6YIwgQSw2LxfI3aeShqZM4/9mvdm9JPqOtuqxE5s1pRKZLnuv7cBeI6ImuiVClTYgICT ssjBFkGiaGPNb6b7egXGYhdfqIO4eTn3ZFcUz43t031FO5BpD3nD3X6RgdXEifRY5zpY Ldd5fGTx5rotOkgv0JF6WJuPz41NZT4D5dl1nb+ySZoGR63wvjQvY6KAiT2RwMWfn20u qp2U/dkVEPlgqyD2Z5/OJKAt7PrIjXmC0VXijJyMtEiU/vXIsU+b3T9/DRfQd4qCdDsm iTsg== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@infradead.org header.s=bombadil.20210309 header.b=ug8j40B6; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Return-Path: Received: from lindbergh.monkeyblade.net (lindbergh.monkeyblade.net. [2620:137:e000::1:18]) by mx.google.com with ESMTPS id k7-20020a63ab47000000b00382b764a7a9si9519062pgp.731.2022.04.22.14.25.18 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Fri, 22 Apr 2022 14:25:19 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:18 as permitted sender) client-ip=2620:137:e000::1:18; Authentication-Results: mx.google.com; dkim=pass header.i=@infradead.org header.s=bombadil.20210309 header.b=ug8j40B6; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Received: from out1.vger.email (out1.vger.email [IPv6:2620:137:e000::1:20]) by lindbergh.monkeyblade.net (Postfix) with ESMTP id 6F5B22CC1A7; Fri, 22 Apr 2022 12:32:44 -0700 (PDT) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1384771AbiDUGVp (ORCPT + 99 others); Thu, 21 Apr 2022 02:21:45 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:58440 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1352817AbiDUGVn (ORCPT ); Thu, 21 Apr 2022 02:21:43 -0400 Received: from bombadil.infradead.org (bombadil.infradead.org [IPv6:2607:7c80:54:e::133]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id B7416BC2B; Wed, 20 Apr 2022 23:18:55 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=infradead.org; s=bombadil.20210309; h=In-Reply-To:Content-Type:MIME-Version :References:Message-ID:Subject:Cc:To:From:Date:Sender:Reply-To: Content-Transfer-Encoding:Content-ID:Content-Description; bh=xlBQ6DVKGvFJX+Ldx3rdWv/HFspbxlibkRveNNlmLbM=; b=ug8j40B6lWGt+wzhUTXj7e353L gJ4Bo/pvrUNY75psm5ERq71079ac/QEKwfkQZXEc0dKCAXNuoiTkVplW+XfWLyd3Kcbn4NLeTFk8/ CWYYY8/aQFy6J1s+IE6OtE9TVksfH751fx0T0NRQzIoi4PCXQOvPwsiS1bFnTYYwbBCl6lvfevuto j1xnoqWAKx1mjzB4N1sTzM2E5FkoM3yyBgja95DbZhY/znKbEN7krEt753Oo2qMjefVGALyBTm+4v YvQoxX+U2FNxDaZ3+lapRetBuRcdlTUGd2mPRaXmZ8UxxgoZKxVQmwYbTTD7lGhYUYCHW3uSr4pOm hy1M7Ruw==; Received: from hch by bombadil.infradead.org with local (Exim 4.94.2 #2 (Red Hat Linux)) id 1nhQ9X-00Bfqb-83; Thu, 21 Apr 2022 06:18:55 +0000 Date: Wed, 20 Apr 2022 23:18:55 -0700 From: Christoph Hellwig To: Logan Gunthorpe Cc: linux-kernel@vger.kernel.org, linux-raid@vger.kernel.org, Song Liu , Christoph Hellwig , Guoqing Jiang , Stephen Bates , Martin Oliveira , David Sloan Subject: Re: [PATCH v2 11/12] md/raid5: Check all disks in a stripe_head for reshape progress Message-ID: References: <20220420195425.34911-1-logang@deltatee.com> <20220420195425.34911-12-logang@deltatee.com> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <20220420195425.34911-12-logang@deltatee.com> X-SRS-Rewrite: SMTP reverse-path rewritten from by bombadil.infradead.org. See http://www.infradead.org/rpr.html X-Spam-Status: No, score=-2.0 required=5.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID,DKIM_VALID_AU,HEADER_FROM_DIFFERENT_DOMAINS, MAILING_LIST_MULTI,RDNS_NONE,SPF_HELO_NONE autolearn=no 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 On Wed, Apr 20, 2022 at 01:54:24PM -0600, Logan Gunthorpe wrote: > +static bool range_ahead_of_reshape(struct mddev *mddev, sector_t min, > + sector_t max, sector_t reshape_sector) > +{ > + if (mddev->reshape_backwards) > + return max < reshape_sector; > + else > + return min >= reshape_sector; > +} Nit: no need for the return. Otherwise looks good: Reviewed-by: Christoph Hellwig