aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--platform/linux-generic/include/odp/api/plat/time_inlines.h2
-rw-r--r--platform/linux-generic/include/odp_ipsec_internal.h2
-rw-r--r--platform/linux-generic/include/odp_packet_io_internal.h2
-rw-r--r--platform/linux-generic/include/odp_pool_internal.h2
-rw-r--r--platform/linux-generic/include/odp_queue_basic_internal.h2
-rw-r--r--platform/linux-generic/include/odp_queue_scalable_internal.h4
-rw-r--r--platform/linux-generic/include/odp_ring_mpmc_internal.h4
-rw-r--r--platform/linux-generic/include/odp_schedule_scalable.h8
-rw-r--r--platform/linux-generic/odp_buffer.c4
-rw-r--r--platform/linux-generic/odp_hash_crc32.c2
-rw-r--r--platform/linux-generic/odp_ipsec_sad.c2
-rw-r--r--platform/linux-generic/odp_packet.c2
-rw-r--r--platform/linux-generic/odp_pool.c2
-rw-r--r--platform/linux-generic/odp_queue_if.c2
-rw-r--r--platform/linux-generic/odp_schedule_basic.c2
-rw-r--r--platform/linux-generic/odp_timer.c2
-rw-r--r--platform/linux-generic/pktio/dpdk.c2
-rw-r--r--platform/linux-generic/pktio/socket.c4
-rw-r--r--platform/linux-generic/pktio/socket_common.c4
-rw-r--r--platform/linux-generic/pktio/socket_mmap.c6
20 files changed, 30 insertions, 30 deletions
diff --git a/platform/linux-generic/include/odp/api/plat/time_inlines.h b/platform/linux-generic/include/odp/api/plat/time_inlines.h
index 0b05aa4f7..1ca495065 100644
--- a/platform/linux-generic/include/odp/api/plat/time_inlines.h
+++ b/platform/linux-generic/include/odp/api/plat/time_inlines.h
@@ -22,7 +22,7 @@
typedef struct _odp_time_global_t {
/* Storage space for struct timespec. Posix headers are not included
* here to avoid application exposure. */
- uint8_t ODP_ALIGNED(_ODP_TIMESPEC_SIZE) timespec[_ODP_TIMESPEC_SIZE];
+ uint8_t timespec[_ODP_TIMESPEC_SIZE] ODP_ALIGNED(_ODP_TIMESPEC_SIZE);
int use_hw;
uint64_t hw_start;
diff --git a/platform/linux-generic/include/odp_ipsec_internal.h b/platform/linux-generic/include/odp_ipsec_internal.h
index 3d7d40a37..c547c3ab7 100644
--- a/platform/linux-generic/include/odp_ipsec_internal.h
+++ b/platform/linux-generic/include/odp_ipsec_internal.h
@@ -92,7 +92,7 @@ int _odp_ipsec_status_send(odp_queue_t queue,
#define ODP_CONFIG_IPSEC_SAS 8
struct ipsec_sa_s {
- odp_atomic_u32_t ODP_ALIGNED_CACHE state;
+ odp_atomic_u32_t state ODP_ALIGNED_CACHE;
/*
* State that gets updated very frequently. Grouped separately
diff --git a/platform/linux-generic/include/odp_packet_io_internal.h b/platform/linux-generic/include/odp_packet_io_internal.h
index 4700bdb07..4f563de66 100644
--- a/platform/linux-generic/include/odp_packet_io_internal.h
+++ b/platform/linux-generic/include/odp_packet_io_internal.h
@@ -78,7 +78,7 @@ struct pktio_entry {
uint8_t tx_ts : 1;
} enabled;
odp_pktio_t handle; /**< pktio handle */
- unsigned char ODP_ALIGNED_CACHE pkt_priv[PKTIO_PRIVATE_SIZE];
+ unsigned char pkt_priv[PKTIO_PRIVATE_SIZE] ODP_ALIGNED_CACHE;
enum {
/* Not allocated */
PKTIO_STATE_FREE = 0,
diff --git a/platform/linux-generic/include/odp_pool_internal.h b/platform/linux-generic/include/odp_pool_internal.h
index a8947ddd9..007cb7b3f 100644
--- a/platform/linux-generic/include/odp_pool_internal.h
+++ b/platform/linux-generic/include/odp_pool_internal.h
@@ -48,7 +48,7 @@ typedef struct ODP_ALIGNED_CACHE {
typedef void (*pool_destroy_cb_fn)(void *pool);
typedef struct pool_t {
- odp_ticketlock_t ODP_ALIGNED_CACHE lock;
+ odp_ticketlock_t lock ODP_ALIGNED_CACHE;
char name[ODP_POOL_NAME_LEN];
odp_pool_param_t params;
diff --git a/platform/linux-generic/include/odp_queue_basic_internal.h b/platform/linux-generic/include/odp_queue_basic_internal.h
index 06cb34a87..4cfc6770b 100644
--- a/platform/linux-generic/include/odp_queue_basic_internal.h
+++ b/platform/linux-generic/include/odp_queue_basic_internal.h
@@ -35,7 +35,7 @@ extern "C" {
struct queue_entry_s {
/* The first cache line is read only */
- queue_enq_fn_t ODP_ALIGNED_CACHE enqueue;
+ queue_enq_fn_t enqueue ODP_ALIGNED_CACHE;
queue_deq_fn_t dequeue;
queue_enq_multi_fn_t enqueue_multi;
queue_deq_multi_fn_t dequeue_multi;
diff --git a/platform/linux-generic/include/odp_queue_scalable_internal.h b/platform/linux-generic/include/odp_queue_scalable_internal.h
index 3c582076c..8b9eac435 100644
--- a/platform/linux-generic/include/odp_queue_scalable_internal.h
+++ b/platform/linux-generic/include/odp_queue_scalable_internal.h
@@ -34,11 +34,11 @@ extern "C" {
struct queue_entry_s {
sched_elem_t sched_elem;
- odp_ticketlock_t ODP_ALIGNED_CACHE lock;
+ odp_ticketlock_t lock ODP_ALIGNED_CACHE;
odp_atomic_u64_t num_timers;
int status;
- queue_enq_fn_t ODP_ALIGNED_CACHE enqueue;
+ queue_enq_fn_t enqueue ODP_ALIGNED_CACHE;
queue_deq_fn_t dequeue;
queue_enq_multi_fn_t enqueue_multi;
queue_deq_multi_fn_t dequeue_multi;
diff --git a/platform/linux-generic/include/odp_ring_mpmc_internal.h b/platform/linux-generic/include/odp_ring_mpmc_internal.h
index 0a659249a..473e69e90 100644
--- a/platform/linux-generic/include/odp_ring_mpmc_internal.h
+++ b/platform/linux-generic/include/odp_ring_mpmc_internal.h
@@ -34,10 +34,10 @@ extern "C" {
*
*/
typedef struct {
- odp_atomic_u32_t ODP_ALIGNED_CACHE r_head;
+ odp_atomic_u32_t r_head ODP_ALIGNED_CACHE;
odp_atomic_u32_t r_tail;
- odp_atomic_u32_t ODP_ALIGNED_CACHE w_head;
+ odp_atomic_u32_t w_head ODP_ALIGNED_CACHE;
odp_atomic_u32_t w_tail;
} ring_mpmc_t;
diff --git a/platform/linux-generic/include/odp_schedule_scalable.h b/platform/linux-generic/include/odp_schedule_scalable.h
index 88986be5f..591b04471 100644
--- a/platform/linux-generic/include/odp_schedule_scalable.h
+++ b/platform/linux-generic/include/odp_schedule_scalable.h
@@ -99,7 +99,7 @@ typedef bitset_t sched_group_mask_t;
typedef struct {
/* Threads currently associated with the sched group */
- bitset_t ODP_ALIGNED_CACHE thr_actual[ODP_SCHED_PRIO_NUM];
+ bitset_t thr_actual[ODP_SCHED_PRIO_NUM] ODP_ALIGNED_CACHE;
bitset_t thr_wanted;
/* Used to spread queues over schedq's */
uint32_t xcount[ODP_SCHED_PRIO_NUM];
@@ -107,7 +107,7 @@ typedef struct {
uint32_t xfactor;
char name[ODP_SCHED_GROUP_NAME_LEN];
/* ODP_SCHED_PRIO_NUM * xfactor. Must be last. */
- sched_queue_t ODP_ALIGNED_CACHE schedq[1];
+ sched_queue_t schedq[1] ODP_ALIGNED_CACHE;
} sched_group_t;
/* Number of reorder contexts per thread */
@@ -136,9 +136,9 @@ typedef struct ODP_ALIGNED_CACHE {
sched_group_mask_t sg_wanted[ODP_SCHED_PRIO_NUM];
bitset_t priv_rvec_free;
/* Bitset of free entries in rvec[] */
- bitset_t ODP_ALIGNED_CACHE rvec_free;
+ bitset_t rvec_free ODP_ALIGNED_CACHE;
/* Reordering contexts to allocate from */
- reorder_context_t ODP_ALIGNED_CACHE rvec[TS_RVEC_SIZE];
+ reorder_context_t rvec[TS_RVEC_SIZE] ODP_ALIGNED_CACHE;
uint32_t loop_cnt; /*Counter to check pktio ingress queue dead loop */
} sched_scalable_thread_state_t;
diff --git a/platform/linux-generic/odp_buffer.c b/platform/linux-generic/odp_buffer.c
index 4c5e72640..54b025779 100644
--- a/platform/linux-generic/odp_buffer.c
+++ b/platform/linux-generic/odp_buffer.c
@@ -18,8 +18,8 @@
#include <odp/visibility_begin.h>
/* Fill in buffer header field offsets for inline functions */
-const _odp_buffer_inline_offset_t ODP_ALIGNED_CACHE
-_odp_buffer_inline_offset = {
+const _odp_buffer_inline_offset_t
+_odp_buffer_inline_offset ODP_ALIGNED_CACHE = {
.event_type = offsetof(odp_buffer_hdr_t, event_type),
.base_data = offsetof(odp_buffer_hdr_t, base_data)
};
diff --git a/platform/linux-generic/odp_hash_crc32.c b/platform/linux-generic/odp_hash_crc32.c
index 4f741fe47..e1416d630 100644
--- a/platform/linux-generic/odp_hash_crc32.c
+++ b/platform/linux-generic/odp_hash_crc32.c
@@ -10,7 +10,7 @@
#include <odp/api/align.h>
/* Table generated with odp_hash_crc_gen64() */
-static const uint32_t ODP_ALIGNED_CACHE crc32_table[256] = {
+static const uint32_t crc32_table[256] ODP_ALIGNED_CACHE = {
0x00000000, 0x77073096, 0xee0e612c, 0x990951ba,
0x076dc419, 0x706af48f, 0xe963a535, 0x9e6495a3,
0x0edb8832, 0x79dcb8a4, 0xe0d5e91e, 0x97d2d988,
diff --git a/platform/linux-generic/odp_ipsec_sad.c b/platform/linux-generic/odp_ipsec_sad.c
index b22970791..c7ea7bb59 100644
--- a/platform/linux-generic/odp_ipsec_sad.c
+++ b/platform/linux-generic/odp_ipsec_sad.c
@@ -85,7 +85,7 @@ typedef struct ipsec_sa_table_t {
ipsec_thread_local_t per_thread[ODP_THREAD_COUNT_MAX];
struct ODP_ALIGNED_CACHE {
ring_mpmc_t ipv4_id_ring;
- uint32_t ODP_ALIGNED_CACHE ipv4_id_data[IPV4_ID_RING_SIZE];
+ uint32_t ipv4_id_data[IPV4_ID_RING_SIZE] ODP_ALIGNED_CACHE;
} hot;
odp_shm_t shm;
} ipsec_sa_table_t;
diff --git a/platform/linux-generic/odp_packet.c b/platform/linux-generic/odp_packet.c
index 8fe2baa30..1a778ff73 100644
--- a/platform/linux-generic/odp_packet.c
+++ b/platform/linux-generic/odp_packet.c
@@ -35,7 +35,7 @@
#include <odp/visibility_begin.h>
/* Fill in packet header field offsets for inline functions */
-const _odp_packet_inline_offset_t ODP_ALIGNED_CACHE _odp_packet_inline = {
+const _odp_packet_inline_offset_t _odp_packet_inline ODP_ALIGNED_CACHE = {
.seg_data = offsetof(odp_packet_hdr_t, seg_data),
.seg_len = offsetof(odp_packet_hdr_t, seg_len),
.seg_next = offsetof(odp_packet_hdr_t, seg_next),
diff --git a/platform/linux-generic/odp_pool.c b/platform/linux-generic/odp_pool.c
index 913e71f5a..236a57f4e 100644
--- a/platform/linux-generic/odp_pool.c
+++ b/platform/linux-generic/odp_pool.c
@@ -70,7 +70,7 @@ static __thread pool_local_t local;
#include <odp/visibility_begin.h>
/* Fill in pool header field offsets for inline functions */
-const _odp_pool_inline_offset_t ODP_ALIGNED_CACHE _odp_pool_inline = {
+const _odp_pool_inline_offset_t _odp_pool_inline ODP_ALIGNED_CACHE = {
.pool_hdl = offsetof(pool_t, pool_hdl),
.uarea_size = offsetof(pool_t, params.pkt.uarea_size)
};
diff --git a/platform/linux-generic/odp_queue_if.c b/platform/linux-generic/odp_queue_if.c
index 1df09ce40..7de06faa3 100644
--- a/platform/linux-generic/odp_queue_if.c
+++ b/platform/linux-generic/odp_queue_if.c
@@ -18,7 +18,7 @@
#include <odp/visibility_begin.h>
-_odp_queue_inline_offset_t ODP_ALIGNED_CACHE _odp_queue_inline_offset;
+_odp_queue_inline_offset_t _odp_queue_inline_offset ODP_ALIGNED_CACHE;
const _odp_queue_api_fn_t *_odp_queue_api;
#include <odp/visibility_end.h>
diff --git a/platform/linux-generic/odp_schedule_basic.c b/platform/linux-generic/odp_schedule_basic.c
index d222cca1d..423b50d95 100644
--- a/platform/linux-generic/odp_schedule_basic.c
+++ b/platform/linux-generic/odp_schedule_basic.c
@@ -169,7 +169,7 @@ typedef struct ODP_ALIGNED_CACHE {
/* Order context of a queue */
typedef struct ODP_ALIGNED_CACHE {
/* Current ordered context id */
- odp_atomic_u64_t ODP_ALIGNED_CACHE ctx;
+ odp_atomic_u64_t ctx ODP_ALIGNED_CACHE;
/* Next unallocated context id */
odp_atomic_u64_t next_ctx;
diff --git a/platform/linux-generic/odp_timer.c b/platform/linux-generic/odp_timer.c
index 39b0e4f0c..35a168063 100644
--- a/platform/linux-generic/odp_timer.c
+++ b/platform/linux-generic/odp_timer.c
@@ -158,7 +158,7 @@ typedef struct timer_global_t {
timer_pool_t *timer_pool[MAX_TIMER_POOLS];
#ifndef ODP_ATOMIC_U128
/* Multiple locks per cache line! */
- _odp_atomic_flag_t ODP_ALIGNED_CACHE locks[NUM_LOCKS];
+ _odp_atomic_flag_t locks[NUM_LOCKS] ODP_ALIGNED_CACHE;
#endif
/* These are read frequently from inline timer */
odp_time_t poll_interval_time;
diff --git a/platform/linux-generic/pktio/dpdk.c b/platform/linux-generic/pktio/dpdk.c
index 669b74628..63cce4005 100644
--- a/platform/linux-generic/pktio/dpdk.c
+++ b/platform/linux-generic/pktio/dpdk.c
@@ -140,7 +140,7 @@ typedef struct ODP_ALIGNED_CACHE {
uint8_t lockless_rx; /**< no locking for rx */
uint8_t lockless_tx; /**< no locking for tx */
/** RX queue locks */
- odp_ticketlock_t ODP_ALIGNED_CACHE rx_lock[PKTIO_MAX_QUEUES];
+ odp_ticketlock_t rx_lock[PKTIO_MAX_QUEUES] ODP_ALIGNED_CACHE;
odp_ticketlock_t tx_lock[PKTIO_MAX_QUEUES]; /**< TX queue locks */
/** cache for storing extra RX packets */
pkt_cache_t rx_cache[PKTIO_MAX_QUEUES];
diff --git a/platform/linux-generic/pktio/socket.c b/platform/linux-generic/pktio/socket.c
index 6c366903e..a248c839e 100644
--- a/platform/linux-generic/pktio/socket.c
+++ b/platform/linux-generic/pktio/socket.c
@@ -30,8 +30,8 @@
#include <odp_classification_internal.h>
typedef struct {
- odp_ticketlock_t ODP_ALIGNED_CACHE rx_lock;
- odp_ticketlock_t ODP_ALIGNED_CACHE tx_lock;
+ odp_ticketlock_t rx_lock ODP_ALIGNED_CACHE;
+ odp_ticketlock_t tx_lock ODP_ALIGNED_CACHE;
int sockfd; /**< socket descriptor */
odp_pool_t pool; /**< pool to alloc packets from */
uint32_t mtu; /**< maximum transmission unit */
diff --git a/platform/linux-generic/pktio/socket_common.c b/platform/linux-generic/pktio/socket_common.c
index 4b99c7c18..703ffe6b6 100644
--- a/platform/linux-generic/pktio/socket_common.c
+++ b/platform/linux-generic/pktio/socket_common.c
@@ -266,8 +266,8 @@ int link_info_fd(int fd, const char *name, odp_pktio_link_info_t *info)
/* Reserve space for the three bitmasks (map_supported, map_advertising, map_lp_advertising)
* at the end of struct ethtool_link_settings. 'link_mode_masks_nwords' defines the bitmask
* length in 32-bit words. */
- uint8_t ODP_ALIGNED_CACHE data[offsetof(struct ethtool_link_settings, link_mode_masks) +
- (3 * sizeof(uint32_t) * hcmd.link_mode_masks_nwords)];
+ uint8_t data[offsetof(struct ethtool_link_settings, link_mode_masks) +
+ (3 * sizeof(uint32_t) * hcmd.link_mode_masks_nwords)] ODP_ALIGNED_CACHE;
ecmd = (void *)data;
*ecmd = hcmd;
diff --git a/platform/linux-generic/pktio/socket_mmap.c b/platform/linux-generic/pktio/socket_mmap.c
index 9005b42c7..be6969e5c 100644
--- a/platform/linux-generic/pktio/socket_mmap.c
+++ b/platform/linux-generic/pktio/socket_mmap.c
@@ -77,11 +77,11 @@ ODP_STATIC_ASSERT(offsetof(struct ring, mm_space) <= ODP_CACHE_LINE_SIZE,
/** Packet socket using mmap rings for both Rx and Tx */
typedef struct {
/** Packet mmap ring for Rx */
- struct ring ODP_ALIGNED_CACHE rx_ring;
+ struct ring rx_ring ODP_ALIGNED_CACHE;
/** Packet mmap ring for Tx */
- struct ring ODP_ALIGNED_CACHE tx_ring;
+ struct ring tx_ring ODP_ALIGNED_CACHE;
- int ODP_ALIGNED_CACHE sockfd;
+ int sockfd ODP_ALIGNED_CACHE;
odp_pool_t pool;
int mtu; /**< maximum transmission unit */
size_t frame_offset; /**< frame start offset from start of pkt buf */