From 482664ddba81b3a5404fd083bb9697dfffc0b6a4 Mon Sep 17 00:00:00 2001 From: Martin Brandenburg Date: Fri, 12 Aug 2016 12:02:31 -0400 Subject: orangefs: add features op This is a new userspace operation, which will be done if the client-core version is greater than or equal to 2.9.6. This will provide a way to implement optional features and to determine which features are supported by the client-core. If the client-core version is older than 2.9.6, no optional features are supported and the op will not be done. The intent is to allow protocol extensions without relying on the client-core's current behavior of ignoring what it doesn't understand. Signed-off-by: Martin Brandenburg --- fs/orangefs/devorangefs-req.c | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) (limited to 'fs/orangefs/devorangefs-req.c') diff --git a/fs/orangefs/devorangefs-req.c b/fs/orangefs/devorangefs-req.c index 7c40e653e526..ec1a5ff1d843 100644 --- a/fs/orangefs/devorangefs-req.c +++ b/fs/orangefs/devorangefs-req.c @@ -17,7 +17,7 @@ /* this file implements the /dev/pvfs2-req device node */ -uint32_t userspace_version; +uint32_t orangefs_userspace_version; static int open_access_count; @@ -389,9 +389,9 @@ static ssize_t orangefs_devreq_write_iter(struct kiocb *iocb, return -EPROTO; } - if (!userspace_version) { - userspace_version = head.version; - } else if (userspace_version != head.version) { + if (!orangefs_userspace_version) { + orangefs_userspace_version = head.version; + } else if (orangefs_userspace_version != head.version) { gossip_err("Error: userspace version changes\n"); return -EPROTO; } @@ -536,7 +536,7 @@ static int orangefs_devreq_release(struct inode *inode, struct file *file) gossip_debug(GOSSIP_DEV_DEBUG, "pvfs2-client-core: device close complete\n"); open_access_count = 0; - userspace_version = 0; + orangefs_userspace_version = 0; mutex_unlock(&devreq_mutex); return 0; } -- cgit v1.2.3