Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1762149AbYAKTz1 (ORCPT ); Fri, 11 Jan 2008 14:55:27 -0500 Received: (majordomo@vger.kernel.org) by vger.kernel.org id S1761587AbYAKTzV (ORCPT ); Fri, 11 Jan 2008 14:55:21 -0500 Received: from pentafluge.infradead.org ([213.146.154.40]:39908 "EHLO pentafluge.infradead.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1759844AbYAKTzU (ORCPT ); Fri, 11 Jan 2008 14:55:20 -0500 Date: Fri, 11 Jan 2008 11:54:56 -0800 From: Arjan van de Ven To: Greg KH Cc: linux-kernel@vger.kernel.org, Jeff Garzik , Linus Torvalds , gregkh@suse.de, inux-pci@atrey.karlin.mff.cuni.cz, Benjamin Herrenschmidt , Martin Mares , Matthew Wilcox Subject: Re: [Patch v2] Make PCI extended config space (MMCONFIG) a driver opt-in Message-ID: <20080111115456.1fd83d88@laptopd505.fenrus.org> In-Reply-To: <20080111190229.GB10112@kroah.com> References: <20071225032605.29147200@laptopd505.fenrus.org> <20080111190229.GB10112@kroah.com> Organization: Intel X-Mailer: Claws Mail 3.0.2 (GTK+ 2.12.1; i386-redhat-linux-gnu) Mime-Version: 1.0 Content-Type: text/plain; charset=US-ASCII Content-Transfer-Encoding: 7bit X-SRS-Rewrite: SMTP reverse-path rewritten from by pentafluge.infradead.org See http://www.infradead.org/rpr.html Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Content-Length: 2891 Lines: 73 On Fri, 11 Jan 2008 11:02:29 -0800 Greg KH wrote: > On Tue, Dec 25, 2007 at 03:26:05AM -0800, Arjan van de Ven wrote: > > > > This patch also adds a sysfs property for each device into which > > root can write a '1' to enable extended configuration space. The > > kernel will print a notice into dmesg when this happens (including > > the name of the app) so that if the system crashes as a result of > > this action, the user can know what action/tool caused it. > > Can you send me a follow-on patch that documents this in > Documentation/ABI please. > --- Documentation/ABI/testing/sysfs-pci-extended-config | 39 ++++++++++++++++++++ 1 file changed, 39 insertions(+) Index: linux-2.6.24-rc7/Documentation/ABI/testing/sysfs-pci-extended-config =================================================================== --- /dev/null +++ linux-2.6.24-rc7/Documentation/ABI/testing/sysfs-pci-extended-config @@ -0,0 +1,39 @@ +What: /sys/devices/pci//extended_config_space +Date: January 11, 2008 +Contact: Arjan van de Ven +Description: + This attribute is for use for system-diagnostic software + only. + + The kernel may decide to restrict PCI configuration space + access for userspace to the first 64 or 256 bytes by + default, for stability reasons. This attribute, when + present, can be used to request access to the full + 4Kb from the kernel. + + Request to get access to the full 4Kb can be done by + writing a '1' into this attribute file. All other values + are reserved for future use and should not be used by + software at this point. + + The kernel may log the request to the various kernel + logging services. The kernel may decide to ignore the + request if the kernel deems extended configuration space + access not reliable enough for the system or the device. + The kernel may decide to not present this attribute + if the kernel decides extended config space is reliable + and made available by default, or if the kernel decides + that extended configuration space will never be + accessible. + + Software needs to gracefully deal with getting the + access not granted. Software also needs to gracefully deal + with this attribute not being present. + + Due to the fragility of extended configuratio space, + system diagnostic software should only set this attribute + on explicit user request, or in the case of GUI like tools, + at least with explicit user permission. + + + -- If you want to reach me at my work email, use arjan@linux.intel.com For development, discussion and tips for power savings, visit http://www.lesswatts.org -- 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/