diff options
Diffstat (limited to 'net/tipc/handler.c')
-rw-r--r-- | net/tipc/handler.c | 16 |
1 files changed, 7 insertions, 9 deletions
diff --git a/net/tipc/handler.c b/net/tipc/handler.c index eb80778d6d9c..b36f0fcd9bdf 100644 --- a/net/tipc/handler.c +++ b/net/tipc/handler.c @@ -1,6 +1,6 @@ /* * net/tipc/handler.c: TIPC signal handling - * + * * Copyright (c) 2000-2006, Ericsson AB * Copyright (c) 2005, Wind River Systems * All rights reserved. @@ -45,7 +45,7 @@ struct queue_item { static struct kmem_cache *tipc_queue_item_cache; static struct list_head signal_queue_head; static DEFINE_SPINLOCK(qitem_lock); -static int handler_enabled = 0; +static int handler_enabled __read_mostly; static void process_signal_queue(unsigned long dummy); @@ -57,14 +57,14 @@ unsigned int tipc_k_signal(Handler routine, unsigned long argument) struct queue_item *item; if (!handler_enabled) { - err("Signal request ignored by handler\n"); + pr_err("Signal request ignored by handler\n"); return -ENOPROTOOPT; } spin_lock_bh(&qitem_lock); item = kmem_cache_alloc(tipc_queue_item_cache, GFP_ATOMIC); if (!item) { - err("Signal queue out of memory\n"); + pr_err("Signal queue out of memory\n"); spin_unlock_bh(&qitem_lock); return -ENOMEM; } @@ -95,9 +95,9 @@ static void process_signal_queue(unsigned long dummy) int tipc_handler_start(void) { - tipc_queue_item_cache = + tipc_queue_item_cache = kmem_cache_create("tipc_queue_items", sizeof(struct queue_item), - 0, SLAB_HWCACHE_ALIGN, NULL, NULL); + 0, SLAB_HWCACHE_ALIGN, NULL); if (!tipc_queue_item_cache) return -ENOMEM; @@ -110,13 +110,12 @@ int tipc_handler_start(void) void tipc_handler_stop(void) { struct list_head *l, *n; - struct queue_item *item; + struct queue_item *item; if (!handler_enabled) return; handler_enabled = 0; - tasklet_disable(&tipc_tasklet); tasklet_kill(&tipc_tasklet); spin_lock_bh(&qitem_lock); @@ -129,4 +128,3 @@ void tipc_handler_stop(void) kmem_cache_destroy(tipc_queue_item_cache); } - |