From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-9.6 required=3.0 tests=DKIM_INVALID,DKIM_SIGNED, HEADER_FROM_DIFFERENT_DOMAINS,INCLUDES_PATCH,MAILING_LIST_MULTI,SIGNED_OFF_BY, SPF_HELO_NONE,SPF_PASS,URIBL_BLOCKED,USER_AGENT_GIT autolearn=ham autolearn_force=no version=3.4.0 Received: from mail.kernel.org (mail.kernel.org [198.145.29.99]) by smtp.lore.kernel.org (Postfix) with ESMTP id 8DCF5C76188 for ; Mon, 22 Jul 2019 09:51:38 +0000 (UTC) Received: from vger.kernel.org (vger.kernel.org [209.132.180.67]) by mail.kernel.org (Postfix) with ESMTP id 673852147A for ; Mon, 22 Jul 2019 09:51:38 +0000 (UTC) Authentication-Results: mail.kernel.org; dkim=fail reason="signature verification failed" (2048-bit key) header.d=infradead.org header.i=@infradead.org header.b="N6yVfPa0" Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1729523AbfGVJvg (ORCPT ); Mon, 22 Jul 2019 05:51:36 -0400 Received: from bombadil.infradead.org ([198.137.202.133]:40368 "EHLO bombadil.infradead.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1729381AbfGVJuw (ORCPT ); Mon, 22 Jul 2019 05:50:52 -0400 DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=infradead.org; s=bombadil.20170209; h=Content-Transfer-Encoding: MIME-Version:References:In-Reply-To:Message-Id:Date:Subject:Cc:To:From:Sender :Reply-To:Content-Type: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=mGvJHkdzdRsod20Z1eDhXnINTiBQVBjvcTiXnSoZLYw=; b=N6yVfPa0wxhN/Rz9yKTGfgoP8p AhpUcdu0ANxWYBWGhr6Ssvu/Q5ungBuqZFh9Anuqx/eNzvmqEzcO5geDd5eiKclnfVVV66WM8ZRa4 on7IbYe9/94AHOCKNF+sG/QObGz99GLp/utijOMG3mPZ4qOMkNzCSQsRaBxJpQTknK1ozr8cnAze8 qZPJkjY53maGxsKfZmsc1A5GHMUJMLrpd8zd7KZku0jZBRQUIe8mu9M7Zt32n/PVk/2wj5g9YfXm2 MkKaivb9uSScXOA37XScKWsfBWnLq32oCTSoa4dGgBuUCYKgA/bxKZiVvTZvNv3rmW0MKIiOodejG lfKZDdGg==; Received: from 089144207240.atnat0016.highway.bob.at ([89.144.207.240] helo=localhost) by bombadil.infradead.org with esmtpsa (Exim 4.92 #3 (Red Hat Linux)) id 1hpUy2-0005gJ-6F; Mon, 22 Jul 2019 09:50:50 +0000 From: Christoph Hellwig To: "Darrick J . Wong" Cc: Damien Le Moal , Andreas Gruenbacher , linux-xfs@vger.kernel.org, linux-fsdevel@vger.kernel.org, linux-kernel@vger.kernel.org Subject: [PATCH 09/12] iomap: move struct iomap_page out of iomap.h Date: Mon, 22 Jul 2019 11:50:21 +0200 Message-Id: <20190722095024.19075-10-hch@lst.de> X-Mailer: git-send-email 2.20.1 In-Reply-To: <20190722095024.19075-1-hch@lst.de> References: <20190722095024.19075-1-hch@lst.de> MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-SRS-Rewrite: SMTP reverse-path rewritten from by bombadil.infradead.org. See http://www.infradead.org/rpr.html Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Now that all the writepage code is in the iomap code there is no need to keep this structure public. Signed-off-by: Christoph Hellwig --- fs/iomap/buffered-io.c | 17 +++++++++++++++++ include/linux/iomap.h | 17 ----------------- 2 files changed, 17 insertions(+), 17 deletions(-) diff --git a/fs/iomap/buffered-io.c b/fs/iomap/buffered-io.c index 21b50e8cb9f2..16f2ea46a238 100644 --- a/fs/iomap/buffered-io.c +++ b/fs/iomap/buffered-io.c @@ -23,6 +23,23 @@ #define CREATE_TRACE_POINTS #include +/* + * Structure allocated for each page when block size < PAGE_SIZE to track + * sub-page uptodate status and I/O completions. + */ +struct iomap_page { + atomic_t read_count; + atomic_t write_count; + DECLARE_BITMAP(uptodate, PAGE_SIZE / 512); +}; + +static inline struct iomap_page *to_iomap_page(struct page *page) +{ + if (page_has_private(page)) + return (struct iomap_page *)page_private(page); + return NULL; +} + static struct bio_set iomap_ioend_bioset; static struct iomap_page * diff --git a/include/linux/iomap.h b/include/linux/iomap.h index 834d3923e2f2..38464b8f34b9 100644 --- a/include/linux/iomap.h +++ b/include/linux/iomap.h @@ -134,23 +134,6 @@ loff_t iomap_apply(struct inode *inode, loff_t pos, loff_t length, unsigned flags, const struct iomap_ops *ops, void *data, iomap_actor_t actor); -/* - * Structure allocate for each page when block size < PAGE_SIZE to track - * sub-page uptodate status and I/O completions. - */ -struct iomap_page { - atomic_t read_count; - atomic_t write_count; - DECLARE_BITMAP(uptodate, PAGE_SIZE / 512); -}; - -static inline struct iomap_page *to_iomap_page(struct page *page) -{ - if (page_has_private(page)) - return (struct iomap_page *)page_private(page); - return NULL; -} - ssize_t iomap_file_buffered_write(struct kiocb *iocb, struct iov_iter *from, const struct iomap_ops *ops); int iomap_readpage(struct page *page, const struct iomap_ops *ops); -- 2.20.1