lkml.org 
[lkml]   [2017]   [Dec]   [7]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
    /
    From
    Date
    SubjectRe: [PATCH v2 net-next 4/4] bpftool: implement cgroup bpf operations
    Roman,

    On Thu, Dec 7, 2017 at 11:23 PM, Jakub Kicinski
    <jakub.kicinski@netronome.com> wrote:
    > On Thu, 7 Dec 2017 18:39:09 +0000, Roman Gushchin wrote:
    >> This patch adds basic cgroup bpf operations to bpftool:
    >> cgroup list, attach and detach commands.
    >>
    >> Usage is described in the corresponding man pages,
    >> and examples are provided.
    >>
    >> Syntax:
    >> $ bpftool cgroup list CGROUP
    >> $ bpftool cgroup attach CGROUP ATTACH_TYPE PROG [ATTACH_FLAGS]
    >> $ bpftool cgroup detach CGROUP ATTACH_TYPE PROG
    >>
    >> Signed-off-by: Roman Gushchin <guro@fb.com>
    >
    > Looks good, a few very minor nits/questions below.
    >
    >> diff --git a/tools/bpf/bpftool/cgroup.c b/tools/bpf/bpftool/cgroup.c
    >> new file mode 100644
    >> index 000000000000..88d67f74313f
    >> --- /dev/null
    >> +++ b/tools/bpf/bpftool/cgroup.c
    >> @@ -0,0 +1,305 @@
    >> +/*
    >> + * Copyright (C) 2017 Facebook
    >> + *
    >> + * This program is free software; you can redistribute it and/or
    >> + * modify it under the terms of the GNU General Public License
    >> + * as published by the Free Software Foundation; either version
    >> + * 2 of the License, or (at your option) any later version.
    >> + *
    >> + * Author: Roman Gushchin <guro@fb.com>
    >> + */

    Have you considered using the new SPDX ids instead?
    e.g. may be something like:
    // SPDX-License-Identifier: GPL-2.0+
    // Copyright (C) 2017 Facebook
    // Author: Roman Gushchin <guro@fb.com>

    Don't you love it with less boilerplate and a better code/comments ratio?
    BTW the comment style may surprise you here: this is a suggestion, but
    not just. Check the posts from Linus on this topic and Thomas's doc
    patches for the rationale.

    Thank you for your kind consideration!

    --
    Cordially
    Philippe Ombredanne

    \
     
     \ /
      Last update: 2017-12-08 00:02    [W:2.356 / U:0.044 seconds]
    ©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site