+ ramfs-support-o_tmpfile.patch added to -mm tree

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



The patch titled
     Subject: ramfs: support O_TMPFILE
has been added to the -mm tree.  Its filename is
     ramfs-support-o_tmpfile.patch

This patch should soon appear at
    http://ozlabs.org/~akpm/mmots/broken-out/ramfs-support-o_tmpfile.patch
and later at
    http://ozlabs.org/~akpm/mmotm/broken-out/ramfs-support-o_tmpfile.patch

Before you just go and hit "reply", please:
   a) Consider who else should be cc'ed
   b) Prefer to cc a suitable mailing list as well
   c) Ideally: find the original patch on the mailing list and do a
      reply-to-all to that, adding suitable additional cc's

*** Remember to use Documentation/process/submit-checklist.rst when testing your code ***

The -mm tree is included into linux-next and is updated
there every 3-4 working days

------------------------------------------------------
From: Alexey Dobriyan <adobriyan@xxxxxxxxx>
Subject: ramfs: support O_TMPFILE

Link: http://lkml.kernel.org/r/20190206073349.GA15311@avx2
Signed-off-by: Alexey Dobriyan <adobriyan@xxxxxxxxx>
Signed-off-by: Andrew Morton <akpm@xxxxxxxxxxxxxxxxxxxx>
---


--- a/fs/ramfs/inode.c~ramfs-support-o_tmpfile
+++ a/fs/ramfs/inode.c
@@ -145,6 +145,17 @@ static int ramfs_symlink(struct inode *
 	return error;
 }
 
+static int ramfs_tmpfile(struct inode *dir, struct dentry *dentry, umode_t mode)
+{
+	struct inode *inode;
+
+	inode = ramfs_get_inode(dir->i_sb, dir, mode, 0);
+	if (!inode)
+		return -ENOSPC;
+	d_tmpfile(dentry, inode);
+	return 0;
+}
+
 static const struct inode_operations ramfs_dir_inode_operations = {
 	.create		= ramfs_create,
 	.lookup		= simple_lookup,
@@ -155,6 +166,7 @@ static const struct inode_operations ram
 	.rmdir		= simple_rmdir,
 	.mknod		= ramfs_mknod,
 	.rename		= simple_rename,
+	.tmpfile	= ramfs_tmpfile,
 };
 
 /*
_

Patches currently in -mm which might be from adobriyan@xxxxxxxxx are

ramfs-support-o_tmpfile.patch
mm-shuffle-gfp_-flags.patch
numa-make-nr_node_ids-unsigned-int.patch
numa-make-nr_online_nodes-unsigned-int.patch
proc-return-exit-code-4-for-skipped-tests.patch
proc-read-kernel-cpu-stat-pointer-once.patch
proc-use-seq_puts-everywhere.patch
proc-test-proc-maps-smaps-smaps_rollup-statm.patch
proc-test-proc-maps-smaps-smaps_rollup-statm-fix.patch
elf-dont-be-afraid-of-overflow.patch
elf-use-list_for_each_entry.patch
elf-use-list_for_each_entry-fix.patch
elf-spread-const-a-little.patch
proc-calculate-end-pointer-for-proc-lookup-at-compile-time.patch




[Index of Archives]     [Kernel Archive]     [IETF Annouce]     [DCCP]     [Netdev]     [Networking]     [Security]     [Bugtraq]     [Yosemite]     [MIPS Linux]     [ARM Linux]     [Linux Security]     [Linux RAID]     [Linux SCSI]

  Powered by Linux