From: Frank Mori Hess Date: Thu, 17 Feb 2005 22:42:09 +0000 (+0000) Subject: patch from Emmanuel PACAUD : X-Git-Tag: r0_7_70~51 X-Git-Url: http://git.tremily.us/?a=commitdiff_plain;h=4242d79428a067659d09f9aa4a4cbe1d7423b623;p=comedi.git patch from Emmanuel PACAUD : Here's a trivial patch that closes comedi device file when detaching comedi_rt_timer driver. --- diff --git a/comedi/drivers/comedi_rt_timer.c b/comedi/drivers/comedi_rt_timer.c index 25eae43a..cdd75b1c 100644 --- a/comedi/drivers/comedi_rt_timer.c +++ b/comedi/drivers/comedi_rt_timer.c @@ -700,10 +700,11 @@ static int timer_detach(comedi_device *dev) rt_task_delete(devpriv->scan_task); kfree(devpriv->scan_task); } - if( devpriv->timer_running ) + if(devpriv->timer_running) stop_rt_timer(); + if(devpriv->device) + comedi_close(devpriv->device); } - return 0; }