From mboxrd@z Thu Jan 1 00:00:00 1970 From: Pavel Machek Subject: Re: [linux-pm] [PATCH 3/5] [pm] Respect the actual device power states in sysfs interface Date: Mon, 20 Feb 2006 19:10:40 +0100 Message-ID: <20060220181040.GI19156@elf.ucw.cz> References: <20060218155543.GE5658@openzaurus.ucw.cz> <20060220000907.GE15608@elf.ucw.cz> <20060220002053.GF15608@elf.ucw.cz> <20060220004142.GI15608@elf.ucw.cz> <20060220175842.GH19156@elf.ucw.cz> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Return-path: Content-Disposition: inline In-Reply-To: Sender: linux-kernel-owner@vger.kernel.org To: Patrick Mochel Cc: greg@kroah.com, torvalds@osdl.org, akpm@osdl.org, linux-pm@osdl.org, linux-kernel@vger.kernel.org List-Id: linux-pm@vger.kernel.org On Po 20-02-06 10:08:36, Patrick Mochel wrote: > > On Mon, 20 Feb 2006, Pavel Machek wrote: > > > Hi! > > > > > > > > Compatibility is already restored. > > > > > > > > > > No, the interface is currently broken. The driver core does not > > > > > dictate > > > > > > > > There were two different interfaces, one accepted 0 and 2, everything > > > > else was invalid, and second accepted 0, 1, 2, 3. > > > > > > > > If you enter D2 on echo 2, you are breaking compatibility with 2.6.15 > > > > or something like that. > > > > > > I don't see how this is true. If a process writes "2" to a PCI device's > > > state file, what else are sane things to do? > > > > In some kernel version (2.6.15, iirc), device entered D3 if you wrote > > "2" to state file, and there are programs out there that depend on > > it. > > Like what? Search archives. Some PCMCIA, IIRC. > > > You dropped the fundamental point, and I don't understand why you disagree > > > with it - the driver core should not be dictating policy to the downstream > > > drivers. It is currently doing this by filtering the power state that is > > > passed in via the "state" file. > > > > That's best we can do to stay compatible. Please introduce new file, > > and make states string-based. > > You are still overlooking the point - the core should not be filtering the > values. It currently is, but it's trivial to fix. What is your issue with > that? That you are breaking compatibility in middle of 2.6 series. And very close to 2.6.16 at that. Pavel -- Web maintainer for suspend.sf.net (www.sf.net/projects/suspend) wanted...