From: Dongsu Park <dongsu@kinvolk.io>
To: linux-kernel@vger.kernel.org
Cc: Alban Crequy <alban@kinvolk.io>,
Miklos Szeredi <miklos@szeredi.hu>,
Mimi Zohar <zohar@linux.vnet.ibm.com>,
Seth Forshee <seth.forshee@canonical.com>,
Dongsu Park <dongsu@kinvolk.io>,
linux-fsdevel@vger.kernel.org, linux-integrity@vger.kernel.org
Subject: [PATCH 1/2] fs/fuse: move SUPER_MAGIC definitions to linux/magic.h
Date: Thu, 11 Jan 2018 20:51:49 +0100 [thread overview]
Message-ID: <5aa0e3c3a8d67939940b3469fdae81b9f1a0f920.1515682581.git.dongsu@kinvolk.io> (raw)
In-Reply-To: <cover.1515682581.git.dongsu@kinvolk.io>
In-Reply-To: <cover.1515682581.git.dongsu@kinvolk.io>
To be able to use FUSE_*SUPER_MAGIC macros in other subsystems like
security/integrity/ima, we need to move the definitions from fs/fuse
to include/uapi/linux/.
The FUSE_*SUPER_MAGIC macros are made available to userspace in the
same way as other filesystems.
Cc: linux-fsdevel@vger.kernel.org
Cc: linux-integrity@vger.kernel.org
Cc: linux-kernel@vger.kernel.org
Cc: Alban Crequy <alban@kinvolk.io>
Cc: Miklos Szeredi <miklos@szeredi.hu>
Cc: Mimi Zohar <zohar@linux.vnet.ibm.com>
Cc: Seth Forshee <seth.forshee@canonical.com>
Signed-off-by: Dongsu Park <dongsu@kinvolk.io>
---
fs/fuse/control.c | 3 +--
fs/fuse/inode.c | 3 +--
include/uapi/linux/magic.h | 3 +++
3 files changed, 5 insertions(+), 4 deletions(-)
diff --git a/fs/fuse/control.c b/fs/fuse/control.c
index b9ea99c5..9015c15c 100644
--- a/fs/fuse/control.c
+++ b/fs/fuse/control.c
@@ -10,8 +10,7 @@
#include <linux/init.h>
#include <linux/module.h>
-
-#define FUSE_CTL_SUPER_MAGIC 0x65735543
+#include <linux/magic.h>
/*
* This is non-NULL when the single instance of the control filesystem
diff --git a/fs/fuse/inode.c b/fs/fuse/inode.c
index 8c98edee..57371b77 100644
--- a/fs/fuse/inode.c
+++ b/fs/fuse/inode.c
@@ -22,6 +22,7 @@
#include <linux/exportfs.h>
#include <linux/posix_acl.h>
#include <linux/pid_namespace.h>
+#include <linux/magic.h>
MODULE_AUTHOR("Miklos Szeredi <miklos@szeredi.hu>");
MODULE_DESCRIPTION("Filesystem in Userspace");
@@ -49,8 +50,6 @@ MODULE_PARM_DESC(max_user_congthresh,
"Global limit for the maximum congestion threshold an "
"unprivileged user can set");
-#define FUSE_SUPER_MAGIC 0x65735546
-
#define FUSE_DEFAULT_BLKSIZE 512
/** Maximum number of outstanding background requests */
diff --git a/include/uapi/linux/magic.h b/include/uapi/linux/magic.h
index 1a6fee97..1534e99c 100644
--- a/include/uapi/linux/magic.h
+++ b/include/uapi/linux/magic.h
@@ -90,4 +90,7 @@
#define BALLOON_KVM_MAGIC 0x13661366
#define ZSMALLOC_MAGIC 0x58295829
+#define FUSE_CTL_SUPER_MAGIC 0x65735543
+#define FUSE_SUPER_MAGIC 0x65735546
+
#endif /* __LINUX_MAGIC_H__ */
--
2.13.6
next prev parent reply other threads:[~2018-01-11 19:51 UTC|newest]
Thread overview: 16+ messages / expand[flat|nested] mbox.gz Atom feed top
2018-01-11 19:51 [PATCH 0/2] turn on force option for FUSE in builtin policies Dongsu Park
2018-01-11 19:51 ` Dongsu Park [this message]
2018-01-11 19:51 ` [PATCH 2/2] ima: " Dongsu Park
2018-01-12 15:33 ` Mimi Zohar
2018-01-14 19:09 ` kbuild test robot
2018-01-16 10:47 ` Dongsu Park
2018-01-15 14:48 ` [PATCH 0/2] " Christoph Hellwig
2018-01-15 16:32 ` Mimi Zohar
2018-01-15 17:18 ` Christoph Hellwig
2018-01-15 21:00 ` Mimi Zohar
2018-01-16 10:41 ` [PATCH] ima,fuse: introduce new fs flag FS_NO_IMA_CACHE Alban Crequy
2018-01-16 11:26 ` Alban Crequy
2018-01-16 11:35 ` Mimi Zohar
2018-01-16 11:09 ` [PATCH 0/2] turn on force option for FUSE in builtin policies Dongsu Park
2018-01-16 11:23 ` Mimi Zohar
2018-01-16 14:05 ` Dongsu Park
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=5aa0e3c3a8d67939940b3469fdae81b9f1a0f920.1515682581.git.dongsu@kinvolk.io \
--to=dongsu@kinvolk.io \
--cc=alban@kinvolk.io \
--cc=linux-fsdevel@vger.kernel.org \
--cc=linux-integrity@vger.kernel.org \
--cc=linux-kernel@vger.kernel.org \
--cc=miklos@szeredi.hu \
--cc=seth.forshee@canonical.com \
--cc=zohar@linux.vnet.ibm.com \
/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).