summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--fs/afs/Makefile2
-rw-r--r--fs/afs/cache.h12
-rw-r--r--fs/afs/callback.c9
-rw-r--r--fs/afs/cell.c51
-rw-r--r--fs/afs/cell.h30
-rw-r--r--fs/afs/cmservice.c46
-rw-r--r--fs/afs/cmservice.h17
-rw-r--r--fs/afs/dir.c50
-rw-r--r--fs/afs/errors.h14
-rw-r--r--fs/afs/file.c20
-rw-r--r--fs/afs/fsclient.c73
-rw-r--r--fs/afs/fsclient.h48
-rw-r--r--fs/afs/inode.c29
-rw-r--r--fs/afs/internal.h36
-rw-r--r--fs/afs/kafsasyncd.c22
-rw-r--r--fs/afs/kafsasyncd.h22
-rw-r--r--fs/afs/kafstimod.c31
-rw-r--r--fs/afs/kafstimod.h20
-rw-r--r--fs/afs/main.c94
-rw-r--r--fs/afs/misc.c6
-rw-r--r--fs/afs/mntpt.c27
-rw-r--r--fs/afs/mount.h8
-rw-r--r--fs/afs/proc.c161
-rw-r--r--fs/afs/server.c47
-rw-r--r--fs/afs/server.h41
-rw-r--r--fs/afs/super.c62
-rw-r--r--fs/afs/super.h16
-rw-r--r--fs/afs/transport.h8
-rw-r--r--fs/afs/types.h34
-rw-r--r--fs/afs/vlclient.c58
-rw-r--r--fs/afs/vlclient.h34
-rw-r--r--fs/afs/vlocation.c102
-rw-r--r--fs/afs/vnode.c36
-rw-r--r--fs/afs/vnode.h36
-rw-r--r--fs/afs/volume.c58
-rw-r--r--fs/afs/volume.h52
36 files changed, 506 insertions, 906 deletions
diff --git a/fs/afs/Makefile b/fs/afs/Makefile
index 4029c9da4b86..8e7197379672 100644
--- a/fs/afs/Makefile
+++ b/fs/afs/Makefile
@@ -2,8 +2,6 @@
# Makefile for Red Hat Linux AFS client.
#
-#CFLAGS += -finstrument-functions
-
kafs-objs := \
callback.o \
cell.o \
diff --git a/fs/afs/cache.h b/fs/afs/cache.h
index 9eb7722b34d5..36a3642cf90e 100644
--- a/fs/afs/cache.h
+++ b/fs/afs/cache.h
@@ -1,4 +1,4 @@
-/* cache.h: AFS local cache management interface
+/* AFS local cache management interface
*
* Copyright (C) 2002 Red Hat, Inc. All Rights Reserved.
* Written by David Howells (dhowells@redhat.com)
@@ -9,8 +9,8 @@
* 2 of the License, or (at your option) any later version.
*/
-#ifndef _LINUX_AFS_CACHE_H
-#define _LINUX_AFS_CACHE_H
+#ifndef AFS_CACHE_H
+#define AFS_CACHE_H
#undef AFS_CACHING_SUPPORT
@@ -20,8 +20,4 @@
#endif
#include "types.h"
-#ifdef __KERNEL__
-
-#endif /* __KERNEL__ */
-
-#endif /* _LINUX_AFS_CACHE_H */
+#endif /* AFS_CACHE_H */
diff --git a/fs/afs/callback.c b/fs/afs/callback.c
index 9cb206e9d4be..26a48fea42f4 100644
--- a/fs/afs/callback.c
+++ b/fs/afs/callback.c
@@ -21,7 +21,6 @@
#include "internal.h"
#include "cmservice.h"
-/*****************************************************************************/
/*
* allow the fileserver to request callback state (re-)initialisation
*/
@@ -79,9 +78,8 @@ int SRXAFSCM_InitCallBackState(struct afs_server *server)
_leave(" = 0");
return 0;
-} /* end SRXAFSCM_InitCallBackState() */
+}
-/*****************************************************************************/
/*
* allow the fileserver to break callback promises
*/
@@ -156,9 +154,8 @@ int SRXAFSCM_CallBack(struct afs_server *server, size_t count,
_leave(" = 0");
return 0;
-} /* end SRXAFSCM_CallBack() */
+}
-/*****************************************************************************/
/*
* allow the fileserver to see if the cache manager is still alive
*/
@@ -166,4 +163,4 @@ int SRXAFSCM_Probe(struct afs_server *server)
{
_debug("SRXAFSCM_Probe(%p)\n", server);
return 0;
-} /* end SRXAFSCM_Probe() */
+}
diff --git a/fs/afs/cell.c b/fs/afs/cell.c
index 1fc578372759..28ed84ec8ff7 100644
--- a/fs/afs/cell.c
+++ b/fs/afs/cell.c
@@ -1,4 +1,4 @@
-/* cell.c: AFS cell and server record management
+/* AFS cell and server record management
*
* Copyright (C) 2002 Red Hat, Inc. All Rights Reserved.
* Written by David Howells (dhowells@redhat.com)
@@ -44,7 +44,6 @@ struct cachefs_index_def afs_cache_cell_index_def = {
};
#endif
-/*****************************************************************************/
/*
* create a cell record
* - "name" is the name of the cell
@@ -137,16 +136,15 @@ int afs_cell_create(const char *name, char *vllist, struct afs_cell **_cell)
_leave(" = 0 (%p)", cell);
return 0;
- badaddr:
+badaddr:
printk(KERN_ERR "kAFS: bad VL server IP address: '%s'\n", vllist);
- error:
+error:
up_write(&afs_cells_sem);
kfree(cell);
_leave(" = %d", ret);
return ret;
-} /* end afs_cell_create() */
+}
-/*****************************************************************************/
/*
* initialise the cell database from module parameters
*/
@@ -199,10 +197,8 @@ int afs_cell_init(char *rootcell)
_leave(" = %d", ret);
return ret;
+}
-} /* end afs_cell_init() */
-
-/*****************************************************************************/
/*
* lookup a cell record
*/
@@ -234,8 +230,7 @@ int afs_cell_lookup(const char *name, unsigned namesz, struct afs_cell **_cell)
if (cell)
ret = 0;
- }
- else {
+ } else {
read_lock(&afs_cells_lock);
cell = afs_cell_root;
@@ -247,8 +242,7 @@ int afs_cell_lookup(const char *name, unsigned namesz, struct afs_cell **_cell)
* for other reasons.
*/
ret = -EDESTADDRREQ;
- }
- else {
+ } else {
afs_get_cell(cell);
ret = 0;
}
@@ -259,10 +253,8 @@ int afs_cell_lookup(const char *name, unsigned namesz, struct afs_cell **_cell)
*_cell = cell;
_leave(" = %d (%p)", ret, cell);
return ret;
+}
-} /* end afs_cell_lookup() */
-
-/*****************************************************************************/
/*
* try and get a cell record
*/
@@ -281,9 +273,8 @@ struct afs_cell *afs_get_cell_maybe(struct afs_cell **_cell)
write_unlock(&afs_cells_lock);
return cell;
-} /* end afs_get_cell_maybe() */
+}
-/*****************************************************************************/
/*
* destroy a cell record
*/
@@ -315,9 +306,8 @@ void afs_put_cell(struct afs_cell *cell)
BUG_ON(!list_empty(&cell->vl_graveyard));
_leave(" [unused]");
-} /* end afs_put_cell() */
+}
-/*****************************************************************************/
/*
* destroy a cell record
*/
@@ -359,9 +349,8 @@ static void afs_cell_destroy(struct afs_cell *cell)
kfree(cell);
_leave(" [destroyed]");
-} /* end afs_cell_destroy() */
+}
-/*****************************************************************************/
/*
* lookup the server record corresponding to an Rx RPC peer
*/
@@ -411,7 +400,7 @@ int afs_server_find_by_peer(const struct rxrpc_peer *peer,
return -ENOENT;
/* we found it in the graveyard - resurrect it */
- found_dead_server:
+found_dead_server:
list_move_tail(&server->link, &cell->sv_list);
afs_get_server(server);
afs_kafstimod_del_timer(&server->timeout);
@@ -419,20 +408,18 @@ int afs_server_find_by_peer(const struct rxrpc_peer *peer,
goto success;
/* we found it - increment its ref count and return it */
- found_server:
+found_server:
afs_get_server(server);
- success:
+success:
write_unlock(&cell->sv_lock);
read_unlock(&afs_cells_lock);
*_server = server;
_leave(" = 0 (s=%p c=%p)", server, cell);
return 0;
+}
-} /* end afs_server_find_by_peer() */
-
-/*****************************************************************************/
/*
* purge in-memory cell database on module unload or afs_init() failure
* - the timeout daemon is stopped before calling this
@@ -520,9 +507,8 @@ void afs_cell_purge(void)
}
_leave("");
-} /* end afs_cell_purge() */
+}
-/*****************************************************************************/
/*
* match a cell record obtained from the cache
*/
@@ -542,10 +528,9 @@ static cachefs_match_val_t afs_cell_cache_match(void *target,
_leave(" = FAILED");
return CACHEFS_MATCH_FAILED;
-} /* end afs_cell_cache_match() */
+}
#endif
-/*****************************************************************************/
/*
* update a cell record in the cache
*/
@@ -563,5 +548,5 @@ static void afs_cell_cache_update(void *source, void *entry)
cell->vl_addrs,
min(sizeof(ccell->vl_servers), sizeof(cell->vl_addrs)));
-} /* end afs_cell_cache_update() */
+}
#endif
diff --git a/fs/afs/cell.h b/fs/afs/cell.h
index 48349108fb00..c135b00c6c75 100644
--- a/fs/afs/cell.h
+++ b/fs/afs/cell.h
@@ -1,4 +1,4 @@
-/* cell.h: AFS cell record
+/* AFS cell record
*
* Copyright (C) 2002 Red Hat, Inc. All Rights Reserved.
* Written by David Howells (dhowells@redhat.com)
@@ -9,8 +9,8 @@
* 2 of the License, or (at your option) any later version.
*/
-#ifndef _LINUX_AFS_CELL_H
-#define _LINUX_AFS_CELL_H
+#ifndef AFS_CELL_H
+#define AFS_CELL_H
#include "types.h"
#include "cache.h"
@@ -19,22 +19,18 @@
extern volatile int afs_cells_being_purged; /* T when cells are being purged by rmmod */
-/*****************************************************************************/
/*
* entry in the cached cell catalogue
*/
-struct afs_cache_cell
-{
+struct afs_cache_cell {
char name[64]; /* cell name (padded with NULs) */
struct in_addr vl_servers[15]; /* cached cell VL servers */
};
-/*****************************************************************************/
/*
* AFS cell record
*/
-struct afs_cell
-{
+struct afs_cell {
atomic_t usage;
struct list_head link; /* main cell list link */
struct list_head proc_link; /* /proc cell list link */
@@ -61,18 +57,14 @@ struct afs_cell
char name[0]; /* cell name - must go last */
};
-extern int afs_cell_init(char *rootcell);
-
-extern int afs_cell_create(const char *name, char *vllist, struct afs_cell **_cell);
-
-extern int afs_cell_lookup(const char *name, unsigned nmsize, struct afs_cell **_cell);
+extern int afs_cell_init(char *);
+extern int afs_cell_create(const char *, char *, struct afs_cell **);
+extern int afs_cell_lookup(const char *, unsigned, struct afs_cell **);
#define afs_get_cell(C) do { atomic_inc(&(C)->usage); } while(0)
-extern struct afs_cell *afs_get_cell_maybe(struct afs_cell **_cell);
-
-extern void afs_put_cell(struct afs_cell *cell);
-
+extern struct afs_cell *afs_get_cell_maybe(struct afs_cell **);
+extern void afs_put_cell(struct afs_cell *);
extern void afs_cell_purge(void);
-#endif /* _LINUX_AFS_CELL_H */
+#endif /* AFS_CELL_H */
diff --git a/fs/afs/cmservice.c b/fs/afs/cmservice.c
index 3d097fddcb7a..3f4585765cbf 100644
--- a/fs/afs/cmservice.c
+++ b/fs/afs/cmservice.c
@@ -1,4 +1,4 @@
-/* cmservice.c: AFS Cache Manager Service
+/* AFS Cache Manager Service
*
* Copyright (C) 2002 Red Hat, Inc. All Rights Reserved.
* Written by David Howells (dhowells@redhat.com)
@@ -106,7 +106,6 @@ static DEFINE_SPINLOCK(afscm_calls_lock);
static DEFINE_SPINLOCK(kafscmd_attention_lock);
static int kafscmd_die;
-/*****************************************************************************/
/*
* AFS Cache Manager kernel thread
*/
@@ -177,10 +176,8 @@ static int kafscmd(void *arg)
/* and that's all */
complete_and_exit(&kafscmd_dead, 0);
+}
-} /* end kafscmd() */
-
-/*****************************************************************************/
/*
* handle a call coming in to the cache manager
* - if I want to keep the call, I must increment its usage count
@@ -202,10 +199,8 @@ static int afscm_new_call(struct rxrpc_call *call)
_leave(" = 0");
return 0;
+}
-} /* end afscm_new_call() */
-
-/*****************************************************************************/
/*
* queue on the kafscmd queue for attention
*/
@@ -226,9 +221,8 @@ static void afscm_attention(struct rxrpc_call *call)
wake_up(&kafscmd_sleepq);
_leave(" {u=%d}", atomic_read(&call->usage));
-} /* end afscm_attention() */
+}
-/*****************************************************************************/
/*
* handle my call being aborted
* - clean up, dequeue and put my ref to the call
@@ -266,9 +260,8 @@ static void afscm_error(struct rxrpc_call *call)
wake_up(&kafscmd_sleepq);
_leave("");
-} /* end afscm_error() */
+}
-/*****************************************************************************/
/*
* map afs abort codes to/from Linux error codes
* - called with call->lock held
@@ -285,9 +278,8 @@ static void afscm_aemap(struct rxrpc_call *call)
default:
break;
}
-} /* end afscm_aemap() */
+}
-/*****************************************************************************/
/*
* start the cache manager service if not already started
*/
@@ -316,18 +308,16 @@ int afscm_start(void)
return 0;
- kill:
+kill:
kafscmd_die = 1;
wake_up(&kafscmd_sleepq);
wait_for_completion(&kafscmd_dead);
- out:
+out:
up_write(&afscm_sem);
return ret;
+}
-} /* end afscm_start() */
-
-/*****************************************************************************/
/*
* stop the cache manager service
*/
@@ -394,10 +384,8 @@ void afscm_stop(void)
}
up_write(&afscm_sem);
+}
-} /* end afscm_stop() */
-
-/*****************************************************************************/
/*
* handle the fileserver breaking a set of callbacks
*/
@@ -460,8 +448,7 @@ static void _SRXAFSCM_CallBack(struct rxrpc_call *call)
pcb->version = ntohl(*bp++);
pcb->expiry = ntohl(*bp++);
pcb->type = ntohl(*bp++);
- }
- else {
+ } else {
pcb->version = 0;
pcb->expiry = 0;
pcb->type = AFSCM_CB_UNTYPED;
@@ -512,10 +499,8 @@ static void _SRXAFSCM_CallBack(struct rxrpc_call *call)
afs_put_server(server);
_leave(" = %d", ret);
+}
-} /* end _SRXAFSCM_CallBack() */
-
-/*****************************************************************************/
/*
* handle the fileserver asking us to initialise our callback state
*/
@@ -580,10 +565,8 @@ static void _SRXAFSCM_InitCallBackState(struct rxrpc_call *call)
afs_put_server(server);
_leave(" = %d", ret);
+}
-} /* end _SRXAFSCM_InitCallBackState() */
-
-/*****************************************************************************/
/*
* handle a probe from a fileserver
*/
@@ -648,5 +631,4 @@ static void _SRXAFSCM_Probe(struct rxrpc_call *call)
afs_put_server(server);
_leave(" = %d", ret);
-
-} /* end _SRXAFSCM_Probe() */
+}
diff --git a/fs/afs/cmservice.h b/fs/afs/cmservice.h
index af8d4d689cb2..66e10c15bd1b 100644
--- a/fs/afs/cmservice.h
+++ b/fs/afs/cmservice.h
@@ -1,4 +1,4 @@
-/* cmservice.h: AFS Cache Manager Service declarations
+/* AFS Cache Manager Service declarations
*
* Copyright (C) 2002 Red Hat, Inc. All Rights Reserved.
* Written by David Howells (dhowells@redhat.com)
@@ -9,8 +9,8 @@
* 2 of the License, or (at your option) any later version.
*/
-#ifndef _LINUX_AFS_CMSERVICE_H
-#define _LINUX_AFS_CMSERVICE_H
+#ifndef AFS_CMSERVICE_H
+#define AFS_CMSERVICE_H
#include <rxrpc/transport.h>
#include "types.h"
@@ -20,10 +20,9 @@ extern int afscm_start(void);
extern void afscm_stop(void);
/* cache manager server functions */
-extern int SRXAFSCM_InitCallBackState(struct afs_server *server);
-extern int SRXAFSCM_CallBack(struct afs_server *server,
- size_t count,
- struct afs_callback callbacks[]);
-extern int SRXAFSCM_Probe(struct afs_server *server);
+extern int SRXAFSCM_InitCallBackState(struct afs_server *);
+extern int SRXAFSCM_CallBack(struct afs_server *, size_t,
+ struct afs_callback[]);
+extern int SRXAFSCM_Probe(struct afs_server *);
-#endif /* _LINUX_AFS_CMSERVICE_H */
+#endif /* AFS_CMSERVICE_H */
diff --git a/fs/afs/dir.c b/fs/afs/dir.c
index b6dc2ebe47a8..2f6d92376461 100644
--- a/fs/afs/dir.c
+++ b/fs/afs/dir.c
@@ -112,7 +112,6 @@ struct afs_dir_lookup_cookie {
int found;
};
-/*****************************************************************************/
/*
* check that a directory page is valid
*/
@@ -157,13 +156,11 @@ static inline void afs_dir_check_page(struct inode *dir, struct page *page)
SetPageChecked(page);
return;
- error:
+error:
SetPageChecked(page);
SetPageError(page);
+}
-} /* end afs_dir_check_page() */
-
-/*****************************************************************************/
/*
* discard a page cached in the pagecache
*/
@@ -171,10 +168,8 @@ static inline void afs_dir_put_page(struct page *page)
{
kunmap(page);
page_cache_release(page);
+}
-} /* end afs_dir_put_page() */
-
-/*****************************************************************************/
/*
* get a page into the pagecache
*/
@@ -197,12 +192,11 @@ static struct page *afs_dir_get_page(struct inode *dir, unsigned long index)
}
return page;
- fail:
+fail:
afs_dir_put_page(page);
return ERR_PTR(-EIO);
-} /* end afs_dir_get_page() */
+}
-/*****************************************************************************/
/*
* open an AFS directory file
*/
@@ -218,10 +212,8 @@ static int afs_dir_open(struct inode *inode, struct file *file)
_leave(" = 0");
return 0;
+}
-} /* end afs_dir_open() */
-
-/*****************************************************************************/
/*
* deal with one block in an AFS directory
*/
@@ -316,9 +308,8 @@ static int afs_dir_iterate_block(unsigned *fpos,
_leave(" = 1 [more]");
return 1;
-} /* end afs_dir_iterate_block() */
+}
-/*****************************************************************************/
/*
* read an AFS directory
*/
@@ -377,12 +368,11 @@ static int afs_dir_iterate(struct inode *dir, unsigned *fpos, void *cookie,
ret = 0;
}
- out:
+out:
_leave(" = %d", ret);
return ret;
-} /* end afs_dir_iterate() */
+}
-/*****************************************************************************/
/*
* read an AFS directory
*/
@@ -399,9 +389,8 @@ static int afs_dir_readdir(struct file *file, void *cookie, filldir_t filldir)
_leave(" = %d", ret);
return ret;
-} /* end afs_dir_readdir() */
+}
-/*****************************************************************************/
/*
* search the directory for a name
* - if afs_dir_iterate_block() spots this function, it'll pass the FID
@@ -426,9 +415,8 @@ static int afs_dir_lookup_filldir(void *_cookie, const char *name, int nlen,
_leave(" = -1 [found]");
return -1;
-} /* end afs_dir_lookup_filldir() */
+}
-/*****************************************************************************/
/*
* look up an entry in a directory
*/
@@ -498,9 +486,8 @@ static struct dentry *afs_dir_lookup(struct inode *dir, struct dentry *dentry,
dentry->d_inode->i_version);
return NULL;
-} /* end afs_dir_lookup() */
+}
-/*****************************************************************************/
/*
* check that a dentry lookup hit has found a valid entry
* - NOTE! the hit can be a negative hit too, so we can't assume we have an
@@ -605,18 +592,18 @@ static int afs_d_revalidate(struct dentry *dentry, struct nameidata *nd)
(void *) (unsigned long) AFS_FS_I(dir)->status.version;
}
- out_valid:
+out_valid:
dput(parent);
_leave(" = 1 [valid]");
return 1;
/* the dirent, if it exists, now points to a different vnode */
- not_found:
+not_found:
spin_lock(&dentry->d_lock);
dentry->d_flags |= DCACHE_NFSFS_RENAMED;
spin_unlock(&dentry->d_lock);
- out_bad:
+out_bad:
if (inode) {
/* don't unhash if we have submounts */
if (have_submounts(dentry))
@@ -633,9 +620,8 @@ static int afs_d_revalidate(struct dentry *dentry, struct nameidata *nd)
_leave(" = 0 [bad]");
return 0;
-} /* end afs_d_revalidate() */
+}
-/*****************************************************************************/
/*
* allow the VFS to enquire as to whether a dentry should be unhashed (mustn't
* sleep)
@@ -657,7 +643,7 @@ static int afs_d_delete(struct dentry *dentry)
_leave(" = 0 [keep]");
return 0;
- zap:
+zap:
_leave(" = 1 [zap]");
return 1;
-} /* end afs_d_delete() */
+}
diff --git a/fs/afs/errors.h b/fs/afs/errors.h
index 574d94ac8d05..bcc0a3309e72 100644
--- a/fs/afs/errors.h
+++ b/fs/afs/errors.h
@@ -1,4 +1,4 @@
-/* errors.h: AFS abort/error codes
+/* AFS abort/error codes
*
* Copyright (C) 2002 Red Hat, Inc. All Rights Reserved.
* Written by David Howells (dhowells@redhat.com)
@@ -9,12 +9,14 @@
* 2 of the License, or (at your option) any later version.
*/
-#ifndef _LINUX_AFS_ERRORS_H
-#define _LINUX_AFS_ERRORS_H
+#ifndef AFS_ERRORS_H
+#define AFS_ERRORS_H
#include "types.h"
-/* file server abort codes */
+/*
+ * file server abort codes
+ */
typedef enum {
VSALVAGE = 101, /* volume needs salvaging */
VNOVNODE = 102, /* no such file/dir (vnode) */
@@ -29,6 +31,6 @@ typedef enum {
VMOVED = 111, /* volume moved to new server - ask this FS where */
} afs_rxfs_abort_t;
-extern int afs_abort_to_error(int abortcode);
+extern int afs_abort_to_error(int);
-#endif /* _LINUX_AFS_ERRORS_H */
+#endif /* AFS_ERRORS_H */
diff --git a/fs/afs/file.c b/fs/afs/file.c
index b17634541f67..01df30d256b8 100644
--- a/fs/afs/file.c
+++ b/fs/afs/file.c
@@ -40,7 +40,6 @@ const struct address_space_operations afs_fs_aops = {
.invalidatepage = afs_file_invalidatepage,
};
-/*****************************************************************************/
/*
* deal with notification that a page was read from the cache
*/
@@ -58,10 +57,9 @@ static void afs_file_readpage_read_complete(void *cookie_data,
SetPageUptodate(page);
unlock_page(page);
-} /* end afs_file_readpage_read_complete() */
+}
#endif
-/*****************************************************************************/
/*
* deal with notification that a page was written to the cache
*/
@@ -74,11 +72,9 @@ static void afs_file_readpage_write_complete(void *cookie_data,
_enter("%p,%p,%p,%d", cookie_data, page, data, error);
unlock_page(page);
-
-} /* end afs_file_readpage_write_complete() */
+}
#endif
-/*****************************************************************************/
/*
* AFS read page from file (or symlink)
*/
@@ -184,10 +180,8 @@ static int afs_file_readpage(struct file *file, struct page *page)
_leave(" = %d", ret);
return ret;
+}
-} /* end afs_file_readpage() */
-
-/*****************************************************************************/
/*
* get a page cookie for the specified page
*/
@@ -202,10 +196,9 @@ int afs_cache_get_page_cookie(struct page *page,
_leave(" = %d", ret);
return ret;
-} /* end afs_cache_get_page_cookie() */
+}
#endif
-/*****************************************************************************/
/*
* invalidate part or all of a page
*/
@@ -240,9 +233,8 @@ static void afs_file_invalidatepage(struct page *page, unsigned long offset)
}
_leave(" = %d", ret);
-} /* end afs_file_invalidatepage() */
+}
-/*****************************************************************************/
/*
* release a page and cleanup its private data
*/
@@ -267,4 +259,4 @@ static int afs_file_releasepage(struct page *page, gfp_t gfp_flags)
_leave(" = 0");
return 0;
-} /* end afs_file_releasepage() */
+}
diff --git a/fs/afs/fsclient.c b/fs/afs/fsclient.c
index 61bc371532ab..f1c3a186842e 100644
--- a/fs/afs/fsclient.c
+++ b/fs/afs/fsclient.c
@@ -29,7 +29,6 @@
#define FSGETROOTVOLUME 151 /* AFS Get root volume name */
#define FSLOOKUP 161 /* AFS lookup file in directory */
-/*****************************************************************************/
/*
* map afs abort codes to/from Linux error codes
* - called with call->lock held
@@ -46,9 +45,8 @@ static void afs_rxfs_aemap(struct rxrpc_call *call)
default:
break;
}
-} /* end afs_rxfs_aemap() */
+}
-/*****************************************************************************/
/*
* get the root volume name from a fileserver
* - this operation doesn't seem to work correctly in OpenAFS server 1.2.2
@@ -162,23 +160,22 @@ int afs_rxfs_get_root_volume(struct afs_server *server,
BUG();
}
- abort:
+abort:
set_current_state(TASK_UNINTERRUPTIBLE);
rxrpc_call_abort(call, ret);
schedule();
- out_unwait:
+out_unwait:
set_current_state(TASK_RUNNING);
remove_wait_queue(&call->waitq, &myself);
rxrpc_put_call(call);
- out_put_conn:
+out_put_conn:
afs_server_release_fsconn(server, conn);
- out:
+out:
kleave("");
return ret;
-} /* end afs_rxfs_get_root_volume() */
+}
#endif
-/*****************************************************************************/
/*
* get information about a volume
*/
@@ -275,26 +272,24 @@ int afs_rxfs_get_volume_info(struct afs_server *server,
/* success */
ret = 0;
- out_unwait:
+out_unwait:
set_current_state(TASK_RUNNING);
remove_wait_queue(&call->waitq, &myself);
rxrpc_put_call(call);
- out_put_conn:
+out_put_conn:
afs_server_release_fsconn(server, conn);
- out:
+out:
_leave("");
return ret;
- abort:
+abort:
set_current_state(TASK_UNINTERRUPTIBLE);
rxrpc_call_abort(call, ret);
schedule();
goto out_unwait;
-
-} /* end afs_rxfs_get_volume_info() */
+}
#endif
-/*****************************************************************************/
/*
* fetch the status information for a file
*/
@@ -401,24 +396,23 @@ int afs_rxfs_fetch_file_status(struct afs_server *server,
/* success */
ret = 0;
- out_unwait:
+out_unwait:
set_current_state(TASK_RUNNING);
remove_wait_queue(&call->waitq, &myself);
rxrpc_put_call(call);
- out_put_conn:
+out_put_conn:
afs_server_release_callslot(server, &callslot);
- out:
+out:
_leave("");
return ret;
- abort:
+abort:
set_current_state(TASK_UNINTERRUPTIBLE);
rxrpc_call_abort(call, ret);
schedule();
goto out_unwait;
-} /* end afs_rxfs_fetch_file_status() */
+}
-/*****************************************************************************/
/*
* fetch the contents of a file or directory
*/
@@ -547,31 +541,29 @@ int afs_rxfs_fetch_file_data(struct afs_server *server,
/* success */
ret = 0;
- out_unwait:
+out_unwait:
set_current_state(TASK_RUNNING);
remove_wait_queue(&call->waitq,&myself);
rxrpc_put_call(call);
- out_put_conn:
+out_put_conn:
afs_server_release_callslot(server, &callslot);
- out:
+out:
_leave(" = %d", ret);
return ret;
- read_failed:
+read_failed:
if (ret == -ECONNABORTED) {
ret = call->app_errno;
goto out_unwait;
}
- abort:
+abort:
set_current_state(TASK_UNINTERRUPTIBLE);
rxrpc_