From patchwork Mon Jun 11 14:06:24 2018 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Matthew Wilcox X-Patchwork-Id: 10458009 Return-Path: Received: from mail.wl.linuxfoundation.org (pdx-wl-mail.web.codeaurora.org [172.30.200.125]) by pdx-korg-patchwork.web.codeaurora.org (Postfix) with ESMTP id E3F8A6020F for ; Mon, 11 Jun 2018 14:11:38 +0000 (UTC) Received: from mail.wl.linuxfoundation.org (localhost [127.0.0.1]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id BEC89287D5 for ; Mon, 11 Jun 2018 14:11:38 +0000 (UTC) Received: by mail.wl.linuxfoundation.org (Postfix, from userid 486) id B947C287B9; Mon, 11 Jun 2018 14:11:38 +0000 (UTC) X-Spam-Checker-Version: SpamAssassin 3.3.1 (2010-03-16) on pdx-wl-mail.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-2.8 required=2.0 tests=BAYES_00,DKIM_SIGNED, MAILING_LIST_MULTI, RCVD_IN_DNSWL_NONE, T_DKIM_INVALID autolearn=unavailable version=3.3.1 Received: from kanga.kvack.org (kanga.kvack.org [205.233.56.17]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id 90447287D5 for ; Mon, 11 Jun 2018 14:11:00 +0000 (UTC) Received: by kanga.kvack.org (Postfix) id 48C016B0299; Mon, 11 Jun 2018 10:07:10 -0400 (EDT) Delivered-To: linux-mm-outgoing@kvack.org Received: by kanga.kvack.org (Postfix, from userid 40) id 412476B029B; Mon, 11 Jun 2018 10:07:10 -0400 (EDT) X-Original-To: int-list-linux-mm@kvack.org X-Delivered-To: int-list-linux-mm@kvack.org Received: by kanga.kvack.org (Postfix, from userid 63042) id 23F326B029A; Mon, 11 Jun 2018 10:07:10 -0400 (EDT) X-Original-To: linux-mm@kvack.org X-Delivered-To: linux-mm@kvack.org Received: from mail-pl0-f69.google.com (mail-pl0-f69.google.com [209.85.160.69]) by kanga.kvack.org (Postfix) with ESMTP id CFDF06B029B for ; Mon, 11 Jun 2018 10:07:09 -0400 (EDT) Received: by mail-pl0-f69.google.com with SMTP id t19-v6so2740088plo.9 for ; Mon, 11 Jun 2018 07:07:09 -0700 (PDT) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:dkim-signature:from:to:cc:subject:date :message-id:in-reply-to:references; bh=l7vqrsvTDgMQ5pcpSIqMCIBtnn2ngsgjRhaUjxPid4k=; b=lb7CkMOYBhf6r9FIuUhksxN9BycaqydMQkx2u8nvfexdlQxo4uj8o33KOmHTZc5lnE 5kqI/KfZxaXhOVQKyIm7MuSjQ7SWbP2B8i3fEVp1X/u8g/Hz8IesZ5L6GAAWnwqFAb/w ytsIAkTfXXjiSpv4fHnEFRMB1Gv76QHM4TSPCY2AgnL/V830uSq69YcLrPn2GjbJXYYU 9IIAR2ohwXJlcuxg433EbWyA+6cRgrm9MLXJ5N3hpcdp+nm6YYYjCD8iVF4yMnuAtN5C UhOBtloyxSfzOwsaTGlXhJqoVNLDvJ1c8nMYOMab9zd4SkbmNj89oc/NH3Cv851AjUDU plDA== X-Gm-Message-State: APt69E0mYzE1roA1DbNs3HZiZPIoK/x3oyNVjX1eCxZ6xDWNu17i3VG2 qVWzPjn4lH6Wqp3XiC06kXWjBvAZr1YYP75CvPEfHcikzhQnbLn0J1nbCPk0D0dabf+48MoivHu bwQel7lOnPj5u8GSG1FDsZf1duzVUYlISk0fDPW1TxzIQ2KG0Ebgy36lkfUmy5UaQWQ== X-Received: by 2002:a17:902:205:: with SMTP id 5-v6mr18515167plc.301.1528726029550; Mon, 11 Jun 2018 07:07:09 -0700 (PDT) X-Google-Smtp-Source: ADUXVKKkuw4FP6sCKHIiPzldpxFJ6rUinKgKeTulrMP61F7lwSY+/RAarlZcQyiumU9Z5kyIgUK3 X-Received: by 2002:a17:902:205:: with SMTP id 5-v6mr18515119plc.301.1528726028713; Mon, 11 Jun 2018 07:07:08 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1528726028; cv=none; d=google.com; s=arc-20160816; b=mn2+3r16qdHNqLpv7TSBE98elpavRAXKOuoobtRhBpp0+L/nHIYGh2089Nu5wjpZTU SiqhprqKDJcLc9EFP/Y0dmEc9OFxGb5v0NYBU4XshNzZieHrWL5+C55dsLNmRDvAqYwr UDb58/iuV3etbFab5Jg3L8ETxsafh+TRVSa0Jz/TfB02z8Q43ViCTsCSTNOMHVDxydr9 miDg2Opxg1XUjns8w4mlxkNbOzjkPrVOb/2iQEWo5xtmXUe05wBYqV3ujAPW0sAuhkvD q7v6DZ+fMP6PGW0BYXahc8A/JLIdxaWShgR9j/o7dsdpnaJdnIb7JthcXOjtPvN9Mc0P 97YQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=references:in-reply-to:message-id:date:subject:cc:to:from :dkim-signature:arc-authentication-results; bh=l7vqrsvTDgMQ5pcpSIqMCIBtnn2ngsgjRhaUjxPid4k=; b=AI2qgd3eQnwOtJP5AIIG5CGTaH6bS6PADwDYFDJ0EGMJacCA73wXZ6AWutJ6w481QV yCPkG+iS5nJRtgprU32lZzklvtpSegbBPfZktVoJinzkpcYyeDDNMtgCsNehHxhMtWEL PniP1fakDzll3sk0F8f9ZzXw1rScWBYKBt1r/DDu+TWSQDYUOScENfuoQgL88VqMvwWj bSaU44ElQm2/CpbmC1vErFOQxkgsXLikLyWwoHmnFKAU84Ok0dHVWx+Y+HaToB+c13DH MP9IiPH9EgWIVhWMctBEIXk2E0QZ2CvHRA3TKYEp9SKzBSuFD84NSPK0bBVIA7vM0Glt qg5g== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@infradead.org header.s=bombadil.20170209 header.b=aPJhJ6xq; spf=pass (google.com: best guess record for domain of willy@infradead.org designates 2607:7c80:54:e::133 as permitted sender) smtp.mailfrom=willy@infradead.org Received: from bombadil.infradead.org (bombadil.infradead.org. [2607:7c80:54:e::133]) by mx.google.com with ESMTPS id b3-v6si22492625pgr.495.2018.06.11.07.07.08 for (version=TLS1_2 cipher=ECDHE-RSA-CHACHA20-POLY1305 bits=256/256); Mon, 11 Jun 2018 07:07:08 -0700 (PDT) Received-SPF: pass (google.com: best guess record for domain of willy@infradead.org designates 2607:7c80:54:e::133 as permitted sender) client-ip=2607:7c80:54:e::133; Authentication-Results: mx.google.com; dkim=pass header.i=@infradead.org header.s=bombadil.20170209 header.b=aPJhJ6xq; spf=pass (google.com: best guess record for domain of willy@infradead.org designates 2607:7c80:54:e::133 as permitted sender) smtp.mailfrom=willy@infradead.org DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=infradead.org; s=bombadil.20170209; h=References:In-Reply-To:Message-Id: Date:Subject:Cc:To:From:Sender:Reply-To:MIME-Version:Content-Type: Content-Transfer-Encoding:Content-ID:Content-Description:Resent-Date: Resent-From:Resent-Sender:Resent-To:Resent-Cc:Resent-Message-ID:List-Id: List-Help:List-Unsubscribe:List-Subscribe:List-Post:List-Owner:List-Archive; bh=l7vqrsvTDgMQ5pcpSIqMCIBtnn2ngsgjRhaUjxPid4k=; b=aPJhJ6xqOtMIh27P/19+yTKdJ hGTBCHyVnv8zdk4wqDHZEf+JBnnt9ZxU2hx/f5Zcc4XFGvmYgCkUGQudofIt+LyYFt6IXfT7IMXy4 sbdWtI4A8TMisIr3CC8z7NkNhaCDXIi4LyFszSz8H3Mv1X1nU45bNbX0mhMCCHe+nRQQqdAXfHgdS F/Qs7u/O4EC5wzYeLEbxo4/KRQ8JBYYXSRfqZPvNqiIw3JUCIJWbGznRT57pKT7ZlcV2WKBaSHf8Q pmmbPz6UNaqt9c+xfvz9G0WhSgJpSqlq12sBUUz5j2JK19+JqjbwTT5vDumr89J8d1R1Md2J4nAjF rRhACmRPw==; Received: from willy by bombadil.infradead.org with local (Exim 4.90_1 #2 (Red Hat Linux)) id 1fSNTP-0004wy-OM; Mon, 11 Jun 2018 14:07:07 +0000 From: Matthew Wilcox To: linux-mm@kvack.org, linux-fsdevel@vger.kernel.org, linux-kernel@vger.kernel.org Cc: Matthew Wilcox , Jan Kara , Jeff Layton , Lukas Czerner , Ross Zwisler , Christoph Hellwig , Goldwyn Rodrigues , Nicholas Piggin , Ryusuke Konishi , linux-nilfs@vger.kernel.org, Jaegeuk Kim , Chao Yu , linux-f2fs-devel@lists.sourceforge.net Subject: [PATCH v13 57/72] fs: Convert buffer to XArray Date: Mon, 11 Jun 2018 07:06:24 -0700 Message-Id: <20180611140639.17215-58-willy@infradead.org> X-Mailer: git-send-email 2.14.3 In-Reply-To: <20180611140639.17215-1-willy@infradead.org> References: <20180611140639.17215-1-willy@infradead.org> X-Bogosity: Ham, tests=bogofilter, spamicity=0.000000, version=1.2.4 Sender: owner-linux-mm@kvack.org Precedence: bulk X-Loop: owner-majordomo@kvack.org List-ID: X-Virus-Scanned: ClamAV using ClamSMTP From: Matthew Wilcox Mostly comment fixes, but one use of __xa_set_tag. Signed-off-by: Matthew Wilcox --- fs/buffer.c | 14 +++++++------- 1 file changed, 7 insertions(+), 7 deletions(-) diff --git a/fs/buffer.c b/fs/buffer.c index 8194e3049fc5..deae44fd64e9 100644 --- a/fs/buffer.c +++ b/fs/buffer.c @@ -562,7 +562,7 @@ void mark_buffer_dirty_inode(struct buffer_head *bh, struct inode *inode) EXPORT_SYMBOL(mark_buffer_dirty_inode); /* - * Mark the page dirty, and set it dirty in the radix tree, and mark the inode + * Mark the page dirty, and set it dirty in the page cache, and mark the inode * dirty. * * If warn is true, then emit a warning if the page is not uptodate and has @@ -579,8 +579,8 @@ void __set_page_dirty(struct page *page, struct address_space *mapping, if (page->mapping) { /* Race with truncate? */ WARN_ON_ONCE(warn && !PageUptodate(page)); account_page_dirtied(page, mapping); - radix_tree_tag_set(&mapping->i_pages, - page_index(page), PAGECACHE_TAG_DIRTY); + __xa_set_tag(&mapping->i_pages, page_index(page), + PAGECACHE_TAG_DIRTY); } xa_unlock_irqrestore(&mapping->i_pages, flags); } @@ -1043,7 +1043,7 @@ __getblk_slow(struct block_device *bdev, sector_t block, * The relationship between dirty buffers and dirty pages: * * Whenever a page has any dirty buffers, the page's dirty bit is set, and - * the page is tagged dirty in its radix tree. + * the page is tagged dirty in the page cache. * * At all times, the dirtiness of the buffers represents the dirtiness of * subsections of the page. If the page has buffers, the page dirty bit is @@ -1066,9 +1066,9 @@ __getblk_slow(struct block_device *bdev, sector_t block, * mark_buffer_dirty - mark a buffer_head as needing writeout * @bh: the buffer_head to mark dirty * - * mark_buffer_dirty() will set the dirty bit against the buffer, then set its - * backing page dirty, then tag the page as dirty in its address_space's radix - * tree and then attach the address_space's inode to its superblock's dirty + * mark_buffer_dirty() will set the dirty bit against the buffer, then set + * its backing page dirty, then tag the page as dirty in the page cache + * and then attach the address_space's inode to its superblock's dirty * inode list. * * mark_buffer_dirty() is atomic. It takes bh->b_page->mapping->private_lock,