iomap: Export iomap_page_create and iomap_set_range_uptodate
Subsystems (2)
PATCH 1/1 iomap: Export iomap_page_create and iomap_set_range_uptodate
These two functions are needed by filesystems for converting inline ("stuffed") inodes into non-inline inodes.
--- fs/iomap/buffered-io.c | 6 ++++-- include/linux/iomap.h | 5 +++++ 2 files changed, 9 insertions(+), 2 deletions(-)
fs/iomap/buffered-io.c +4 -2
@@ -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)
include/linux/iomap.h +5 -0
@@ -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);
Signature · 1 line
2.20.1
Quoted 4 lines · Andreas Gruenbacher
These two functions are needed by filesystems for converting inline ("stuffed") inodes into non-inline inodes.
Signed-off-by Andreas Gruenbacher <[email protected]>
Looks fine to me... this is a 5.6 change, correct?
--D
Quoted 69 lines
--- fs/iomap/buffered-io.c | 6 ++++-- include/linux/iomap.h | 5 +++++ 2 files changed, 9 insertions(+), 2 deletions(-)fs/iomap/buffered-io.c +4
-2@@ -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)include/linux/iomap.h +5
-0@@ -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);Signature · 1 line
2.20.1
Am Di., 10. Dez. 2019 um 21:33 Uhr schrieb Darrick J. Wong <[email protected]>:
Quoted 7 lines · Andreas Gruenbacher
Quoted 4 lines
These two functions are needed by filesystems for converting inline ("stuffed") inodes into non-inline inodes.
Signed-off-by Andreas Gruenbacher <[email protected]>Looks fine to me... this is a 5.6 change, correct?
Yes, so there's still plenty of time to get things in place until then. I'd like to hear from Christoph if he has any objections. In any case, this patch isn't going to break anything.
Thanks,
Andreas
Quoted 6 lines · Andreas Gr?nbacher
Am Di., 10. Dez. 2019 um 21:33 Uhr schrieb Darrick J. Wong <[email protected]>:
Quoted 4 lines · Andreas Gruenbacher
Quoted 3 lines
These two functions are needed by filesystems for converting inline ("stuffed") inodes into non-inline inodes.
Quoted 7 lines
Quoted 3 lines
Quoted 1 line
Signed-off-by Andreas Gruenbacher <[email protected]>Looks fine to me... this is a 5.6 change, correct?
Yes, so there's still plenty of time to get things in place until then. I'd like to hear from Christoph if he has any objections. In any case, this patch isn't going to break anything.
By the way, the other symbols in fs/iomap/ are all EXPORT_SYMBOL_GPL. Does gfs2/RH/anyone have a particular requirement for EXPORT_SYMBOL, or could we make the new exports _GPL to match the rest?
--D
Quoted 2 lines
Thanks,
Andreas
Am Di., 10. Dez. 2019 um 22:25 Uhr schrieb Darrick J. Wong <[email protected]>:
Quoted 11 lines · Andreas Gr?nbacher
Quoted 10 lines
Am Di., 10. Dez. 2019 um 21:33 Uhr schrieb Darrick J. Wong <[email protected]>:
Quoted 7 lines · Andreas Gruenbacher
Quoted 4 lines
These two functions are needed by filesystems for converting inline ("stuffed") inodes into non-inline inodes.
Signed-off-by Andreas Gruenbacher <[email protected]>Looks fine to me... this is a 5.6 change, correct?
Quoted 7 lines
Quoted 3 lines
Yes, so there's still plenty of time to get things in place until then. I'd like to hear from Christoph if he has any objections. In any case, this patch isn't going to break anything.
By the way, the other symbols in
fs/iomap/are allEXPORT_SYMBOL_GPL. Does gfs2/RH/anyone have a particular requirement forEXPORT_SYMBOL, or could we make the new exports_GPLto match the rest?
I don't mind EXPORT_SYMBOL_GPL.
Thanks,
Andreas
At very least this needs to be a EXPORT_SYMBOL_GPL in sent in a series with the actual user. But I'm not all that happy about exporting such low-level helpers. Can't we come up with a useful higher level primitive instead?