Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1759831AbYAJRET (ORCPT ); Thu, 10 Jan 2008 12:04:19 -0500 Received: (majordomo@vger.kernel.org) by vger.kernel.org id S1755938AbYAJREI (ORCPT ); Thu, 10 Jan 2008 12:04:08 -0500 Received: from iolanthe.rowland.org ([192.131.102.54]:49966 "HELO iolanthe.rowland.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with SMTP id S1755408AbYAJREH (ORCPT ); Thu, 10 Jan 2008 12:04:07 -0500 Date: Thu, 10 Jan 2008 12:04:06 -0500 (EST) From: Alan Stern X-X-Sender: stern@iolanthe.rowland.org To: "Rafael J. Wysocki" cc: Johannes Berg , Greg KH , Andrew Morton , Len Brown , Ingo Molnar , ACPI Devel Maling List , LKML , pm list Subject: Re: [PATCH] PM: Acquire device locks on suspend In-Reply-To: <200801101759.10701.rjw@sisk.pl> Message-ID: MIME-Version: 1.0 Content-Type: TEXT/PLAIN; charset=US-ASCII Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Content-Length: 1318 Lines: 31 On Thu, 10 Jan 2008, Rafael J. Wysocki wrote: > > > > > > Also, the kerneldoc for destroy_suspended_device() should contain an > > > > > > extra paragraph warning that the routine should never be called except > > > > > > within the scope of a system sleep transition. In practice this means > > > > > > it has to be directly or indirectly invoked by a suspend or resume > > > > > > method. > > > > > > > > > > Or by a CPU hotplug notifier (that will be the majority of cases, IMO). > > > > > > > > In your patch the call is made in response to a CPU_UP_CANCELED_FROZEN > > > > notification. Isn't it true that this notification is issued only as > > > > part of a system sleep transition? > > > > > > Yes, it is. > > > > So it counts as being indirectly invoked by a resume method. > > Rather, by the resume core. Technically, it's invoked by > enable_nonboot_cpus(), which is not a resume method literally. Okay, then the routine should only be called directly or indirectly from a suspend or resume method or from the suspend or resume core. Alan Stern -- 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/