1/* 2 * Copyright (C) 2011, 2012 Internet Systems Consortium, Inc. ("ISC") 3 * 4 * Permission to use, copy, modify, and/or distribute this software for any 5 * purpose with or without fee is hereby granted, provided that the above 6 * copyright notice and this permission notice appear in all copies. 7 * 8 * THE SOFTWARE IS PROVIDED "AS IS" AND ISC DISCLAIMS ALL WARRANTIES WITH 9 * REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY 10 * AND FITNESS. IN NO EVENT SHALL ISC BE LIABLE FOR ANY SPECIAL, DIRECT, 11 * INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM 12 * LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE 13 * OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR 14 * PERFORMANCE OF THIS SOFTWARE. 15 */ 16 17/* $Id$ */ 18 19/*! \file */ 20 21#include <config.h> 22 23#include <isc/buffer.h> 24#include <isc/entropy.h> 25#include <isc/hash.h> 26#include <isc/log.h> 27#include <isc/mem.h> 28#include <isc/print.h> 29#include <isc/result.h> 30#include <isc/string.h> 31#include <isc/task.h> 32#include <isc/timer.h> 33#include <isc/util.h> 34 35#define CHECK(r) \ 36 do { \ 37 result = (r); \ 38 if (result != ISC_R_SUCCESS) \ 39 goto cleanup; \ 40 } while (0) 41 42extern isc_mem_t *mctx; 43extern isc_entropy_t *ectx; 44extern isc_log_t *lctx; 45extern isc_taskmgr_t *taskmgr; 46isc_timermgr_t *timermgr; 47isc_socketmgr_t *socketmgr; 48extern int ncpus; 49 50isc_result_t 51isc_test_begin(FILE *logfile, isc_boolean_t start_managers); 52 53void 54isc_test_end(void); 55 56void 57isc_test_nap(isc_uint32_t usec); 58