lkml.org 
[lkml]   [2020]   [Apr]   [1]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
Date
From
SubjectRe: [PATCH v3 10/10] mmap locking API: rename mmap_sem to mmap_lock
On Fri, Mar 27, 2020 at 03:51:02PM -0700, Michel Lespinasse wrote:
> Rename the mmap_sem field to mmap_lock. Any new uses of this lock
> should now go through the new mmap locking api. The mmap_lock is
> still implemented as a rwsem, though this could change in the future.

> diff --git a/include/linux/mm_types.h b/include/linux/mm_types.h
> index c28911c3afa8..a168d13b5c44 100644
> --- a/include/linux/mm_types.h
> +++ b/include/linux/mm_types.h
> @@ -431,7 +431,7 @@ struct mm_struct {
> spinlock_t page_table_lock; /* Protects page tables and some
> * counters
> */
> - struct rw_semaphore mmap_sem;
> + struct rw_semaphore mmap_lock;

It would be best if you change the type too.

>
> struct list_head mmlist; /* List of maybe swapped mm's. These
> * are globally strung together off

\
 
 \ /
  Last update: 2020-04-01 15:49    [W:0.173 / U:0.840 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site