mbox series

[v3,0/2] fs/lock: Cleanup around flock syscall.

Message ID 20220717043532.35821-1-kuniyu@amazon.com (mailing list archive)
Headers show
Series fs/lock: Cleanup around flock syscall. | expand

Message

Kuniyuki Iwashima July 17, 2022, 4:35 a.m. UTC
The first patch removes allocate-and-free for struct file_lock
in flock syscall and the second patch rearrange some operations.

Changes:
  v3:
    * Test LOCK_MAND first in patch 2

  v2: https://lore.kernel.org/linux-fsdevel/20220716233343.22106-1-kuniyu@amazon.com/
    * Use F_UNLCK in locks_remove_flock() (Chuck Lever)
    * Fix uninitialised error in flock syscall (kernel test robot)
    * Fix error when setting LOCK_NB
    * Split patches not to mix different kinds of optimisations and
      not to miss errors reported by kernel test robot

  v1: https://lore.kernel.org/linux-fsdevel/20220716013140.61445-1-kuniyu@amazon.com/


Kuniyuki Iwashima (2):
  fs/lock: Don't allocate file_lock in flock_make_lock().
  fs/lock: Rearrange ops in flock syscall.

 fs/locks.c | 77 ++++++++++++++++++++----------------------------------
 1 file changed, 28 insertions(+), 49 deletions(-)

Comments

Jeff Layton July 18, 2022, 10:43 a.m. UTC | #1
On Sat, 2022-07-16 at 21:35 -0700, Kuniyuki Iwashima wrote:
> The first patch removes allocate-and-free for struct file_lock
> in flock syscall and the second patch rearrange some operations.
> 
> Changes:
>   v3:
>     * Test LOCK_MAND first in patch 2
> 
>   v2: https://lore.kernel.org/linux-fsdevel/20220716233343.22106-1-kuniyu@amazon.com/
>     * Use F_UNLCK in locks_remove_flock() (Chuck Lever)
>     * Fix uninitialised error in flock syscall (kernel test robot)
>     * Fix error when setting LOCK_NB
>     * Split patches not to mix different kinds of optimisations and
>       not to miss errors reported by kernel test robot
> 
>   v1: https://lore.kernel.org/linux-fsdevel/20220716013140.61445-1-kuniyu@amazon.com/
> 
> 
> Kuniyuki Iwashima (2):
>   fs/lock: Don't allocate file_lock in flock_make_lock().
>   fs/lock: Rearrange ops in flock syscall.
> 
>  fs/locks.c | 77 ++++++++++++++++++++----------------------------------
>  1 file changed, 28 insertions(+), 49 deletions(-)
> 

This looks good, and I've added it to the branch I feed into linux-next.
If all goes well, I'll plan to ask Linus to pull this in for v5.20.
Since you respun it, I dropped Chuck's Reviewed-by. Chuck, please re-
review if you want me to put that back.

Thanks!