]> git.baikalelectronics.ru Git - kernel.git/commit
kernel/fork.c: unshare(): use swap() to make code cleaner
authorRan Xiaokai <ran.xiaokai@zte.com.cn>
Tue, 9 Nov 2021 02:35:22 +0000 (18:35 -0800)
committerLinus Torvalds <torvalds@linux-foundation.org>
Tue, 9 Nov 2021 18:02:52 +0000 (10:02 -0800)
commitbd4dabd528b7cb5864663e5c2b9d869f1ddabfe3
tree93b3633ae001b74a97a45ba02c5ca37808bd0a78
parentfbc76e89faa33d2ebbb05e935e6cf95ce36d468b
kernel/fork.c: unshare(): use swap() to make code cleaner

Use swap() instead of reimplementing it.

Link: https://lkml.kernel.org/r/20210909022046.8151-1-ran.xiaokai@zte.com.cn
Signed-off-by: Ran Xiaokai <ran.xiaokai@zte.com.cn>
Cc: Gabriel Krisman Bertazi <krisman@collabora.com>
Cc: Peter Zijlstra <peterz@infradead.org>
Cc: Eric W. Biederman <ebiederm@xmission.com>
Cc: Jens Axboe <axboe@kernel.dk>
Cc: Alexey Gladkov <legion@kernel.org>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
kernel/fork.c