aboutsummaryrefslogtreecommitdiffstats
path: root/Documentation/filesystems/Locking
diff options
context:
space:
mode:
authorGlenn Elliott <gelliott@cs.unc.edu>2012-03-04 19:47:13 -0500
committerGlenn Elliott <gelliott@cs.unc.edu>2012-03-04 19:47:13 -0500
commitc71c03bda1e86c9d5198c5d83f712e695c4f2a1e (patch)
treeecb166cb3e2b7e2adb3b5e292245fefd23381ac8 /Documentation/filesystems/Locking
parentea53c912f8a86a8567697115b6a0d8152beee5c8 (diff)
parent6a00f206debf8a5c8899055726ad127dbeeed098 (diff)
Merge branch 'mpi-master' into wip-k-fmlpwip-k-fmlp
Conflicts: litmus/sched_cedf.c
Diffstat (limited to 'Documentation/filesystems/Locking')
-rw-r--r--Documentation/filesystems/Locking270
1 files changed, 139 insertions, 131 deletions
diff --git a/Documentation/filesystems/Locking b/Documentation/filesystems/Locking
index 2db4283efa8d..57d827d6071d 100644
--- a/Documentation/filesystems/Locking
+++ b/Documentation/filesystems/Locking
@@ -9,24 +9,30 @@ be able to use diff(1).
9 9
10--------------------------- dentry_operations -------------------------- 10--------------------------- dentry_operations --------------------------
11prototypes: 11prototypes:
12 int (*d_revalidate)(struct dentry *, int); 12 int (*d_revalidate)(struct dentry *, struct nameidata *);
13 int (*d_hash) (struct dentry *, struct qstr *); 13 int (*d_hash)(const struct dentry *, const struct inode *,
14 int (*d_compare) (struct dentry *, struct qstr *, struct qstr *); 14 struct qstr *);
15 int (*d_compare)(const struct dentry *, const struct inode *,
16 const struct dentry *, const struct inode *,
17 unsigned int, const char *, const struct qstr *);
15 int (*d_delete)(struct dentry *); 18 int (*d_delete)(struct dentry *);
16 void (*d_release)(struct dentry *); 19 void (*d_release)(struct dentry *);
17 void (*d_iput)(struct dentry *, struct inode *); 20 void (*d_iput)(struct dentry *, struct inode *);
18 char *(*d_dname)((struct dentry *dentry, char *buffer, int buflen); 21 char *(*d_dname)((struct dentry *dentry, char *buffer, int buflen);
22 struct vfsmount *(*d_automount)(struct path *path);
23 int (*d_manage)(struct dentry *, bool);
19 24
20locking rules: 25locking rules:
21 none have BKL 26 rename_lock ->d_lock may block rcu-walk
22 dcache_lock rename_lock ->d_lock may block 27d_revalidate: no no yes (ref-walk) maybe
23d_revalidate: no no no yes 28d_hash no no no maybe
24d_hash no no no yes 29d_compare: yes no no maybe
25d_compare: no yes no no 30d_delete: no yes no no
26d_delete: yes no yes no 31d_release: no no yes no
27d_release: no no no yes 32d_iput: no no yes no
28d_iput: no no no yes
29d_dname: no no no no 33d_dname: no no no no
34d_automount: no no yes no
35d_manage: no no yes (ref-walk) maybe
30 36
31--------------------------- inode_operations --------------------------- 37--------------------------- inode_operations ---------------------------
32prototypes: 38prototypes:
@@ -42,18 +48,22 @@ ata *);
42 int (*rename) (struct inode *, struct dentry *, 48 int (*rename) (struct inode *, struct dentry *,
43 struct inode *, struct dentry *); 49 struct inode *, struct dentry *);
44 int (*readlink) (struct dentry *, char __user *,int); 50 int (*readlink) (struct dentry *, char __user *,int);
45 int (*follow_link) (struct dentry *, struct nameidata *); 51 void * (*follow_link) (struct dentry *, struct nameidata *);
52 void (*put_link) (struct dentry *, struct nameidata *, void *);
46 void (*truncate) (struct inode *); 53 void (*truncate) (struct inode *);
47 int (*permission) (struct inode *, int, struct nameidata *); 54 int (*permission) (struct inode *, int, unsigned int);
55 int (*check_acl)(struct inode *, int, unsigned int);
48 int (*setattr) (struct dentry *, struct iattr *); 56 int (*setattr) (struct dentry *, struct iattr *);
49 int (*getattr) (struct vfsmount *, struct dentry *, struct kstat *); 57 int (*getattr) (struct vfsmount *, struct dentry *, struct kstat *);
50 int (*setxattr) (struct dentry *, const char *,const void *,size_t,int); 58 int (*setxattr) (struct dentry *, const char *,const void *,size_t,int);
51 ssize_t (*getxattr) (struct dentry *, const char *, void *, size_t); 59 ssize_t (*getxattr) (struct dentry *, const char *, void *, size_t);
52 ssize_t (*listxattr) (struct dentry *, char *, size_t); 60 ssize_t (*listxattr) (struct dentry *, char *, size_t);
53 int (*removexattr) (struct dentry *, const char *); 61 int (*removexattr) (struct dentry *, const char *);
62 void (*truncate_range)(struct inode *, loff_t, loff_t);
63 int (*fiemap)(struct inode *, struct fiemap_extent_info *, u64 start, u64 len);
54 64
55locking rules: 65locking rules:
56 all may block, none have BKL 66 all may block
57 i_mutex(inode) 67 i_mutex(inode)
58lookup: yes 68lookup: yes
59create: yes 69create: yes
@@ -66,19 +76,23 @@ rmdir: yes (both) (see below)
66rename: yes (all) (see below) 76rename: yes (all) (see below)
67readlink: no 77readlink: no
68follow_link: no 78follow_link: no
79put_link: no
69truncate: yes (see below) 80truncate: yes (see below)
70setattr: yes 81setattr: yes
71permission: no 82permission: no (may not block if called in rcu-walk mode)
83check_acl: no
72getattr: no 84getattr: no
73setxattr: yes 85setxattr: yes
74getxattr: no 86getxattr: no
75listxattr: no 87listxattr: no
76removexattr: yes 88removexattr: yes
89truncate_range: yes
90fiemap: no
77 Additionally, ->rmdir(), ->unlink() and ->rename() have ->i_mutex on 91 Additionally, ->rmdir(), ->unlink() and ->rename() have ->i_mutex on
78victim. 92victim.
79 cross-directory ->rename() has (per-superblock) ->s_vfs_rename_sem. 93 cross-directory ->rename() has (per-superblock) ->s_vfs_rename_sem.
80 ->truncate() is never called directly - it's a callback, not a 94 ->truncate() is never called directly - it's a callback, not a
81method. It's called by vmtruncate() - library function normally used by 95method. It's called by vmtruncate() - deprecated library function used by
82->setattr(). Locking information above applies to that call (i.e. is 96->setattr(). Locking information above applies to that call (i.e. is
83inherited from ->setattr() - vmtruncate() is used when ATTR_SIZE had been 97inherited from ->setattr() - vmtruncate() is used when ATTR_SIZE had been
84passed). 98passed).
@@ -90,8 +104,8 @@ of the locking scheme for directory operations.
90prototypes: 104prototypes:
91 struct inode *(*alloc_inode)(struct super_block *sb); 105 struct inode *(*alloc_inode)(struct super_block *sb);
92 void (*destroy_inode)(struct inode *); 106 void (*destroy_inode)(struct inode *);
93 void (*dirty_inode) (struct inode *); 107 void (*dirty_inode) (struct inode *, int flags);
94 int (*write_inode) (struct inode *, int); 108 int (*write_inode) (struct inode *, struct writeback_control *wbc);
95 int (*drop_inode) (struct inode *); 109 int (*drop_inode) (struct inode *);
96 void (*evict_inode) (struct inode *); 110 void (*evict_inode) (struct inode *);
97 void (*put_super) (struct super_block *); 111 void (*put_super) (struct super_block *);
@@ -105,16 +119,16 @@ prototypes:
105 int (*show_options)(struct seq_file *, struct vfsmount *); 119 int (*show_options)(struct seq_file *, struct vfsmount *);
106 ssize_t (*quota_read)(struct super_block *, int, char *, size_t, loff_t); 120 ssize_t (*quota_read)(struct super_block *, int, char *, size_t, loff_t);
107 ssize_t (*quota_write)(struct super_block *, int, const char *, size_t, loff_t); 121 ssize_t (*quota_write)(struct super_block *, int, const char *, size_t, loff_t);
122 int (*bdev_try_to_free_page)(struct super_block*, struct page*, gfp_t);
108 123
109locking rules: 124locking rules:
110 All may block [not true, see below] 125 All may block [not true, see below]
111 None have BKL
112 s_umount 126 s_umount
113alloc_inode: 127alloc_inode:
114destroy_inode: 128destroy_inode:
115dirty_inode: (must not sleep) 129dirty_inode:
116write_inode: 130write_inode:
117drop_inode: !!!inode_lock!!! 131drop_inode: !!!inode->i_lock!!!
118evict_inode: 132evict_inode:
119put_super: write 133put_super: write
120write_super: read 134write_super: read
@@ -127,6 +141,7 @@ umount_begin: no
127show_options: no (namespace_sem) 141show_options: no (namespace_sem)
128quota_read: no (see below) 142quota_read: no (see below)
129quota_write: no (see below) 143quota_write: no (see below)
144bdev_try_to_free_page: no (see below)
130 145
131->statfs() has s_umount (shared) when called by ustat(2) (native or 146->statfs() has s_umount (shared) when called by ustat(2) (native or
132compat), but that's an accident of bad API; s_umount is used to pin 147compat), but that's an accident of bad API; s_umount is used to pin
@@ -139,19 +154,23 @@ be the only ones operating on the quota file by the quota code (via
139dqio_sem) (unless an admin really wants to screw up something and 154dqio_sem) (unless an admin really wants to screw up something and
140writes to quota files with quotas on). For other details about locking 155writes to quota files with quotas on). For other details about locking
141see also dquot_operations section. 156see also dquot_operations section.
157->bdev_try_to_free_page is called from the ->releasepage handler of
158the block device inode. See there for more details.
142 159
143--------------------------- file_system_type --------------------------- 160--------------------------- file_system_type ---------------------------
144prototypes: 161prototypes:
145 int (*get_sb) (struct file_system_type *, int, 162 int (*get_sb) (struct file_system_type *, int,
146 const char *, void *, struct vfsmount *); 163 const char *, void *, struct vfsmount *);
164 struct dentry *(*mount) (struct file_system_type *, int,
165 const char *, void *);
147 void (*kill_sb) (struct super_block *); 166 void (*kill_sb) (struct super_block *);
148locking rules: 167locking rules:
149 may block BKL 168 may block
150get_sb yes no 169mount yes
151kill_sb yes no 170kill_sb yes
152 171
153->get_sb() returns error or 0 with locked superblock attached to the vfsmount 172->mount() returns ERR_PTR or the root dentry; its superblock should be locked
154(exclusive on ->s_umount). 173on return.
155->kill_sb() takes a write-locked superblock, does all shutdown work on it, 174->kill_sb() takes a write-locked superblock, does all shutdown work on it,
156unlocks and drops the reference. 175unlocks and drops the reference.
157 176
@@ -173,28 +192,38 @@ prototypes:
173 sector_t (*bmap)(struct address_space *, sector_t); 192 sector_t (*bmap)(struct address_space *, sector_t);
174 int (*invalidatepage) (struct page *, unsigned long); 193 int (*invalidatepage) (struct page *, unsigned long);
175 int (*releasepage) (struct page *, int); 194 int (*releasepage) (struct page *, int);
195 void (*freepage)(struct page *);
176 int (*direct_IO)(int, struct kiocb *, const struct iovec *iov, 196 int (*direct_IO)(int, struct kiocb *, const struct iovec *iov,
177 loff_t offset, unsigned long nr_segs); 197 loff_t offset, unsigned long nr_segs);
178 int (*launder_page) (struct page *); 198 int (*get_xip_mem)(struct address_space *, pgoff_t, int, void **,
199 unsigned long *);
200 int (*migratepage)(struct address_space *, struct page *, struct page *);
201 int (*launder_page)(struct page *);
202 int (*is_partially_uptodate)(struct page *, read_descriptor_t *, unsigned long);
203 int (*error_remove_page)(struct address_space *, struct page *);
179 204
180locking rules: 205locking rules:
181 All except set_page_dirty may block 206 All except set_page_dirty and freepage may block
182 207
183 BKL PageLocked(page) i_mutex 208 PageLocked(page) i_mutex
184writepage: no yes, unlocks (see below) 209writepage: yes, unlocks (see below)
185readpage: no yes, unlocks 210readpage: yes, unlocks
186sync_page: no maybe 211sync_page: maybe
187writepages: no 212writepages:
188set_page_dirty no no 213set_page_dirty no
189readpages: no 214readpages:
190write_begin: no locks the page yes 215write_begin: locks the page yes
191write_end: no yes, unlocks yes 216write_end: yes, unlocks yes
192perform_write: no n/a yes 217bmap:
193bmap: no 218invalidatepage: yes
194invalidatepage: no yes 219releasepage: yes
195releasepage: no yes 220freepage: yes
196direct_IO: no 221direct_IO:
197launder_page: no yes 222get_xip_mem: maybe
223migratepage: yes (both)
224launder_page: yes
225is_partially_uptodate: yes
226error_remove_page: yes
198 227
199 ->write_begin(), ->write_end(), ->sync_page() and ->readpage() 228 ->write_begin(), ->write_end(), ->sync_page() and ->readpage()
200may be called from the request handler (/dev/loop). 229may be called from the request handler (/dev/loop).
@@ -274,9 +303,8 @@ under spinlock (it cannot block) and is sometimes called with the page
274not locked. 303not locked.
275 304
276 ->bmap() is currently used by legacy ioctl() (FIBMAP) provided by some 305 ->bmap() is currently used by legacy ioctl() (FIBMAP) provided by some
277filesystems and by the swapper. The latter will eventually go away. All 306filesystems and by the swapper. The latter will eventually go away. Please,
278instances do not actually need the BKL. Please, keep it that way and don't 307keep it that way and don't breed new callers.
279breed new callers.
280 308
281 ->invalidatepage() is called when the filesystem must attempt to drop 309 ->invalidatepage() is called when the filesystem must attempt to drop
282some or all of the buffers from the page when it is being truncated. It 310some or all of the buffers from the page when it is being truncated. It
@@ -288,55 +316,44 @@ buffers from the page in preparation for freeing it. It returns zero to
288indicate that the buffers are (or may be) freeable. If ->releasepage is zero, 316indicate that the buffers are (or may be) freeable. If ->releasepage is zero,
289the kernel assumes that the fs has no private interest in the buffers. 317the kernel assumes that the fs has no private interest in the buffers.
290 318
319 ->freepage() is called when the kernel is done dropping the page
320from the page cache.
321
291 ->launder_page() may be called prior to releasing a page if 322 ->launder_page() may be called prior to releasing a page if
292it is still found to be dirty. It returns zero if the page was successfully 323it is still found to be dirty. It returns zero if the page was successfully
293cleaned, or an error value if not. Note that in order to prevent the page 324cleaned, or an error value if not. Note that in order to prevent the page
294getting mapped back in and redirtied, it needs to be kept locked 325getting mapped back in and redirtied, it needs to be kept locked
295across the entire operation. 326across the entire operation.
296 327
297 Note: currently almost all instances of address_space methods are
298using BKL for internal serialization and that's one of the worst sources
299of contention. Normally they are calling library functions (in fs/buffer.c)
300and pass foo_get_block() as a callback (on local block-based filesystems,
301indeed). BKL is not needed for library stuff and is usually taken by
302foo_get_block(). It's an overkill, since block bitmaps can be protected by
303internal fs locking and real critical areas are much smaller than the areas
304filesystems protect now.
305
306----------------------- file_lock_operations ------------------------------ 328----------------------- file_lock_operations ------------------------------
307prototypes: 329prototypes:
308 void (*fl_insert)(struct file_lock *); /* lock insertion callback */
309 void (*fl_remove)(struct file_lock *); /* lock removal callback */
310 void (*fl_copy_lock)(struct file_lock *, struct file_lock *); 330 void (*fl_copy_lock)(struct file_lock *, struct file_lock *);
311 void (*fl_release_private)(struct file_lock *); 331 void (*fl_release_private)(struct file_lock *);
312 332
313 333
314locking rules: 334locking rules:
315 BKL may block 335 file_lock_lock may block
316fl_insert: yes no 336fl_copy_lock: yes no
317fl_remove: yes no 337fl_release_private: maybe no
318fl_copy_lock: yes no
319fl_release_private: yes yes
320 338
321----------------------- lock_manager_operations --------------------------- 339----------------------- lock_manager_operations ---------------------------
322prototypes: 340prototypes:
323 int (*fl_compare_owner)(struct file_lock *, struct file_lock *); 341 int (*fl_compare_owner)(struct file_lock *, struct file_lock *);
324 void (*fl_notify)(struct file_lock *); /* unblock callback */ 342 void (*fl_notify)(struct file_lock *); /* unblock callback */
325 void (*fl_copy_lock)(struct file_lock *, struct file_lock *); 343 int (*fl_grant)(struct file_lock *, struct file_lock *, int);
326 void (*fl_release_private)(struct file_lock *); 344 void (*fl_release_private)(struct file_lock *);
327 void (*fl_break)(struct file_lock *); /* break_lease callback */ 345 void (*fl_break)(struct file_lock *); /* break_lease callback */
346 int (*fl_change)(struct file_lock **, int);
328 347
329locking rules: 348locking rules:
330 BKL may block 349 file_lock_lock may block
331fl_compare_owner: yes no 350fl_compare_owner: yes no
332fl_notify: yes no 351fl_notify: yes no
333fl_copy_lock: yes no 352fl_grant: no no
334fl_release_private: yes yes 353fl_release_private: maybe no
335fl_break: yes no 354fl_break: yes no
336 355fl_change yes no
337 Currently only NFSD and NLM provide instances of this class. None of the 356
338them block. If you have out-of-tree instances - please, show up. Locking
339in that area will change.
340--------------------------- buffer_head ----------------------------------- 357--------------------------- buffer_head -----------------------------------
341prototypes: 358prototypes:
342 void (*b_end_io)(struct buffer_head *bh, int uptodate); 359 void (*b_end_io)(struct buffer_head *bh, int uptodate);
@@ -349,21 +366,36 @@ call this method upon the IO completion.
349 366
350--------------------------- block_device_operations ----------------------- 367--------------------------- block_device_operations -----------------------
351prototypes: 368prototypes:
352 int (*open) (struct inode *, struct file *); 369 int (*open) (struct block_device *, fmode_t);
353 int (*release) (struct inode *, struct file *); 370 int (*release) (struct gendisk *, fmode_t);
354 int (*ioctl) (struct inode *, struct file *, unsigned, unsigned long); 371 int (*ioctl) (struct block_device *, fmode_t, unsigned, unsigned long);
372 int (*compat_ioctl) (struct block_device *, fmode_t, unsigned, unsigned long);
373 int (*direct_access) (struct block_device *, sector_t, void **, unsigned long *);
355 int (*media_changed) (struct gendisk *); 374 int (*media_changed) (struct gendisk *);
375 void (*unlock_native_capacity) (struct gendisk *);
356 int (*revalidate_disk) (struct gendisk *); 376 int (*revalidate_disk) (struct gendisk *);
377 int (*getgeo)(struct block_device *, struct hd_geometry *);
378 void (*swap_slot_free_notify) (struct block_device *, unsigned long);
357 379
358locking rules: 380locking rules:
359 BKL bd_sem 381 bd_mutex
360open: yes yes 382open: yes
361release: yes yes 383release: yes
362ioctl: yes no 384ioctl: no
363media_changed: no no 385compat_ioctl: no
364revalidate_disk: no no 386direct_access: no
387media_changed: no
388unlock_native_capacity: no
389revalidate_disk: no
390getgeo: no
391swap_slot_free_notify: no (see below)
392
393media_changed, unlock_native_capacity and revalidate_disk are called only from
394check_disk_change().
395
396swap_slot_free_notify is called with swap_lock and sometimes the page lock
397held.
365 398
366The last two are called only from check_disk_change().
367 399
368--------------------------- file_operations ------------------------------- 400--------------------------- file_operations -------------------------------
369prototypes: 401prototypes:
@@ -395,34 +427,22 @@ prototypes:
395 unsigned long (*get_unmapped_area)(struct file *, unsigned long, 427 unsigned long (*get_unmapped_area)(struct file *, unsigned long,
396 unsigned long, unsigned long, unsigned long); 428 unsigned long, unsigned long, unsigned long);
397 int (*check_flags)(int); 429 int (*check_flags)(int);
430 int (*flock) (struct file *, int, struct file_lock *);
431 ssize_t (*splice_write)(struct pipe_inode_info *, struct file *, loff_t *,
432 size_t, unsigned int);
433 ssize_t (*splice_read)(struct file *, loff_t *, struct pipe_inode_info *,
434 size_t, unsigned int);
435 int (*setlease)(struct file *, long, struct file_lock **);
436 long (*fallocate)(struct file *, int, loff_t, loff_t);
398}; 437};
399 438
400locking rules: 439locking rules:
401 All may block. 440 All may block except for ->setlease.
402 BKL 441 No VFS locks held on entry except for ->fsync and ->setlease.
403llseek: no (see below) 442
404read: no 443->fsync() has i_mutex on inode.
405aio_read: no 444
406write: no 445->setlease has the file_list_lock held and must not sleep.
407aio_write: no
408readdir: no
409poll: no
410unlocked_ioctl: no
411compat_ioctl: no
412mmap: no
413open: no
414flush: no
415release: no
416fsync: no (see below)
417aio_fsync: no
418fasync: no
419lock: yes
420readv: no
421writev: no
422sendfile: no
423sendpage: no
424get_unmapped_area: no
425check_flags: no
426 446
427->llseek() locking has moved from llseek to the individual llseek 447->llseek() locking has moved from llseek to the individual llseek
428implementations. If your fs is not using generic_file_llseek, you 448implementations. If your fs is not using generic_file_llseek, you
@@ -432,17 +452,10 @@ mutex or just to use i_size_read() instead.
432Note: this does not protect the file->f_pos against concurrent modifications 452Note: this does not protect the file->f_pos against concurrent modifications
433since this is something the userspace has to take care about. 453since this is something the userspace has to take care about.
434 454
435Note: ext2_release() was *the* source of contention on fs-intensive 455->fasync() is responsible for maintaining the FASYNC bit in filp->f_flags.
436loads and dropping BKL on ->release() helps to get rid of that (we still 456Most instances call fasync_helper(), which does that maintenance, so it's
437grab BKL for cases when we close a file that had been opened r/w, but that 457not normally something one needs to worry about. Return values > 0 will be
438can and should be done using the internal locking with smaller critical areas). 458mapped to zero in the VFS layer.
439Current worst offender is ext2_get_block()...
440
441->fasync() is called without BKL protection, and is responsible for
442maintaining the FASYNC bit in filp->f_flags. Most instances call
443fasync_helper(), which does that maintenance, so it's not normally
444something one needs to worry about. Return values > 0 will be mapped to
445zero in the VFS layer.
446 459
447->readdir() and ->ioctl() on directories must be changed. Ideally we would 460->readdir() and ->ioctl() on directories must be changed. Ideally we would
448move ->readdir() to inode_operations and use a separate method for directory 461move ->readdir() to inode_operations and use a separate method for directory
@@ -453,8 +466,6 @@ components. And there are other reasons why the current interface is a mess...
453->read on directories probably must go away - we should just enforce -EISDIR 466->read on directories probably must go away - we should just enforce -EISDIR
454in sys_read() and friends. 467in sys_read() and friends.
455 468
456->fsync() has i_mutex on inode.
457
458--------------------------- dquot_operations ------------------------------- 469--------------------------- dquot_operations -------------------------------
459prototypes: 470prototypes:
460 int (*write_dquot) (struct dquot *); 471 int (*write_dquot) (struct dquot *);
@@ -489,12 +500,12 @@ prototypes:
489 int (*access)(struct vm_area_struct *, unsigned long, void*, int, int); 500 int (*access)(struct vm_area_struct *, unsigned long, void*, int, int);
490 501
491locking rules: 502locking rules:
492 BKL mmap_sem PageLocked(page) 503 mmap_sem PageLocked(page)
493open: no yes 504open: yes
494close: no yes 505close: yes
495fault: no yes can return with page locked 506fault: yes can return with page locked
496page_mkwrite: no yes can return with page locked 507page_mkwrite: yes can return with page locked
497access: no yes 508access: yes
498 509
499 ->fault() is called when a previously not present pte is about 510 ->fault() is called when a previously not present pte is about
500to be faulted in. The filesystem must find and return the page associated 511to be faulted in. The filesystem must find and return the page associated
@@ -521,6 +532,3 @@ VM_IO | VM_PFNMAP VMAs.
521 532
522(if you break something or notice that it is broken and do not fix it yourself 533(if you break something or notice that it is broken and do not fix it yourself
523- at least put it here) 534- at least put it here)
524
525ipc/shm.c::shm_delete() - may need BKL.
526->read() and ->write() in many drivers are (probably) missing BKL.