BPF List
 help / color / mirror / Atom feed
From: Yonghong Song <yhs@fb.com>
To: Ivan Khoronzhuk <ivan.khoronzhuk@linaro.org>,
	"magnus.karlsson@intel.com" <magnus.karlsson@intel.com>,
	"bjorn.topel@intel.com" <bjorn.topel@intel.com>
Cc: "davem@davemloft.net" <davem@davemloft.net>,
	"hawk@kernel.org" <hawk@kernel.org>,
	"john.fastabend@gmail.com" <john.fastabend@gmail.com>,
	"jakub.kicinski@netronome.com" <jakub.kicinski@netronome.com>,
	"daniel@iogearbox.net" <daniel@iogearbox.net>,
	"netdev@vger.kernel.org" <netdev@vger.kernel.org>,
	"bpf@vger.kernel.org" <bpf@vger.kernel.org>,
	"xdp-newbies@vger.kernel.org" <xdp-newbies@vger.kernel.org>,
	"linux-kernel@vger.kernel.org" <linux-kernel@vger.kernel.org>
Subject: Re: [PATCH bpf-next 1/3] libbpf: add asm/unistd.h to xsk to get __NR_mmap2
Date: Wed, 14 Aug 2019 00:32:41 +0000	[thread overview]
Message-ID: <05e5d15b-5ef9-b4dc-a76c-0d423fb2f15d@fb.com> (raw)
In-Reply-To: <20190813102318.5521-2-ivan.khoronzhuk@linaro.org>



On 8/13/19 3:23 AM, Ivan Khoronzhuk wrote:
> That's needed to get __NR_mmap2 when mmap2 syscall is used.

It seems I did not have this issue on x64 machine e.g., Fedora 29.
My glibc version is 2.28. gcc 8.2.1.

What is your particular system glibc version?
So needing kernel asm/unistd.h is because of older glibc on your
system, or something else? Could you clarify?

> 
> Signed-off-by: Ivan Khoronzhuk <ivan.khoronzhuk@linaro.org>
> ---
>   tools/lib/bpf/xsk.c | 1 +
>   1 file changed, 1 insertion(+)
> 
> diff --git a/tools/lib/bpf/xsk.c b/tools/lib/bpf/xsk.c
> index 5007b5d4fd2c..f2fc40f9804c 100644
> --- a/tools/lib/bpf/xsk.c
> +++ b/tools/lib/bpf/xsk.c
> @@ -12,6 +12,7 @@
>   #include <stdlib.h>
>   #include <string.h>
>   #include <unistd.h>
> +#include <asm/unistd.h>
>   #include <arpa/inet.h>
>   #include <asm/barrier.h>
>   #include <linux/compiler.h>
> 

  parent reply	other threads:[~2019-08-14  0:33 UTC|newest]

Thread overview: 20+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2019-08-13 10:23 [PATCH bpf-next 0/3] xdpsock: allow mmap2 usage for 32bits Ivan Khoronzhuk
2019-08-13 10:23 ` [PATCH bpf-next 1/3] libbpf: add asm/unistd.h to xsk to get __NR_mmap2 Ivan Khoronzhuk
2019-08-13 17:36   ` Jonathan Lemon
2019-08-13 23:38   ` Andrii Nakryiko
2019-08-14  9:24     ` Ivan Khoronzhuk
2019-08-14 11:57       ` Ivan Khoronzhuk
2019-08-14 13:32         ` Björn Töpel
2019-08-14 16:17           ` Yonghong Song
2019-08-14 19:54           ` Ivan Khoronzhuk
2019-08-14 15:51       ` Yonghong Song
2019-08-14 19:56       ` Andrii Nakryiko
2019-08-14  0:32   ` Yonghong Song [this message]
2019-08-14 10:19     ` Ivan Khoronzhuk
2019-08-13 10:23 ` [PATCH bpf-next 2/3] xdp: xdp_umem: replace kmap on vmap for umem map Ivan Khoronzhuk
2019-08-13 17:42   ` Jonathan Lemon
2019-08-13 18:30     ` Ivan Khoronzhuk
2019-08-13 18:33       ` Jonathan Lemon
2019-08-13 10:23 ` [PATCH bpf-next 3/3] samples: bpf: syscal_nrs: use mmap2 if defined Ivan Khoronzhuk
2019-08-13 17:41   ` Jonathan Lemon
2019-08-13 18:59     ` Ivan Khoronzhuk

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=05e5d15b-5ef9-b4dc-a76c-0d423fb2f15d@fb.com \
    --to=yhs@fb.com \
    --cc=bjorn.topel@intel.com \
    --cc=bpf@vger.kernel.org \
    --cc=daniel@iogearbox.net \
    --cc=davem@davemloft.net \
    --cc=hawk@kernel.org \
    --cc=ivan.khoronzhuk@linaro.org \
    --cc=jakub.kicinski@netronome.com \
    --cc=john.fastabend@gmail.com \
    --cc=linux-kernel@vger.kernel.org \
    --cc=magnus.karlsson@intel.com \
    --cc=netdev@vger.kernel.org \
    --cc=xdp-newbies@vger.kernel.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox