[Devel] Re: [PATCH 1/1] cls_cgroup: unify classid syntax to tc

Paul Menage menage at google.com
Thu Jun 11 22:06:00 PDT 2009


On Thu, Jun 11, 2009 at 8:40 PM, Minoru Usui<usui at mxm.nes.nec.co.jp> wrote:
>
> It's true. If my patch applied, old syntax can't use.
> But I think compatibility is important, too.
> So I'll make a new patch which can use both old and new syntax, when we write classid to net_cls.classid file.
>
> Present implementation is an asymmetry with read and write.(read: decimal, write: hexadecimal)

You can write the classid value in decimal too, or even octal - it
just uses strtoull() to convert the string to an integer, so
0x-prefixed hex values are handled automatically.

>
> If it's ok, I'd like to be able to use tc syntax(X:Y style),
> because cls_cgroup's purpose is select class which create by tc command.
> tc command can only use classid syntax X:Y style, so we should be able to use X:Y style to cls_cgroup.

We should keep it as it is - purely apart from compatibility issues,
there's no need to introduce the complexity of the tc interface into
the cls_cgroup kernel code. When a cgroup control file represents a
simple integer, then it should be exposed as such.

Paul
_______________________________________________
Containers mailing list
Containers at lists.linux-foundation.org
https://lists.linux-foundation.org/mailman/listinfo/containers




More information about the Devel mailing list