| 177 | } |
| 178 | |
| 179 | static int |
| 180 | test_stack_name_reuse(uint32_t flags) |
| 181 | { |
| 182 | struct rte_stack *s[2]; |
| 183 | |
| 184 | s[0] = rte_stack_create("test", STACK_SIZE, rte_socket_id(), flags); |
| 185 | if (s[0] == NULL) { |
| 186 | printf("[%s():%u] Failed to create a stack\n", |
| 187 | __func__, __LINE__); |
| 188 | return -1; |
| 189 | } |
| 190 | |
| 191 | s[1] = rte_stack_create("test", STACK_SIZE, rte_socket_id(), flags); |
| 192 | if (s[1] != NULL) { |
| 193 | printf("[%s():%u] Failed to detect re-used name\n", |
| 194 | __func__, __LINE__); |
| 195 | return -1; |
| 196 | } |
| 197 | |
| 198 | rte_stack_free(s[0]); |
| 199 | |
| 200 | return 0; |
| 201 | } |
| 202 | |
| 203 | static int |
| 204 | test_stack_name_length(uint32_t flags) |
no test coverage detected