[<prev] [next>] [<thread-prev] [day] [month] [year] [list]
Message-ID: <m1fwgipano.fsf@fess.ebiederm.org>
Date: Sun, 18 Dec 2011 00:05:31 -0800
From: ebiederm@...ssion.com (Eric W. Biederman)
To: Lucian Adrian Grijincu <lucian.grijincu@...il.com>
Cc: linux-kernel <linux-kernel@...r.kernel.org>,
netdev@...r.kernel.org, Octavian Purdila <tavi@...pub.ro>,
"David S . Miller" <davem@...emloft.net>,
Alexey Dobriyan <adobriyan@...il.com>,
Damien Millescamps <damien.millescamps@...nd.com>,
Anca Emanuel <anca.emanuel@...il.com>,
Benjamin LaHaise <bcrl@...ck.org>
Subject: Re: v6: faster tree-based sysctl implementation
I spent some time playing this and managed to get something that works
using proc_dir_entries. And while it is simpler (600 less lines of
code) it takes about 3x the space of just what using ctl_table entries
does.
I managed to prove to myself that the current sysctl infrastructure
relies the union directory existence semantics pretty strongly. Despite
all of Al's work to the contrary when he introduced attached_by and kin
in sysctl head.
One nice thing I managed to do was to shift around the problem a bit
so that only at /proc/sys/net do we to namespace weirdness. Which also
considerably simplifies the problem.
Now that I know that normal unix directory semantics are a lost cause
removing the child entry from ctl_table looks like a very productive
exercise.
Furthermore it feels like the optimal data structure would be a
directory tree that is created on demand as we create entries,
and a second copy of that directory tree that is per network namespace.
That is very similar to the data structure you wound up with.
So in the next little bit I am going to see if I can combine what
you did and what I did and see if I can come up with something that
is obvious in how it works from looking at it's data structures.
Eric
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/
Powered by blists - more mailing lists