Add clock
This commit is contained in:
parent
52d67f54e0
commit
d114e89ca8
5 changed files with 18 additions and 8 deletions
|
@ -62,8 +62,6 @@ grub_uint64_t grub_mmap_get_upper (void);
|
|||
|
||||
extern grub_uint32_t EXPORT_VAR (grub_arch_memsize);
|
||||
extern grub_uint32_t EXPORT_VAR (grub_arch_highmemsize);
|
||||
extern grub_uint32_t EXPORT_VAR (grub_arch_busclock);
|
||||
extern grub_uint32_t EXPORT_VAR (grub_arch_cpuclock);
|
||||
|
||||
#endif
|
||||
|
||||
|
|
|
@ -21,10 +21,13 @@
|
|||
|
||||
#include <grub/symbol.h>
|
||||
|
||||
#define GRUB_TICKS_PER_SECOND 1000
|
||||
#define GRUB_TICKS_PER_SECOND (grub_arch_cpuclock / 2)
|
||||
|
||||
/* Return the real time in ticks. */
|
||||
grub_uint32_t EXPORT_FUNC (grub_get_rtc) (void);
|
||||
grub_uint64_t EXPORT_FUNC (grub_get_rtc) (void);
|
||||
|
||||
extern grub_uint32_t EXPORT_VAR (grub_arch_busclock);
|
||||
extern grub_uint32_t EXPORT_VAR (grub_arch_cpuclock);
|
||||
|
||||
static inline void
|
||||
grub_cpu_idle(void)
|
||||
|
|
|
@ -23,7 +23,7 @@
|
|||
#include <grub/symbol.h>
|
||||
#include <grub/cpu/time.h>
|
||||
|
||||
#ifdef GRUB_MACHINE_EMU
|
||||
#if defined (GRUB_MACHINE_EMU) || defined (GRUB_UTIL)
|
||||
#define GRUB_TICKS_PER_SECOND 100000
|
||||
#else
|
||||
#include <grub/machine/time.h>
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue