* Patch "xfs: move more RT specific code under CONFIG_XFS_RT" has been added to the 4.9-stable tree
@ 2017-10-24 12:54 gregkh
0 siblings, 0 replies; only message in thread
From: gregkh @ 2017-10-24 12:54 UTC (permalink / raw)
To: dchinner, bfoster, darrick.wong, gregkh; +Cc: stable, stable-commits
This is a note to let you know that I've just added the patch titled
xfs: move more RT specific code under CONFIG_XFS_RT
to the 4.9-stable tree which can be found at:
http://www.kernel.org/git/?p=linux/kernel/git/stable/stable-queue.git;a=summary
The filename of the patch is:
xfs-move-more-rt-specific-code-under-config_xfs_rt.patch
and it can be found in the queue-4.9 subdirectory.
If you, or anyone else, feels it should not be added to the stable tree,
please let <stable@vger.kernel.org> know about it.
>From bb9c2e5433250f5b477035dc478314f8e6dd5e36 Mon Sep 17 00:00:00 2001
From: Dave Chinner <dchinner@redhat.com>
Date: Mon, 9 Oct 2017 11:37:22 -0700
Subject: xfs: move more RT specific code under CONFIG_XFS_RT
From: Dave Chinner <dchinner@redhat.com>
commit bb9c2e5433250f5b477035dc478314f8e6dd5e36 upstream.
Various utility functions and interfaces that iterate internal
devices try to reference the realtime device even when RT support is
not compiled into the kernel.
Make sure this code is excluded from the CONFIG_XFS_RT=n build,
and where appropriate stub functions to return fatal errors if
they ever get called when RT support is not present.
Signed-Off-By: Dave Chinner <dchinner@redhat.com>
Reviewed-by: Brian Foster <bfoster@redhat.com>
Reviewed-by: Darrick J. Wong <darrick.wong@oracle.com>
Signed-off-by: Darrick J. Wong <darrick.wong@oracle.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
---
fs/xfs/xfs_bmap_util.c | 2 ++
fs/xfs/xfs_bmap_util.h | 13 +++++++++++++
2 files changed, 15 insertions(+)
--- a/fs/xfs/xfs_bmap_util.c
+++ b/fs/xfs/xfs_bmap_util.c
@@ -84,6 +84,7 @@ xfs_zero_extent(
GFP_NOFS, true);
}
+#ifdef CONFIG_XFS_RT
int
xfs_bmap_rtalloc(
struct xfs_bmalloca *ap) /* bmap alloc argument struct */
@@ -195,6 +196,7 @@ xfs_bmap_rtalloc(
}
return 0;
}
+#endif /* CONFIG_XFS_RT */
/*
* Check if the endoff is outside the last extent. If so the caller will grow
--- a/fs/xfs/xfs_bmap_util.h
+++ b/fs/xfs/xfs_bmap_util.h
@@ -28,7 +28,20 @@ struct xfs_mount;
struct xfs_trans;
struct xfs_bmalloca;
+#ifdef CONFIG_XFS_RT
int xfs_bmap_rtalloc(struct xfs_bmalloca *ap);
+#else /* !CONFIG_XFS_RT */
+/*
+ * Attempts to allocate RT extents when RT is disable indicates corruption and
+ * should trigger a shutdown.
+ */
+static inline int
+xfs_bmap_rtalloc(struct xfs_bmalloca *ap)
+{
+ return -EFSCORRUPTED;
+}
+#endif /* CONFIG_XFS_RT */
+
int xfs_bmap_eof(struct xfs_inode *ip, xfs_fileoff_t endoff,
int whichfork, int *eof);
int xfs_bmap_punch_delalloc_range(struct xfs_inode *ip,
Patches currently in stable-queue which might be from dchinner@redhat.com are
queue-4.9/xfs-cancel-dirty-pages-on-invalidation.patch
queue-4.9/xfs-move-more-rt-specific-code-under-config_xfs_rt.patch
queue-4.9/xfs-don-t-change-inode-mode-if-acl-update-fails.patch
queue-4.9/xfs-trim-writepage-mapping-to-within-eof.patch
queue-4.9/xfs-don-t-log-uninitialised-fields-in-inode-structures.patch
^ permalink raw reply [flat|nested] only message in thread
only message in thread, other threads:[~2017-10-24 12:55 UTC | newest]
Thread overview: (only message) (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2017-10-24 12:54 Patch "xfs: move more RT specific code under CONFIG_XFS_RT" has been added to the 4.9-stable tree gregkh
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).