![Shraddha Barke](/assets/img/avatar_default.png)
Since the things defined by digi.h are not used in dgnc_utils.c, remove the header from this file. Signed-off-by: Shraddha Barke <shraddha.6596@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
18 lines
362 B
C
18 lines
362 B
C
#include <linux/tty.h>
|
|
#include <linux/sched.h>
|
|
#include "dgnc_utils.h"
|
|
|
|
/*
|
|
* dgnc_ms_sleep()
|
|
*
|
|
* Put the driver to sleep for x ms's
|
|
*
|
|
* Returns 0 if timed out, !0 (showing signal) if interrupted by a signal.
|
|
*/
|
|
int dgnc_ms_sleep(ulong ms)
|
|
{
|
|
__set_current_state(TASK_INTERRUPTIBLE);
|
|
schedule_timeout((ms * HZ) / 1000);
|
|
return signal_pending(current);
|
|
}
|