Re: [PATCH 00/18] xfrm: Add compat layer

2018-07-30 Thread Florian Westphal
Dmitry Safonov wrote: > On Sat, 2018-07-28 at 14:18 -0700, David Miller wrote: > > From: Dmitry Safonov > > Date: Sat, 28 Jul 2018 17:26:55 +0100 > > > > > Well, I think, I'll rework my patches set according to critics and > > > separate compat xfrm layer. I've already a selftest to check that

Re: [PATCH 00/18] xfrm: Add compat layer

2018-07-30 Thread Dmitry Safonov
On Sat, 2018-07-28 at 14:18 -0700, David Miller wrote: > From: Dmitry Safonov > Date: Sat, 28 Jul 2018 17:26:55 +0100 > > > Well, I think, I'll rework my patches set according to critics and > > separate compat xfrm layer. I've already a selftest to check that > 32/64 > > bit xfrm works - so the

Re: [PATCH 00/18] xfrm: Add compat layer

2018-07-28 Thread David Miller
From: Dmitry Safonov Date: Sat, 28 Jul 2018 17:26:55 +0100 > Well, I think, I'll rework my patches set according to critics and > separate compat xfrm layer. I've already a selftest to check that 32/64 > bit xfrm works - so the most time-taking part is done. The way you've done the compat

Re: [PATCH 00/18] xfrm: Add compat layer

2018-07-28 Thread Dmitry Safonov
On Fri, 2018-07-27 at 09:48 -0700, Nathan Harold wrote: > We (Android) are very interested in removing the restriction for 32- > bit userspace processes accessing xfrm netlink on 64-bit kernels. > IPsec support is required to pass Android conformance tests, and any > manufacturer wishing to ship

Re: [PATCH 00/18] xfrm: Add compat layer

2018-07-27 Thread Andy Lutomirski
> On Jul 27, 2018, at 9:48 AM, Nathan Harold wrote: > > We (Android) are very interested in removing the restriction for 32-bit > userspace processes accessing xfrm netlink on 64-bit kernels. IPsec support > is required to pass Android conformance tests, and any manufacturer wishing > to

Re: [PATCH 00/18] xfrm: Add compat layer

2018-07-27 Thread Nathan Harold
*We (Android) are very interested in removing the restriction for 32-bit userspace processes accessing xfrm netlink on 64-bit kernels. IPsec support is required to pass Android conformance tests, and any manufacturer wishing to ship 32-bit userspace with a recent kernel needs out-of-tree changes

Re: [PATCH 00/18] xfrm: Add compat layer

2018-07-27 Thread Dmitry Safonov
On Fri, 2018-07-27 at 16:19 +0200, Florian Westphal wrote: > Dmitry Safonov wrote: > > 1. It will double copy netlink messages, making it O(n) instead of > > O(1), where n - is number of bind()s.. Probably we don't care much. > > About those bind() patches, I don't understand why they are

Re: [PATCH 00/18] xfrm: Add compat layer

2018-07-27 Thread Florian Westphal
Dmitry Safonov wrote: > 1. It will double copy netlink messages, making it O(n) instead of > O(1), where n - is number of bind()s.. Probably we don't care much. About those bind() patches, I don't understand why they are needed. Why can't you just add the compat skb to the native skb when doing

Re: [PATCH 00/18] xfrm: Add compat layer

2018-07-27 Thread Dmitry Safonov
On Fri, 2018-07-27 at 09:37 +0200, Steffen Klassert wrote: > On Thu, Jul 26, 2018 at 10:49:59AM +0200, Florian Westphal wrote: > > Dmitry Safonov wrote: > > > So, here I add a compatible layer to xfrm. > > > As xfrm uses netlink notifications, kernel should send them in > > > ABI > > > format

Re: [PATCH 00/18] xfrm: Add compat layer

2018-07-27 Thread Steffen Klassert
On Thu, Jul 26, 2018 at 10:49:59AM +0200, Florian Westphal wrote: > Dmitry Safonov wrote: > > So, here I add a compatible layer to xfrm. > > As xfrm uses netlink notifications, kernel should send them in ABI > > format that an application will parse. The proposed solution is > > to save the ABI

Re: [PATCH 00/18] xfrm: Add compat layer

2018-07-26 Thread Florian Westphal
Dmitry Safonov wrote: > So, here I add a compatible layer to xfrm. > As xfrm uses netlink notifications, kernel should send them in ABI > format that an application will parse. The proposed solution is > to save the ABI of bind() syscall. The realization detail is > to create kernel-hidden, non

[PATCH 00/18] xfrm: Add compat layer

2018-07-25 Thread Dmitry Safonov
Due to some historical mistake, xfrm User ABI differ between native and compatible applications. The difference is in structures paddings and in the result in the size of netlink messages. As it's already visible ABI, it cannot be adjusted by packing structures. Possibility for compatible