aboutsummaryrefslogtreecommitdiff
path: root/drivers/mtd/lpddr/lpddr_cmds.c
diff options
context:
space:
mode:
authorShachar Raindel <[email protected]>2015-04-14 15:46:29 -0700
committerLinus Torvalds <[email protected]>2015-04-14 16:49:03 -0700
commit28766805275c12c2298883cece3f98505ac764b4 (patch)
tree332f2b844899b5c2f86500bdd837bff047e01eb1 /drivers/mtd/lpddr/lpddr_cmds.c
parent4e047f897771222215ee572e1c0b25e9417376eb (diff)
mm: refactor do_wp_page - rewrite the unlock flow
When do_wp_page is ending, in several cases it needs to unlock the pages and ptls it was accessing. Currently, this logic was "called" by using a goto jump. This makes following the control flow of the function harder. Readability was further hampered by the unlock case containing large amount of logic needed only in one of the 3 cases. Using goto for cleanup is generally allowed. However, moving the trivial unlocking flows to the relevant call sites allow deeper refactoring in the next patch. Signed-off-by: Shachar Raindel <[email protected]> Acked-by: Linus Torvalds <[email protected]> Acked-by: Kirill A. Shutemov <[email protected]> Acked-by: Rik van Riel <[email protected]> Acked-by: Andi Kleen <[email protected]> Acked-by: Haggai Eran <[email protected]> Acked-by: Johannes Weiner <[email protected]> Cc: Mel Gorman <[email protected]> Cc: Matthew Wilcox <[email protected]> Cc: Dave Hansen <[email protected]> Cc: Naoya Horiguchi <[email protected]> Cc: Andrea Arcangeli <[email protected]> Cc: Peter Feiner <[email protected]> Cc: Michel Lespinasse <[email protected]> Reviewed-by: Michal Hocko <[email protected]> Signed-off-by: Andrew Morton <[email protected]> Signed-off-by: Linus Torvalds <[email protected]>
Diffstat (limited to 'drivers/mtd/lpddr/lpddr_cmds.c')
0 files changed, 0 insertions, 0 deletions