[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <20080702143554.GY9594@localdomain>
Date: Wed, 2 Jul 2008 09:35:54 -0500
From: Nathan Lynch <ntl@...ox.com>
To: Andi Kleen <andi@...stfloor.org>
Cc: Andrew Morton <akpm@...ux-foundation.org>,
Paul Mackerras <paulus@...ba.org>,
torvalds@...ux-foundation.org, linux-kernel@...r.kernel.org,
greg@...ah.com
Subject: Re: Is sysfs the right place to get cache and CPU topology info?
Andi Kleen wrote:
> Andrew Morton <akpm@...ux-foundation.org> writes:
> >
> > sysfs is part of the kernel ABI. We should design our interfaces there
> > as carefully as we design any others.
>
> The basic problem is that sysfs exports an internal kernel object model
> and these tend to change. To really make it stable would require
> splitting it into internal and presented interface.
True, but... /sys/devices/system/cpu has been there since around 2.6.5
iirc. A google code search for that path shows plenty of programs
(including hal) that hard-code it. Exposed object model or not,
changing that path would break lots of software.
> I would be all
> for it, but it doesn't seem realistic to me currently. If we cannot
> even get basic interfaces like the syscall capability stable how would
> you expect to stabilize the complete kobjects?
>
> And the specific problem with the x86 cache sysfs interface is that it's so
> complicated that no human can really read it directly. This means to
> actually use it you need some kind of frontend (i have a cheesy
> lscache script for this).
Human readability is nice, but a more important issue IMO is whether
the cache interface can be considered stable enough for programs to
rely on it. I notice there's no entry for it in Documentation/ABI.
--
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