Skip to content
Open
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
7 changes: 3 additions & 4 deletions HW-3/P3/satya_module.c
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@ static char *n = "Satya";
static long time = 0; /*in seconds*/
int count = 0;

void myfunc(unsigned long s)
void myfunc(struct timer_list * s)
{
count++;
printk("My name is %s and count is %d\n", n, count);
Expand All @@ -36,9 +36,8 @@ void myfunc(unsigned long s)

static void timer_init(void)
{
init_timer(&mytimer);
mytimer.function = myfunc;
mytimer.data = 0;
timer_setup(&mytimer, myfunc, 0);

if(time == 0)
{
mytimer.expires = (unsigned long)(jiffies + HZ/2);
Expand Down