New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
bpf_tests: Bumped CoverBee to v0.3.2 blank state value fix #24180
bpf_tests: Bumped CoverBee to v0.3.2 blank state value fix #24180
Conversation
07d79c5
to
19e7844
Compare
Hi @dylandreimerink, thanks for your PR, and it does fix the issue of local verifier error. However I just hit another issue related to ipv6. Let me elaborate the steps. First I pulled this pr to local: Then I created a new bpf test file in bpf/tests/tc_ipv6_test.c with these code: // SPDX-License-Identifier: (GPL-2.0-only OR BSD-2-Clause)
/* Copyright Authors of Cilium */
#include "common.h"
#include <bpf/ctx/skb.h>
#include <bpf/helpers_skb.h>
#include "pktgen.h"
#define ENABLE_IPV6
#define ETH_HLEN 0
#define ENABLE_HOST_ROUTING 1
#define ENABLE_NODEPORT
#define DISABLE_LOOPBACK_LB
#define TEST_IP_LOCAL v4_pod_one
#define TEST_IP_REMOTE v4_pod_two
#define TEST_IPV6_LOCAL v6_pod_one
#define TEST_IPV6_REMOTE v6_pod_two
#define TEST_LXC_ID_LOCAL 233
#define SECCTX_FROM_IPCACHE 1
#include "bpf_host.c"
PKTGEN("tc", "ipv6_l3_to_l2_fast_redirect")
int ipv6_l3_to_l2_fast_redirect_pktgen(struct __ctx_buff *ctx)
{
struct pktgen builder;
/* Init packet builder */
pktgen__init(&builder, ctx);
pktgen__finish(&builder);
return 0;
}
SETUP("tc", "ipv6_l3_to_l2_fast_redirect")
int ipv6_l3_to_l2_fast_redirect_setup(struct __ctx_buff __maybe_unused *ctx)
{
return TEST_PASS;
}
CHECK("tc", "ipv6_l3_to_l2_fast_redirect")
int ipv6_l3_to_l2_fast_redirect_check(__maybe_unused const struct __ctx_buff __maybe_unused *ctx)
{
test_init();
test_finish();
} After that, I ran An interesting fact is, the verifier will pass the check once I delete the macro The verifier error logs are
My host is Linux gray-Latitude-5530 5.19.0-35-generic #36~22.04.1-Ubuntu SMP PREEMPT_DYNAMIC Fri Feb 17 15:17:25 UTC 2 x86_64 x86_64 x86_64 GNU/Linux. |
@jschwinger233 the Our codebase has to run on kernel versions which do no yet support "global data" from maps, so we have a mechanism called "static data" that patches values in the program just before loading instead of using global data from maps. See In a lot of locations we have surrounded the definitions of these static data variables with |
@dylandreimerink Of course, thanks for sharing. It turns out it's Can't wait to see this PR merged. |
There was a bug in CoverBee which caused instrumentation to fail on some programs if the verifier log contained frame pointer dumps at the end of a log line without a value. Signed-off-by: Dylan Reimerink <dylan.reimerink@isovalent.com>
19e7844
to
151b4a0
Compare
Alright, PR is accepted by all code owners. All tests are green, except for ConformanceGatewayAPI which is hitting #24217. CoverBee is only used by the BPF test CI which passes, so no need for e2e tests. Marking as ready-to-merge. |
There was a bug in CoverBee which caused instrumentation to fail on some programs if the verifier log contained frame pointer dumps at the end of a log line without a value.
This fixes a bug reported by @jspaleta and @jschwinger233