mirror of
https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
synced 2026-05-02 08:39:08 -04:00
Merge tag 'afs-fixes-20200609' of git://git.kernel.org/pub/scm/linux/kernel/git/dhowells/linux-fs
Pull AFS fixes from David Howells: "A set of small patches to fix some things, most of them minor. - Fix a memory leak in afs_put_sysnames() - Fix an oops in AFS file locking - Fix new use of BUG() - Fix debugging statements containing %px - Remove afs_zero_fid as it's unused - Make afs_zap_data() static" * tag 'afs-fixes-20200609' of git://git.kernel.org/pub/scm/linux/kernel/git/dhowells/linux-fs: afs: Make afs_zap_data() static afs: Remove afs_zero_fid as it's not used afs: Fix debugging statements with %px to be %p afs: Fix use of BUG() afs: Fix file locking afs: Fix memory leak in afs_put_sysnames()
This commit is contained in:
@@ -980,7 +980,7 @@ static struct dentry *afs_lookup(struct inode *dir, struct dentry *dentry,
|
||||
if (!IS_ERR_OR_NULL(inode))
|
||||
fid = AFS_FS_I(inode)->fid;
|
||||
|
||||
_debug("splice %px", dentry->d_inode);
|
||||
_debug("splice %p", dentry->d_inode);
|
||||
d = d_splice_alias(inode, dentry);
|
||||
if (!IS_ERR_OR_NULL(d)) {
|
||||
d->d_fsdata = dentry->d_fsdata;
|
||||
|
||||
@@ -71,7 +71,7 @@ static void afs_schedule_lock_extension(struct afs_vnode *vnode)
|
||||
void afs_lock_op_done(struct afs_call *call)
|
||||
{
|
||||
struct afs_operation *op = call->op;
|
||||
struct afs_vnode *vnode = op->lock.lvnode;
|
||||
struct afs_vnode *vnode = op->file[0].vnode;
|
||||
|
||||
if (call->error == 0) {
|
||||
spin_lock(&vnode->lock);
|
||||
|
||||
@@ -538,7 +538,7 @@ struct inode *afs_root_iget(struct super_block *sb, struct key *key)
|
||||
* mark the data attached to an inode as obsolete due to a write on the server
|
||||
* - might also want to ditch all the outstanding writes and dirty pages
|
||||
*/
|
||||
void afs_zap_data(struct afs_vnode *vnode)
|
||||
static void afs_zap_data(struct afs_vnode *vnode)
|
||||
{
|
||||
_enter("{%llx:%llu}", vnode->fid.vid, vnode->fid.vnode);
|
||||
|
||||
|
||||
@@ -795,7 +795,6 @@ struct afs_operation {
|
||||
struct afs_read *req;
|
||||
} fetch;
|
||||
struct {
|
||||
struct afs_vnode *lvnode; /* vnode being locked */
|
||||
afs_lock_type_t type;
|
||||
} lock;
|
||||
struct {
|
||||
@@ -1070,7 +1069,6 @@ extern int afs_ilookup5_test_by_fid(struct inode *, void *);
|
||||
extern struct inode *afs_iget_pseudo_dir(struct super_block *, bool);
|
||||
extern struct inode *afs_iget(struct afs_operation *, struct afs_vnode_param *);
|
||||
extern struct inode *afs_root_iget(struct super_block *, struct key *);
|
||||
extern void afs_zap_data(struct afs_vnode *);
|
||||
extern bool afs_check_validity(struct afs_vnode *);
|
||||
extern int afs_validate(struct afs_vnode *, struct key *);
|
||||
extern int afs_getattr(const struct path *, struct kstat *, u32, unsigned int);
|
||||
|
||||
@@ -567,6 +567,7 @@ void afs_put_sysnames(struct afs_sysnames *sysnames)
|
||||
if (sysnames->subs[i] != afs_init_sysname &&
|
||||
sysnames->subs[i] != sysnames->blank)
|
||||
kfree(sysnames->subs[i]);
|
||||
kfree(sysnames);
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
@@ -28,7 +28,7 @@ static struct afs_volume *afs_sample_volume(struct afs_cell *cell, struct key *k
|
||||
};
|
||||
|
||||
volume = afs_create_volume(&fc);
|
||||
_leave(" = %px", volume);
|
||||
_leave(" = %p", volume);
|
||||
return volume;
|
||||
}
|
||||
|
||||
@@ -73,7 +73,8 @@ static int afs_compare_addrs(const struct sockaddr_rxrpc *srx_a,
|
||||
}
|
||||
|
||||
default:
|
||||
BUG();
|
||||
WARN_ON(1);
|
||||
diff = 1;
|
||||
}
|
||||
|
||||
out:
|
||||
|
||||
@@ -15,8 +15,6 @@
|
||||
#include "xdr_fs.h"
|
||||
#include "protocol_yfs.h"
|
||||
|
||||
static const struct afs_fid afs_zero_fid;
|
||||
|
||||
#define xdr_size(x) (sizeof(*x) / sizeof(__be32))
|
||||
|
||||
static void xdr_decode_YFSFid(const __be32 **_bp, struct afs_fid *fid)
|
||||
|
||||
Reference in New Issue
Block a user