Merge branch 'master' into wrapfs
authorAndrew Burford <aburford@cs.stonybrook.edu>
Tue, 10 May 2022 16:00:19 +0000 (12:00 -0400)
committerAndrew Burford <aburford@cs.stonybrook.edu>
Tue, 10 May 2022 16:00:19 +0000 (12:00 -0400)
1  2 
MAINTAINERS
fs/Kconfig
fs/Makefile
fs/read_write.c
include/linux/namei.h
include/uapi/linux/magic.h

diff --cc MAINTAINERS
index 4c7ba16c9a9d3cd5add29af50c6e9085fd44de84,d7b4f32875a94d385b5670d9498ca7e3673bd5e4..759c8c0de764e68045be1d81167c55f0d9d7201e
@@@ -17904,21 -20069,22 +20069,31 @@@ F:        sound/soc/codecs/wm
  WORKQUEUE
  M:    Tejun Heo <tj@kernel.org>
  R:    Lai Jiangshan <jiangshanlai@gmail.com>
- T:    git git://git.kernel.org/pub/scm/linux/kernel/git/tj/wq.git
  S:    Maintained
+ T:    git git://git.kernel.org/pub/scm/linux/kernel/git/tj/wq.git
+ F:    Documentation/core-api/workqueue.rst
  F:    include/linux/workqueue.h
  F:    kernel/workqueue.c
- F:    Documentation/core-api/workqueue.rst
+ WWAN DRIVERS
+ M:    Loic Poulain <loic.poulain@linaro.org>
+ M:    Sergey Ryazanov <ryazanov.s.a@gmail.com>
+ R:    Johannes Berg <johannes@sipsolutions.net>
+ L:    netdev@vger.kernel.org
+ S:    Maintained
+ F:    drivers/net/wwan/
+ F:    include/linux/wwan.h
+ F:    include/uapi/linux/wwan.h
  
 +WRAP FILE SYSTEM
 +M:    Erez Zadok <ezk@cs.sunysb.edu>
 +L:    wrapfs@filesystems.org
 +W:    https://wrapfs.filesystems.org/
 +T:    git git://git.fsl.cs.sunysb.edu/wrapfs-latest.git
 +S:    Maintained
 +F:    Documentation/filesystems/wrapfs.txt
 +F:    fs/wrapfs/
 +
  X-POWERS AXP288 PMIC DRIVERS
  M:    Hans de Goede <hdegoede@redhat.com>
  S:    Maintained
diff --cc fs/Kconfig
Simple merge
diff --cc fs/Makefile
Simple merge
diff --cc fs/read_write.c
index d33c77e3cf3c789ec4b7b6ee7aa3a70d6ac90414,9db7adf160d206d58cefe9c308513f476bc5d6e4..02148009b7028ed3ee6792aa0098650dbf15949e
@@@ -455,20 -485,24 +485,25 @@@ ssize_t vfs_read(struct file *file, cha
                return -EFAULT;
  
        ret = rw_verify_area(READ, file, pos, count);
-       if (!ret) {
-               if (count > MAX_RW_COUNT)
-                       count =  MAX_RW_COUNT;
-               ret = __vfs_read(file, buf, count, pos);
-               if (ret > 0) {
-                       fsnotify_access(file);
-                       add_rchar(current, ret);
-               }
-               inc_syscr(current);
-       }
+       if (ret)
+               return ret;
+       if (count > MAX_RW_COUNT)
+               count =  MAX_RW_COUNT;
  
+       if (file->f_op->read)
+               ret = file->f_op->read(file, buf, count, pos);
+       else if (file->f_op->read_iter)
+               ret = new_sync_read(file, buf, count, pos);
+       else
+               ret = -EINVAL;
+       if (ret > 0) {
+               fsnotify_access(file);
+               add_rchar(current, ret);
+       }
+       inc_syscr(current);
        return ret;
  }
 +EXPORT_SYMBOL(vfs_read);
  
  static ssize_t new_sync_write(struct file *filp, const char __user *buf, size_t len, loff_t *ppos)
  {
@@@ -552,22 -594,25 +595,26 @@@ ssize_t vfs_write(struct file *file, co
                return -EFAULT;
  
        ret = rw_verify_area(WRITE, file, pos, count);
-       if (!ret) {
-               if (count > MAX_RW_COUNT)
-                       count =  MAX_RW_COUNT;
-               file_start_write(file);
-               ret = __vfs_write(file, buf, count, pos);
-               if (ret > 0) {
-                       fsnotify_modify(file);
-                       add_wchar(current, ret);
-               }
-               inc_syscw(current);
-               file_end_write(file);
+       if (ret)
+               return ret;
+       if (count > MAX_RW_COUNT)
+               count =  MAX_RW_COUNT;
+       file_start_write(file);
+       if (file->f_op->write)
+               ret = file->f_op->write(file, buf, count, pos);
+       else if (file->f_op->write_iter)
+               ret = new_sync_write(file, buf, count, pos);
+       else
+               ret = -EINVAL;
+       if (ret > 0) {
+               fsnotify_modify(file);
+               add_wchar(current, ret);
        }
+       inc_syscw(current);
+       file_end_write(file);
        return ret;
  }
 +EXPORT_SYMBOL(vfs_write);
  
  /* file_ppos returns &file->f_pos or NULL if file is stream */
  static inline loff_t *file_ppos(struct file *file)
index 80655b920a8f495b9730a000e7cd75802720b4e6,be9a2b349ca7e80e003f4ce86bd2512a928f1494..00bc3c0b08a8c76916fb6d5a86fce998e072a6ab
@@@ -55,9 -63,6 +63,8 @@@ extern struct dentry *kern_path_create(
  extern struct dentry *user_path_create(int, const char __user *, struct path *, unsigned int);
  extern void done_path_create(struct path *, struct dentry *);
  extern struct dentry *kern_path_locked(const char *, struct path *);
- extern int kern_path_mountpoint(int, const char *, struct path *, unsigned int);
 +extern int vfs_path_lookup(struct dentry *, struct vfsmount *,
 +                         const char *, unsigned int, struct path *);
  
  extern struct dentry *try_lookup_one_len(const char *, struct dentry *, int);
  extern struct dentry *lookup_one_len(const char *, struct dentry *, int);
Simple merge