From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-2.5 required=3.0 tests=DKIM_INVALID,DKIM_SIGNED, HEADER_FROM_DIFFERENT_DOMAINS,MAILING_LIST_MULTI,SPF_HELO_NONE,SPF_PASS, URIBL_BLOCKED,USER_AGENT_NEOMUTT autolearn=unavailable autolearn_force=no version=3.4.0 Received: from mail.kernel.org (mail.kernel.org [198.145.29.99]) by smtp.lore.kernel.org (Postfix) with ESMTP id 3B139C31E50 for ; Fri, 14 Jun 2019 22:33:26 +0000 (UTC) Received: from vger.kernel.org (vger.kernel.org [209.132.180.67]) by mail.kernel.org (Postfix) with ESMTP id 1205F20866 for ; Fri, 14 Jun 2019 22:33:26 +0000 (UTC) Authentication-Results: mail.kernel.org; dkim=fail reason="signature verification failed" (2048-bit key) header.d=armlinux.org.uk header.i=@armlinux.org.uk header.b="ijB5goFF" Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1726501AbfFNWdY (ORCPT ); Fri, 14 Jun 2019 18:33:24 -0400 Received: from pandora.armlinux.org.uk ([78.32.30.218]:44554 "EHLO pandora.armlinux.org.uk" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1725981AbfFNWdX (ORCPT ); Fri, 14 Jun 2019 18:33:23 -0400 DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=armlinux.org.uk; s=pandora-2019; h=Sender:In-Reply-To:Content-Type: MIME-Version:References:Message-ID:Subject:Cc:To:From:Date:Reply-To: Content-Transfer-Encoding:Content-ID:Content-Description:Resent-Date: Resent-From:Resent-Sender:Resent-To:Resent-Cc:Resent-Message-ID:List-Id: List-Help:List-Unsubscribe:List-Subscribe:List-Post:List-Owner:List-Archive; bh=rhGH8vXrbfkTpqfy9SG7tV3FRuGTSRoQ0FXi9YN+f4E=; b=ijB5goFFdS+erFs2GYvxqE7Iv oSwFh7xFBAsh9tpJyjt2A7G2wU5AVJnwvUd84S2unF9MbSZi5foK2S3PEREOFfgym9J3u4dn9bPQi MWso1gcq4O2HW7lIgeuk/nyVJke55kSSlWJGzCZCTpd6nyjtv473J8/6rrLQjDg0Wj2pxy3SS33Ee 4GQ+IlMnDM2325lUhbweMDAjaoVT6vP0LSOsXm5mA2GSCRPqwsuA1+c9aN9TbP1T7/nJbx+4IN0qW ZdQFKiyS7xfJ04RmJSrWxG/r+Q/uGbHTnjmOPl/5iQf71qutrsDgxhibUlkZSaT5MPo0ynMy9R5pq cMYSw9lyA==; Received: from shell.armlinux.org.uk ([2002:4e20:1eda:1:5054:ff:fe00:4ec]:38712) by pandora.armlinux.org.uk with esmtpsa (TLSv1.2:ECDHE-RSA-AES256-GCM-SHA384:256) (Exim 4.90_1) (envelope-from ) id 1hbul4-0004DD-OZ; Fri, 14 Jun 2019 23:33:18 +0100 Received: from linux by shell.armlinux.org.uk with local (Exim 4.89) (envelope-from ) id 1hbukw-0002YP-RD; Fri, 14 Jun 2019 23:33:10 +0100 Date: Fri, 14 Jun 2019 23:33:10 +0100 From: Russell King - ARM Linux admin To: Dexuan Cui Cc: Michael Kelley , "linux-acpi@vger.kernel.org" , "rjw@rjwysocki.net" , "lenb@kernel.org" , "robert.moore@intel.com" , "erik.schmauss@intel.com" , Russ Dill , Sebastian Capella , Pavel Machek , Lorenzo Pieralisi , "linux-hyperv@vger.kernel.org" , "linux-kernel@vger.kernel.org" , KY Srinivasan , Stephen Hemminger , Haiyang Zhang , Sasha Levin , "olaf@aepfle.de" , "apw@canonical.com" , "jasowang@redhat.com" , vkuznets , "marcelo.cerri@canonical.com" Subject: Re: [PATCH] ACPI: PM: Export the function acpi_sleep_state_supported() Message-ID: <20190614223310.pwwoefu5qdvcuaiy@shell.armlinux.org.uk> References: <1560536224-35338-1-git-send-email-decui@microsoft.com> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: User-Agent: NeoMutt/20170113 (1.7.2) Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Hi, On Fri, Jun 14, 2019 at 10:19:02PM +0000, Dexuan Cui wrote: > > -----Original Message----- > > From: Michael Kelley > > Sent: Friday, June 14, 2019 1:48 PM > > To: Dexuan Cui ; linux-acpi@vger.kernel.org; > > rjw@rjwysocki.net; lenb@kernel.org; robert.moore@intel.com; > > erik.schmauss@intel.com > > Cc: linux-hyperv@vger.kernel.org; linux-kernel@vger.kernel.org; KY Srinivasan > > ; Stephen Hemminger ; > > Haiyang Zhang ; Sasha Levin > > ; olaf@aepfle.de; apw@canonical.com; > > jasowang@redhat.com; vkuznets ; > > marcelo.cerri@canonical.com > > Subject: RE: [PATCH] ACPI: PM: Export the function > > acpi_sleep_state_supported() > > > > It seems that sleep.c isn't built when on the ARM64 architecture. Using > > acpi_sleep_state_supported() directly in hv_balloon.c will be problematic > > since hv_balloon.c needs to be architecture independent when the > > Hyper-V ARM64 support is added. If that doesn't change, a per-architecture > > wrapper will be needed to give hv_balloon.c the correct information. This > > may affect whether acpi_sleep_state_supported() needs to be exported vs. > > just removing the "static". I'm not sure what the best approach is. > > > > Michael > > + some ARM experts who worked on arch/arm/kernel/hibernate.c. > > drivers/acpi/sleep.c is only built if ACPI_SYSTEM_POWER_STATES_SUPPORT > is defined, but it looks this option is not defined on ARM. > > It looks ARM does not support the ACPI S4 state, then how do we know > if an ARM host supports hibernation or not? Don't forget that Linux does not support ACPI on 32-bit ARM, which is quite different from the situation on 64-bit ARM. arch/arm/kernel/hibernate.c is only for 32-bit ARM, and is written with the assumption that there is no interaction required with any firmware to save state, and later restore state upon resuming. Or am I missing something? -- RMK's Patch system: https://www.armlinux.org.uk/developer/patches/ FTTC broadband for 0.8mile line in suburbia: sync at 12.1Mbps down 622kbps up According to speedtest.net: 11.9Mbps down 500kbps up