Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id ; Wed, 27 Feb 2002 16:48:32 -0500 Received: (majordomo@vger.kernel.org) by vger.kernel.org id ; Wed, 27 Feb 2002 16:48:16 -0500 Received: from hq.fsmlabs.com ([209.155.42.197]:16645 "EHLO hq.fsmlabs.com") by vger.kernel.org with ESMTP id ; Wed, 27 Feb 2002 16:45:40 -0500 From: Cort Dougan Date: Wed, 27 Feb 2002 14:44:42 -0700 To: Alan Cox Cc: Val Henson , "Randy.Dunlap" , Laurent , linux-kernel@vger.kernel.org Subject: Re: read_proc issue Message-ID: <20020227144442.Y31381@host171.fsmlabs.com> In-Reply-To: <20020227140432.L20918@boardwalk> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline User-Agent: Mutt/1.2.5i In-Reply-To: ; from alan@lxorguk.ukuu.org.uk on Wed, Feb 27, 2002 at 09:42:04PM +0000 Sender: linux-kernel-owner@vger.kernel.org X-Mailing-List: linux-kernel@vger.kernel.org That's a good solution in the general case but doesn't work for some of the proc entries that already exist. cpuinfo, for example. There seem to be a number of niche /proc methods already. A cache-on-open method would be very useful for files like cpuinfo and a number of other files for PPC. It sure would make accessing /proc files less whacky for user-code. } Another approach is to do the calculation open and remember it in per } fd private data. You can recover that and free it on release. It could } even be a buffer holding the actual "content" - To unsubscribe from this list: send the line "unsubscribe linux-kernel" in the body of a message to majordomo@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html Please read the FAQ at http://www.tux.org/lkml/