Linux kernel -stable discussions
 help / color / mirror / Atom feed
From: Pu Lehui <pulehui@huawei.com>
To: Luiz Capitulino <luizcap@amazon.com>
Cc: <stable@vger.kernel.org>, Eduard Zingerman <eddyz87@gmail.com>,
	Greg KH <greg@kroah.com>, Alexei Starovoitov <ast@kernel.org>,
	Daniel Borkmann <daniel@iogearbox.net>,
	Andrii Nakryiko <andrii@kernel.org>,
	Pu Lehui <pulehui@huaweicloud.com>
Subject: Re: [PATCH 5.15 0/6] Backporting for 5.15 test_verifier failed
Date: Thu, 10 Aug 2023 08:59:56 +0800	[thread overview]
Message-ID: <b2f3c875-8666-8853-deef-140adc34b73c@huawei.com> (raw)
In-Reply-To: <c1dd76a0-b5e2-1365-ba02-e78fc5a82564@amazon.com>



On 2023/8/9 22:59, Luiz Capitulino wrote:
> 
> 
> On 2023-08-04 12:43, Luiz Capitulino wrote:
>>
>>
>> On 2023-08-04 11:30, Pu Lehui wrote:
>>
>>>
>>>
>>>
>>> Hi Luiz,
>>>
>>> My local 5.15 environment is a little bit weird, could you help me to
>>> test it?
>>
>> I'll give this a try, but unfortunately I'm not sure I'll be able to
>> get back to you before mid next week.
> 
> I was finally able to test this, it does fix the original failure but
> I'm also getting:
> 
> """
> #150/p calls: trigger reg2btf_ids[reg->type] for reg->type > 
> __BPF_REG_TYPE_MAX FAIL
> FAIL
> Summary: 1236 PASSED, 582 SKIPPED, 1 FAILED
> """
> 
> Also, some bpf tests don't build for me which causes the bpf tests
> not to be installed. I'm attaching the build errors, although this
> could be because my user-space is old or some misconfiguration
> on my part.
> 
> Since the original issue is fixed:
> 
> Tested-by: Luiz Capitulino <luizcap@amazon.com>

Thanks Luiz, will take time to address this new issue

> 
>>
>> - Luiz
>>
>>>
>>> On 2023/8/4 23:24, Pu Lehui wrote:
>>>> Luiz Capitulino reported the test_verifier test failed:
>>>> "precise: ST insn causing spi > allocated_stack".
>>>> And it was introduced by the following upstream commit:
>>>> ecdf985d7615 ("bpf: track immediate values written to stack by 
>>>> BPF_ST instruction")
>>>>
>>>> Eduard's investigation [4] shows that test failure is not a bug, but a
>>>> difference in BPF verifier behavior between upstream, where commits
>>>> [1,2,3] by Andrii are present, and 5.15, where these commits are 
>>>> absent.
>>>>
>>>> Backporting strategy is consistent with Eduard in kernel version 6.1 
>>>> [5],
>>>> but with some conflicts in patch #1, #4 and #6 due to the bpf of 5.15
>>>> doesn't support more features.
>>>>
>>>> Commits of Andrii:
>>>> [1] be2ef8161572 ("bpf: allow precision tracking for programs with 
>>>> subprogs")
>>>> [2] f63181b6ae79 ("bpf: stop setting precise in current state")
>>>> [3] 7a830b53c17b ("bpf: aggressively forget precise markings during 
>>>> state checkpointing")
>>>>
>>>> Links:
>>>> [4] 
>>>> https://lore.kernel.org/stable/c9b10a8a551edafdfec855fbd35757c6238ad258.camel@gmail.com/
>>>> [5] 
>>>> https://lore.kernel.org/all/20230724124223.1176479-2-eddyz87@gmail.com/
>>>>
>>>> Andrii Nakryiko (4):
>>>>    bpf: allow precision tracking for programs with subprogs
>>>>    bpf: stop setting precise in current state
>>>>    bpf: aggressively forget precise markings during state checkpointing
>>>>    selftests/bpf: make test_align selftest more robust
>>>>
>>>> Ilya Leoshkevich (1):
>>>>    selftests/bpf: Fix sk_assign on s390x
>>>>
>>>> Yonghong Song (1):
>>>>    selftests/bpf: Workaround verification failure for
>>>>      fexit_bpf2bpf/func_replace_return_code
>>>>
>>>>   kernel/bpf/verifier.c                         | 199 
>>>> ++++++++++++++++--
>>>>   .../testing/selftests/bpf/prog_tests/align.c  |  36 ++--
>>>>   .../selftests/bpf/prog_tests/sk_assign.c      |  25 ++-
>>>>   .../selftests/bpf/progs/connect4_prog.c       |   2 +-
>>>>   .../selftests/bpf/progs/test_sk_assign.c      |  11 +
>>>>   .../bpf/progs/test_sk_assign_libbpf.c         |   3 +
>>>>   6 files changed, 243 insertions(+), 33 deletions(-)
>>>>   create mode 100644 
>>>> tools/testing/selftests/bpf/progs/test_sk_assign_libbpf.c
>>>>

  reply	other threads:[~2023-08-10  1:00 UTC|newest]

Thread overview: 12+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2023-08-04 15:24 [PATCH 5.15 0/6] Backporting for 5.15 test_verifier failed Pu Lehui
2023-08-04 15:24 ` [PATCH 5.15 1/6] bpf: allow precision tracking for programs with subprogs Pu Lehui
2023-08-04 15:24 ` [PATCH 5.15 2/6] bpf: stop setting precise in current state Pu Lehui
2023-08-04 15:24 ` [PATCH 5.15 3/6] bpf: aggressively forget precise markings during state checkpointing Pu Lehui
2023-08-04 15:24 ` [PATCH 5.15 4/6] selftests/bpf: make test_align selftest more robust Pu Lehui
2023-08-04 15:24 ` [PATCH 5.15 5/6] selftests/bpf: Workaround verification failure for fexit_bpf2bpf/func_replace_return_code Pu Lehui
2023-08-04 15:24 ` [PATCH 5.15 6/6] selftests/bpf: Fix sk_assign on s390x Pu Lehui
2023-08-04 15:30 ` [PATCH 5.15 0/6] Backporting for 5.15 test_verifier failed Pu Lehui
2023-08-04 16:43   ` Luiz Capitulino
2023-08-09 14:59     ` Luiz Capitulino
2023-08-10  0:59       ` Pu Lehui [this message]
2023-08-12  9:27 ` Greg KH

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=b2f3c875-8666-8853-deef-140adc34b73c@huawei.com \
    --to=pulehui@huawei.com \
    --cc=andrii@kernel.org \
    --cc=ast@kernel.org \
    --cc=daniel@iogearbox.net \
    --cc=eddyz87@gmail.com \
    --cc=greg@kroah.com \
    --cc=luizcap@amazon.com \
    --cc=pulehui@huaweicloud.com \
    --cc=stable@vger.kernel.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox