lkml.org 
[lkml]   [2014]   [Sep]   [10]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
    /
    Date
    From
    SubjectRe: [PATCH v11 net-next 11/12] net: filter: move eBPF instruction macros
    On 09/10/2014 07:10 AM, Alexei Starovoitov wrote:
    > move instruction macros (like BPF_MOV64_REG or BPF_ALU32_IMM)
    > from linux/filter.h into uapi/linux/bpf.h
    > so that userspace programs can use them.
    >
    > verifier testsuite (in later patches) will be using them.
    >
    > Signed-off-by: Alexei Starovoitov <ast@plumgrid.com>

    I don't think we need this commit at all. These macros are not really
    part of the ABI and we should expose __as less as possible__, otherwise
    we won't be able to alter them anymore. Plus, based on your previous
    argumentation regarding the header file expose, we also won't be able
    to add any new macros anymore since you could run into name collisions.

    Anyway, I don't see a reason why a e.g. central user space eBPF library
    cannot live with, for example, a private copy of these helper macros or
    whatever it wants to define by itself.

    I know in classic BPF there's BPF_STMT() and BPF_JUMP() but it's much
    less complicated than eBPF and less likely to changes.


    \
     
     \ /
      Last update: 2014-09-10 14:01    [W:4.602 / U:0.008 seconds]
    ©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site