lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <921d83a9-aa44-acee-4fcf-dbc45cc0a66a@huawei.com>
Date:   Wed, 25 Jan 2017 09:06:19 +0800
From:   "Wangnan (F)" <wangnan0@...wei.com>
To:     Joe Stringer <joe@....org>, <acme@...nel.org>
CC:     <ast@...com>, <daniel@...earbox.net>,
        <linux-kernel@...r.kernel.org>, <netdev@...r.kernel.org>
Subject: Re: [PATCHv2 perf/core 5/7] tools lib bpf: Add bpf_program__pin()



On 2017/1/25 9:04, Wangnan (F) wrote:
>
>
> On 2017/1/23 9:11, Joe Stringer wrote:
>> Add a new API to pin a BPF program to the filesystem. The user can
>> specify the path full path within a BPF filesystem to pin the program.
>> Programs with multiple instances are pinned as 'foo', 'foo_1', 'foo_2',
>> and so on.
>>
>> Signed-off-by: Joe Stringer <joe@....org>
>> ---
>> v2: Don't automount BPF filesystem
>>      Split program, map, object pinning into separate APIs and separate
>>      patches.
>> ---

[SNIP]

>> +int bpf_program__pin(struct bpf_program *prog, const char *path)
>
> In your next patch please let caller select one instance:
>
> int bpf_program__pin(struct bpf_program *prog, int instance, const 
> char *path)
> (please choose a better name)
>
> Then your can wrap it with another function to pin all instances, 
> implement
> naming schema (%s_%d) there.
>
> Then implement naming schema in bpf_object__pin like:
>
> %s/objectname_mapname
> %s/objectname_progname_%d
>

Is it possible to use directory tree instead?

%s/object/mapname
%s/object/prog/instance

Thank you.

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ