[PATCH v2 0/8] net/tcp: Fix several bugs and allow rttcp to be built

2018-11-06 Thread Sebastian Smolorz via Xenomai
This patch series makes RTnet's tcp module usable again. It was not working due to several bugs which showed up in combination with reworked RTDM of Xenomai 3. Tests on real hardware (little endian) were successful. A test on big endian is still pending. Sebastian Smolorz (8): net/tcp: return u

[PATCH v2 5/8] net/tcp: fix TCP connection termination

2018-11-06 Thread Sebastian Smolorz via Xenomai
Closing a connected TCP socket initiates a handshake procedure. The closing socket is supposed to receive two more packets and send one ACK at the end. RTnet's TCP stack tries to get a reference to a socket before writing data to its buffer. Taking a reference to an RTnet socket in Xenomai 3 is rea

[PATCH v2 3/8] net/tcp: Fix bug when obtaining RST socket's private structure from its rtdm_fd pointer

2018-11-06 Thread Sebastian Smolorz via Xenomai
Signed-off-by: Sebastian Smolorz --- kernel/drivers/net/stack/ipv4/tcp/tcp.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/kernel/drivers/net/stack/ipv4/tcp/tcp.c b/kernel/drivers/net/stack/ipv4/tcp/tcp.c index 8605a8c..2678e6a 100644 --- a/kernel/drivers/net/stack/ipv4/tcp

[PATCH v2 6/8] net/tcp: Set valid flags in struct tcphdr on little and big endian machines

2018-11-06 Thread Sebastian Smolorz via Xenomai
Setting TCP header flags like ACK was fragile and not working when RTnet was running on big endian processors. Use the macro provided by the linux kernel for setting the TCP flags instead. Signed-off-by: Sebastian Smolorz --- kernel/drivers/net/stack/ipv4/tcp/tcp.c | 9 + 1 file changed,

[PATCH v2 1/8] net/tcp: return ufd in rt_tcp_accept()

2018-11-06 Thread Sebastian Smolorz via Xenomai
Fix compilation error in rt_tcp_accept() when returning its socket's own file descriptor. Signed-off-by: Sebastian Smolorz --- kernel/drivers/net/stack/ipv4/tcp/tcp.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/kernel/drivers/net/stack/ipv4/tcp/tcp.c b/kernel/drivers/net

[PATCH v2 8/8] net/tcp: Allow choice of rttcp protocol in Kconfig

2018-11-06 Thread Sebastian Smolorz via Xenomai
Signed-off-by: Sebastian Smolorz --- kernel/drivers/net/stack/ipv4/Kconfig | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/kernel/drivers/net/stack/ipv4/Kconfig b/kernel/drivers/net/stack/ipv4/Kconfig index fef7e19..8fb3c1a 100644 --- a/kernel/drivers/net/stack/ipv4/Kconfig +

[PATCH v2 7/8] net/tcp: return already copied number of bytes to recv() callers when peer socket terminates

2018-11-06 Thread Sebastian Smolorz via Xenomai
In the following situation a recv() call to a RT-TCP socket returned 0 although there was data already copied to the caller's buffer: - S1 connects to S2 - S1 calls recv() with buffer size b1 - S2 sends data of size b2 < b1 - S1 receives the data, copies it to its buffer and waits for more data -

[PATCH v2 2/8] net/tcp: fix listen() and shutdown() IOCTL calls

2018-11-06 Thread Sebastian Smolorz via Xenomai
listen() and shutdown() pass their simple int argument directly casted to void *arg, not as a pointer to their value. Signed-off-by: Sebastian Smolorz --- kernel/drivers/net/stack/ipv4/tcp/tcp.c | 12 ++-- 1 file changed, 2 insertions(+), 10 deletions(-) diff --git a/kernel/drivers/net/

[PATCH v2 4/8] net/tcp: Copy data back to user buffer in rt_tcp_recvmsg

2018-11-06 Thread Sebastian Smolorz via Xenomai
A bug in rt_tcp_recvmsg() prevented an application to receive data over an RTTCP socket. Data was not copied back to the application's buffer but rather into a temporary kernel buffer. Signed-off-by: Sebastian Smolorz --- kernel/drivers/net/stack/ipv4/tcp/tcp.c | 13 +++-- 1 file changed

Re: [PATCH 0/4] net/tcp: Fix several bugs and allow rttcp to be built

2018-11-06 Thread Sebastian Smolorz via Xenomai
Hi Phong, Sebastian Smolorz wrote: > Pham, Phong wrote: > > Hi Sebastian, > > > > " Phong, can you test this on your machine?" > > No the fix does not work. It overwrites the window field. > > Did you try the patch I sent here? > > https://www.xenomai.org/pipermail/xenomai/2018-November/039831.ht

[PATCH] debian: Add config folder to xenomai-kernel-source

2018-11-06 Thread Jan Kiszka via Xenomai
Meanwhile required for prepare-kernel.sh. Signed-off-by: Jan Kiszka --- debian/rules | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/debian/rules b/debian/rules index 8b871a4882..99ed8982ce 100755 --- a/debian/rules +++ b/debian/rules @@ -73,7 +73,7 @@ install: build

Re: Debian packages for Xenomai 3.x

2018-11-06 Thread Jan Kiszka via Xenomai
On 30.11.17 12:27, Leopold Palomo-Avellaneda wrote: > Hi, > > > if someone is interested I have been working a bit with the debian directory > in > xenomai3. > > I have changed the approach to the libraries. I think that now it has not > sense > to have a libxenomai1 so I have changed it to xe

Re: Segmentation error 6 in rt_heap_create() without --enable-pshared

2018-11-06 Thread Jan Kiszka via Xenomai
On 05.11.18 16:48, Petr Červenka wrote: >> Only? Sorry for insisting, but it may help to reduce the search space, and >> it's >> also important as I'd like to release a new stable version - without known >> issues. > > >> Thanks, >> Jan > > >   > I can confirm now, that the problem happens onl

[PATCH] debian: Enable SMP in userspace package

2018-11-06 Thread Jan Kiszka via Xenomai
Hard to find a UP target these days, and we definitely want to be generic with Debian packages. Signed-off-by: Jan Kiszka --- debian/rules | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/debian/rules b/debian/rules index 99ed8982ce..883ae3ed8c 100755 --- a/debian/rules +++

Re: [PATCH v2 4/8] net/tcp: Copy data back to user buffer in rt_tcp_recvmsg

2018-11-06 Thread Jan Kiszka via Xenomai
On 06.11.18 11:00, Sebastian Smolorz via Xenomai wrote: > A bug in rt_tcp_recvmsg() prevented an application to receive data > over an RTTCP socket. Data was not copied back to the application's > buffer but rather into a temporary kernel buffer. > > Signed-off-by: Sebastian Smolorz > --- > kern

RE: [PATCH 0/4] net/tcp: Fix several bugs and allow rttcp to be built

2018-11-06 Thread Pham, Phong via Xenomai
Hi Sebastian, Your patch (fixing TCP flags endianness issue) does work. (I was under the impression to use tcp_flag_word and fix it in rt_tcp_set_flags() which I reported doesn't work earlier.) Phong. -Original Message- From: Sebastian Smolorz [mailto:sebastian.smol...@gmx.de] Sent:

Re: Kernel oops during rtnet loopback usage on x86_64 (e1000e)

2018-11-06 Thread Jan Kiszka via Xenomai
On 04.11.18 17:17, Philippe Gerum wrote: > On 6/21/18 4:57 PM, Jan Kiszka wrote: >> On 2018-06-21 15:41, Jan Kiszka wrote: >>> On 2018-06-21 13:55, Jan Kiszka wrote: On 2018-06-21 13:20, Pintu Kumar wrote: > Dear Jan, Greg, > > Is there any pointer about this issue? > This is b

[RFC] xenomai-images: test and demo image generator

2018-11-06 Thread Jan Kiszka via Xenomai
Hi all, as I was (and still am) in the need to test also non-x86 from time to time, I hacked up a little framework for generating bootable Debian images with Xenomai pre-installed. It's currently hosted on my personal github space: https://github.com/jan-kiszka/xenomai-images I think we should m

Re: [RFC] xenomai-images: test and demo image generator

2018-11-06 Thread Greg Gallagher via Xenomai
This looks really good. How easy is it to add more targets? I looked at the jailhouse-images commits to see how to add a board, is that a good place to start to see how to add a new board? -Greg On Tue, Nov 6, 2018 at 1:58 PM Jan Kiszka via Xenomai wrote: > > Hi all, > > as I was (and still am

Re: [PATCH 0/4] net/tcp: Fix several bugs and allow rttcp to be built

2018-11-06 Thread Sebastian Smolorz via Xenomai
Hi Phong, Pham, Phong wrote: > Hi Sebastian, > > Your patch (fixing TCP flags endianness issue) does work. Great, thanks for testing. -- Sebastian > (I was > under the impression to use tcp_flag_word and fix it in > rt_tcp_set_flags() which I reported doesn't work earlier.) > Phong. > > -O

Re:32bit on 64bit in xenomai 2.6.0

2018-11-06 Thread Manikanta Mylavarapu via Xenomai
Dear all, I am trying to run 32bit applications on 64bit xenomai. I installed xenomai 2.6.0 on fedora 13 x86_64. I installed all 32bit GCC lib & c librarys (glibc-devel.i686 & going.i686). I made one hello world sample (non-rt) app, it is giving error while running "-bash: ./a.out: cannot execut

Re: [RFC] xenomai-images: test and demo image generator

2018-11-06 Thread Jan Kiszka via Xenomai
On 06.11.18 20:28, Greg Gallagher wrote: > This looks really good. How easy is it to add more targets? I looked > at the jailhouse-images commits to see how to add a board, is that a > good place to start to see how to add a new board? > Yes, it is. But I'll likely commit at least one real exam

Re: 32bit on 64bit in xenomai 2.6.0

2018-11-06 Thread Jan Kiszka via Xenomai
On 07.11.18 07:15, Manikanta Mylavarapu via Xenomai wrote: > Dear all, > > I am trying to run 32bit applications on 64bit xenomai. I installed xenomai > 2.6.0 on fedora 13 x86_64. I installed all 32bit GCC lib & c librarys > (glibc-devel.i686 & going.i686). > > I made one hello world sample (non-

Re: 32bit on 64bit in xenomai 2.6.0

2018-11-06 Thread Manikanta Mylavarapu via Xenomai
Thank you Jan. For my project requirement I am working with xenomai 2.6.0 on fedora 13. My doubt is at least sample app compiled as a 32bit exe on 64bit kernel should work. But it is not running on xenomai patched 64bit os,why? On Wed, Nov 7, 2018, 12:13 PM Jan Kiszka wrote: > On 07.11.18 07:1

Re: [RFC] xenomai-images: test and demo image generator

2018-11-06 Thread Jan Kiszka via Xenomai
On 07.11.18 07:37, Jan Kiszka wrote: > On 06.11.18 20:28, Greg Gallagher wrote: >> This looks really good. How easy is it to add more targets? I looked >> at the jailhouse-images commits to see how to add a board, is that a >> good place to start to see how to add a new board? >> > > Yes, it is.