[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <20171227022730.y27gwva2u2ilyrul@ast-mbp>
Date: Tue, 26 Dec 2017 18:27:31 -0800
From: Alexei Starovoitov <alexei.starovoitov@...il.com>
To: Eric Leblond <eric@...it.org>
Cc: netdev@...r.kernel.org, daniel@...earbox.net,
linux-kernel@...r.kernel.org, ast@...nel.org
Subject: Re: [PATCH bpf-next 2/3] libbpf: add error reporting in XDP
On Mon, Dec 25, 2017 at 11:13:24PM +0100, Eric Leblond wrote:
> Parse netlink ext attribute to get the error message returned by
> the card.
>
> Signed-off-by: Eric Leblond <eric@...it.org>
...
> diff --git a/tools/lib/bpf/nlattr.c b/tools/lib/bpf/nlattr.c
> new file mode 100644
> index 000000000000..962de14f74e3
> --- /dev/null
> +++ b/tools/lib/bpf/nlattr.c
> @@ -0,0 +1,188 @@
> +
> +/*
> + * NETLINK Netlink attributes
> + *
> + * Authors: Thomas Graf <tgraf@...g.ch>
> + * Alexey Kuznetsov <kuznet@....inr.ac.ru>
> + */
...
> diff --git a/tools/lib/bpf/nlattr.h b/tools/lib/bpf/nlattr.h
> new file mode 100644
> index 000000000000..b95f3e64c14d
> --- /dev/null
> +++ b/tools/lib/bpf/nlattr.h
> @@ -0,0 +1,164 @@
> +#ifndef __NLATTR_H
> +#define __NLATTR_H
Every file in kernel repo has to have SPDX license identifier.
Also note that tools/lib/bpf is LGPL whereas _if_ you're copying
these functions from kernel lib/nlattr.c then it's GPL which we cannot mix.
Probably easier to copy from libnl instead which is LGPL.
Powered by blists - more mailing lists