public inbox for bpf@vger.kernel.org
 help / color / mirror / Atom feed
From: Mark Wielaard <mark@klomp.org>
To: Jiri Olsa <jolsa@redhat.com>, Tony Ambardar <tony.ambardar@gmail.com>
Cc: Yonghong Song <yhs@fb.com>,
	Daniel Borkmann <daniel@iogearbox.net>,
	Alexei Starovoitov <ast@kernel.org>,
	Andrii Nakryiko <andrii@kernel.org>, bpf <bpf@vger.kernel.org>,
	Networking <netdev@vger.kernel.org>,
	Stable <stable@vger.kernel.org>, Jiri Olsa <jolsa@kernel.org>,
	Frank Eigler <fche@redhat.com>
Subject: Re: [PATCH bpf v1] bpf: fix libelf endian handling in resolv_btfids
Date: Thu, 17 Jun 2021 12:44:42 +0200	[thread overview]
Message-ID: <46f035765fa4ee139fa5ec387d9395f1f466bb5e.camel@klomp.org> (raw)
In-Reply-To: <YMsRa3nT4tlzO6DJ@krava>

On Thu, 2021-06-17 at 11:10 +0200, Jiri Olsa wrote:
> On Wed, Jun 16, 2021 at 03:09:13PM -0700, Tony Ambardar wrote:
> > On Wed, 16 Jun 2021 at 09:38, Jiri Olsa <jolsa@redhat.com> wrote:
> > > I have no idea how is this handled in libelf (perhaps it's ok),
> > > but just that comment above suggests it could be also 64 bits,
> > > cc-ing Frank and Mark for more insight
> > > 
> > 
> > One other area I'd like to confirm is with section compression. Is
> > it safe
> > to ignore this for .BTF_ids? I've done so because
> > include/linux/btf_ids.h
> > appears to define the section with SHF_ALLOC flag set, which is
> > incompatible with compression based on "libelf.h" comments.
> 
> not sure what you mean.. where it wouldn't be safe?
> what workflow/processing

I haven't looked at the code/patch, but Tony is correct that if a
section has SHF_ALLOC set it cannot be a compressed section.
SHF_COMPRESSED is incompatbile with SHF_ALLOC (or SHF_NOBITS) sections,
because it would be unclear what a loader would need to do with them
(uncompress the data first, then map it, or map the compressed data as
is into memory).

So ignoring whether or not a section is compressed for SHF_ALLOC
sections is fine.

Cheers,

Mark

  reply	other threads:[~2021-06-17 10:44 UTC|newest]

Thread overview: 12+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2021-06-16  9:25 [PATCH bpf v1] bpf: fix libelf endian handling in resolv_btfids Tony Ambardar
2021-06-16 15:56 ` Yonghong Song
2021-06-16 16:38   ` Jiri Olsa
2021-06-16 22:09     ` Tony Ambardar
2021-06-17  9:10       ` Jiri Olsa
2021-06-17 10:44         ` Mark Wielaard [this message]
2021-06-16 22:28     ` Mark Wielaard
2021-06-17  9:02       ` Jiri Olsa
2021-06-17 11:22         ` Daniel Borkmann
2021-06-18  0:20           ` Tony Ambardar
2021-06-18  6:14 ` [PATCH bpf v2] " Tony Ambardar
2021-06-18 15:10   ` patchwork-bot+netdevbpf

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=46f035765fa4ee139fa5ec387d9395f1f466bb5e.camel@klomp.org \
    --to=mark@klomp.org \
    --cc=andrii@kernel.org \
    --cc=ast@kernel.org \
    --cc=bpf@vger.kernel.org \
    --cc=daniel@iogearbox.net \
    --cc=fche@redhat.com \
    --cc=jolsa@kernel.org \
    --cc=jolsa@redhat.com \
    --cc=netdev@vger.kernel.org \
    --cc=stable@vger.kernel.org \
    --cc=tony.ambardar@gmail.com \
    --cc=yhs@fb.com \
    /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