Add function prototypes
authoraleph <aleph@38d2e660-2303-0410-9eaa-f027e97ec537>
Mon, 7 Jun 2004 15:58:00 +0000 (15:58 +0000)
committeraleph <aleph@38d2e660-2303-0410-9eaa-f027e97ec537>
Mon, 7 Jun 2004 15:58:00 +0000 (15:58 +0000)
git-svn-id: https://src.develer.com/svnoss/bertos/trunk@36 38d2e660-2303-0410-9eaa-f027e97ec537

drv/timer.h
kern/event.h

index 3484c5a6386ffcd8148edb28c80dd72c290c33b4..f7fb4bff6edb74d7cc1af4c6c066d0f4f8d9319e 100755 (executable)
@@ -15,6 +15,9 @@
 
 /*
  * $Log$
+ * Revision 1.5  2004/06/07 15:57:12  aleph
+ * Add function prototypes
+ *
  * Revision 1.4  2004/06/06 18:25:44  bernie
  * Rename event macros to look like regular functions.
  *
@@ -47,6 +50,7 @@ typedef struct Timer
        Event  expire;    /*!< Event to execute when the timer expires */
 } Timer;
 
+/* Function protos */
 extern void timer_init(void);
 extern Timer *timer_new(void);
 extern void timer_delete(Timer *timer);
@@ -56,14 +60,19 @@ extern void timer_delay(time_t time);
 extern void timer_udelay(utime_t utime);
 INLINE time_t timer_gettick(void);
 INLINE time_t timer_gettick_irq(void);
+INLINE void timer_set_event_softint(Timer* timer, Hook func, void* user_data);
+INLINE void timer_set_delay(Timer* timer, time_t delay);
+
+#if defined(CONFIG_KERN_SIGNALS) && CONFIG_KERN_SIGNALS
 
-#ifdef CONFIG_KERN_SIGNALS
 /*! Set the timer so that it sends a signal when it expires */
+INLINE void timer_set_event_signal(Timer* timer, struct Process* proc, sigset_t sigs);
 INLINE void timer_set_event_signal(Timer* timer, struct Process* proc, sigset_t sigs)
 {
        event_initSignal(&timer->expire, proc, sigs);
 }
-#endif
+
+#endif /* CONFIG_KERN_SIGNALS */
 
 /*! Set the timer so that it calls an user hook when it expires */
 INLINE void timer_set_event_softint(Timer* timer, Hook func, void* user_data)
index cfb81ad8a4ef7067cb1fde066414d12bbb2821ff..e1196c9eca7a9227f4d00a479c54d64806dde679 100755 (executable)
@@ -18,6 +18,9 @@
 
 /*
  * $Log$
+ * Revision 1.4  2004/06/07 15:58:00  aleph
+ * Add function prototypes
+ *
  * Revision 1.3  2004/06/06 18:25:44  bernie
  * Rename event macros to look like regular functions.
  *
@@ -84,6 +87,7 @@ typedef struct Event
        ((e)->action = EVENT_IGNORE)
 
 /*! Same as event_initNone(), but returns the initialized event */
+INLINE Event event_createNone(void);
 INLINE Event event_createNone(void)
 {
        Event e;
@@ -96,6 +100,7 @@ INLINE Event event_createNone(void)
        ((e)->action = EVENT_SOFTINT,(e)->Ev.Int.func = (f), (e)->Ev.Int.user_data = (u))
 
 /*! Same as event_initSoftInt(), but returns the initialized event */
+INLINE Event event_createSoftInt(Hook func, void* user_data);
 INLINE Event event_createSoftInt(Hook func, void* user_data)
 {
        Event e;
@@ -113,6 +118,7 @@ INLINE Event event_createSoftInt(Hook func, void* user_data)
        ((e)->action = EVENT_SIGNAL,(e)->Ev.Sig.sig_proc = (p), (e)->Ev.Sig.sig_bit = (s))
 
 /*! Same as event_initSignal(), but returns the initialized event */
+INLINE Event event_createSignal(struct Process* proc, sig_t bit);
 INLINE Event event_createSignal(struct Process* proc, sig_t bit)
 {
        Event e;