Subversion Repositories shark

Compare Revisions

Ignore whitespace Rev 493 → Rev 494

/shark/trunk/drivers/linuxc26/include/linux/timer.h
18,6 → 18,9
unsigned long data;
 
struct tvec_t_base_s *base;
 
/* Added by Nino */
int event_timer;
};
 
#define TIMER_MAGIC 0x4b87ad6e
38,12 → 41,13
* init_timer() must be done to a timer prior calling *any* of the
* other timer functions.
*/
static inline void init_timer(struct timer_list * timer)
/*static inline void init_timer(struct timer_list * timer)
{
timer->base = NULL;
timer->magic = TIMER_MAGIC;
spin_lock_init(&timer->lock);
}
}*/
extern void init_timer(struct timer_list * timer);
 
/***
* timer_pending - is a timer pending?
55,10 → 59,11
*
* return value: 1 if the timer is pending, 0 if not.
*/
static inline int timer_pending(const struct timer_list * timer)
/*static inline int timer_pending(const struct timer_list * timer)
{
return timer->base != NULL;
}
}*/
extern int timer_pending(struct timer_list * timer);
 
extern void add_timer_on(struct timer_list *timer, int cpu);
extern int del_timer(struct timer_list * timer);
79,10 → 84,11
* Timers with an ->expired field in the past will be executed in the next
* timer tick.
*/
static inline void add_timer(struct timer_list * timer)
/*static inline void add_timer(struct timer_list * timer)
{
__mod_timer(timer, timer->expires);
}
}*/
extern void add_timer(struct timer_list * timer);
 
#ifdef CONFIG_SMP
extern int del_timer_sync(struct timer_list * timer);
/shark/trunk/drivers/linuxc26/include/linuxcomp.h
1,6 → 1,10
#ifndef __LINUX_COMP__
#define __LINUX_COMP__
 
#ifndef __i386__
#define __i386__
#endif
 
#define CONFIG_M386
 
#define va_list void*
32,4 → 36,27
void shark_internal_sem_wait(void *sem);
void shark_internal_sem_post(void *sem);
 
 
#define CONFIG_GAMEPORT
 
#ifndef _STRUCT_TIMESPEC
#define _STRUCT_TIMESPEC
struct timespec {
long tv_sec; /* Seconds */
long tv_nsec; /* Nanoseconds */
};
#endif /* _STRUCT_TIMESPEC */
 
extern TIME sys_gettime(struct timespec *t);
 
#define jiffies26 (sys_gettime(NULL)*HZ/1000000) /* Has to be controlled... */
//#define jiffies26 (TIME)0
 
int shark_event_post(struct timespec *time, void (*handler)(void *p), void *par);
int shark_event_delete(int index);
 
/* Interrupt handler installation and removal */
int shark_handler_set(int no, void (*fast)(int), int pi);
int shark_handler_remove(int no);
 
#endif
/shark/trunk/drivers/linuxc26/makefile
11,7 → 11,8
OBJS_PATH = $(BASE)/drivers/linuxc26
 
OBJS = bus.o linuxcomp.o core.o driver.o vsprintf.o interface.o kobject.o\
shark_linuxc26.o shark_glue.o class.o
shark_linuxc26.o shark_glue.o class.o\
int.o timer.o
 
C_OPT += -I../linuxc26/include