X-Git-Url: https://git.sur5r.net/?a=blobdiff_plain;f=src%2Fhelper%2Ftime_support.c;h=7a9a80010533a173231a70c15896ee3eac727b8a;hb=57be9774bf27c800433c2c6f387656a7d663b8ad;hp=e97993be6a298d6db98b5f6c8634c3d1cb643c01;hpb=2585fc34200938fb3fa55a450ea37f68012aafa7;p=openocd diff --git a/src/helper/time_support.c b/src/helper/time_support.c index e97993be..7a9a8001 100644 --- a/src/helper/time_support.c +++ b/src/helper/time_support.c @@ -2,6 +2,12 @@ * Copyright (C) 2006 by Dominic Rath * * Dominic.Rath@gmx.de * * * + * Copyright (C) 2007,2008 Øyvind Harboe * + * oyvind.harboe@zylin.com * + * * + * Copyright (C) 2008 by Spencer Oliver * + * spen@spen-soft.co.uk * + * * * This program is free software; you can redistribute it and/or modify * * it under the terms of the GNU General Public License as published by * * the Free Software Foundation; either version 2 of the License, or * @@ -21,15 +27,9 @@ #include "config.h" #endif -#include "replacements.h" #include "time_support.h" #include "log.h" -#include - -int timeval_subtract(struct timeval *result, struct timeval *x, struct timeval *y); -int timeval_add(struct timeval *result, struct timeval *x, struct timeval *y); -int timeval_add_time(struct timeval *result, int sec, int usec); /* calculate difference between two struct timeval values */ int timeval_subtract(struct timeval *result, struct timeval *x, struct timeval *y) @@ -83,11 +83,9 @@ int timeval_add_time(struct timeval *result, int sec, int usec) return 0; } -int duration_start_measure(duration_t *duration) +void duration_start_measure(duration_t *duration) { gettimeofday(&duration->start, NULL); - - return ERROR_OK; } int duration_stop_measure(duration_t *duration, char **text) @@ -110,9 +108,6 @@ int duration_stop_measure(duration_t *duration, char **text) return ERROR_OK; } - - - long long timeval_ms() { struct timeval now;