lkml.org 
[lkml]   [2015]   [May]   [27]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
Date
From
SubjectRe: [RFC PATCH v4 07/29] bpf tools: Check endianess and make libbpf fail early
On Wed, May 27, 2015 at 05:19:42AM +0000, Wang Nan wrote:
> Check endianess according to EHDR. Code is taken from
> tools/perf/util/symbol-elf.c.
>
> Libbpf doesn't magically convert missmatched endianess. See discussion
> on https://lkml.org/lkml/2015/5/18/650 that, even if we swap
> eBPF instructions to correct byte order, we are unable to deal with
> endianess in code logical generated by LLVM.
>
> Therefore, libbpf should simply reject missmatched ELF object, and let
> LLVM to create good code.
>
> Signed-off-by: Wang Nan <wangnan0@huawei.com>

lgtm
Acked-by: Alexei Starovoitov <ast@plumgrid.com>


\
 
 \ /
  Last update: 2015-05-28 04:21    [W:0.630 / U:0.456 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site