Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]


Groups > linux.kernel > #1221012

[PATCH 2/3] fput: move ->f_next_put into a union with ->f_version

From Oleg Nesterov <oleg@redhat.com>
Newsgroups linux.kernel
Subject [PATCH 2/3] fput: move ->f_next_put into a union with ->f_version
Date 2015-09-08 19:20 +0200
Message-ID <q6uIP-2hN-27@gated-at.bofh.it> (permalink)
References <q6uIN-2hN-7@gated-at.bofh.it>
Organization linux.* mail to news gateway

Show all headers | View raw


file->f_next_put can share the memory with file->f_version (I hope).

Signed-off-by: Oleg Nesterov <oleg@redhat.com>
---
 include/linux/fs.h | 6 ++++--
 1 file changed, 4 insertions(+), 2 deletions(-)

diff --git a/include/linux/fs.h b/include/linux/fs.h
index 3941b86..58faad6 100644
--- a/include/linux/fs.h
+++ b/include/linux/fs.h
@@ -860,8 +860,10 @@ struct file {
 	const struct cred	*f_cred;
 	struct file_ra_state	f_ra;
 
-	u64			f_version;
-	struct file		*f_next_put;
+	union {
+		u64		f_version;
+		struct file	*f_next_put;
+	};
 #ifdef CONFIG_SECURITY
 	void			*f_security;
 #endif
-- 
2.4.3

--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/

Back to linux.kernel | Previous | NextPrevious in thread | Find similar | Unroll thread


Thread

[PATCH 0/3] task_work: restore fifo ordering guarantee Oleg Nesterov <oleg@redhat.com> - 2015-09-08 19:20 +0200
  [PATCH 1/3] fput: don't abuse task_work_add() when possible Oleg Nesterov <oleg@redhat.com> - 2015-09-08 19:20 +0200
  [PATCH 2/3] fput: move ->f_next_put into a union with ->f_version Oleg Nesterov <oleg@redhat.com> - 2015-09-08 19:20 +0200

csiph-web