mod_timer
- From: milind.dumbare@xxxxxxxxx
- Date: 20 Jan 2006 02:43:37 -0800
Hi all,
I need help for using mod_timer.
------------------------------------------------------------------------------------------------------------------------------------
extern int mod_timer(struct timer_list *timer, unsigned long expires);
struct timer_list {
struct list_head entry;
unsigned long expires;
spinlock_t lock;
unsigned long magic;
void (*function)(unsigned long);
unsigned long data;
struct tvec_t_base_s *base;
};
------------------------------------------------------------------------------------------------------------------------------------
what I have done.....
int my_function(unsigned long data)
{
[snip]
}
struct timer_list timer;
[snip]
timer.function=&my_funciton()
mod_timer(&timer, jiffies + 2 * HZ)
is this code sufficient........
what are other fields in struct timer_list I can use for.........
is parameter passed (expires) in mod_timer and field (expires) in
struct timer_list same
.
- Follow-Ups:
- Re: mod_timer
- From: Mozis
- Re: mod_timer
- Prev by Date: Serial communication, detecting parity bits
- Next by Date: open() hanging...
- Previous by thread: Serial communication, detecting parity bits
- Next by thread: Re: mod_timer
- Index(es):
Relevant Pages
|