qubes-linux-kernel/patches.suse/connector-read-mostly

24 lines
767 B
Plaintext
Raw Normal View History

From: Chris Mason <mason@suse.com>
Subject: Make proc_event_num_listeners __read_mostly
Patch-mainline: not yet
This will lower the fast path costs of the userland connector code.
Acked-by: Jeff Mahoney <jeffm@suse.com>
---
drivers/connector/cn_proc.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
--- a/drivers/connector/cn_proc.c
+++ b/drivers/connector/cn_proc.c
@@ -34,7 +34,7 @@
#define CN_PROC_MSG_SIZE (sizeof(struct cn_msg) + sizeof(struct proc_event))
-static atomic_t proc_event_num_listeners = ATOMIC_INIT(0);
+static atomic_t proc_event_num_listeners __read_mostly = ATOMIC_INIT(0);
static struct cb_id cn_proc_event_id = { CN_IDX_PROC, CN_VAL_PROC };
/* proc_event_counts is used as the sequence number of the netlink message */