#ifndef INLINE_TIMER_H
#define INLINE_TIMER_H

/*
    *** Automatically generated from '/home/aros/ABIv0/Build/20110803/AROS/rom/timer/timer.conf'. Edits will be lost. ***
    Copyright © 1995-2011, The AROS Development Team. All rights reserved.
*/

/*
    Desc: Inline function for timer
*/

#include <aros/libcall.h>
#include <exec/types.h>
#include <aros/preprocessor/variadic/cast2iptr.hpp>


static inline void __inline_Timer_AddTime(struct timeval * __arg1, struct timeval * __arg2, APTR __TimerBase)
{
    AROS_LC2NR(void, AddTime,
        AROS_LCA(struct timeval *,(__arg1),A0),
        AROS_LCA(struct timeval *,(__arg2),A1),
        struct Device *, (__TimerBase), 7, Timer    );
}

#define AddTime(arg1, arg2) \
    __inline_Timer_AddTime((arg1), (arg2), (APTR)TimerBase)

static inline void __inline_Timer_SubTime(struct timeval * __arg1, struct timeval * __arg2, APTR __TimerBase)
{
    AROS_LC2NR(void, SubTime,
        AROS_LCA(struct timeval *,(__arg1),A0),
        AROS_LCA(struct timeval *,(__arg2),A1),
        struct Device *, (__TimerBase), 8, Timer    );
}

#define SubTime(arg1, arg2) \
    __inline_Timer_SubTime((arg1), (arg2), (APTR)TimerBase)

static inline LONG __inline_Timer_CmpTime(struct timeval * __arg1, struct timeval * __arg2, APTR __TimerBase)
{
    return AROS_LC2(LONG, CmpTime,
        AROS_LCA(struct timeval *,(__arg1),A0),
        AROS_LCA(struct timeval *,(__arg2),A1),
        struct Device *, (__TimerBase), 9, Timer    );
}

#define CmpTime(arg1, arg2) \
    __inline_Timer_CmpTime((arg1), (arg2), (APTR)TimerBase)

static inline ULONG __inline_Timer_ReadEClock(struct EClockVal * __arg1, APTR __TimerBase)
{
    return AROS_LC1(ULONG, ReadEClock,
        AROS_LCA(struct EClockVal *,(__arg1),A0),
        struct Device *, (__TimerBase), 10, Timer    );
}

#define ReadEClock(arg1) \
    __inline_Timer_ReadEClock((arg1), (APTR)TimerBase)

static inline void __inline_Timer_GetSysTime(struct timeval * __arg1, APTR __TimerBase)
{
    AROS_LC1NR(void, GetSysTime,
        AROS_LCA(struct timeval *,(__arg1),A0),
        struct Device *, (__TimerBase), 11, Timer    );
}

#define GetSysTime(arg1) \
    __inline_Timer_GetSysTime((arg1), (APTR)TimerBase)

#endif /* INLINE_TIMER_H*/
