From mboxrd@z Thu Jan 1 00:00:00 1970 From: Thomas Gleixner Subject: Re: [PATCH] - race-free suspend. Was: Re: [linux-pm] [PATCH 0/8] Suspend block api (version 8) Date: Wed, 2 Jun 2010 14:26:24 +0200 (CEST) Message-ID: References: <201006010005.19554.rjw@sisk.pl> <20100601090023.788cabf4@notabene.brown> <201006010232.20263.rjw@sisk.pl> <20100601113309.609349fd@notabene.brown> <20100601122012.1edeaf48@notabene.brown> <20100602153235.340a7852@notabene.brown> <20100602180614.729246ea@notabene.brown> Mime-Version: 1.0 Content-Type: MULTIPART/MIXED; BOUNDARY="8323328-1357201380-1275481585=:2933" Return-path: Received: from www.tglx.de ([62.245.132.106]:41346 "EHLO www.tglx.de" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1757713Ab0FBM1W (ORCPT ); Wed, 2 Jun 2010 08:27:22 -0400 In-Reply-To: Sender: linux-omap-owner@vger.kernel.org List-Id: linux-omap@vger.kernel.org To: =?ISO-8859-15?Q?Arve_Hj=F8nnev=E5g?= Cc: Neil Brown , "Rafael J. Wysocki" , Alan Stern , Felipe Balbi , Peter Zijlstra , "Paul@smtp1.linux-foundation.org" , LKML , Florian Mickler , Linux OMAP Mailing List , Linux PM , Alan Cox , James Bottomley This message is in MIME format. The first part should be readable text, while the remaining parts are likely unreadable without MIME-aware tools. --8323328-1357201380-1275481585=:2933 Content-Type: TEXT/PLAIN; charset=ISO-8859-1 Content-Transfer-Encoding: 8BIT On Wed, 2 Jun 2010, Arve Hjønnevåg wrote: > 2010/6/2 Thomas Gleixner : > > On Wed, 2 Jun 2010, Arve Hjønnevåg wrote: > >> 2010/6/2 Neil Brown : > >> > There would still need to be some sort of communication between the the > >> > suspend daemon on any event daemon to ensure that the events had been > >> > processed.  This could be very light weight interaction.  The point though is > >> > that with this patch it becomes possible to avoid races.  Possible is better > >> > than impossible. > >> > > >> > >> We already have a solution. I don't think rejecting our solution but > >> merging a worse solution should be the goal. > > > > That's not the goal at all. We want a solution which is acceptable for > > android and OTOH does not get into the way of other approaches. > > > > I don't actually think the suspend blocker patchset get in the way of > anything else. > > > The main problem I have is that suspend blockers are only addressing > > one particular problem space of power management. > > > > We have more requirements than that, e.g. an active device transfer > > requires to prevent the idle code to select a deep power state due to > > latency requirements. > > > > So we then have to implement two mechanisms in the relevant drivers: > > > >   1) telling the idle code to limit latency > >   2) telling the suspend code not to suspend > > And 3) telling the idle code to not enter low power modes that disrupt > active interrupts or clocks. > > Our wakelock code handles 2 and 3, but I removed support for 3 on > request since you can hack it by specifying a latency value that you > know the low power mode cannot support. You are mixing concepts. clock domains and power domains are a separate issue which are already handled by the run time power management code and the clock framework. The interrupt latency is a QoS requirement and has nothing to do with power domains and clock domains simply because I can go deeper w/o violating the clock and power domain constraints when the latency allows it. > > My main interest is to limit it to one mechanism, which is QoS based > > and let idle and suspend make the appropriate decisions based on that > > information. > > > > We can use one mechanism for this, but we still have to specify both. > To me this is just another naming argument and not a good reason to > not merge the suspend blocker code. You have to modify the same The main objection against suspend blocker is the user space interface / ABI issue, not the driver code which we can fix in no time. But we cannot fix it once it is glued into a user space interface. I don't care about adding two empty static inlines into a header file, which allows to merge the android drivers, but I care much about giving a guaranteed behaviour to user space. Thanks, tglx --8323328-1357201380-1275481585=:2933--