[PATCH 0/4] current vs ptr to current dereferencing

From: Davidlohr Bueso
Date: Tue Jan 03 2017 - 16:43:43 EST


Hi,

This is a re-spin of the earlier rfc[1] wrt deleting the set_task_state()
interfaces. In order for us not taking a hit on arm64, these patches
depend on Mark's fix to get rid of read_sysreg():

http://lists.infradead.org/pipermail/linux-arm-kernel/2017-January/476461.html

First three patches get rid of 'tsk = current' based assignments to
simply use current/get_current macro directly now that we have some
actual numbers -- in which the conversion does improve some performance
numbers, specially the locking bits. This is only around what directly
is touched by patch 4, making it very obvious that we are indeed calling
upon the current task. There are other users left with this pattern that
could be cleaned up later.

Applies against v4.10-rc2.

[1] https://lkml.org/lkml/2016/12/30/230

Thanks.

Davidlohr Bueso (4):
kernel/exit: Compute current directly
drivers/tty: Compute current directly
kernel/locking: Compute current directly
sched: Remove set_task_state()

arch/um/drivers/random.c | 2 +-
drivers/md/dm-bufio.c | 2 +-
drivers/md/dm-crypt.c | 4 ++--
drivers/md/persistent-data/dm-block-manager.c | 4 ++--
.../staging/lustre/lnet/libcfs/linux/linux-debug.c | 2 +-
drivers/tty/tty_ldsem.c | 18 +++++++--------
include/linux/sched.h | 27 +---------------------
kernel/exit.c | 22 +++++++++---------
kernel/locking/mutex.c | 19 ++++++++-------
kernel/locking/rwsem-spinlock.c | 18 ++++++---------
kernel/locking/rwsem-xadd.c | 7 +++---
kernel/locking/semaphore.c | 7 +++---
12 files changed, 49 insertions(+), 83 deletions(-)

--
2.6.6