Re: [Qemu-devel] [PATCH RFC 1/4] slirp: add helper for tcp6 socket creation

2018-10-30 Thread Samuel Thibault
Maxim Samoylov, le mar. 30 oct. 2018 16:58:17 +0300, a ecrit: > On 27.10.2018 14:11, Samuel Thibault wrote: > > Is there a reason why you set SO_OOBINLINE, but not TCP_NODELAY? That's > > the kind of discrepancy we don't want to let unseen, thus the reason for > > a shared implementation :) > >

Re: [Qemu-devel] [PATCH RFC 1/4] slirp: add helper for tcp6 socket creation

2018-10-30 Thread Maxim Samoylov
On 27.10.2018 14:11, Samuel Thibault wrote: Hello, Thanks for working on this! Hi! I preferred to make this RFC simple and straightforward with dumb code duplication because I wasn't sure if the feature is useful for upstream at all :) I will then unify v4 and v6 implementations as you

Re: [Qemu-devel] [PATCH RFC 1/4] slirp: add helper for tcp6 socket creation

2018-10-27 Thread Samuel Thibault
Samuel Thibault, le sam. 27 oct. 2018 13:11:41 +0200, a ecrit: > struct socket * > tcp_listen(Slirp *slirp, uint32_t haddr, u_int hport, uint32_t laddr, >u_int lport, int flags) > { > struct sockaddr_in addr; > struct socket *so; > socklen_t addrsize = sizeof(addr);

Re: [Qemu-devel] [PATCH RFC 1/4] slirp: add helper for tcp6 socket creation

2018-10-27 Thread Samuel Thibault
Hello, Thanks for working on this! There is a lot of overlap with tcp_listen. It'd be much better to refactor it this way: struct socket * tcpx_listen(Slirp *slirp, struct sockaddr *addr, socklen_t *addrlen, int flags) { ... The current content of tcp_listen, with all heading and