Received: by 2002:a05:6a10:1a4d:0:0:0:0 with SMTP id nk13csp2616042pxb; Thu, 3 Feb 2022 10:12:34 -0800 (PST) X-Google-Smtp-Source: ABdhPJyiSTQvHKuWO4k4NWlUj8TScYMoMLOAMjSkOC/pUOy266bqMJ8b/ocfPM9nIRFCbzW1dxH1 X-Received: by 2002:a17:906:30c9:: with SMTP id b9mr31163991ejb.377.1643911954414; Thu, 03 Feb 2022 10:12:34 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1643911954; cv=none; d=google.com; s=arc-20160816; b=Y45NMUcg7LPoVTGrNAXLFUtKDR4xhaGZfFRqR+B7YtDtAS/kguiMsj83ot6Swye5pm holr4JhL81/3R6PHfPmj4f2rAxBBBmvkUbb+v73OZTd1XhC+Jw+yKaQoCi2auGN1pu00 fRM2H3iz+r8iol938MxkElaV8P5jdmnF1ZM1sW5AO/C25pEXslyb2IRNYE74l2otcJU2 cFtWPHQQeeIVQyRHiTMPadzfpT5AK1MdQLH+zJRL4joua3fux6VXbkKrV0Bu+6kgEuY6 VUI3sfpSyJTLm9BAJzeCYvtAH67uG6IOwbu281/IlHGQalDmn6WqAa7kEwxFf6TZKZjA TroQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:content-transfer-encoding:in-reply-to:from :references:cc:to:content-language:subject:user-agent:mime-version :date:message-id:dkim-signature; bh=WWOapjCQjVg9c89BH1eP10gAd2LFeCCpAH4S3v6BFzM=; b=AdiX2FNMMDSW/woVMJC2pqp7c2IvvN8hq9VhWHw+dP+ohR8C9eOGXZsdlf/D4KOyh0 U3Z69DE8vpwjKKuBRI6FU7rn/4/dXpaJXA3z3nuv/GHhG12rxdM3obT1XRJuNELTREaX FKkFtK96Nux3h+L08vhqmlm6bECFv12j/4ghwl1jZ5cJLi6umopQN3G0qDYENBs3VWb0 JwULZgzRXVgchZAWScAvu9eSATGOkE8BlNSiGWJii5xjoO+N/HP1iFjrlPJ/mW5Z5LSY kxJbGdcZyTdoT1K0Oo9V5BEV6Ba1GdGBcqle3EdjdwqEvW+mCS6WnthLKO5ZrYlqw5Qo V6VQ== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@gmail.com header.s=20210112 header.b=P213NYhn; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=QUARANTINE dis=NONE) header.from=gmail.com Return-Path: Received: from out1.vger.email (out1.vger.email. [2620:137:e000::1:20]) by mx.google.com with ESMTP id m9si11514352edd.66.2022.02.03.10.12.08; Thu, 03 Feb 2022 10:12:34 -0800 (PST) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) client-ip=2620:137:e000::1:20; Authentication-Results: mx.google.com; dkim=pass header.i=@gmail.com header.s=20210112 header.b=P213NYhn; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=QUARANTINE dis=NONE) header.from=gmail.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1351138AbiBCRgd (ORCPT + 99 others); Thu, 3 Feb 2022 12:36:33 -0500 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:45146 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S233512AbiBCRgb (ORCPT ); Thu, 3 Feb 2022 12:36:31 -0500 Received: from mail-pf1-x42a.google.com (mail-pf1-x42a.google.com [IPv6:2607:f8b0:4864:20::42a]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 26ED5C061714 for ; Thu, 3 Feb 2022 09:36:31 -0800 (PST) Received: by mail-pf1-x42a.google.com with SMTP id i186so2863956pfe.0 for ; Thu, 03 Feb 2022 09:36:31 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20210112; h=message-id:date:mime-version:user-agent:subject:content-language:to :cc:references:from:in-reply-to:content-transfer-encoding; bh=WWOapjCQjVg9c89BH1eP10gAd2LFeCCpAH4S3v6BFzM=; b=P213NYhnN21etN0dyRcDdZH1ks0gm7dddQKmpVQs65W2g7eXM44L6msfH5gfH8UC2J RaR73rUGM74+Ic4NXvnZuOFLv9NsX/uuqynhMcO/8iwQBiphTBw/eJZw+QoCJeplqq6R BBOnGRm+heiB55wc5aYXIPRy9yWcrf+dJDSIyi/Jyr2+857zeWimfQly242Q1976GHan W0ZCQPCu3ry0kjPJqlov85Q4SVqYU8tomdfGpfOoP8RPrXd4XhJxqccOCnWPqzoxO9IB sbHcx86PVw8rcUQH+xXufgd0MUv8bKvh+hfkWH/ZREDQ2Q/toKuGg6IZlVy3GcsxDe/K lF0A== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; h=x-gm-message-state:message-id:date:mime-version:user-agent:subject :content-language:to:cc:references:from:in-reply-to :content-transfer-encoding; bh=WWOapjCQjVg9c89BH1eP10gAd2LFeCCpAH4S3v6BFzM=; b=LasN5NeiIL5VXJhTnU8XmsAxbqd9vfBy1jDBg7tItCY/nGz3/mLzqD2qm6IrMzOTiK er00n7U9i2WtAsgP8WBkt3vMM7RdhiOP3bDshHo+UtlrRjnqvT2EFf+PNu0YBb4aQC/H BINzrtSx0thX76BcrRFN83djmi+ttMR4F3IzOygQ5aGVtd2S5J22bylPCxJIuWPqdcr1 LNHqMruT9Uf6PjGyeIEnX1wFKNrex8J+knBoP0pJB94r7/Dascu+XiBIuvGFr50NkMUn SrLd+wC3tZqCaBHlN5A5KWIM7CRtZEMk2rVRT9XAPNNBFJur5in74VX9kqYX43if/IA/ O2Ew== X-Gm-Message-State: AOAM533JKzqsrRJGnkFvhKssYszNMvuCftGDoJZyM+t03bz3nI4Wamaz UYFK4L9EoM08gPPTE6F0vPA= X-Received: by 2002:a62:b40e:: with SMTP id h14mr35036831pfn.79.1643909790568; Thu, 03 Feb 2022 09:36:30 -0800 (PST) Received: from [192.168.1.3] (ip72-194-116-95.oc.oc.cox.net. [72.194.116.95]) by smtp.gmail.com with ESMTPSA id pf4sm12465721pjb.35.2022.02.03.09.36.29 (version=TLS1_3 cipher=TLS_AES_128_GCM_SHA256 bits=128/128); Thu, 03 Feb 2022 09:36:30 -0800 (PST) Message-ID: <34938793-cecc-2ad8-a4eb-81bb278ce9b5@gmail.com> Date: Thu, 3 Feb 2022 09:36:28 -0800 MIME-Version: 1.0 User-Agent: Mozilla/5.0 (Windows NT 10.0; Win64; x64; rv:91.0) Gecko/20100101 Thunderbird/91.5.0 Subject: Re: [PATCH 0/4] Broadcom STB PM PSCI extensions Content-Language: en-US To: Sudeep Holla , Florian Fainelli Cc: linux-arm-kernel@lists.infradead.org, "maintainer:BROADCOM BCM7XXX ARM ARCHITECTURE" , Mark Rutland , Lorenzo Pieralisi , open list References: <20220122035421.4086618-1-f.fainelli@gmail.com> <20220203111435.e3eblv47ljkwkvwf@bogus> From: Florian Fainelli In-Reply-To: <20220203111435.e3eblv47ljkwkvwf@bogus> Content-Type: text/plain; charset=UTF-8; format=flowed Content-Transfer-Encoding: 7bit Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On 2/3/2022 3:14 AM, Sudeep Holla wrote: > On Fri, Jan 21, 2022 at 07:54:17PM -0800, Florian Fainelli wrote: >> Hi all, >> >> This patch series contains the Broadcom STB PSCI extensions which adds >> some additional functions on top of the existing standard PSCI interface >> which is the reason for having the driver implement a custom >> suspend_ops. >> >> These platforms have traditionally supported a mode that is akin to >> ACPI's S2 with the CPU in WFI and all of the chip being clock gated >> which is entered with "echo standby > /sys/power/state". Additional a >> true suspend to DRAM as defined in ACPI by S3 is implemented with "echo >> mem > /sys/power/state". > > How different is the above "standby" state compare to the standard "idle" > (a.k.a suspend-to-idle which is different from system-to-ram/S3) ? There are a few differences: - s2idle does not power gate the secondary CPUs - s2idle requires the use of in-band interrupts for wake-up The reasons for implementing "standby" are largely two fold: - we need to achieve decent power savings (typically below 0.5W for the whole system while allowing Wake-on-WLAN, GPIO, RTC, infrared, etc.) - we have a security subsystem that requires the CPUs to be either power gated or idle in order the hardware state machine that lets the system enter such a state and allows the out of band interrupts from being wake-up sources > Suspend to idle takes all the CPUs to lowest possible power state instead > of cpu-hotplug in S2R. Also I assume some userspace has to identify when > to enter "standby" vs "mem" right ? I am trying to see how addition of > "idle" changes that(if it does). Sorry for too many questions. > Right that user-space in our case is either custom (like RDK, or completely custom), or is Android. For Android it looks like we are carrying a patch that makes "mem" de-generate into "standby" but this is largely because we had historically problems with "mem" that are being addressed (completely orthogonal). I did not consider it as a viable option at the time, but if we were to implement "standby" in drivers/firmware/psci/psci.c would that be somewhat acceptable? -- Florian