This is an automated email from the git hooks/post-receive script. It was
generated because a ref change was pushed to the repository containing
the project "".
The branch, master has been updated
via 8286cff9c5bb890d169b58857e3ab6cd118a2af4 (commit)
from 138a4a92b0bbf5bcc713a62747644276ada8d05d (commit)
Those revisions listed above that are new to this repository have
not appeared on any other notification email; so we list those
revisions in full, below.
- Log -----------------------------------------------------------------
commit 8286cff9c5bb890d169b58857e3ab6cd118a2af4
Author: Ola Liljedahl <ola.liljedahl(a)arm.com>
Date: Tue Mar 28 14:23:28 2017 -0500
linux-generic: ring.c: use required memory orderings
Signed-off-by: Ola Liljedahl <ola.liljedahl(a)arm.com>
Reviewed-by: Brian Brooks <brian.brooks(a)arm.com>
Signed-off-by: Maxim Uvarov <maxim.uvarov(a)linaro.org>
diff --git a/platform/linux-generic/pktio/ring.c b/platform/linux-generic/pktio/ring.c
index aeda04b..e3c73d1 100644
--- a/platform/linux-generic/pktio/ring.c
+++ b/platform/linux-generic/pktio/ring.c
@@ -263,8 +263,8 @@ int ___ring_mp_do_enqueue(_ring_t *r, void * const *obj_table,
/* Reset n to the initial burst count */
n = max;
- prod_head = r->prod.head;
- cons_tail = r->cons.tail;
+ prod_head = __atomic_load_n(&r->prod.head, __ATOMIC_RELAXED);
+ cons_tail = __atomic_load_n(&r->cons.tail, __ATOMIC_ACQUIRE);
/* The subtraction is done between two unsigned 32bits value
* (the result is always modulo 32 bits even if we have
* prod_head > cons_tail). So 'free_entries' is always between 0
@@ -306,12 +306,12 @@ int ___ring_mp_do_enqueue(_ring_t *r, void * const *obj_table,
* If there are other enqueues in progress that preceded us,
* we need to wait for them to complete
*/
- while (odp_unlikely(r->prod.tail != prod_head))
+ while (odp_unlikely(__atomic_load_n(&r->prod.tail, __ATOMIC_RELAXED) !=
+ prod_head))
odp_cpu_pause();
/* Release our entries and the memory they refer to */
- __atomic_thread_fence(__ATOMIC_RELEASE);
- r->prod.tail = prod_next;
+ __atomic_store_n(&r->prod.tail, prod_next, __ATOMIC_RELEASE);
return ret;
}
@@ -328,7 +328,7 @@ int ___ring_sp_do_enqueue(_ring_t *r, void * const *obj_table,
int ret;
prod_head = r->prod.head;
- cons_tail = r->cons.tail;
+ cons_tail = __atomic_load_n(&r->cons.tail, __ATOMIC_ACQUIRE);
/* The subtraction is done between two unsigned 32bits value
* (the result is always modulo 32 bits even if we have
* prod_head > cons_tail). So 'free_entries' is always between 0
@@ -361,8 +361,7 @@ int ___ring_sp_do_enqueue(_ring_t *r, void * const *obj_table,
}
/* Release our entries and the memory they refer to */
- __atomic_thread_fence(__ATOMIC_RELEASE);
- r->prod.tail = prod_next;
+ __atomic_store_n(&r->prod.tail, prod_next, __ATOMIC_RELEASE);
return ret;
}
@@ -385,8 +384,8 @@ int ___ring_mc_do_dequeue(_ring_t *r, void **obj_table,
/* Restore n as it may change every loop */
n = max;
- cons_head = r->cons.head;
- prod_tail = r->prod.tail;
+ cons_head = __atomic_load_n(&r->cons.head, __ATOMIC_RELAXED);
+ prod_tail = __atomic_load_n(&r->prod.tail, __ATOMIC_ACQUIRE);
/* The subtraction is done between two unsigned 32bits value
* (the result is always modulo 32 bits even if we have
* cons_head > prod_tail). So 'entries' is always between 0
@@ -419,12 +418,12 @@ int ___ring_mc_do_dequeue(_ring_t *r, void **obj_table,
* If there are other dequeues in progress that preceded us,
* we need to wait for them to complete
*/
- while (odp_unlikely(r->cons.tail != cons_head))
+ while (odp_unlikely(__atomic_load_n(&r->cons.tail, __ATOMIC_RELAXED) !=
+ cons_head))
odp_cpu_pause();
/* Release our entries and the memory they refer to */
- __atomic_thread_fence(__ATOMIC_RELEASE);
- r->cons.tail = cons_next;
+ __atomic_store_n(&r->cons.tail, cons_next, __ATOMIC_RELEASE);
return behavior == _RING_QUEUE_FIXED ? 0 : n;
}
@@ -441,7 +440,7 @@ int ___ring_sc_do_dequeue(_ring_t *r, void **obj_table,
uint32_t mask = r->prod.mask;
cons_head = r->cons.head;
- prod_tail = r->prod.tail;
+ prod_tail = __atomic_load_n(&r->prod.tail, __ATOMIC_ACQUIRE);
/* The subtraction is done between two unsigned 32bits value
* (the result is always modulo 32 bits even if we have
* cons_head > prod_tail). So 'entries' is always between 0
@@ -461,11 +460,10 @@ int ___ring_sc_do_dequeue(_ring_t *r, void **obj_table,
r->cons.head = cons_next;
/* Acquire the pointers and the memory they refer to */
- __atomic_thread_fence(__ATOMIC_ACQUIRE);
/* copy in table */
DEQUEUE_PTRS();
- r->cons.tail = cons_next;
+ __atomic_store_n(&r->cons.tail, cons_next, __ATOMIC_RELEASE);
return behavior == _RING_QUEUE_FIXED ? 0 : n;
}
-----------------------------------------------------------------------
Summary of changes:
platform/linux-generic/pktio/ring.c | 30 ++++++++++++++----------------
1 file changed, 14 insertions(+), 16 deletions(-)
hooks/post-receive
--
This is an automated email from the git hooks/post-receive script. It was
generated because a ref change was pushed to the repository containing
the project "".
The branch, master has been updated
via 138a4a92b0bbf5bcc713a62747644276ada8d05d (commit)
from 539b12c997b213c687249669b4ed4dc058d957ee (commit)
Those revisions listed above that are new to this repository have
not appeared on any other notification email; so we list those
revisions in full, below.
- Log -----------------------------------------------------------------
commit 138a4a92b0bbf5bcc713a62747644276ada8d05d
Author: Matias Elo <matias.elo(a)nokia.com>
Date: Thu Mar 30 10:41:02 2017 +0300
test: bench_packet: fix headroom/tailroom test return values
Zero is a valid return value from the packet headroom/tailroom functions.
Signed-off-by: Matias Elo <matias.elo(a)nokia.com>
Reviewed-by: Bill Fischofer <bill.fischofer(a)linaro.org>
Signed-off-by: Maxim Uvarov <maxim.uvarov(a)linaro.org>
diff --git a/test/common_plat/performance/odp_bench_packet.c b/test/common_plat/performance/odp_bench_packet.c
index 7a3a004..c4cd613 100644
--- a/test/common_plat/performance/odp_bench_packet.c
+++ b/test/common_plat/performance/odp_bench_packet.c
@@ -618,7 +618,7 @@ static int bench_packet_headroom(void)
for (i = 0; i < TEST_REPEAT_COUNT; i++)
ret += odp_packet_headroom(gbl_args->pkt_tbl[i]);
- return ret;
+ return i;
}
static int bench_packet_tailroom(void)
@@ -629,7 +629,7 @@ static int bench_packet_tailroom(void)
for (i = 0; i < TEST_REPEAT_COUNT; i++)
ret += odp_packet_tailroom(gbl_args->pkt_tbl[i]);
- return ret;
+ return i;
}
static int bench_packet_tail(void)
-----------------------------------------------------------------------
Summary of changes:
test/common_plat/performance/odp_bench_packet.c | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
hooks/post-receive
--
This is an automated email from the git hooks/post-receive script. It was
generated because a ref change was pushed to the repository containing
the project "".
The branch, master has been updated
via 5876b4f36fbbaf10f5242915a1b29dee37cfb005 (commit)
from 7ba232f77c60f707d279478a798f6ea14fe9c143 (commit)
Those revisions listed above that are new to this repository have
not appeared on any other notification email; so we list those
revisions in full, below.
- Log -----------------------------------------------------------------
commit 5876b4f36fbbaf10f5242915a1b29dee37cfb005
Author: Bill Fischofer <bill.fischofer(a)linaro.org>
Date: Thu Mar 23 16:56:50 2017 -0500
validation: packet: do not require a max packet length
Address bug https://bugs.linaro.org/show_bug.cgi?id=2908 by adding
appropriate pool capability checks to the packet, pktio, and crypto tests
to account for pkt.max_len, pkt.max_seg_len, or pkt.max_segs_per_pkt
being zero, indicating these limits are bound only by available
memory.
Signed-off-by: Bill Fischofer <bill.fischofer(a)linaro.org>
Reviewed-by: Balakrishna Garapati <balakrishna.garapati(a)linaro.org>
Signed-off-by: Maxim Uvarov <maxim.uvarov(a)linaro.org>
diff --git a/test/common_plat/validation/api/crypto/crypto.c b/test/common_plat/validation/api/crypto/crypto.c
index e7c2bf3..94beb2f 100644
--- a/test/common_plat/validation/api/crypto/crypto.c
+++ b/test/common_plat/validation/api/crypto/crypto.c
@@ -48,12 +48,14 @@ int crypto_init(odp_instance_t *inst)
params.pkt.num = PKT_POOL_NUM;
params.type = ODP_POOL_PACKET;
- if (PKT_POOL_LEN > pool_capa.pkt.max_seg_len) {
+ if (pool_capa.pkt.max_seg_len &&
+ PKT_POOL_LEN > pool_capa.pkt.max_seg_len) {
fprintf(stderr, "Warning: small packet segment length\n");
params.pkt.seg_len = pool_capa.pkt.max_seg_len;
}
- if (PKT_POOL_LEN > pool_capa.pkt.max_len) {
+ if (pool_capa.pkt.max_len &&
+ PKT_POOL_LEN > pool_capa.pkt.max_len) {
fprintf(stderr, "Pool max packet length too small\n");
return -1;
}
diff --git a/test/common_plat/validation/api/packet/packet.c b/test/common_plat/validation/api/packet/packet.c
index 900c426..669122a 100644
--- a/test/common_plat/validation/api/packet/packet.c
+++ b/test/common_plat/validation/api/packet/packet.c
@@ -114,6 +114,8 @@ int packet_suite_init(void)
printf("pool_capability failed\n");
return -1;
}
+ if (capa.pkt.max_segs_per_pkt == 0)
+ capa.pkt.max_segs_per_pkt = 10;
/* Pick a typical packet size and decrement it to the single segment
* limit if needed (min_seg_len maybe equal to max_len
@@ -366,6 +368,8 @@ void packet_test_alloc_segmented(void)
int ret, i, num_alloc;
CU_ASSERT_FATAL(odp_pool_capability(&capa) == 0);
+ if (capa.pkt.max_segs_per_pkt == 0)
+ capa.pkt.max_segs_per_pkt = 10;
if (capa.pkt.max_len)
max_len = capa.pkt.max_len;
@@ -1847,6 +1851,9 @@ void packet_test_extend_ref(void)
{
odp_packet_t max_pkt, ref;
uint32_t hr, tr, max_len;
+ odp_pool_capability_t capa;
+
+ CU_ASSERT_FATAL(odp_pool_capability(&capa) == 0);
max_pkt = odp_packet_copy(segmented_test_packet,
odp_packet_pool(segmented_test_packet));
@@ -1860,8 +1867,10 @@ void packet_test_extend_ref(void)
odp_packet_push_tail(max_pkt, tr);
/* Max packet should not be extendable at either end */
- CU_ASSERT(odp_packet_extend_tail(&max_pkt, 1, NULL, NULL) < 0);
- CU_ASSERT(odp_packet_extend_head(&max_pkt, 1, NULL, NULL) < 0);
+ if (max_len == capa.pkt.max_len) {
+ CU_ASSERT(odp_packet_extend_tail(&max_pkt, 1, NULL, NULL) < 0);
+ CU_ASSERT(odp_packet_extend_head(&max_pkt, 1, NULL, NULL) < 0);
+ }
/* See if we can trunc and extend anyway */
CU_ASSERT(odp_packet_trunc_tail(&max_pkt, hr + tr + 1,
diff --git a/test/common_plat/validation/api/pktio/pktio.c b/test/common_plat/validation/api/pktio/pktio.c
index 4f3c0c0..54f206e 100644
--- a/test/common_plat/validation/api/pktio/pktio.c
+++ b/test/common_plat/validation/api/pktio/pktio.c
@@ -124,7 +124,7 @@ static void set_pool_len(odp_pool_param_t *params, odp_pool_capability_t *capa)
{
uint32_t seg_len;
- seg_len = capa->pkt.max_seg_len;
+ seg_len = capa->pkt.max_seg_len ? capa->pkt.max_seg_len : PKT_BUF_SIZE;
switch (pool_segmentation) {
case PKT_POOL_SEGMENTED:
@@ -620,7 +620,8 @@ static void pktio_txrx_multi(pktio_info_t *pktio_a, pktio_info_t *pktio_b,
CU_ASSERT_FATAL(odp_pool_capability(&pool_capa) == 0);
- if (packet_len > pool_capa.pkt.max_len)
+ if (pool_capa.pkt.max_len &&
+ packet_len > pool_capa.pkt.max_len)
packet_len = pool_capa.pkt.max_len;
}
@@ -1689,7 +1690,8 @@ int pktio_check_send_failure(void)
odp_pktio_close(pktio_tx);
/* Failure test supports only single segment */
- if (pool_capa.pkt.max_seg_len < mtu + 32)
+ if (pool_capa.pkt.max_seg_len &&
+ pool_capa.pkt.max_seg_len < mtu + 32)
return ODP_TEST_INACTIVE;
return ODP_TEST_ACTIVE;
@@ -1728,7 +1730,8 @@ void pktio_test_send_failure(void)
CU_ASSERT_FATAL(odp_pool_capability(&pool_capa) == 0);
- if (pool_capa.pkt.max_seg_len < mtu + 32) {
+ if (pool_capa.pkt.max_seg_len &&
+ pool_capa.pkt.max_seg_len < mtu + 32) {
CU_FAIL("Max packet seg length is too small.");
return;
}
-----------------------------------------------------------------------
Summary of changes:
test/common_plat/validation/api/crypto/crypto.c | 6 ++++--
test/common_plat/validation/api/packet/packet.c | 13 +++++++++++--
test/common_plat/validation/api/pktio/pktio.c | 11 +++++++----
3 files changed, 22 insertions(+), 8 deletions(-)
hooks/post-receive
--
This is an automated email from the git hooks/post-receive script. It was
generated because a ref change was pushed to the repository containing
the project "".
The branch, api-next has been updated
via 35e0f869ff3db3c0b2f2100541ba4897d8bef7b4 (commit)
via 7ba232f77c60f707d279478a798f6ea14fe9c143 (commit)
via 97b7d50af6b7239db03d941e4816f4da98ab9449 (commit)
via b056efea2b416831e4d0ecf6494ee10c8da4b117 (commit)
via 746455fcdf279fcef7ec6a3eb6c5f1b465588554 (commit)
via ec8a54c9236925ea97ee154eb70093d6effb1311 (commit)
via 37db76d04174f90f86c8103e6a1ca9d1e9518098 (commit)
via e6a635ac73e99a9a7a6b499685a72139e87044ea (commit)
via a347c91412f0db5c25141b709a93eaf040a77730 (commit)
via 88dbb00623102878f2e0e1dd720a942fdd980ca3 (commit)
from ff6c083358f97f7b5b261d8e75ca7a2eaaab5dea (commit)
Those revisions listed above that are new to this repository have
not appeared on any other notification email; so we list those
revisions in full, below.
- Log -----------------------------------------------------------------
commit 35e0f869ff3db3c0b2f2100541ba4897d8bef7b4
Merge: ff6c083 7ba232f
Author: Maxim Uvarov <maxim.uvarov(a)linaro.org>
Date: Wed Mar 22 21:50:27 2017 +0300
Merge branch 'master' into api-next
Signed-off-by: Maxim Uvarov <maxim.uvarov(a)linaro.org>
-----------------------------------------------------------------------
Summary of changes:
.travis.yml | 2 +-
DEPENDENCIES | 2 +-
platform/linux-generic/Makefile.am | 2 +-
platform/linux-generic/include/odp_ring_internal.h | 4 +-
platform/linux-generic/m4/odp_dpdk.m4 | 33 +++--
platform/linux-generic/odp_packet.c | 4 +
platform/linux-generic/odp_pool.c | 7 +-
platform/linux-generic/pktio/dpdk.c | 152 +--------------------
scripts/build-pktio-dpdk | 2 +-
test/common_plat/performance/odp_bench_packet.c | 86 ++++++++++++
.../validation/api/pktio/pktio_run_dpdk.sh | 2 +-
11 files changed, 125 insertions(+), 171 deletions(-)
hooks/post-receive
--
This is an automated email from the git hooks/post-receive script. It was
generated because a ref change was pushed to the repository containing
the project "".
The branch, master has been updated
via 7ba232f77c60f707d279478a798f6ea14fe9c143 (commit)
from 97b7d50af6b7239db03d941e4816f4da98ab9449 (commit)
Those revisions listed above that are new to this repository have
not appeared on any other notification email; so we list those
revisions in full, below.
- Log -----------------------------------------------------------------
commit 7ba232f77c60f707d279478a798f6ea14fe9c143
Author: Brian Brooks <brian.brooks(a)linaro.org>
Date: Tue Mar 21 23:54:17 2017 -0500
linux-gen: ring: fix memory ordering in ring dequeue
Acquire ordering is needed to maintain proper release consistency with
the ring enqueue operation. This issue presented itself as deadlock when
running on an ARM-based chip.
Signed-off-by: Brian Brooks <brian.brooks(a)linaro.org>
Reviewed-by: Bill Fischofer <bill.fischofer(a)linaro.org>
Signed-off-by: Maxim Uvarov <maxim.uvarov(a)linaro.org>
diff --git a/platform/linux-generic/include/odp_ring_internal.h b/platform/linux-generic/include/odp_ring_internal.h
index 55fedeb..44b83c6 100644
--- a/platform/linux-generic/include/odp_ring_internal.h
+++ b/platform/linux-generic/include/odp_ring_internal.h
@@ -57,7 +57,7 @@ static inline uint32_t ring_deq(ring_t *ring, uint32_t mask)
/* Move reader head. This thread owns data at the new head. */
do {
- tail = odp_atomic_load_u32(&ring->w_tail);
+ tail = odp_atomic_load_acq_u32(&ring->w_tail);
if (head == tail)
return RING_EMPTY;
@@ -90,7 +90,7 @@ static inline uint32_t ring_deq_multi(ring_t *ring, uint32_t mask,
/* Move reader head. This thread owns data at the new head. */
do {
- tail = odp_atomic_load_u32(&ring->w_tail);
+ tail = odp_atomic_load_acq_u32(&ring->w_tail);
/* Ring is empty */
if (head == tail)
-----------------------------------------------------------------------
Summary of changes:
platform/linux-generic/include/odp_ring_internal.h | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
hooks/post-receive
--
This is an automated email from the git hooks/post-receive script. It was
generated because a ref change was pushed to the repository containing
the project "".
The branch, master has been updated
via 97b7d50af6b7239db03d941e4816f4da98ab9449 (commit)
from b056efea2b416831e4d0ecf6494ee10c8da4b117 (commit)
Those revisions listed above that are new to this repository have
not appeared on any other notification email; so we list those
revisions in full, below.
- Log -----------------------------------------------------------------
commit 97b7d50af6b7239db03d941e4816f4da98ab9449
Author: Dmitry Eremin-Solenikov <dmitry.ereminsolenikov(a)linaro.org>
Date: Fri Mar 10 13:14:55 2017 +0300
linux-generic: pool: don't allocate buffers from invalid pool
Add ODP_ASSERT checking that passed pool is not ODP_POOL_INVALID before
tring to allocate buffers from that pool.
Signed-off-by: Dmitry Eremin-Solenikov <dmitry.ereminsolenikov(a)linaro.org>
Reviewed-by: Bill Fischofer <bill.fischofer(a)linaro.org>
Signed-off-by: Maxim Uvarov <maxim.uvarov(a)linaro.org>
diff --git a/platform/linux-generic/odp_pool.c b/platform/linux-generic/odp_pool.c
index 145002d..9dba734 100644
--- a/platform/linux-generic/odp_pool.c
+++ b/platform/linux-generic/odp_pool.c
@@ -769,6 +769,8 @@ odp_buffer_t odp_buffer_alloc(odp_pool_t pool_hdl)
pool_t *pool;
int ret;
+ ODP_ASSERT(ODP_POOL_INVALID != pool_hdl);
+
pool = pool_entry_from_hdl(pool_hdl);
ret = buffer_alloc_multi(pool, &buf, NULL, 1);
@@ -782,6 +784,8 @@ int odp_buffer_alloc_multi(odp_pool_t pool_hdl, odp_buffer_t buf[], int num)
{
pool_t *pool;
+ ODP_ASSERT(ODP_POOL_INVALID != pool_hdl);
+
pool = pool_entry_from_hdl(pool_hdl);
return buffer_alloc_multi(pool, buf, NULL, num);
-----------------------------------------------------------------------
Summary of changes:
platform/linux-generic/odp_pool.c | 4 ++++
1 file changed, 4 insertions(+)
hooks/post-receive
--
This is an automated email from the git hooks/post-receive script. It was
generated because a ref change was pushed to the repository containing
the project "".
The branch, master has been updated
via ec8a54c9236925ea97ee154eb70093d6effb1311 (commit)
from 37db76d04174f90f86c8103e6a1ca9d1e9518098 (commit)
Those revisions listed above that are new to this repository have
not appeared on any other notification email; so we list those
revisions in full, below.
- Log -----------------------------------------------------------------
commit ec8a54c9236925ea97ee154eb70093d6effb1311
Author: Janne Peltonen <janne.peltonen(a)nokia.com>
Date: Tue Mar 7 11:16:32 2017 +0200
linux-gen: abi: fix include/odp/api/abi symlink creation
Fix the ABI symlink creation that went broken in 3d6cbd2.
Signed-off-by: Janne Peltonen <janne.peltonen(a)nokia.com>
Signed-off-by: Maxim Uvarov <maxim.uvarov(a)linaro.org>
diff --git a/platform/linux-generic/Makefile.am b/platform/linux-generic/Makefile.am
index 682bac6..056ba67 100644
--- a/platform/linux-generic/Makefile.am
+++ b/platform/linux-generic/Makefile.am
@@ -225,7 +225,7 @@ endif
# specific include path for installed files.
install-data-hook:
if [ -h $(prefix)/include/odp/api/abi ]; then \
- : \
+ : ; \
else \
$(LN_S) -rf $(prefix)/include/odp/arch/@ARCH_ABI@/odp/api/abi \
$(prefix)/include/odp/api/abi; \
-----------------------------------------------------------------------
Summary of changes:
platform/linux-generic/Makefile.am | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
hooks/post-receive
--