On Wed, Apr 19, 2017 at 10:44 AM, William Tu wrote:
> Thanks for the reply.
>
>> could you increase the max to 1M or so
>> and see what the actual number of insns it needs?
>
> it takes 112,762 insns. And the kernel runs a while (~6 seconds) to verify it.
>
>> If the program is short, as you say,
Thanks for the reply.
> could you increase the max to 1M or so
> and see what the actual number of insns it needs?
it takes 112,762 insns. And the kernel runs a while (~6 seconds) to verify it.
> If the program is short, as you say, can you debug
> the state prunning to see why it's not recogniz
On Fri, Apr 14, 2017 at 12:48:11PM -0700, William Tu wrote:
> Thanks for all the feedbacks from the iovisor summit. Since then,
> we've tried a couple of workarounds for this issue, the following
> shares the observations and code.
>
> === Original code, xdp9.c ===
> xdp9.c is to parse IPv4, TCP,
Thanks for all the feedbacks from the iovisor summit. Since then,
we've tried a couple of workarounds for this issue, the following
shares the observations and code.
=== Original code, xdp9.c ===
xdp9.c is to parse IPv4, TCP, UDP, ICMP and update checksum.
https://gist.github.com/williamtu/759eedb
On Fri, Feb 10, 2017 at 9:08 AM, William Tu wrote:
> my program is too huge so I start with simple example using xdp1_kern.c
> I tried adding an ethernet header as local variable:
>
> --- a/samples/bpf/xdp1_kern.c
> +++ b/samples/bpf/xdp1_kern.c
> @@ -51,10 +51,19 @@ int xdp_prog1(struct xdp_md *c
my program is too huge so I start with simple example using xdp1_kern.c
I tried adding an ethernet header as local variable:
--- a/samples/bpf/xdp1_kern.c
+++ b/samples/bpf/xdp1_kern.c
@@ -51,10 +51,19 @@ int xdp_prog1(struct xdp_md *ctx)
u64 nh_off;
u32 ipproto;
+ struct et
On Thu, Feb 9, 2017 at 8:59 AM, Alexei Starovoitov
wrote:
> On Thu, Feb 9, 2017 at 8:43 AM, William Tu via iovisor-dev
> wrote:
>>
>> $(CLANG) \
>> -D__KERNEL__ -D__ASM_SYSREG_H -Wno-unused-value -Wno-pointer-sign \
>> -Wno-compare-distinct-pointer-types \
>> -Wno-gnu-
On Thu, Feb 9, 2017 at 8:43 AM, William Tu via iovisor-dev
wrote:
>
> $(CLANG) \
> -D__KERNEL__ -D__ASM_SYSREG_H -Wno-unused-value -Wno-pointer-sign \
> -Wno-compare-distinct-pointer-types \
> -Wno-gnu-variable-sized-type-not-at-end \
> -Wno-tautological-compare
> You are generating the C files in the end, right? So the code
> shown is what clang gets to compile; or does this come from
> another llvm front end somehow?
yes, we are generating C files, then clang v3.8, then LLVM v4.0. It's
the same compile options used in sample/bpf/Makefile
>
> Also this
On 02/09/2017 04:23 PM, William Tu wrote:
On Thu, Feb 9, 2017 at 5:11 AM, Daniel Borkmann wrote:
On 02/08/2017 09:22 PM, William Tu via iovisor-dev wrote:
Hi,
I have a program which I use around at most 300byte of local stack as
below. The largest struct is the "struct Headers" which is arou
On Thu, Feb 9, 2017 at 5:11 AM, Daniel Borkmann wrote:
> On 02/08/2017 09:22 PM, William Tu via iovisor-dev wrote:
>>
>> Hi,
>>
>> I have a program which I use around at most 300byte of local stack as
>> below. The largest struct is the "struct Headers" which is around 80
>> byte. However, when lo
On 02/08/2017 09:22 PM, William Tu via iovisor-dev wrote:
Hi,
I have a program which I use around at most 300byte of local stack as
below. The largest struct is the "struct Headers" which is around 80
byte. However, when loading into the verifier, it says
393: (7b) *(u64 *)(r10 -56) = r1
394: (
Hi,
I have a program which I use around at most 300byte of local stack as
below. The largest struct is the "struct Headers" which is around 80
byte. However, when loading into the verifier, it says
393: (7b) *(u64 *)(r10 -56) = r1
394: (05) goto pc+56
451: (7b) *(u64 *)(r10 -528) = r0
invalid sta
13 matches
Mail list logo