1 /* SPDX-License-Identifier: BSD-3-Clause
2 * Copyright(c) 2019 Intel Corporation
8 rte_stack_std_init(struct rte_stack *s)
10 rte_spinlock_init(&s->stack_std.lock);
14 rte_stack_std_get_memsize(unsigned int count)
16 ssize_t sz = sizeof(struct rte_stack);
18 sz += RTE_CACHE_LINE_ROUNDUP(count * sizeof(void *));
20 /* Add padding to avoid false sharing conflicts caused by
21 * next-line hardware prefetchers.
23 sz += 2 * RTE_CACHE_LINE_SIZE;