Re: [lng-odp] [PATCH] pool: Do not flush cache of non-initialized pools

2015-04-21 Thread Nicolas Morey Chaisemartin
- Original Message - From: Mike Holmes mike.hol...@linaro.org To: Nicolas Morey-Chaisemartin nmo...@kalray.eu Cc: lng-odp lng-odp@lists.linaro.org Sent: Tuesday, 21 April, 2015 7:24:44 PM Subject: Re: [lng-odp] [PATCH] pool: Do not flush cache of non-initialized pools On 21 April

[lng-odp] [PATCH] pool: Make sure all atomics are initialized before stored or incremented

2015-04-21 Thread Nicolas Morey-Chaisemartin
Signed-off-by: Nicolas Morey-Chaisemartin nmo...@kalray.eu --- platform/linux-generic/odp_pool.c | 26 -- 1 file changed, 16 insertions(+), 10 deletions(-) diff --git a/platform/linux-generic/odp_pool.c b/platform/linux-generic/odp_pool.c index bf49623..23cd503 100644

[lng-odp] [PATCH] pool: Do not flush cache of non-initialized pools

2015-04-21 Thread Nicolas Morey-Chaisemartin
Flush cache triggers atomic_add on some of the pool atomics which have never been initialized if the pool hasn't been. Signed-off-by: Nicolas Morey-Chaisemartin nmo...@kalray.eu --- platform/linux-generic/odp_pool.c | 2 ++ 1 file changed, 2 insertions(+) diff --git a/platform/linux-generic

Re: [lng-odp] [PATCH] Use inttypes defines to print (u)int32_t values

2015-04-20 Thread Nicolas Morey-Chaisemartin
--utf8 but I can not apply it even after that. Did you use git send-email command? Thanks, Maxim. On 04/16/15 12:31, Nicolas Morey-Chaisemartin wrote: --- platform/linux-generic/odp_buffer.c | 4 ++-- platform/linux-generic/odp_packet.c | 14 +++--- 2 files changed, 9

[lng-odp] [PATCHv2] Use inttypes defines to print (u)int32_t values

2015-04-20 Thread Nicolas Morey-Chaisemartin
Signed-off-by: Nicolas Morey-Chaisemartin nmo...@kalray.eu --- platform/linux-generic/odp_buffer.c | 4 ++-- platform/linux-generic/odp_packet.c | 14 +++--- 2 files changed, 9 insertions(+), 9 deletions(-) diff --git a/platform/linux-generic/odp_buffer.c b/platform/linux-generic

Re: [lng-odp] Atomics

2015-04-21 Thread Nicolas Morey-Chaisemartin
On 04/21/2015 01:31 PM, Ola Liljedahl wrote: On 17 April 2015 at 10:46, Nicolas Morey-Chaisemartin nmo...@kalray.eu mailto:nmo...@kalray.eu wrote: Hello every one, I am currently working on porting the linux-generic implementation of DPDK on Kalray architecture and slightly

[lng-odp] [PATCH 1/3] test: classification: add missing init of atomic variable

2015-04-24 Thread Nicolas Morey-Chaisemartin
Signed-off-by: Nicolas Morey-Chaisemartin nmo...@kalray.eu --- test/validation/classification/odp_classification_tests.c | 1 + 1 file changed, 1 insertion(+) diff --git a/test/validation/classification/odp_classification_tests.c b/test/validation/classification/odp_classification_tests.c index

[lng-odp] Threads Thread Safety

2015-04-24 Thread Nicolas Morey-Chaisemartin
Hi everyone, I'm currently trying to get all the ODP validation tests running on our MPPA platform and ran across an issue: It appears CUnit (2.1-3) is *not* thread safe ! It isn't a very big issue but it creates unexpected behaviour (and warnings in our simulators) in the odp_shm test for

[lng-odp] [PATCH 2/3] linux-generic: packet_io: init l2 and l3 cos table spinlocks

2015-04-24 Thread Nicolas Morey-Chaisemartin
Signed-off-by: Nicolas Morey-Chaisemartin nmo...@kalray.eu --- platform/linux-generic/odp_packet_io.c | 2 ++ 1 file changed, 2 insertions(+) diff --git a/platform/linux-generic/odp_packet_io.c b/platform/linux-generic/odp_packet_io.c index cfe5b71..f16685d 100644 --- a/platform/linux-generic

[lng-odp] [PATCH 3/3] validation: synchronizers: fix init of custom barrier atomic

2015-04-24 Thread Nicolas Morey-Chaisemartin
Signed-off-by: Nicolas Morey-Chaisemartin nmo...@kalray.eu --- test/validation/odp_synchronizers.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/test/validation/odp_synchronizers.c b/test/validation/odp_synchronizers.c index edb6bf1..a9be1c5 100644 --- a/test/validation

[lng-odp] [PATCH] api: time: force time defines as ULL to avoid computation overflows on 32bits systems

2015-04-24 Thread Nicolas Morey-Chaisemartin
For example the odp_timer validation tests computes 10 * ODP_TIME_SEC and stores it into an uint64_t, but the computation overflows on 32b systems and the test fails Signed-off-by: Nicolas Morey-Chaisemartin nmo...@kalray.eu --- include/odp/api/time.h | 6 +++--- 1 file changed, 3 insertions

[lng-odp] [PATCH] validation: use PRIu32 instead of %u to print uint32_t variables

2015-04-22 Thread Nicolas Morey-Chaisemartin
Signed-off-by: Nicolas Morey-Chaisemartin nmo...@kalray.eu --- This triggers some warnings in checkpatch about long string and multi-line strings. Seeing the latest debate about split string vs 80 cols, I tried to keep the same format. If you want me to fix it one way opr the other, please let

[lng-odp] [PATCH v2 2/2] linux-generic: pool: fix initialization of odp_buffer_hdr ref_count

2015-04-22 Thread Nicolas Morey-Chaisemartin
Signed-off-by: Nicolas Morey-Chaisemartin nmo...@kalray.eu --- platform/linux-generic/odp_pool.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/platform/linux-generic/odp_pool.c b/platform/linux-generic/odp_pool.c index ea993bb..a3d80b5 100644 --- a/platform/linux-generic

[lng-odp] [PATCH v2 1/2] linux-generic: pool: initialize atomics during odp_pool_init_global

2015-04-22 Thread Nicolas Morey-Chaisemartin
Signed-off-by: Nicolas Morey-Chaisemartin nmo...@kalray.eu --- platform/linux-generic/odp_pool.c | 12 1 file changed, 12 insertions(+) diff --git a/platform/linux-generic/odp_pool.c b/platform/linux-generic/odp_pool.c index bf49623..ea993bb 100644 --- a/platform/linux-generic

Re: [lng-odp] Atomics

2015-04-22 Thread Nicolas Morey-Chaisemartin
On 04/22/2015 10:07 AM, Maxim Uvarov wrote: On 22 April 2015 at 11:04, Nicolas Morey-Chaisemartin nmo...@kalray.eu mailto:nmo...@kalray.eu wrote: I guess the idea would be to move odp_atomic_internal.h to include/odp/plat/atomic.h (or something similar) and use its function

Re: [lng-odp] Atomics

2015-04-22 Thread Nicolas Morey-Chaisemartin
On 04/22/2015 09:56 AM, Maxim Uvarov wrote: I don't know if this influences the location of odp_atomic_internal.h in the ODP source structure. Maybe the makefiles can grab files (to be installed) from anywhere. Maxim, Anders? _internal.h prefixes says that file has internal

Re: [lng-odp] Atomics

2015-04-22 Thread Nicolas Morey-Chaisemartin
On 04/22/2015 11:39 AM, Maxim Uvarov wrote: In that case what you need is. That is odp API: ./include/odp/api/atomic.h That is platfrom implementation (linux-generic): ./platform/linux-generic/include/odp/atomic.h That is some internal functions which linux-generic platfrom does.

Re: [lng-odp] [PATCH v2 2/2] linux-generic: pool: fix initialization of odp_buffer_hdr ref_count

2015-04-24 Thread Nicolas Morey-Chaisemartin
All good now. Thanks! On 04/23/2015 10:53 PM, Bill Fischofer wrote: Both parts should be applied. On Thu, Apr 23, 2015 at 8:02 AM, Nicolas Morey-Chaisemartin nmo...@kalray.eu mailto:nmo...@kalray.eu wrote: Thanks. Is there a reason why you did not apply the first patch

Re: [lng-odp] [PATCH] api: time: force time defines as ULL to avoid computation overflows on 32bits systems

2015-04-30 Thread Nicolas Morey-Chaisemartin
On 04/29/2015 08:43 PM, Mike Holmes wrote: But this is in the public API so it may be used in an application and it could now change the size of a structure in memory. Maybe I'm missing something but I don't see how. This is only a literal value. The time type used by the API is already on

Re: [lng-odp] Threads Thread Safety

2015-04-27 Thread Nicolas Morey-Chaisemartin
On 04/27/2015 02:29 PM, Mike Holmes wrote: On 24 April 2015 at 08:30, Nicolas Morey-Chaisemartin nmo...@kalray.eu mailto:nmo...@kalray.eu wrote: Hi everyone, I'm currently trying to get all the ODP validation tests running on our MPPA platform and ran across an issue

[lng-odp] [PATCH] test: synchronizers: use thread_id instead of cpu_id to detect slow thread

2015-05-04 Thread Nicolas Morey-Chaisemartin
The test assumes that cpu_id ranges from 0 to n CPU - 1 which is not necessary true on all archs. Meanwhile thread ids are always ranging from 0 to N (0 here is for the main test thread) Signed-off-by: Nicolas Morey-Chaisemartin nmo...@kalray.eu --- test/validation/odp_synchronizers.c | 2

[lng-odp] [PATCH] test: pktio: add missing atomic init

2015-05-06 Thread Nicolas Morey-Chaisemartin
Signed-off-by: Nicolas Morey-Chaisemartin nmo...@kalray.eu --- test/validation/odp_pktio.c | 1 + 1 file changed, 1 insertion(+) diff --git a/test/validation/odp_pktio.c b/test/validation/odp_pktio.c index 67e709e..583e291 100644 --- a/test/validation/odp_pktio.c +++ b/test/validation

[lng-odp] [PATCH v3] linux-generic: use inttypes defines to print (u)int32_t values

2015-05-06 Thread Nicolas Morey-Chaisemartin
Signed-off-by: Nicolas Morey-Chaisemartin nmo...@kalray.eu --- Submitted this patch a couple of weeks ago with a bad title ( [PATCHv2] Use inttypes defines to print (u)int32_t values) and didn't any feedback. platform/linux-generic/odp_buffer.c | 4 ++-- platform/linux-generic/odp_packet.c

[lng-odp] [PATCH] test: pktio_perf: add missing atomic init

2015-05-11 Thread Nicolas Morey-Chaisemartin
Signed-off-by: Nicolas Morey-Chaisemartin nmo...@kalray.eu --- test/performance/odp_pktio_perf.c | 1 + 1 file changed, 1 insertion(+) diff --git a/test/performance/odp_pktio_perf.c b/test/performance/odp_pktio_perf.c index 38ce328..fbe27a0 100644 --- a/test/performance/odp_pktio_perf.c +++ b

[lng-odp] [PATCH] test: use CU_ASSERT_FATAL in case odp_buffer_alloc failed to avoid segfaults

2015-05-05 Thread Nicolas Morey-Chaisemartin
Signed-off-by: Nicolas Morey-Chaisemartin nmo...@kalray.eu --- test/validation/odp_queue.c| 1 + test/validation/odp_schedule.c | 4 ++-- 2 files changed, 3 insertions(+), 2 deletions(-) diff --git a/test/validation/odp_queue.c b/test/validation/odp_queue.c index 5d47399..5123939 100644

[lng-odp] [PATCH] linux-generic: buffer: init all the odp_buffer_bits_t struct to avoid valgrind warnings

2015-05-05 Thread Nicolas Morey-Chaisemartin
-by: Nicolas Morey-Chaisemartin nmo...@kalray.eu --- platform/linux-generic/include/odp_buffer_inlines.h | 1 + 1 file changed, 1 insertion(+) diff --git a/platform/linux-generic/include/odp_buffer_inlines.h b/platform/linux-generic/include/odp_buffer_inlines.h index 4a44c5f..2c792e2 100644 --- a/platform

Re: [lng-odp] [PATCH v2] linux-generic/odp_impl: add implementation version details

2015-05-18 Thread Nicolas Morey-Chaisemartin
On 05/07/2015 02:38 PM, Mike Holmes wrote: Signed-off-by: Mike Holmes mike.hol...@linaro.org + +GIT_DESC !=$(top_builddir)/scripts/git_hash.sh This breaks the build on older distrib (Centos 7). It seems the != is only available in Make = 4.0 I replaced it by this: GIT_DESC = $(shell

Re: [lng-odp] [PATCH v2] linux-generic/odp_impl: add implementation version details

2015-05-18 Thread Nicolas Morey-Chaisemartin
. On 05/18/2015 18:32, Maxim Uvarov wrote: Hello Anders, can you please take a look what is portable solution here? Thank you, Maxim. On 05/18/2015 17:52, Nicolas Morey-Chaisemartin wrote: On 05/07/2015 02:38 PM, Mike Holmes wrote: Signed-off-by: Mike Holmes mike.hol...@linaro.org

[lng-odp] [PATCH] platform: Makefile.inc: use `` instead of != for compatibility with older versions of Make

2015-05-19 Thread Nicolas Morey-Chaisemartin
Suggested-by: Maxim Uvarov maxim.uva...@linaro.org Signed-off-by: Nicolas Morey-Chaisemartin nmo...@kalray.eu --- platform/Makefile.inc | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/platform/Makefile.inc b/platform/Makefile.inc index f232daa..f64e37c 100644 --- a/platform

[lng-odp] [PATCH] validation: packet: use PRIu32 instead of %d

2015-05-19 Thread Nicolas Morey-Chaisemartin
Signed-off-by: Nicolas Morey-Chaisemartin nmo...@kalray.eu --- Note: the new checkpatch does not seem to be happy with PRIu32 put this way (CamelCase and no space in concatenated strings) but I kept it homogeneous with the other printfs test/validation/odp_packet.c | 3 ++- 1 file changed, 2

Re: [lng-odp] [Bug 1449] New: odp_timer_test core dump

2015-05-19 Thread Nicolas Morey-Chaisemartin
I ran into the same issue on our side and after a quick look, this is kind of expected. By setting a period to a time duration smaller than the resolution, the probability is very high that this would happen Example: Get tick = N Time out = Tick + Period = N + 0 = N == New tick ==

[lng-odp] [PATCH] helper: ring: remove unused include

2015-05-18 Thread Nicolas Morey-Chaisemartin
Signed-off-by: Nicolas Morey-Chaisemartin nmo...@kalray.eu --- helper/ring.c | 1 - 1 file changed, 1 deletion(-) diff --git a/helper/ring.c b/helper/ring.c index a24a020..721c1fc 100644 --- a/helper/ring.c +++ b/helper/ring.c @@ -75,7 +75,6 @@ #include odp_align_internal.h #include odp

Re: [lng-odp] [PATCH] test: pktio_perf: add support for batch reception

2015-06-02 Thread Nicolas Morey-Chaisemartin
On 06/02/2015 11:19 AM, Stuart Haslam wrote: On Mon, Jun 01, 2015 at 06:44:10PM +0200, Nicolas Morey-Chaisemartin wrote: Signed-off-by: Nicolas Morey-Chaisemartin nmo...@kalray.eu --- test/performance/odp_pktio_perf.c | 72 +-- 1 file changed, 54

Re: [lng-odp] [PATCH] test: pktio_perf: add support for batch reception

2015-06-02 Thread Nicolas Morey-Chaisemartin
Uvarov wrote: Looks good. But why default is 1 and not BATCH_LEN_MAX? Then more then faster right? Stuart, it's your test. Do you also want to review it? Thank you, Maxim. On 06/01/15 19:44, Nicolas Morey-Chaisemartin wrote: Signed-off-by: Nicolas Morey-Chaisemartin nmo...@kalray.eu

[lng-odp] [PATCH] configure: remove extra result message

2015-06-05 Thread Nicolas Morey-Chaisemartin
Signed-off-by: Nicolas Morey-Chaisemartin nmo...@kalray.eu --- configure.ac | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/configure.ac b/configure.ac index 89b0846..ed74b4a 100644 --- a/configure.ac +++ b/configure.ac @@ -229,7 +229,7 @@ AC_HELP_STRING([--with-openssl-path

[lng-odp] [PATCH] doc: use only WITH_PLATFORM and not always linux-generic

2015-06-05 Thread Nicolas Morey-Chaisemartin
Signed-off-by: Nicolas Morey-Chaisemartin nmo...@kalray.eu --- doc/doxygen.cfg | 1 - 1 file changed, 1 deletion(-) diff --git a/doc/doxygen.cfg b/doc/doxygen.cfg index 6283387..213a903 100644 --- a/doc/doxygen.cfg +++ b/doc/doxygen.cfg @@ -13,7 +13,6 @@ WARN_NO_PARAMDOC = YES INPUT = $(SRCDIR

[lng-odp] [PATCH 1/3] performance: pktio_perf: use PRIu32 to printf uint32_t

2015-06-09 Thread Nicolas Morey-Chaisemartin
Signed-off-by: Nicolas Morey-Chaisemartin nmo...@kalray.eu --- test/performance/odp_pktio_perf.c | 6 -- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/test/performance/odp_pktio_perf.c b/test/performance/odp_pktio_perf.c index 17975bf..6d9b66c 100644 --- a/test/performance

[lng-odp] [PATCH 0/3] Warning fixes

2015-06-09 Thread Nicolas Morey-Chaisemartin
Small patch series to remove compiler warnings on our system Nicolas Morey-Chaisemartin (3): performance: pktio_perf: use PRIu32 to printf uint32_t validation: packet: remove debug messages validation: system: manually cast char to int test/performance/odp_pktio_perf.c| 6

[lng-odp] [PATCH 3/3 v2] validation: system: manually cast char to int

2015-06-09 Thread Nicolas Morey-Chaisemartin
of system Signed-off-by: Nicolas Morey-Chaisemartin nmo...@kalray.eu --- test/validation/ver_abt_log_dbg/odp_system.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/test/validation/ver_abt_log_dbg/odp_system.c b/test/validation/ver_abt_log_dbg/odp_system.c index 1a40957..5185a71

[lng-odp] [PATCH 2/3] validation: packet: remove debug messages

2015-06-09 Thread Nicolas Morey-Chaisemartin
Signed-off-by: Nicolas Morey-Chaisemartin nmo...@kalray.eu --- test/validation/odp_packet.c | 2 -- 1 file changed, 2 deletions(-) diff --git a/test/validation/odp_packet.c b/test/validation/odp_packet.c index a363438..5915aba 100644 --- a/test/validation/odp_packet.c +++ b/test/validation

Re: [lng-odp] [PATCH 3/3] validation: system: manually cast char to int

2015-06-09 Thread Nicolas Morey-Chaisemartin
Please ignore this one (just posted v2). I broke the indentation while trying to understand the warning message :) On 06/09/2015 10:06 AM, Nicolas Morey-Chaisemartin wrote: On some systems, char is mapped to unsigned char which causes gcc to issue this warning: test/validation

Re: [lng-odp] [PATCH] doc: use only WITH_PLATFORM and not always linux-generic

2015-06-08 Thread Nicolas Morey-Chaisemartin
that it helps other platforms. On 5 June 2015 at 08:22, Nicolas Morey-Chaisemartin nmo...@kalray.eu mailto:nmo...@kalray.eu wrote: Signed-off-by: Nicolas Morey-Chaisemartin nmo...@kalray.eu mailto:nmo...@kalray.eu --- doc/doxygen.cfg | 1 - 1 file

[lng-odp] [PATCH] scripts: add dist dependency to git_hash.sh

2015-06-03 Thread Nicolas Morey-Chaisemartin
This forces automake to also copy the git_hash.sh script when running make distcheck Address bug https://bugs.linaro.org/show_bug.cgi?id=1603 Signed-off-by: Nicolas Morey-Chaisemartin nmo...@kalray.eu --- Makefile.am | 2 +- configure.ac| 1 + scripts/Makefile.am | 1 + 3 files

Re: [lng-odp] [PATCH] scripts: add dist dependency to git_hash.sh

2015-06-03 Thread Nicolas Morey-Chaisemartin
, Nicolas Morey-Chaisemartin nmo...@kalray.eu mailto:nmo...@kalray.eu wrote: This forces automake to also copy the git_hash.sh script when running make distcheck Address bug https://bugs.linaro.org/show_bug.cgi?id=1603 Signed-off-by: Nicolas Morey-Chaisemartin nmo

[lng-odp] [PATCH] example: use PRIx32 macro

2015-06-09 Thread Nicolas Morey-Chaisemartin
Also adds a check of sscanf return value to make checkpatch happy Signed-off-by: Nicolas Morey-Chaisemartin nmo...@kalray.eu --- example/classifier/odp_classifier.c | 6 -- example/timer/odp_timer_test.c | 3 ++- 2 files changed, 6 insertions(+), 3 deletions(-) diff --git a/example

Re: [lng-odp] [PATCH 2/2] example: use SCNx32/PRIx32 macro

2015-06-10 Thread Nicolas Morey-Chaisemartin
On 06/10/2015 02:20 PM, Maxim Uvarov wrote: On 06/10/15 15:06, Nicolas Morey-Chaisemartin wrote: /* Not the expected expiration tick, timer has * been reset or cancelled or freed */ -EXAMPLE_ABORT(Unexpected timeout received (timer %x, tick %PRIu64

[lng-odp] [PATCH 2/2] example: use SCNx32/PRIx32 macro

2015-06-10 Thread Nicolas Morey-Chaisemartin
Signed-off-by: Nicolas Morey-Chaisemartin nmo...@kalray.eu --- example/classifier/odp_classifier.c | 2 +- example/timer/odp_timer_test.c | 4 ++-- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/example/classifier/odp_classifier.c b/example/classifier/odp_classifier.c index

[lng-odp] [PATCH 1/2] example: classifier: check sscanf return code

2015-06-10 Thread Nicolas Morey-Chaisemartin
Signed-off-by: Nicolas Morey-Chaisemartin nmo...@kalray.eu --- example/classifier/odp_classifier.c | 6 -- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/example/classifier/odp_classifier.c b/example/classifier/odp_classifier.c index 48fc1ab..63678b7 100644 --- a/example

Re: [lng-odp] [PATCH] example: use PRIx32 macro

2015-06-10 Thread Nicolas Morey-Chaisemartin
Fixed and split into two patches so Mike is happier too ;) On 06/10/2015 12:18 PM, Maxim Uvarov wrote: On 06/09/15 17:26, Nicolas Morey-Chaisemartin wrote: Also adds a check of sscanf return value to make checkpatch happy Signed-off-by: Nicolas Morey-Chaisemartin nmo...@kalray.eu

Re: [lng-odp] [PATCH 2/2] example: use SCNx32/PRIx32 macro

2015-06-10 Thread Nicolas Morey-Chaisemartin
On 06/10/2015 02:32 PM, Maxim Uvarov wrote: On 06/10/15 15:26, Nicolas Morey-Chaisemartin wrote: On 06/10/2015 02:20 PM, Maxim Uvarov wrote: On 06/10/15 15:06, Nicolas Morey-Chaisemartin wrote: /* Not the expected expiration tick, timer has * been reset

Re: [lng-odp] [PATCH] example: use PRIx32 macro

2015-06-09 Thread Nicolas Morey Chaisemartin
The sscanf format is also changed. Because of this checkpatch was bothering me with the uncheck returned value so I squashed it in the same path. If you'd rather have two patches, I'll happily split it :) -- Nicolas Morey Chaisemartin Phone : +33 6 42 46 68 87 nmo...@kalray.eu KALRAY

Re: [lng-odp] [PATCH] scripts: add dist dependency to git_hash.sh

2015-06-04 Thread Nicolas Morey-Chaisemartin
. On 06/03/15 11:28, Nicolas Morey-Chaisemartin wrote: This forces automake to also copy the git_hash.sh script when running make distcheck Address bug https://bugs.linaro.org/show_bug.cgi?id=1603 Signed-off-by: Nicolas Morey-Chaisemartin nmo...@kalray.eu --- Makefile.am | 2

Re: [lng-odp] [PATCH 1/3] performance: pktio_perf: use PRIu32 to printf uint32_t

2015-06-09 Thread Nicolas Morey-Chaisemartin
’ expects argument of type ‘int’, but argument 2 has type ‘uint32_t’ [-Werror=format=] On 06/09/2015 02:02 PM, Maxim Uvarov wrote: On 06/09/15 11:06, Nicolas Morey-Chaisemartin wrote: -printf(\tTransmit batch length:\t%d\n, gbl_args-args.tx_batch_len); -printf(\tReceive batch length: \t%d

Re: [lng-odp] [PATCH 1/3] performance: pktio_perf: use PRIu32 to printf uint32_t

2015-06-09 Thread Nicolas Morey-Chaisemartin
, or should all the PRI.NN macros be padded with spaces? On 06/09/2015 10:06 AM, Nicolas Morey-Chaisemartin wrote: Signed-off-by: Nicolas Morey-Chaisemartin nmo...@kalray.eu --- test/performance/odp_pktio_perf.c | 6 -- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/test

Re: [lng-odp] [PATCH] linux-generic: buffer: reduce field size and reorder for better packing

2015-06-23 Thread Nicolas Morey-Chaisemartin
On 06/23/2015 03:17 PM, Ola Liljedahl wrote: }; } flags; - int type; /* buffer type */ - int event_type; /* for reuse as event */ + shortallocator; /*

[lng-odp] [PATCH] configurable binaries extension

2015-06-22 Thread Nicolas Morey-Chaisemartin
Add $(EXEEXT) to all binary generated so platform can easily configure the binaries extension and use the LOG_COMPILER features of automake. This should have no visible effect unless EXEEXT is set by the configure Signed-off-by: Nicolas Morey-Chaisemartin nmo...@kalray.eu --- configure.ac

[lng-odp] [PATCHv2] linux-generic: buffer: reduce field size and reorder for better packing

2015-06-25 Thread Nicolas Morey-Chaisemartin
odp_buffer_hdr_t was: /* size: 136, cachelines: 3, members: 15 */ /* sum members: 124, holes: 3, sum holes: 12 */ and is now: /* size: 120, cachelines: 2, members: 15 */ /* sum members: 116, holes: 1, sum holes: 4 */ Signed-off-by: Nicolas Morey-Chaisemartin nmo

[lng-odp] [PATCH] linux-generic: buffer: reduce field size and reorder for better packing

2015-06-22 Thread Nicolas Morey-Chaisemartin
odp_buffer_hdr_t was: /* size: 136, cachelines: 3, members: 15 */ /* sum members: 124, holes: 3, sum holes: 12 */ and is now: /* size: 120, cachelines: 2, members: 15 */ /* sum members: 116, holes: 1, sum holes: 4 */ Signed-off-by: Nicolas Morey-Chaisemartin nmo

[lng-odp] [PATCH] linux-generic: pool: remove double init

2015-06-12 Thread Nicolas Morey-Chaisemartin
Signed-off-by: Nicolas Morey-Chaisemartin nmo...@kalray.eu --- platform/linux-generic/odp_pool.c | 1 - 1 file changed, 1 deletion(-) diff --git a/platform/linux-generic/odp_pool.c b/platform/linux-generic/odp_pool.c index 35e79a0..c89012b 100644 --- a/platform/linux-generic/odp_pool.c +++ b

[lng-odp] [PATCHv2 2/3] checkpatch: remove line length limit for examples and tests log functions

2015-06-11 Thread Nicolas Morey-Chaisemartin
Signed-off-by: Nicolas Morey-Chaisemartin nmo...@kalray.eu --- scripts/checkpatch.pl | 2 ++ 1 file changed, 2 insertions(+) diff --git a/scripts/checkpatch.pl b/scripts/checkpatch.pl index 4bd7230..cee734a 100755 --- a/scripts/checkpatch.pl +++ b/scripts/checkpatch.pl @@ -365,6 +365,8 @@ our

[lng-odp] [PATCHv2 1/3] example: classifier: check sscanf return code

2015-06-11 Thread Nicolas Morey-Chaisemartin
Signed-off-by: Nicolas Morey-Chaisemartin nmo...@kalray.eu --- example/classifier/odp_classifier.c | 6 -- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/example/classifier/odp_classifier.c b/example/classifier/odp_classifier.c index 48fc1ab..63678b7 100644 --- a/example

[lng-odp] [PATCH] test: pktio_perf: add support for batch reception

2015-06-01 Thread Nicolas Morey-Chaisemartin
Signed-off-by: Nicolas Morey-Chaisemartin nmo...@kalray.eu --- test/performance/odp_pktio_perf.c | 72 +-- 1 file changed, 54 insertions(+), 18 deletions(-) diff --git a/test/performance/odp_pktio_perf.c b/test/performance/odp_pktio_perf.c index fbe27a0

Re: [lng-odp] [PATCH] test: pktio_perf: add support for batch reception

2015-06-02 Thread Nicolas Morey-Chaisemartin
On 06/02/2015 11:58 AM, Maxim Uvarov wrote: Btw, is odp_queue_deq faster than odp_queue_deq_multi for 1 packet? If not why do we need odp_queue_deq then? Maxim. From what I can see on our platform odp_schedule and odp_schedule_multi with num = 1 have the same performances. It seems that

[lng-odp] [PATCHv2] test: pktio_perf: add support for batch reception

2015-06-02 Thread Nicolas Morey-Chaisemartin
Signed-off-by: Nicolas Morey-Chaisemartin nmo...@kalray.eu --- v2: * Change default value of rx_batch_len to the same as tx_batch_len * Use odp_schedule_multi when Rx batching is enabled test/performance/odp_pktio_perf.c | 77 ++- 1 file changed, 59 insertions

[lng-odp] [PATCHv3] test: pktio_perf: add support for batch reception

2015-06-02 Thread Nicolas Morey-Chaisemartin
Signed-off-by: Nicolas Morey-Chaisemartin nmo...@kalray.eu --- v3: * Fix help for rxbatch option test/performance/odp_pktio_perf.c | 77 ++- 1 file changed, 59 insertions(+), 18 deletions(-) diff --git a/test/performance/odp_pktio_perf.c b/test/performance

[lng-odp] [PATCH 2/2] helper: linux: check pthread_join return code

2015-07-01 Thread Nicolas Morey-Chaisemartin
Signed-off-by: Nicolas Morey-Chaisemartin nmo...@kalray.eu --- helper/linux.c | 7 ++- 1 file changed, 6 insertions(+), 1 deletion(-) diff --git a/helper/linux.c b/helper/linux.c index be1ea13..2aa6835 100644 --- a/helper/linux.c +++ b/helper/linux.c @@ -139,10 +139,15 @@ int

[lng-odp] [PATCH 1/2] test: pktio_perf: fix pthread_t offset for tx threads

2015-07-01 Thread Nicolas Morey-Chaisemartin
Offset wrongly used num_tx_workers instead of num_rx_workers which caused threads to be badly joined. Without this patch: $./test/performance/odp_pktio_perf -c 3 Segmentation fault (core dumped) Signed-off-by: Nicolas Morey-Chaisemartin nmo...@kalray.eu --- test/performance

Re: [lng-odp] [PATCHv2 1/3] linux-generic: pktio: remove basic socket implementation

2015-07-01 Thread Nicolas Morey-Chaisemartin
for linux-generic than small a performance benefit. -Petri -Original Message- From: lng-odp [mailto:lng-odp-boun...@lists.linaro.org] On Behalf Of ext Maxim Uvarov Sent: Wednesday, July 01, 2015 3:09 PM To: Nicolas Morey-Chaisemartin; Stuart Haslam Cc: lng-odp@lists.linaro.org

[lng-odp] [PATCH 1/3] test: factor TESTS_ENVIRONMENT flags in Makefile.inc

2015-06-30 Thread Nicolas Morey-Chaisemartin
Signed-off-by: Nicolas Morey-Chaisemartin nmo...@kalray.eu --- helper/test/Makefile.am | 2 +- platform/linux-generic/test/Makefile.am | 3 ++- test/Makefile.inc | 2 ++ test/performance/Makefile.am| 2 +- 4 files changed, 6 insertions(+), 3

[lng-odp] [PATCH 3/3] test: suffix binaries with ${EXEEXT} in test scripts

2015-06-30 Thread Nicolas Morey-Chaisemartin
Signed-off-by: Nicolas Morey-Chaisemartin nmo...@kalray.eu --- platform/linux-generic/test/pktio/pktio_run | 6 +++--- test/performance/odp_l2fwd_run | 4 ++-- test/performance/odp_scheduling_run | 2 +- 3 files changed, 6 insertions(+), 6 deletions(-) diff --git a/platform

Re: [lng-odp] [PATCH 2/2] validation: packet: add segmented packet segment tests

2015-07-01 Thread Nicolas Morey-Chaisemartin
It does not apply anymore due to Christophe patches which moved odp_packet.c. Otherwise Reviewed and tested. On 06/25/2015 11:48 PM, Bill Fischofer wrote: Signed-off-by: Bill Fischofer bill.fischo...@linaro.org Extend segment tests to catch Bug https://bugs.linaro.org/show_bug.cgi?id=1661

Re: [lng-odp] [PATCH 1/3] test: factor TESTS_ENVIRONMENT flags in Makefile.inc

2015-07-03 Thread Nicolas Morey-Chaisemartin
/pltform/test/Makefile.am. Does this make sense for you? Would that fit you needs? On 3 July 2015 at 13:52, Nicolas Morey-Chaisemartin nmo...@kalray.eu mailto:nmo...@kalray.eu wrote: Maybe I can do it the other way around and put the common flags in the platform/plat/test/Makefile.am

Re: [lng-odp] [PATCHv2 3/3] test: pktio: reduce pools seg_len to test segmented packets

2015-07-03 Thread Nicolas Morey-Chaisemartin
In the end, how would you want me to test the support of segmented packets? On 07/02/2015 06:57 PM, Bill Fischofer wrote: If the requested seg_len exceeds ODP_CONFIG_PACKET_SEG_LEN_MAX the odp_pool_create() call will fail, so applications need to be mindful that implementations may have

Re: [lng-odp] [PATCHv2 1/3] linux-generic: pktio: remove basic socket implementation

2015-07-03 Thread Nicolas Morey-Chaisemartin
-Original Message- From: lng-odp [mailto:lng-odp-boun...@lists.linaro.org] On Behalf Of Maxim Uvarov Sent: Wednesday, July 01, 2015 5:39 PM To: Nicolas Morey-Chaisemartin; Stuart Haslam Cc: lng-odp@lists.linaro.org Subject: Re: [lng-odp] [PATCHv2 1/3] linux-generic: pktio: remove basic

Re: [lng-odp] [PATCH] linux-generic: pktio: replace linux/if.h by net/if.h

2015-07-02 Thread Nicolas Morey-Chaisemartin
On 07/02/2015 12:23 PM, Stuart Haslam wrote: On Thu, Jul 02, 2015 at 10:47:44AM +0200, Nicolas Morey-Chaisemartin wrote: Both linux/if.h and net/if.h were used but they are not necesseraly compatible and it is not possible to include both in the same file. Trying to understand the problem

[lng-odp] [PATCH] linux-generic: pktio: replace linux/if.h by net/if.h

2015-07-02 Thread Nicolas Morey-Chaisemartin
Both linux/if.h and net/if.h were used but they are not necesseraly compatible and it is not possible to include both in the same file. Signed-off-by: Nicolas Morey-Chaisemartin nmo...@kalray.eu --- platform/linux-generic/include/odp_packet_io_internal.h | 4 ++-- platform/linux-generic

Re: [lng-odp] [PATCH 1/2] test: pktio_perf: fix pthread_t offset for tx threads

2015-07-02 Thread Nicolas Morey-Chaisemartin
It may not segfault depending on what is on your stack at this point and in the pthread_t. Depending on #RX #Tx or the opposit, it eithers join a thread twice, or join an unitiliazed pthread_t. On 07/02/2015 11:18 AM, Maxim Uvarov wrote: On 07/01/15 16:40, Nicolas Morey-Chaisemartin wrote

Re: [lng-odp] [PATCH] configurable binaries extension

2015-06-29 Thread Nicolas Morey-Chaisemartin
With the validation tests being moved, I don't think this on applies anymore. I have another on ready to submit if you are interested On 06/29/2015 03:03 PM, Maxim Uvarov wrote: Anders, please take a look at this changes. Thanks, Maxim. On 06/22/15 13:06, Nicolas Morey-Chaisemartin wrote

[lng-odp] [PATCHv2] configurable binaries extension

2015-06-29 Thread Nicolas Morey-Chaisemartin
Add $(EXEEXT) to all binary generated so platform can easily configure the binaries extension and use the LOG_COMPILER features of automake. This should have no visible effect unless EXEEXT is set by the configure Signed-off-by: Nicolas Morey-Chaisemartin nmo...@kalray.eu --- Updated to apply

Re: [lng-odp] odp items for discussion

2015-06-29 Thread Nicolas Morey-Chaisemartin
We have the same kind of issue with our port. We don't want (more precisely cannot for the moment) more than a thread per core. The way we handled it is by tweaking the implementation of cpu_count and the default_mask to ignore the first core (which is running the main). It would make sense to

Re: [lng-odp] [PATCH] validation: scheduler run cpu_num - 1 worker threads

2015-06-29 Thread Nicolas Morey-Chaisemartin
I'm fine with this but why should it only be for this test and not all of them? On 06/29/2015 06:09 PM, Maxim Uvarov wrote: Use first cpu as control thread to run workers. And all other cpus for workers run with pthread_create. If needed to run something on current core it has to be run

Re: [lng-odp] [PATCHv2 3/3] test: pktio: reduce pools seg_len to test segmented packets

2015-07-06 Thread Nicolas Morey-Chaisemartin
On 07/03/2015 04:54 PM, Maxim Uvarov wrote: On 07/03/15 16:08, Nicolas Morey-Chaisemartin wrote: In the end, how would you want me to test the support of segmented packets? because we can not destroy pool (on some platfroms it's leaked). Then the only option is to create separate

Re: [lng-odp] [RFC 00/15] Add and use a generic pktio interface for all implementation

2015-07-06 Thread Nicolas Morey-Chaisemartin
On 07/06/2015 12:10 AM, Mike Holmes wrote: Agree, 15 patches is right on the need to do a pull request from your repo to keep it manageable. It starts with a bit of cleanup and reorganizing functions in different files, What is the right way to make a pull request for ODP? Should I just

[lng-odp] [RFC 02/15] checkpatch: remove check for potential ether_addr_copy

2015-07-03 Thread Nicolas Morey-Chaisemartin
Signed-off-by: Nicolas Morey-Chaisemartin nmo...@kalray.eu --- scripts/checkpatch.pl | 10 -- 1 file changed, 10 deletions(-) diff --git a/scripts/checkpatch.pl b/scripts/checkpatch.pl index 00d30b2..4983a0c 100755 --- a/scripts/checkpatch.pl +++ b/scripts/checkpatch.pl @@ -5035,16

[lng-odp] [RFC 06/15] linux-generic: packet_loop: add method to get mac address

2015-07-03 Thread Nicolas Morey-Chaisemartin
Signed-off-by: Nicolas Morey-Chaisemartin nmo...@kalray.eu --- platform/linux-generic/include/odp_packet_io_internal.h | 1 + platform/linux-generic/odp_packet_io.c | 8 +++- platform/linux-generic/odp_packet_loop.c| 8 3 files changed, 12 insertions

[lng-odp] [RFC 05/15] linux-generic: packet_loop: add function get MTU

2015-07-03 Thread Nicolas Morey-Chaisemartin
Signed-off-by: Nicolas Morey-Chaisemartin nmo...@kalray.eu --- platform/linux-generic/include/odp_packet_io_internal.h | 1 + platform/linux-generic/odp_packet_io.c | 4 +--- platform/linux-generic/odp_packet_loop.c| 8 3 files changed, 10 insertions

[lng-odp] [RFC 13/15] linux-generic: packet_io: promisc_mode_get methods for all pktio_socks

2015-07-03 Thread Nicolas Morey-Chaisemartin
Add temporarly function definitions to odp_packet_io_internal.h instead of odp_packet_socket.h to obtain pktio_entry_t definition Signed-off-by: Nicolas Morey-Chaisemartin nmo...@kalray.eu --- .../linux-generic/include/odp_packet_io_internal.h | 4 ++ platform/linux-generic/include

[lng-odp] [RFC 10/15] linux-generic: packet_io: add mtu_get methods for all pktio_socks

2015-07-03 Thread Nicolas Morey-Chaisemartin
Add temporarly function definitions to odp_packet_io_internal.h instead of odp_packet_socket.h to obtain pktio_entry_t definition Signed-off-by: Nicolas Morey-Chaisemartin nmo...@kalray.eu --- .../linux-generic/include/odp_packet_io_internal.h | 4 +++ platform/linux-generic/include

[lng-odp] [RFC 14/15] linux-generic: packet_io: packet_sock_* self closes on error during setup

2015-07-03 Thread Nicolas Morey-Chaisemartin
Signed-off-by: Nicolas Morey-Chaisemartin nmo...@kalray.eu --- platform/linux-generic/odp_packet_io.c | 6 platform/linux-generic/odp_packet_socket.c | 31 +- platform/linux-generic/odp_packet_socket_mmap.c | 42 ++--- 3 files changed, 39

[lng-odp] [RFC 04/15] linux-generic: packet_io: move loopback to another file

2015-07-03 Thread Nicolas Morey-Chaisemartin
Signed-off-by: Nicolas Morey-Chaisemartin nmo...@kalray.eu --- platform/linux-generic/Makefile.am | 1 + .../linux-generic/include/odp_packet_io_internal.h | 6 ++ platform/linux-generic/odp_packet_io.c | 52 + platform/linux-generic/odp_packet_loop.c

[lng-odp] [RFC 01/15] linux-generic: pktio: replace linux/if.h by net/if.h

2015-07-03 Thread Nicolas Morey-Chaisemartin
Both linux/if.h and net/if.h were used but they are not necesseraly compatible and it is not possible to include both in the same file. Signed-off-by: Nicolas Morey-Chaisemartin nmo...@kalray.eu --- platform/linux-generic/include/odp_packet_io_internal.h | 4 ++-- platform/linux-generic

[lng-odp] [RFC 08/15] linux-generic: packet_loop: add method for setting promisc mode

2015-07-03 Thread Nicolas Morey-Chaisemartin
Signed-off-by: Nicolas Morey-Chaisemartin nmo...@kalray.eu --- platform/linux-generic/include/odp_packet_io_internal.h | 1 + platform/linux-generic/odp_packet_io.c | 2 +- platform/linux-generic/odp_packet_loop.c| 6 ++ 3 files changed, 8 insertions(+), 1

[lng-odp] [RFC 09/15] linux-generic: packet_pool: add method to get promisc mode

2015-07-03 Thread Nicolas Morey-Chaisemartin
Signed-off-by: Nicolas Morey-Chaisemartin nmo...@kalray.eu --- platform/linux-generic/include/odp_packet_io_internal.h | 1 + platform/linux-generic/odp_packet_io.c | 2 +- platform/linux-generic/odp_packet_loop.c| 5 + 3 files changed, 7 insertions(+), 1

[lng-odp] [RFC 07/15] linux-generic: packet_loop: add method to close a loopback pktio

2015-07-03 Thread Nicolas Morey-Chaisemartin
Signed-off-by: Nicolas Morey-Chaisemartin nmo...@kalray.eu --- platform/linux-generic/include/odp_packet_io_internal.h | 1 + platform/linux-generic/odp_packet_io.c | 2 +- platform/linux-generic/odp_packet_loop.c| 5 + 3 files changed, 7 insertions(+), 1

[lng-odp] [RFC 11/15] linux-generic: packet_io: add mac_addr_get methods for all pktio_socks

2015-07-03 Thread Nicolas Morey-Chaisemartin
Add temporarly function definitions to odp_packet_io_internal.h instead of odp_packet_socket.h to obtain pktio_entry_t definition Signed-off-by: Nicolas Morey-Chaisemartin nmo...@kalray.eu --- platform/linux-generic/include/odp_packet_io_internal.h | 4 platform/linux-generic

[lng-odp] [RFC 15/15] linux-generic: packet_io: use generic interface for all pktio implementations

2015-07-03 Thread Nicolas Morey-Chaisemartin
...@kalray.eu Signed-off-by: Nicolas Morey-Chaisemartin nmo...@kalray.eu --- platform/linux-generic/Makefile.am | 1 + .../linux-generic/include/odp_packet_io_internal.h | 52 +++ platform/linux-generic/include/odp_packet_socket.h | 38 - platform/linux-generic/odp_packet_io.c

[lng-odp] [RFC 00/15] Add and use a generic pktio interface for all implementation

2015-07-03 Thread Nicolas Morey-Chaisemartin
to the new function pointer interface Nicolas Morey-Chaisemartin (15): linux-generic: pktio: replace linux/if.h by net/if.h checkpatch: remove check for potential ether_addr_copy linux-generic: packet_socket: move socket_mmap to another file linux-generic: packet_io: move loopback

[lng-odp] [RFC 03/15] linux-generic: packet_socket: move socket_mmap to another file

2015-07-03 Thread Nicolas Morey-Chaisemartin
Signed-off-by: Nicolas Morey-Chaisemartin nmo...@kalray.eu --- platform/linux-generic/Makefile.am | 1 + platform/linux-generic/include/odp_packet_socket.h | 13 + platform/linux-generic/odp_packet_socket.c | 484 platform/linux-generic

[lng-odp] [RFC 12/15] linux-generic: packet_io: promisc_mode_set methods for all pktio_socks

2015-07-03 Thread Nicolas Morey-Chaisemartin
Add temporarly function definitions to odp_packet_io_internal.h instead of odp_packet_socket.h to obtain pktio_entry_t definition Signed-off-by: Nicolas Morey-Chaisemartin nmo...@kalray.eu --- .../linux-generic/include/odp_packet_io_internal.h | 4 ++ platform/linux-generic/include

Re: [lng-odp] [RFC 15/15] linux-generic: packet_io: use generic interface for all pktio implementations

2015-07-03 Thread Nicolas Morey-Chaisemartin
On 07/03/2015 12:22 PM, Maxim Uvarov wrote: On 07/03/15 10:06, Nicolas Morey-Chaisemartin wrote: In that patch I would name all functions with same prefix, then postfix. Like loopback_mac_addr_get(). In that case function will be close to each other when you do search by tags. Maxim

  1   2   3   4   5   6   >