Skip to contentSkip to conversation

Small change needed in nfs_xdr.h

PATCH In review Boaz Harrosh 2 participants 4 messages Jun 13, 2011 – Jun 14, 2011

Subsystems (2)
lore
Share & tools
lore
#0 lore raw

cover Small change needed in nfs_xdr.h

Hi trond

I need this simple patch:

[PATCH 1/2] nfs_xdr: Move nfs4_string definition out of #ifdef CONFIG_NFS_V4

exofs file system wants to use pnfs_osd_xdr.h file instead of redefining pnfs-objects types in it's private "pnfs.h" header.

Before we do the switch we must make sure pnfs_osd_xdr.h is compilable also under NFS versions smaller than 4.1. Since now it is needed regardless of version, by the exofs code.

Only miss-out is nfs4_string move it to global scope.

So I can submit this patch to the exofs tree:
[PATCH 1/2] exofs: pnfs-tree: Remove pnfs-osd private definitions

Now that pnfs-osd has hit mainline we can remove exofs's private header. (And the FIXME comment)

The small problem is that if we both keep a copy of the patch in linux-next, it will be fine until there are possibly more changes to nfs_xdr.h. git merge will not like that.

If you have another batch for this -rc you could include the patch and I'll rebase my linux-next on that -rc. Or we can risk having the same patch and if there are any more changes just ping me and I'll see what I do with linux-next. Or you can send me your ack-by: and I can submit it through exofs tree.

Thanks
Boaz

#1 lore raw

PATCH 1/2 nfs_xdr: Move nfs4_string definition out of #ifdef CONFIG_NFS_V4

exofs file system wants to use pnfs_osd_xdr.h file instead of redefining pnfs-objects types in it's private "pnfs.h" headr.

Before we do the switch we must make sure pnfs_osd_xdr.h is compilable also under NFS versions smaller than 4.1. Since now it is needed regardless of version, by the exofs code.

Only miss-out is nfs4_string move it to global scope.

---
 include/linux/nfs_xdr.h |   10 +++++-----
 1 files changed, 5 insertions(+), 5 deletions(-)
include/linux/nfs_xdr.h +5 -5
index 0a21844..7372921 100644
@@ -774,6 +774,11 @@ struct nfs3_getaclres {
 	struct posix_acl *	acl_default;
 };
 
+struct nfs4_string {
+	unsigned int len;
+	char *data;
+};
+
 #ifdef CONFIG_NFS_V4
 
 typedef u64 clientid4;
@@ -964,11 +969,6 @@ struct nfs4_server_caps_res {
 	struct nfs4_sequence_res	seq_res;
 };
 
-struct nfs4_string {
-	unsigned int len;
-	char *data;
-};
-
 #define NFS4_PATHNAME_MAXCOMPONENTS 512
 struct nfs4_pathname {
 	unsigned int ncomponents;
Signature · 1 line
1.7.3.4
Acked-by on v1 1/2
#2 lore raw

Re: [PATCH 1/2] nfs_xdr: Move nfs4_string definition out of #ifdef CONFIG_NFS_V4

Quoted 10 lines · Boaz Harrosh

exofs file system wants to use pnfs_osd_xdr.h file instead of redefining pnfs-objects types in it's private "pnfs.h" headr.

Before we do the switch we must make sure pnfs_osd_xdr.h is compilable also under NFS versions smaller than 4.1. Since now it is needed regardless of version, by the exofs code.

Only miss-out is nfs4_string move it to global scope.

Signature · 6 lines
Trond Myklebust
Linux NFS client maintainer

NetApp
[email protected]
www.netapp.com
#3 lore raw

PATCH 2/2 exofs: pnfs-tree: Remove pnfs-osd private definitions

In reply to Boaz Harrosh

Now that pnfs-osd has hit mainline we can remove exofs's private header. (And the FIXME comment)

---
 fs/exofs/exofs.h |    6 +-----
 fs/exofs/pnfs.h  |   45 ---------------------------------------------
 2 files changed, 1 insertions(+), 50 deletions(-)
 delete mode 100644 fs/exofs/pnfs.h
fs/exofs/exofs.h +1 -5
index c965806..e103dbd 100644
@@ -36,13 +36,9 @@
 #include <linux/fs.h>
 #include <linux/time.h>
 #include <linux/backing-dev.h>
+#include <linux/pnfs_osd_xdr.h>
 #include "common.h"
 
-/* FIXME: Remove once pnfs hits mainline
- * #include <linux/exportfs/pnfs_osd_xdr.h>
- */
-#include "pnfs.h"
-
 #define EXOFS_ERR(fmt, a...) printk(KERN_ERR "exofs: " fmt, ##a)
 
 #ifdef CONFIG_EXOFS_DEBUG
fs/exofs/pnfs.h deleted +0 -45

45 lines not on this page · raw message

Signature · 1 line
1.7.3.4