linux-kernel.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Andreas Gruenbacher <agruenba@redhat.com>
To: "Darrick J. Wong" <darrick.wong@oracle.com>
Cc: Andreas Gruenbacher <agruenba@redhat.com>,
	linux-xfs@vger.kernel.org, linux-fsdevel@vger.kernel.org,
	linux-kernel@vger.kernel.org, cluster-devel@redhat.com
Subject: [PATCH] iomap: Export iomap_page_create and iomap_set_range_uptodate
Date: Tue, 10 Dec 2019 11:29:16 +0100	[thread overview]
Message-ID: <20191210102916.842-1-agruenba@redhat.com> (raw)

These two functions are needed by filesystems for converting inline
("stuffed") inodes into non-inline inodes.

Signed-off-by: Andreas Gruenbacher <agruenba@redhat.com>
---
 fs/iomap/buffered-io.c | 6 ++++--
 include/linux/iomap.h  | 5 +++++
 2 files changed, 9 insertions(+), 2 deletions(-)

diff --git a/fs/iomap/buffered-io.c b/fs/iomap/buffered-io.c
index 828444e14d09..e8f6d7ba4e3c 100644
--- a/fs/iomap/buffered-io.c
+++ b/fs/iomap/buffered-io.c
@@ -41,7 +41,7 @@ static inline struct iomap_page *to_iomap_page(struct page *page)
 
 static struct bio_set iomap_ioend_bioset;
 
-static struct iomap_page *
+struct iomap_page *
 iomap_page_create(struct inode *inode, struct page *page)
 {
 	struct iomap_page *iop = to_iomap_page(page);
@@ -64,6 +64,7 @@ iomap_page_create(struct inode *inode, struct page *page)
 	SetPagePrivate(page);
 	return iop;
 }
+EXPORT_SYMBOL(iomap_page_create);
 
 static void
 iomap_page_release(struct page *page)
@@ -164,7 +165,7 @@ iomap_iop_set_range_uptodate(struct page *page, unsigned off, unsigned len)
 	spin_unlock_irqrestore(&iop->uptodate_lock, flags);
 }
 
-static void
+void
 iomap_set_range_uptodate(struct page *page, unsigned off, unsigned len)
 {
 	if (PageError(page))
@@ -175,6 +176,7 @@ iomap_set_range_uptodate(struct page *page, unsigned off, unsigned len)
 	else
 		SetPageUptodate(page);
 }
+EXPORT_SYMBOL(iomap_set_range_uptodate);
 
 static void
 iomap_read_finish(struct iomap_page *iop, struct page *page)
diff --git a/include/linux/iomap.h b/include/linux/iomap.h
index 8b09463dae0d..b00f9bc396b1 100644
--- a/include/linux/iomap.h
+++ b/include/linux/iomap.h
@@ -13,6 +13,7 @@
 struct address_space;
 struct fiemap_extent_info;
 struct inode;
+struct iomap_page;
 struct iomap_writepage_ctx;
 struct iov_iter;
 struct kiocb;
@@ -152,6 +153,10 @@ 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);
 
+struct iomap_page *iomap_page_create(struct inode *inode, struct page *page);
+void iomap_set_range_uptodate(struct page *page, unsigned off, unsigned len);
+
+
 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


             reply	other threads:[~2019-12-10 10:29 UTC|newest]

Thread overview: 6+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2019-12-10 10:29 Andreas Gruenbacher [this message]
2019-12-10 20:32 ` [PATCH] iomap: Export iomap_page_create and iomap_set_range_uptodate Darrick J. Wong
2019-12-10 20:39   ` Andreas Grünbacher
2019-12-10 21:25     ` Darrick J. Wong
2019-12-10 21:27       ` Andreas Grünbacher
2019-12-12  9:55 ` Christoph Hellwig

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20191210102916.842-1-agruenba@redhat.com \
    --to=agruenba@redhat.com \
    --cc=cluster-devel@redhat.com \
    --cc=darrick.wong@oracle.com \
    --cc=linux-fsdevel@vger.kernel.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux-xfs@vger.kernel.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).