From 43fea1be12abf52dc12a61eef6059beed55c2df8 Mon Sep 17 00:00:00 2001 From: Linus Torvalds Date: Mon, 10 Feb 2003 22:58:04 -0800 Subject: Sanitize kernel daemon signal handling and process naming. Add a name argument to daemonize() (va_arg) to avoid all the kernel threads having to duplicate the name setting over and over again. Make daemonize() disable all signals by default, and add a "allow_signal()" function to let daemons say they explicitly want to support a signal. Make flush_signal() take the signal lock, so that callers do not need to. --- drivers/hotplug/cpqphp_ctrl.c | 5 +---- 1 file changed, 1 insertion(+), 4 deletions(-) (limited to 'drivers/hotplug/cpqphp_ctrl.c') diff --git a/drivers/hotplug/cpqphp_ctrl.c b/drivers/hotplug/cpqphp_ctrl.c index deb229539165..b9a8432487f4 100644 --- a/drivers/hotplug/cpqphp_ctrl.c +++ b/drivers/hotplug/cpqphp_ctrl.c @@ -1709,10 +1709,7 @@ static int event_thread(void* data) { struct controller *ctrl; lock_kernel(); - daemonize(); - - // New name - strcpy(current->comm, "phpd_event"); + daemonize("phpd_event"); unlock_kernel(); -- cgit v1.2.3