summaryrefslogtreecommitdiffstats
path: root/include/linux/srcutiny.h
diff options
context:
space:
mode:
authorPaul E. McKenney2017-04-21 22:33:20 +0200
committerPaul E. McKenney2017-06-08 17:25:31 +0200
commit3ddf20c953520203c42dbed1f091ed52080e1cd2 (patch)
treed2525db5a55d7fe86dd0d22d1c4326548ccd970e /include/linux/srcutiny.h
parentrcutorture: Reduce CPUs dedicated to testing Classic SRCU (diff)
downloadkernel-qcow2-linux-3ddf20c953520203c42dbed1f091ed52080e1cd2.tar.gz
kernel-qcow2-linux-3ddf20c953520203c42dbed1f091ed52080e1cd2.tar.xz
kernel-qcow2-linux-3ddf20c953520203c42dbed1f091ed52080e1cd2.zip
srcu: Shrink Tiny SRCU a bit more
This commit rearranges Tiny SRCU's srcu_struct structure, substitutes u8 for bool, and shrinks counters down to short. Signed-off-by: Paul E. McKenney <paulmck@linux.vnet.ibm.com>
Diffstat (limited to 'include/linux/srcutiny.h')
-rw-r--r--include/linux/srcutiny.h8
1 files changed, 4 insertions, 4 deletions
diff --git a/include/linux/srcutiny.h b/include/linux/srcutiny.h
index 42311ee0334f..b8859179b001 100644
--- a/include/linux/srcutiny.h
+++ b/include/linux/srcutiny.h
@@ -27,15 +27,15 @@
#include <linux/swait.h>
struct srcu_struct {
- int srcu_lock_nesting[2]; /* srcu_read_lock() nesting depth. */
+ short srcu_lock_nesting[2]; /* srcu_read_lock() nesting depth. */
+ short srcu_idx; /* Current reader array element. */
+ u8 srcu_gp_running; /* GP workqueue running? */
+ u8 srcu_gp_waiting; /* GP waiting for readers? */
struct swait_queue_head srcu_wq;
/* Last srcu_read_unlock() wakes GP. */
unsigned long srcu_gp_seq; /* GP seq # for callback tagging. */
struct rcu_segcblist srcu_cblist;
/* Pending SRCU callbacks. */
- int srcu_idx; /* Current reader array element. */
- bool srcu_gp_running; /* GP workqueue running? */
- bool srcu_gp_waiting; /* GP waiting for readers? */
struct work_struct srcu_work; /* For driving grace periods. */
#ifdef CONFIG_DEBUG_LOCK_ALLOC
struct lockdep_map dep_map;