[<prev] [next>] [<thread-prev] [day] [month] [year] [list]
Message-ID: <c1b75598-f1a2-899d-06e0-04dc26cd7670@iogearbox.net>
Date: Wed, 12 Sep 2018 22:02:31 +0200
From: Daniel Borkmann <daniel@...earbox.net>
To: Martin KaFai Lau <kafai@...com>, netdev@...r.kernel.org
Cc: Alexei Starovoitov <ast@...com>, kernel-team@...com
Subject: Re: [PATCH bpf] bpf: btf: Fix end boundary calculation for type
section
On 09/12/2018 07:29 PM, Martin KaFai Lau wrote:
> The end boundary math for type section is incorrect in
> btf_check_all_metas(). It just happens that hdr->type_off
> is always 0 for now because there are only two sections
> (type and string) and string section must be at the end (ensured
> in btf_parse_str_sec).
>
> However, type_off may not be 0 if a new section would be added later.
> This patch fixes it.
>
> Fixes: f80442a4cd18 ("bpf: btf: Change how section is supported in btf_header")
> Reported-by: Dmitry Vyukov <dvyukov@...gle.com>
> Signed-off-by: Martin KaFai Lau <kafai@...com>
Applied to bpf, thanks everyone!
Powered by blists - more mailing lists