diff options
| -rw-r--r-- | arch/mips/kernel/binfmt_elfn32.c | 11 | ||||
| -rw-r--r-- | arch/mips/kernel/binfmt_elfo32.c | 11 |
2 files changed, 22 insertions, 0 deletions
diff --git a/arch/mips/kernel/binfmt_elfn32.c b/arch/mips/kernel/binfmt_elfn32.c index e06f777e9c49..1188e00bb120 100644 --- a/arch/mips/kernel/binfmt_elfn32.c +++ b/arch/mips/kernel/binfmt_elfn32.c | |||
| @@ -119,4 +119,15 @@ MODULE_AUTHOR("Ralf Baechle (ralf@linux-mips.org)"); | |||
| 119 | #undef TASK_SIZE | 119 | #undef TASK_SIZE |
| 120 | #define TASK_SIZE TASK_SIZE32 | 120 | #define TASK_SIZE TASK_SIZE32 |
| 121 | 121 | ||
| 122 | #undef cputime_to_timeval | ||
| 123 | #define cputime_to_timeval cputime_to_compat_timeval | ||
| 124 | static __inline__ void | ||
| 125 | cputime_to_compat_timeval(const cputime_t cputime, struct compat_timeval *value) | ||
| 126 | { | ||
| 127 | unsigned long jiffies = cputime_to_jiffies(cputime); | ||
| 128 | |||
| 129 | value->tv_usec = (jiffies % HZ) * (1000000L / HZ); | ||
| 130 | value->tv_sec = jiffies / HZ; | ||
| 131 | } | ||
| 132 | |||
| 122 | #include "../../../fs/binfmt_elf.c" | 133 | #include "../../../fs/binfmt_elf.c" |
diff --git a/arch/mips/kernel/binfmt_elfo32.c b/arch/mips/kernel/binfmt_elfo32.c index 97c5a1668e53..202e581e6096 100644 --- a/arch/mips/kernel/binfmt_elfo32.c +++ b/arch/mips/kernel/binfmt_elfo32.c | |||
| @@ -162,4 +162,15 @@ MODULE_AUTHOR("Ralf Baechle (ralf@linux-mips.org)"); | |||
| 162 | #undef TASK_SIZE | 162 | #undef TASK_SIZE |
| 163 | #define TASK_SIZE TASK_SIZE32 | 163 | #define TASK_SIZE TASK_SIZE32 |
| 164 | 164 | ||
| 165 | #undef cputime_to_timeval | ||
| 166 | #define cputime_to_timeval cputime_to_compat_timeval | ||
| 167 | static __inline__ void | ||
| 168 | cputime_to_compat_timeval(const cputime_t cputime, struct compat_timeval *value) | ||
| 169 | { | ||
| 170 | unsigned long jiffies = cputime_to_jiffies(cputime); | ||
| 171 | |||
| 172 | value->tv_usec = (jiffies % HZ) * (1000000L / HZ); | ||
| 173 | value->tv_sec = jiffies / HZ; | ||
| 174 | } | ||
| 175 | |||
| 165 | #include "../../../fs/binfmt_elf.c" | 176 | #include "../../../fs/binfmt_elf.c" |
