[PATCH mptcp-next v9 0/8] use GENL_REQ_ATTR_CHECK in userspace pm

Geliang Tang posted 8 patches 1 week, 4 days ago
Patches applied successfully (tree, apply log)
git fetch https://github.com/multipath-tcp/mptcp_net-next tags/patchew/cover.1736493803.git.tanggeliang@kylinos.cn
net/mptcp/pm_netlink.c   |  43 +++++++++---
net/mptcp/pm_userspace.c | 148 +++++++++++++++++++++++----------------
2 files changed, 118 insertions(+), 73 deletions(-)
[PATCH mptcp-next v9 0/8] use GENL_REQ_ATTR_CHECK in userspace pm
Posted by Geliang Tang 1 week, 4 days ago
From: Geliang Tang <tanggeliang@kylinos.cn>

v9:
 patch 3, move the code using NL_SET_ERR_MSG_ATTR into patch 8.
 patch 7, adjust the location of "pernet = pm_nl_get_pernet(net);".

v8:
 - move the set_flags() patches out of this set.
 - differences from v6:
  - adjust the order of the patches.
  - keep "pernet = pm_nl_get_pernet(net);" at the beginning of
    mptcp_pm_nl_set_flags().
  - not use NL_SET_ERR_MSG_ATTR in mptcp_pm_nl_set_flags(), since 'attr'
    will be removed in the commit "mptcp: add local & remote parameters for
    set_flags".
  - update the code related mptcp_userspace_pm_remove_id_zero_address()
    since a new patch to drop "info" parameter of this patch is added.
  - add a comment "mptcp_pm_nl_mp_prio_send_ack() only fails in one case"
    in mptcp_userspace_pm_set_flags().

v7:
 - update set_flags() interface.
 - drop 'info' parameter of userspace_pm_remove_id_zero_address().
 - rebase v6 on top of these changes.

This is a newer version of the series started by Geliang, now making
them more uniform on how the NL errors are set, and giving more hints to
the userspace about what's wrong.

Geliang Tang (2):
  mptcp: drop info of userspace_pm_remove_id_zero_address
  mptcp: pm: userspace: use GENL_REQ_ATTR_CHECK

Matthieu Baerts (NGI0) (6):
  mptcp: pm: userspace: flags: clearer msg if no remote addr
  mptcp: pm: more precise error messages
  mptcp: pm: improve error messages
  mptcp: pm: remove duplicated error messages
  mptcp: pm: mark missing address attributes
  mptcp: pm: use NL_SET_ERR_MSG_ATTR when possible

 net/mptcp/pm_netlink.c   |  43 +++++++++---
 net/mptcp/pm_userspace.c | 148 +++++++++++++++++++++++----------------
 2 files changed, 118 insertions(+), 73 deletions(-)

-- 
2.45.2
Re: [PATCH mptcp-next v9 0/8] use GENL_REQ_ATTR_CHECK in userspace pm
Posted by MPTCP CI 1 week, 4 days ago
Hi Matthieu,

Thank you for your modifications, that's great!

Our CI did some validations and here is its report:

- KVM Validation: normal: Success! ✅
- KVM Validation: debug: Success! ✅
- KVM Validation: btf-normal (only bpftest_all): Success! ✅
- KVM Validation: btf-debug (only bpftest_all): Unstable: 1 failed test(s): bpftest_test_progs-no_alu32_mptcp 🔴
- Task: https://github.com/multipath-tcp/mptcp_net-next/actions/runs/12705350996

Initiator: Patchew Applier
Commits: https://github.com/multipath-tcp/mptcp_net-next/commits/d5de4a4eab65
Patchwork: https://patchwork.kernel.org/project/mptcp/list/?series=924037


If there are some issues, you can reproduce them using the same environment as
the one used by the CI thanks to a docker image, e.g.:

    $ cd [kernel source code]
    $ docker run -v "${PWD}:${PWD}:rw" -w "${PWD}" --privileged --rm -it \
        --pull always mptcp/mptcp-upstream-virtme-docker:latest \
        auto-normal

For more details:

    https://github.com/multipath-tcp/mptcp-upstream-virtme-docker


Please note that despite all the efforts that have been already done to have a
stable tests suite when executed on a public CI like here, it is possible some
reported issues are not due to your modifications. Still, do not hesitate to
help us improve that ;-)

Cheers,
MPTCP GH Action bot
Bot operated by Matthieu Baerts (NGI0 Core)
Re: [PATCH mptcp-next v9 0/8] use GENL_REQ_ATTR_CHECK in userspace pm
Posted by Matthieu Baerts 1 week, 4 days ago
Hi Geliang,

On 10/01/2025 08:30, Geliang Tang wrote:
> From: Geliang Tang <tanggeliang@kylinos.cn>
> 
> v9:
>  patch 3, move the code using NL_SET_ERR_MSG_ATTR into patch 8.
>  patch 7, adjust the location of "pernet = pm_nl_get_pernet(net);".

Thank you for the new version.

I have one small request in patch 8/8, but I can fix that when applying
the patches if that's OK with you.

I can also do the modifications in set_flags(), and fix the conflicts
when applying "BPF path manager, part 2" (if it is ready)

Cheers,
Matt
-- 
Sponsored by the NGI0 Core fund.
Re: [PATCH mptcp-next v9 0/8] use GENL_REQ_ATTR_CHECK in userspace pm
Posted by Matthieu Baerts 1 week, 2 days ago
Hi Geliang,

On 10/01/2025 12:21, Matthieu Baerts wrote:
> Hi Geliang,
> 
> On 10/01/2025 08:30, Geliang Tang wrote:
>> From: Geliang Tang <tanggeliang@kylinos.cn>
>>
>> v9:
>>  patch 3, move the code using NL_SET_ERR_MSG_ATTR into patch 8.
>>  patch 7, adjust the location of "pernet = pm_nl_get_pernet(net);".
> 
> Thank you for the new version.
> 
> I have one small request in patch 8/8, but I can fix that when applying
> the patches if that's OK with you.
> 
> I can also do the modifications in set_flags(), and fix the conflicts
> when applying "BPF path manager, part 2" (if it is ready)

As discussed on the "BPF path manager, part 2" thread, I will apply
patches from these 2 series with the suggested modifications.

Reviewed-by: Matthieu Baerts (NGI0) <matttbe@kernel.org>

Cheers,
Matt
-- 
Sponsored by the NGI0 Core fund.
Re: [PATCH mptcp-next v9 0/8] use GENL_REQ_ATTR_CHECK in userspace pm
Posted by Matthieu Baerts 1 week, 2 days ago
Hi Geliang,

On 12/01/2025 13:43, Matthieu Baerts wrote:
> Hi Geliang,
> 
> On 10/01/2025 12:21, Matthieu Baerts wrote:
>> Hi Geliang,
>>
>> On 10/01/2025 08:30, Geliang Tang wrote:
>>> From: Geliang Tang <tanggeliang@kylinos.cn>
>>>
>>> v9:
>>>  patch 3, move the code using NL_SET_ERR_MSG_ATTR into patch 8.
>>>  patch 7, adjust the location of "pernet = pm_nl_get_pernet(net);".
>>
>> Thank you for the new version.
>>
>> I have one small request in patch 8/8, but I can fix that when applying
>> the patches if that's OK with you.
>>
>> I can also do the modifications in set_flags(), and fix the conflicts
>> when applying "BPF path manager, part 2" (if it is ready)
> 
> As discussed on the "BPF path manager, part 2" thread, I will apply
> patches from these 2 series with the suggested modifications.
> 
> Reviewed-by: Matthieu Baerts (NGI0) <matttbe@kernel.org>

Now in our tree (feat. for net-next) with my/your RvB tag:

New patches for t/upstream:
- 5e429e15a686: mptcp: drop info of userspace_pm_remove_id_zero_address
- 81e5a669e7d9: mptcp: pm: userspace: flags: clearer msg if no remote addr
- 677a8abf8d6c: mptcp: pm: more precise error messages
- b4609c1a21bc: mptcp: pm: improve error messages
- b8f41c31bdfc: mptcp: pm: userspace: use GENL_REQ_ATTR_CHECK
- 59b41cafd64c: mptcp: pm: remove duplicated error messages
- 94f4c18c1bd8: mptcp: pm: mark missing address attributes
- 04606ffe7837: mptcp: pm: use NL_SET_ERR_MSG_ATTR when possible
- Results: 632bb7330ffe..472c88326ee3 (export)

Tests are now in progress:

- export:
https://github.com/multipath-tcp/mptcp_net-next/commit/2ee1204b47d42c73b7fb3bce9534d89666d24a98/checks

Cheers,
Matt
-- 
Sponsored by the NGI0 Core fund.