/*-
* BSD LICENSE
*
- * Copyright(c) 2010-2013 Intel Corporation. All rights reserved.
+ * Copyright(c) 2010-2014 Intel Corporation. All rights reserved.
* All rights reserved.
*
* Redistribution and use in source and binary forms, with or without
#include <stdint.h>
#include <unistd.h>
-#include <cmdline_parse.h>
-
#include <rte_common.h>
#include <rte_cycles.h>
#include <rte_interrupts.h>
#include "test.h"
-#define TEST_INTERRUPT_CHECK_INTERVAL 1000 /* ms */
+#define TEST_INTERRUPT_CHECK_INTERVAL 100 /* ms */
/* predefined interrupt handle types */
enum test_interrupt_handle_type {
}
#else
-/* to be implemented for baremetal later */
+/* to be implemented for bsd later */
static inline int
test_interrupt_handle_sanity_check(struct rte_intr_handle *intr_handle)
{
if (test_interrupt_trigger_interrupt() < 0)
return -1;
- /* check flag in 3 seconds */
+ /* check flag */
for (count = 0; flag == 0 && count < 3; count++)
rte_delay_ms(TEST_INTERRUPT_CHECK_INTERVAL);
/**
* Main function of testing interrupt.
*/
-int
+static int
test_interrupt(void)
{
int ret = -1;
return ret;
}
+REGISTER_TEST_COMMAND(interrupt_autotest, test_interrupt);