git.droids-corp.org
/
dpdk.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
ethdev: add represented port action to flow API
[dpdk.git]
/
app
/
test
/
test_debug.c
diff --git
a/app/test/test_debug.c
b/app/test/test_debug.c
index
25eab97
..
23b24db
100644
(file)
--- a/
app/test/test_debug.c
+++ b/
app/test/test_debug.c
@@
-4,6
+4,8
@@
#include <stdio.h>
#include <stdint.h>
#include <stdio.h>
#include <stdint.h>
+#include <sys/resource.h>
+#include <sys/time.h>
#include <sys/wait.h>
#include <unistd.h>
#include <sys/wait.h>
#include <unistd.h>
@@
-28,9
+30,14
@@
test_panic(void)
pid = fork();
pid = fork();
- if (pid == 0)
+ if (pid == 0) {
+ struct rlimit rl;
+
+ /* No need to generate a coredump when panicking. */
+ rl.rlim_cur = rl.rlim_max = 0;
+ setrlimit(RLIMIT_CORE, &rl);
rte_panic("Test Debug\n");
rte_panic("Test Debug\n");
-
else if (pid < 0)
{
+
} else if (pid < 0)
{
printf("Fork Failed\n");
return -1;
}
printf("Fork Failed\n");
return -1;
}
@@
-66,13
+73,11
@@
test_exit_val(int exit_val)
}
wait(&status);
printf("Child process status: %d\n", status);
}
wait(&status);
printf("Child process status: %d\n", status);
-#ifndef RTE_EAL_ALWAYS_PANIC_ON_ERROR
if(!WIFEXITED(status) || WEXITSTATUS(status) != (uint8_t)exit_val){
printf("Child process terminated with incorrect status (expected = %d)!\n",
exit_val);
return -1;
}
if(!WIFEXITED(status) || WEXITSTATUS(status) != (uint8_t)exit_val){
printf("Child process terminated with incorrect status (expected = %d)!\n",
exit_val);
return -1;
}
-#endif
return 0;
}
return 0;
}
@@
-113,7
+118,6
@@
static int
test_debug(void)
{
rte_dump_stack();
test_debug(void)
{
rte_dump_stack();
- rte_dump_registers();
if (test_panic() < 0)
return -1;
if (test_exit() < 0)
if (test_panic() < 0)
return -1;
if (test_exit() < 0)