]> Git Repo - linux.git/commit - mm/mmap.c
mm/mmap.c: rb_parent is not necessary in __vma_link_list()
authorWei Yang <[email protected]>
Sun, 1 Dec 2019 01:50:53 +0000 (17:50 -0800)
committerLinus Torvalds <[email protected]>
Sun, 1 Dec 2019 14:29:19 +0000 (06:29 -0800)
commitaba6dfb75fe15650991442efd137c32fbf2e2b85
tree413724e68ad7e10d88f9cc738d220eb241d605e7
parent1b9fc5b24fa2e7c0e67778cda77ac231fb4bcac7
mm/mmap.c: rb_parent is not necessary in __vma_link_list()

Now we use rb_parent to get next, while this is not necessary.

When prev is NULL, this means vma should be the first element in the list.
Then next should be current first one (mm->mmap), no matter whether we
have parent or not.

After removing it, the code shows the beauty of symmetry.

Link: http://lkml.kernel.org/r/[email protected]
Signed-off-by: Wei Yang <[email protected]>
Acked-by: Andrew Morton <[email protected]>
Cc: Mel Gorman <[email protected]>
Cc: Vlastimil Babka <[email protected]>
Cc: Matthew Wilcox <[email protected]>
Signed-off-by: Andrew Morton <[email protected]>
Signed-off-by: Linus Torvalds <[email protected]>
mm/internal.h
mm/mmap.c
mm/nommu.c
mm/util.c
This page took 0.044165 seconds and 4 git commands to generate.