Merge branch 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/viro/vfs
Pull vfs pile (part one) from Al Viro: "Assorted stuff - cleaning namei.c up a bit, fixing ->d_name/->d_parent locking violations, etc. The most visible changes here are death of FS_REVAL_DOT (replaced with "has ->d_weak_revalidate()") and a new helper getting from struct file to inode. Some bits of preparation to xattr method interface changes. Misc patches by various people sent this cycle *and* ocfs2 fixes from several cycles ago that should've been upstream right then. PS: the next vfs pile will be xattr stuff." * 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/viro/vfs: (46 commits) saner proc_get_inode() calling conventions proc: avoid extra pde_put() in proc_fill_super() fs: change return values from -EACCES to -EPERM fs/exec.c: make bprm_mm_init() static ocfs2/dlm: use GFP_ATOMIC inside a spin_lock ocfs2: fix possible use-after-free with AIO ocfs2: Fix oops in ocfs2_fast_symlink_readpage() code path get_empty_filp()/alloc_file() leave both ->f_pos and ->f_version zero target: writev() on single-element vector is pointless export kernel_write(), convert open-coded instances fs: encode_fh: return FILEID_INVALID if invalid fid_type kill f_vfsmnt vfs: kill FS_REVAL_DOT by adding a d_weak_revalidate dentry op nfsd: handle vfs_getattr errors in acl protocol switch vfs_getattr() to struct path default SET_PERSONALITY() in linux/elf.h ceph: prepopulate inodes only when request is aborted d_hash_and_lookup(): export, switch open-coded instances 9p: switch v9fs_set_create_acl() to inode+fid, do it before d_instantiate() 9p: split dropping the acls from v9fs_set_create_acl() ...
This commit is contained in:
@@ -399,11 +399,9 @@ static int file_release(struct inode *inode, struct file *filp)
|
||||
|
||||
static unsigned int file_poll(struct file *file, poll_table * wait)
|
||||
{
|
||||
int minor;
|
||||
int minor = iminor(file_inode(file));
|
||||
unsigned int mask = 0;
|
||||
|
||||
minor = iminor(file->f_path.dentry->d_inode);
|
||||
|
||||
poll_wait(file, &channel_wqs[minor].rt_queue, wait);
|
||||
poll_wait(file, &channel_wqs[minor].lx_queue, wait);
|
||||
|
||||
@@ -424,7 +422,7 @@ static unsigned int file_poll(struct file *file, poll_table * wait)
|
||||
static ssize_t file_read(struct file *file, char __user * buffer, size_t count,
|
||||
loff_t * ppos)
|
||||
{
|
||||
int minor = iminor(file->f_path.dentry->d_inode);
|
||||
int minor = iminor(file_inode(file));
|
||||
|
||||
/* data available? */
|
||||
if (!rtlx_read_poll(minor, (file->f_flags & O_NONBLOCK) ? 0 : 1)) {
|
||||
@@ -437,11 +435,8 @@ static ssize_t file_read(struct file *file, char __user * buffer, size_t count,
|
||||
static ssize_t file_write(struct file *file, const char __user * buffer,
|
||||
size_t count, loff_t * ppos)
|
||||
{
|
||||
int minor;
|
||||
struct rtlx_channel *rt;
|
||||
|
||||
minor = iminor(file->f_path.dentry->d_inode);
|
||||
rt = &rtlx->channel[minor];
|
||||
int minor = iminor(file_inode(file));
|
||||
struct rtlx_channel *rt = &rtlx->channel[minor];
|
||||
|
||||
/* any space left... */
|
||||
if (!rtlx_write_poll(minor)) {
|
||||
|
@@ -1149,7 +1149,7 @@ static ssize_t vpe_write(struct file *file, const char __user * buffer,
|
||||
size_t ret = count;
|
||||
struct vpe *v;
|
||||
|
||||
if (iminor(file->f_path.dentry->d_inode) != minor)
|
||||
if (iminor(file_inode(file)) != minor)
|
||||
return -ENODEV;
|
||||
|
||||
v = get_vpe(tclimit);
|
||||
|
Reference in New Issue
Block a user