diff options
| author | 192.168.1.134 <[email protected]> | 2021-12-09 19:18:24 +0800 |
|---|---|---|
| committer | 192.168.1.134 <[email protected]> | 2021-12-09 19:18:24 +0800 |
| commit | 6378f95f00fd51410d2715da55d728d4a40494de (patch) | |
| tree | bb46a565875d538189e1c1dfc9b1cfddf6862a92 /components/drivers/include | |
| parent | d6b05287bbeaf9369546009e5af445f350b97fe9 (diff) | |
| parent | 462f093cbd7531098de3b7aadb5f8d5f1b99b4a9 (diff) | |
Merge branch 'master' of https://github.com/RT-Thread/rt-thread
Diffstat (limited to 'components/drivers/include')
| -rw-r--r-- | components/drivers/include/drivers/alarm.h | 3 | ||||
| -rw-r--r-- | components/drivers/include/drivers/cputime.h | 4 |
2 files changed, 4 insertions, 3 deletions
diff --git a/components/drivers/include/drivers/alarm.h b/components/drivers/include/drivers/alarm.h index 11637df949..56822b72e1 100644 --- a/components/drivers/include/drivers/alarm.h +++ b/components/drivers/include/drivers/alarm.h @@ -13,7 +13,8 @@ #ifndef __ALARM_H__ #define __ALARM_H__ -#include <time.h> +#include <sys/time.h> +#include <rtdef.h> #define RT_ALARM_TM_NOW -1 /* set the alarm tm_day,tm_mon,tm_sec,etc. to now.we also call it "don't care" value */ diff --git a/components/drivers/include/drivers/cputime.h b/components/drivers/include/drivers/cputime.h index 26a1e40f8e..ec98f3152e 100644 --- a/components/drivers/include/drivers/cputime.h +++ b/components/drivers/include/drivers/cputime.h @@ -16,11 +16,11 @@ struct rt_clock_cputime_ops { float (*cputime_getres) (void); - uint32_t (*cputime_gettime)(void); + uint64_t (*cputime_gettime)(void); }; float clock_cpu_getres(void); -uint32_t clock_cpu_gettime(void); +uint64_t clock_cpu_gettime(void); uint32_t clock_cpu_microsecond(uint32_t cpu_tick); uint32_t clock_cpu_millisecond(uint32_t cpu_tick); |
