[<prev] [next>] [<thread-prev] [day] [month] [year] [list]
Message-ID: <CAADnVQJ-GhhZskSjWq-rfNCZfUoNn4vMxwPHoGSRng3A5aaBsw@mail.gmail.com>
Date: Sat, 5 Oct 2019 18:05:01 -0700
From: Alexei Starovoitov <alexei.starovoitov@...il.com>
To: Andrii Nakryiko <andriin@...com>
Cc: bpf <bpf@...r.kernel.org>,
Network Development <netdev@...r.kernel.org>,
Alexei Starovoitov <ast@...com>,
Daniel Borkmann <daniel@...earbox.net>,
Andrii Nakryiko <andrii.nakryiko@...il.com>,
Kernel Team <kernel-team@...com>
Subject: Re: [PATCH bpf-next] libbpf: fix BTF-defined map's __type macro
handling of arrays
On Fri, Oct 4, 2019 at 1:10 AM Andrii Nakryiko <andriin@...com> wrote:
>
> Due to a quirky C syntax of declaring pointers to array or function
> prototype, existing __type() macro doesn't work with map key/value types
> that are array or function prototype. One has to create a typedef first
> and use it to specify key/value type for a BPF map. By using typeof(),
> pointer to type is now handled uniformly for all kinds of types. Convert
> one of self-tests as a demonstration.
>
> Signed-off-by: Andrii Nakryiko <andriin@...com>
Applied. Thanks
Powered by blists - more mailing lists