diff options
author | Derek Hower <drh5@cs.wisc.edu> | 2010-01-19 15:48:12 -0600 |
---|---|---|
committer | Derek Hower <drh5@cs.wisc.edu> | 2010-01-19 15:48:12 -0600 |
commit | 279f179babc9e5663156777c533c06edc91bce9a (patch) | |
tree | e6718ee514cc81678491b50562ce8c463c0b20fd /src/kern/linux | |
parent | 5aa104e072eb20f6aca49b169521b0c2da33c844 (diff) | |
parent | 295516a590b6e47c9a881f193027447e500c749c (diff) | |
download | gem5-279f179babc9e5663156777c533c06edc91bce9a.tar.xz |
merge
Diffstat (limited to 'src/kern/linux')
-rw-r--r-- | src/kern/linux/linux.cc | 1 | ||||
-rw-r--r-- | src/kern/linux/linux.hh | 12 | ||||
-rw-r--r-- | src/kern/linux/printk.hh | 2 |
3 files changed, 13 insertions, 2 deletions
diff --git a/src/kern/linux/linux.cc b/src/kern/linux/linux.cc index abe7c0b75..72f1832b8 100644 --- a/src/kern/linux/linux.cc +++ b/src/kern/linux/linux.cc @@ -28,6 +28,7 @@ * Authors: Ali Saidi */ +#include <cstdio> #include <string> #include "cpu/thread_context.hh" diff --git a/src/kern/linux/linux.hh b/src/kern/linux/linux.hh index 7c16228ea..7fe107139 100644 --- a/src/kern/linux/linux.hh +++ b/src/kern/linux/linux.hh @@ -62,6 +62,7 @@ class Linux : public OperatingSystem typedef uint64_t size_t; typedef uint64_t off_t; typedef int64_t time_t; + typedef int64_t clock_t; typedef uint32_t uid_t; typedef uint32_t gid_t; //@} @@ -136,6 +137,17 @@ class Linux : public OperatingSystem int64_t tv_usec; //!< microseconds }; + /// Clock ticks per second, for times(). + static const int M5_SC_CLK_TCK = 100; + + /// For times(). + struct tms { + int64_t tms_utime; //!< user time + int64_t tms_stime; //!< system time + int64_t tms_cutime; //!< user time of children + int64_t tms_cstime; //!< system time of children + }; + // For writev/readv struct tgt_iovec { uint64_t iov_base; // void * diff --git a/src/kern/linux/printk.hh b/src/kern/linux/printk.hh index da9564b7e..5c6ee073d 100644 --- a/src/kern/linux/printk.hh +++ b/src/kern/linux/printk.hh @@ -32,8 +32,6 @@ #ifndef __PRINTK_HH__ #define __PRINTK_HH__ -#include "arch/isa_specific.hh" - #include <sstream> class Arguments; |