Received: by 2002:a05:7412:37c9:b0:e2:908c:2ebd with SMTP id jz9csp1144150rdb; Wed, 20 Sep 2023 00:17:59 -0700 (PDT) X-Google-Smtp-Source: AGHT+IGrMb0L2Bfx8iFsa6/hMFr1BJYLmDpwSn/6fgHkwMcBVlwJSdBTMZWWqQzwZGWUjqiQgX/v X-Received: by 2002:a05:6a00:21c6:b0:690:3f29:a874 with SMTP id t6-20020a056a0021c600b006903f29a874mr1773894pfj.23.1695194279313; Wed, 20 Sep 2023 00:17:59 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1695194279; cv=none; d=google.com; s=arc-20160816; b=M5XfP6KOu6Y0iycy3m0hiUpw4quWeQjxTa9T0KG5QNzXpd/vQj5vMX+Teu8b9MG4mQ HBuIxNElKd+y09M9jA8NsV+P4AY9O1sQ3ngJdNKt/9pGkADO5Yf/UQJ44AwWnWUz2btj tF2jUPjqVnkB2HtfVLMurE3IEQxtqF+Ut4c9+nu4zMExCkHcdWJveBvw/NJImwxO+egL xM104UzVKNN3h2kHRz49Shm68Dsvb/Z3Bi6Kj5Bb/j0zhGsUhVhJtwvjVa7b8cSZKpzs yPJLqVGSvsPKBduKADJL9gh7bJJSi+3Dd1Pso/VXhUTtP1k/yDMgQq1YrTxZQFufwheT d/jg== 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=uE+UAnC9YgmNAUhKoTWIdxRk/FdOddBgLymLwlPaqnk=; fh=cNZnyw59k30LYFm/cx7WqIuIvVQgPC4uJhnqUaYgZq8=; b=T35P7KUksKQMj1/tfbH8d5m3ZzjHnkMELImpljbhZfkMCBToVz4XtLuSK0SxEsly/T qCq8X92hCIBB7Xf6Kwl3pyefTmiLwOE1WJgCIDJi+VspWplynaAVrzux63C5tq5RgK6E q+2T/atEvPvhbvwXhDi24Hh40KIKtGARTmc/wgH1XEGmwyyvjFSPJF+6MgYCQzX+GB/7 mSnTVMheAsQHY4M/GZ1xq4zuJtV89QwoIRylOyfH9oYYX6fz/x+x55h/ALrAsrBDssnY l2aanH01z6tvcPYr1OBZMKsyx/jYb9tI0GopGJp3Ke/UN4xwFrMgUYDh+yf7MX6Bu70R IRYw== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@infradead.org header.s=casper.20170209 header.b=ekNfgmFw; spf=pass (google.com: domain of linux-ext4-owner@vger.kernel.org designates 23.128.96.34 as permitted sender) smtp.mailfrom=linux-ext4-owner@vger.kernel.org Return-Path: Received: from howler.vger.email (howler.vger.email. [23.128.96.34]) by mx.google.com with ESMTPS id fi15-20020a056a00398f00b0068fcff1dc3asi11381976pfb.339.2023.09.20.00.17.58 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Wed, 20 Sep 2023 00:17:59 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-ext4-owner@vger.kernel.org designates 23.128.96.34 as permitted sender) client-ip=23.128.96.34; Authentication-Results: mx.google.com; dkim=pass header.i=@infradead.org header.s=casper.20170209 header.b=ekNfgmFw; spf=pass (google.com: domain of linux-ext4-owner@vger.kernel.org designates 23.128.96.34 as permitted sender) smtp.mailfrom=linux-ext4-owner@vger.kernel.org Received: from out1.vger.email (depot.vger.email [IPv6:2620:137:e000::3:0]) by howler.vger.email (Postfix) with ESMTP id EE1908084598; Tue, 19 Sep 2023 20:11:24 -0700 (PDT) X-Virus-Status: Clean X-Virus-Scanned: clamav-milter 0.103.10 at howler.vger.email Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S231675AbjITDL1 (ORCPT + 99 others); Tue, 19 Sep 2023 23:11:27 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:45514 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S231630AbjITDL0 (ORCPT ); Tue, 19 Sep 2023 23:11:26 -0400 Received: from casper.infradead.org (casper.infradead.org [IPv6:2001:8b0:10b:1236::1]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 9640DB0; Tue, 19 Sep 2023 20:11:17 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=infradead.org; s=casper.20170209; 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=uE+UAnC9YgmNAUhKoTWIdxRk/FdOddBgLymLwlPaqnk=; b=ekNfgmFwoHu8gIoYFOjAVApvtB 3IXO/kDTQVK7eWR0y6nYylINvIk4NtmEm3kQODEPrUFwrj5dXTYcXamT6rwoq/2nvLl5fEGFiXvrd qGejySTQ2pAFXZBOhqsyHwndRN62Ily6nVv64jjObtM6K2L7dmD/rDOmehFEm5JknDqooHYchnJLb YI/tCYH/CrK1gcaARvorBnRcZOqw+jUnC5gKxqrYuQkFKyzuOj4PSUCgORs7pW00BJ/+8vty/M8I/ 5YP4CSRdEi8Ax4LZNa3piEYfC9C6VrjU/6PZSNvOYis9wkJzK92YeqJ4CXWiya1PLUT44i/m0R7WO mKrrt6Uw==; Received: from willy by casper.infradead.org with local (Exim 4.94.2 #2 (Red Hat Linux)) id 1qincN-003PFJ-OR; Wed, 20 Sep 2023 03:11:11 +0000 Date: Wed, 20 Sep 2023 04:11:11 +0100 From: Matthew Wilcox To: Andreas Gruenbacher Cc: Andrew Morton , linux-fsdevel@vger.kernel.org, gfs2@lists.linux.dev, linux-nilfs@vger.kernel.org, linux-ntfs-dev@lists.sourceforge.net, ntfs3@lists.linux.dev, ocfs2-devel@lists.linux.dev, reiserfs-devel@vger.kernel.org, linux-ext4@vger.kernel.org, Pankaj Raghav Subject: Re: [PATCH 07/26] gfs2; Convert gfs2_getjdatabuf to use a folio Message-ID: References: <20230919045135.3635437-1-willy@infradead.org> <20230919045135.3635437-8-willy@infradead.org> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: X-Spam-Status: No, score=-2.1 required=5.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID,DKIM_VALID_AU,DKIM_VALID_EF,RCVD_IN_DNSWL_BLOCKED, SPF_HELO_NONE,SPF_NONE 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-ext4@vger.kernel.org X-Greylist: Sender passed SPF test, not delayed by milter-greylist-4.6.4 (howler.vger.email [0.0.0.0]); Tue, 19 Sep 2023 20:11:25 -0700 (PDT) On Wed, Sep 20, 2023 at 12:27:08AM +0200, Andreas Gruenbacher wrote: > Thanks, > > but this patch has an unwanted semicolon in the subject. Thanks. My laptop has a dodgy shift key, so this sometimes happens. The build quality on HP Spectre laptops has gone downhill in the last few years. > > - page = find_get_page_flags(mapping, index, FGP_LOCK|FGP_ACCESSED); > > - if (!page) > > - return NULL; > > - if (!page_has_buffers(page)) { > > - unlock_page(page); > > - put_page(page); > > + folio = __filemap_get_folio(mapping, index, FGP_LOCK | FGP_ACCESSED, 0); > > + if (IS_ERR(folio)) > > return NULL; > > - } > > - /* Locate header for our buffer within our page */ > > - for (bh = page_buffers(page); bufnum--; bh = bh->b_this_page) > > - /* Do nothing */; > > - get_bh(bh); > > - unlock_page(page); > > - put_page(page); > > + bh = folio_buffers(folio); > > + if (bh) > > + get_nth_bh(bh, bufnum); > > And we need this here: > > bh = get_nth_bh(bh, bufnum); Oof. I should make that __must_check so the compiler tells me I'm being an idiot. Thanks!