parameter to the
creation functions, but pushes all error recovery into fs/libfs.c.
Signed-off-by: Emanuele Giuseppe Esposito
---
fs/libfs.c | 226 +
include/linux/fs.h | 18
2 files changed, 244 insertions(+)
diff --git a/fs/libfs.c b/fs
It is a common special case for new_inode to initialize the
time to the current time and the inode to get_next_ino().
Introduce a core function that does it.
Signed-off-by: Emanuele Giuseppe Esposito
---
fs/libfs.c | 20
include/linux/fs.h | 1 +
2 files changed
The only difference, compared to the pre-existing code, is that symlink
creation now triggers fsnotify_create. This was a bug in the debugfs
code, since for example vfs_symlink does call fsnotify_create.
Signed-off-by: Emanuele Giuseppe Esposito
---
fs/debugfs/inode.c | 144
There is no semantic change intended; the code in the libfs.c
functions in fact was derived from debugfs and tracefs code.
Signed-off-by: Emanuele Giuseppe Esposito
---
fs/tracefs/inode.c | 86 --
1 file changed, 7 insertions(+), 79 deletions(-)
diff
libfs.c has many functions that are useful to implement dentry and inode
operations, but not many at the filesystem level. Start adding file
creation wrappers, the simplest returns an anonymous inode.
There is no functional change intended.
Signed-off-by: Emanuele Giuseppe Esposito
---
drivers
duces the dentry and inode creation functions. Patch 6-7 can then
adopt them in debugfs and tracefs.
Signed-off-by: Emanuele Giuseppe Esposito
v1->v2: rename simple_new_inode in new_inode_current_time,
more detailed explanations, put all common code in fs/libfs.c
Emanuele Giuseppe Esposito (7
Simplify passing the count and mount to simple_pin_fs and
simple_release_fs by wrapping them in the simple_fs struct,
in preparation for adding more high level operations to
fs/libfs.c
There is no functional change intended.
Signed-off-by: Emanuele Giuseppe Esposito
---
drivers/gpu/drm
0 on entry and on exit).
There is no functional change intended.
Signed-off-by: Emanuele Giuseppe Esposito
---
security/apparmor/apparmorfs.c | 13 +++--
1 file changed, 7 insertions(+), 6 deletions(-)
diff --git a/security/apparmor/apparmorfs.c b/security/apparmor/apparmorfs.c
index
On 4/21/20 1:19 PM, Frederic Barrat wrote:
diff --git a/drivers/misc/cxl/Kconfig b/drivers/misc/cxl/Kconfig
index 39eec9031487..a62795079d9c 100644
--- a/drivers/misc/cxl/Kconfig
+++ b/drivers/misc/cxl/Kconfig
@@ -19,6 +19,7 @@ config CXL
select CXL_BASE
select CXL_AFU_DRIVER_OPS
On 4/16/20 8:44 AM, Luis Chamberlain wrote:
On Tue, Apr 14, 2020 at 02:42:55PM +0200, Emanuele Giuseppe Esposito wrote:
aa_mk_null_file is using simple_pin_fs/simple_release_fs with local
variables as arguments, for what would amount to a simple
vfs_kern_mount/mntput pair if everything was
On 4/16/20 8:59 AM, Luis Chamberlain wrote:
On Tue, Apr 14, 2020 at 02:42:54PM +0200, Emanuele Giuseppe Esposito wrote:
This series of patches introduce wrappers for functions,
arguments simplification in functions calls and most importantly
groups duplicated code in a single header
On 4/14/20 3:01 PM, Greg Kroah-Hartman wrote:
On Tue, Apr 14, 2020 at 02:42:58PM +0200, Emanuele Giuseppe Esposito wrote:
It is a common special case for new_inode to initialize the
time to the current time and the inode to get_next_ino().
Introduce a core function that does it and use it
On 4/14/20 2:56 PM, Greg Kroah-Hartman wrote:
On Tue, Apr 14, 2020 at 02:43:00PM +0200, Emanuele Giuseppe Esposito wrote:
A bunch of code is duplicated between debugfs and tracefs, unify it to the
simplefs library.
The code is very similar, except that dentry and inode creation are unified
The only difference, compared to the pre-existing code, is that symlink
creation now triggers fsnotify_create. This was a bug in the debugfs
code, since for example vfs_symlink does call fsnotify_create.
Signed-off-by: Emanuele Giuseppe Esposito
---
fs/debugfs/inode.c | 144
It is a common special case for new_inode to initialize the
time to the current time and the inode to get_next_ino().
Introduce a core function that does it and use it throughout
Linux.
Signed-off-by: Emanuele Giuseppe Esposito
---
arch/powerpc/platforms/cell/spufs/inode.c | 4 +---
arch/s390
Simplify passing the count and mount to simple_pin_fs and simple_release_fs,
in preparation for adding more high level operations to the simplefs API.
Signed-off-by: Emanuele Giuseppe Esposito
---
drivers/gpu/drm/drm_drv.c | 11 +--
drivers/misc/cxl/api.c | 13
There is no semantic change intended; the code in the simplefs.c functions in
fact was derived from debugfs and tracefs code.
Signed-off-by: Emanuele Giuseppe Esposito
---
fs/tracefs/inode.c | 86 --
1 file changed, 7 insertions(+), 79 deletions
parameter to the creation
functions, but pushes all error recovery into fs/simplefs.c.
Signed-off-by: Emanuele Giuseppe Esposito
---
fs/simplefs.c| 150 +++
include/linux/simplefs.h | 19 +
2 files changed, 169 insertions(+)
diff --git a/fs
Start adding file creation wrappers, the simplest returns an anonymous
inode.
Signed-off-by: Emanuele Giuseppe Esposito
---
drivers/gpu/drm/drm_drv.c | 2 +-
drivers/misc/cxl/api.c | 2 +-
drivers/scsi/cxlflash/ocxl_hw.c | 2 +-
fs/simplefs.c | 6 ++
include
aa_mk_null_file is using simple_pin_fs/simple_release_fs with local
variables as arguments, for what would amount to a simple
vfs_kern_mount/mntput pair if everything was inlined. Just use
the normal filesystem API since the reference counting is not needed
here.
Signed-off-by: Emanuele Giuseppe
We will augment this family of functions with inode management. To avoid
littering include/linux/fs.h and fs/libfs.c, move them to a separate header,
with a Kconfig symbol to enable them.
Signed-off-by: Emanuele Giuseppe Esposito
---
drivers/gpu/drm/Kconfig | 1 +
drivers/gpu/drm
This series of patches introduce wrappers for functions,
arguments simplification in functions calls and most importantly
groups duplicated code in a single header, simplefs, to avoid redundancy
in the linux fs, especially debugfs and tracefs.
Signed-off-by: Emanuele Giuseppe Esposito
Emanuele
22 matches
Mail list logo