Re: [PATCH 5/5] cobalt/sched: weak: add early parameter checking handler

2019-01-24 Thread Jan Kiszka via Xenomai
On 29.11.18 14:54, Philippe Gerum via Xenomai wrote: This is actually a plain conversion of the former sched_declare() handler to the recently introduced sched_chkparam(), which only checks the weak scheduling parameters. By doing so, we ensure that those checks are done early and

Re: [PATCH 4/9] cobalt/ancillaries: prevent false positive with -Wstringop-truncation

2019-01-24 Thread Jan Kiszka via Xenomai
On 26.10.18 16:08, Philippe Gerum wrote: knamecpy() is meant to copying NUL terminated strings even if this incurs potential truncation of the source argument if need be, prevent GCC 8.x from detecting a false positive when -Wstringop-truncation is in effect. ---

Re: [PATCH 4/5] drivers/ipc: bufp: fix read-write, write-write preemption cases

2019-01-24 Thread Jan Kiszka via Xenomai
On 14.01.19 18:35, Philippe Gerum wrote: The token-based approach for detecting preemption while data is being moved into or out of the ring only protects from read vs read races, not from races involving a write side. For instance, a reader might read dirty data being changed by a writer

Re: [PATCH 06/12] net/rtdev: ensure per-device skbs get mapped at registration

2019-01-24 Thread Jan Kiszka via Xenomai
On 24.01.19 16:34, Philippe Gerum wrote: This patch works around a regression introduced by #74464ee37d0, causing a new device's skbs not to be passed to its ->map_rtskb() handler when registered, breaking further DMA inits in the driver. Signed-off-by: Philippe Gerum ---

Re: [PATCH 05/12] net/stack: fresh rtskb should have ip_summed set to CHECKSUM_NONE

2019-01-24 Thread Jan Kiszka via Xenomai
Cleanup or fix? I agree with the change, but if it's a fix, it should also go into stable. On 24.01.19 16:34, Philippe Gerum wrote: Signed-off-by: Philippe Gerum --- kernel/drivers/net/stack/rtskb.c | 1 + 1 file changed, 1 insertion(+) diff --git a/kernel/drivers/net/stack/rtskb.c

Re: [PATCH 02/12] drivers/gpio: provide optional timestamped readouts

2019-01-24 Thread Jan Kiszka via Xenomai
On 24.01.19 16:34, Philippe Gerum wrote: In timestamping mode, read() returns the timestamp of the latest event receipt on the pin based on CLOCK_MONOTONIC, along with the pin state. This is an optional pin readout mode controlled by the GPIO_RTIOC_TS request, e.g.: struct rtdm_gpio_readout

Re: [PATCH 00/12] Assorted updates: RTnet, GPIO, smokey tests

2019-01-24 Thread Jan Kiszka via Xenomai
On 24.01.19 16:34, Philippe Gerum wrote: Patch 1 addresses the issue in the posix_clock fix as discussed in And I'm still seeing a 100% identical patch and commit log... [1]. Patch 6 works around a recent regression in RTnet as mentioned in [2] (tested with the IGB driver which implements a

Debugging system freeze, SIGXCPU

2019-01-24 Thread Ari Mozes via Xenomai
I am new to Xenomai and trying to troubleshoot a repeatable Linux freeze I was experiencing (nothing in the system logs I could find, unresponsive to any keystrokes like REISUB, etc.) I then switched from cobalt 3.0.7 running on Linux 4.4.71 to cobalt 3.0.8 on 4.14.89, but the problem remained.

[PATCH 10/12] testsuite/smokey: net: do not down a previously running test interface

2019-01-24 Thread Philippe Gerum via Xenomai
If the test interface is already up on entry, keep it that way on exit, so that we may run this test multiple times without having to reconfigure. Signed-off-by: Philippe Gerum --- testsuite/smokey/net_common/setup.c | 11 +++ 1 file changed, 7 insertions(+), 4 deletions(-) diff --git

[PATCH 12/12] testsuite/smokey: net_client: improve stats readability

2019-01-24 Thread Philippe Gerum via Xenomai
Visibale with --verbose=2. Signed-off-by: Philippe Gerum --- testsuite/smokey/net_common/client.c | 26 -- 1 file changed, 16 insertions(+), 10 deletions(-) diff --git a/testsuite/smokey/net_common/client.c b/testsuite/smokey/net_common/client.c index

[PATCH 08/12] net/udp: getfrag: remove direct reference to user memory

2019-01-24 Thread Philippe Gerum via Xenomai
This issue triggers domain violation on ARM, SMAP violation on x86. Signed-off-by: Philippe Gerum --- kernel/drivers/net/stack/ipv4/udp/udp.c | 15 +++ 1 file changed, 7 insertions(+), 8 deletions(-) diff --git a/kernel/drivers/net/stack/ipv4/udp/udp.c

[PATCH 04/12] net/stack: allow initializing pre-allocated device structs

2019-01-24 Thread Philippe Gerum via Xenomai
We may want to embed struct rtnet_device into a pre-allocated parent container struct, which makes rtdev_alloc() and rt_alloc_etherdev() useless for the purpose. The new rtdev_init() and rt_init_etherdev() calls can be used to initialize a pre-allocated device structure and set it up with default

[PATCH 06/12] net/rtdev: ensure per-device skbs get mapped at registration

2019-01-24 Thread Philippe Gerum via Xenomai
This patch works around a regression introduced by #74464ee37d0, causing a new device's skbs not to be passed to its ->map_rtskb() handler when registered, breaking further DMA inits in the driver. Signed-off-by: Philippe Gerum --- kernel/drivers/net/stack/rtdev.c | 37

[PATCH 01/12] testsuite/smokey: posix_clock: prevent false positive in time-dependent test

2019-01-24 Thread Philippe Gerum via Xenomai
clock_decrease_after_periodic_timer_first_tick checks that periodic interval timers based on CLOCK_REALTIME are not (pathologically) affected by the epoch going backwards. To this end, we measure the actual time observed between two ticks of a periodic timer based on CLOCK_REALTIME with a call to

[PATCH 03/12] testsuite/gpiotest: enable timestamping on 'timestamp' argument

2019-01-24 Thread Philippe Gerum via Xenomai
Signed-off-by: Philippe Gerum --- testsuite/gpiotest/gpiotest.c | 37 +++ 1 file changed, 29 insertions(+), 8 deletions(-) diff --git a/testsuite/gpiotest/gpiotest.c b/testsuite/gpiotest/gpiotest.c index 3c8c6c318..7347ac506 100644 ---

[PATCH 05/12] net/stack: fresh rtskb should have ip_summed set to CHECKSUM_NONE

2019-01-24 Thread Philippe Gerum via Xenomai
Signed-off-by: Philippe Gerum --- kernel/drivers/net/stack/rtskb.c | 1 + 1 file changed, 1 insertion(+) diff --git a/kernel/drivers/net/stack/rtskb.c b/kernel/drivers/net/stack/rtskb.c index f5609027b..cc7563719 100644 --- a/kernel/drivers/net/stack/rtskb.c +++

[PATCH 02/12] drivers/gpio: provide optional timestamped readouts

2019-01-24 Thread Philippe Gerum via Xenomai
In timestamping mode, read() returns the timestamp of the latest event receipt on the pin based on CLOCK_MONOTONIC, along with the pin state. This is an optional pin readout mode controlled by the GPIO_RTIOC_TS request, e.g.: struct rtdm_gpio_readout rdo; int ret, on, val; on = 1; ret =

[PATCH 00/12] Assorted updates: RTnet, GPIO, smokey tests

2019-01-24 Thread Philippe Gerum via Xenomai
Patch 1 addresses the issue in the posix_clock fix as discussed in [1]. Patch 6 works around a recent regression in RTnet as mentioned in [2] (tested with the IGB driver which implements a map_rtskb handler). Both commits are also -stable candidates. A couple of other changes extend the GPIO