From f13e7b320295856f5e391049493245cc4aae022a Mon Sep 17 00:00:00 2001 From: Dirk von Suchodoletz Date: Fri, 27 Mar 2009 22:22:22 +0000 Subject: Not really a fix yet, but "kill_proc" is deprecated in newer kernels ... git-svn-id: http://svn.openslx.org/svn/openslx/contrib/dnbd2/trunk@2766 95ad53e4-c205-0410-b2fa-d234c58c8868 --- kernel/devices.c | 6 +++++- kernel/servers.c | 6 +++++- 2 files changed, 10 insertions(+), 2 deletions(-) diff --git a/kernel/devices.c b/kernel/devices.c index 7c1102b..cf89851 100644 --- a/kernel/devices.c +++ b/kernel/devices.c @@ -76,7 +76,11 @@ void stop_device(dnbd2_device_t *dev) /* Stop request processing. */ del_timer(&dev->requeue_timer); dev->tx_signal = 1; - kill_proc(dev->tx_id, SIGKILL, 1); + #if LINUX_VERSION_CODE >= KERNEL_VERSION(2,6,27) + kill_proc_info(SIGKILL, 1, dev->tx_id); + #else + kill_proc(dev->tx_id, SIGKILL, 1); + #endif wait_for_completion(&dev->tx_stop); /* Empty pending-queue. */ diff --git a/kernel/servers.c b/kernel/servers.c index 52d565b..bd7f386 100644 --- a/kernel/servers.c +++ b/kernel/servers.c @@ -160,7 +160,11 @@ void stop_rx_loop(struct srv_info *srv_info) { if (!srv_info->rx_id) return; - kill_proc(srv_info->rx_id, SIGKILL, 1); + #if LINUX_VERSION_CODE >= KERNEL_VERSION(2,6,27) + kill_proc_info(SIGKILL, 1, srv_info->rx_id); + #else + kill_proc(srv_info->rx_id, SIGKILL, 1); + #endif wait_for_completion(&srv_info->rx_stop); srv_info->rx_id = 0; } -- cgit v1.2.3-55-g7522