Received: by 2002:a05:7412:798b:b0:fc:a2b0:25d7 with SMTP id fb11csp381416rdb; Thu, 22 Feb 2024 06:45:00 -0800 (PST) X-Forwarded-Encrypted: i=3; AJvYcCXiimemP+4yWLIZFuOqF+9G5DJRpois9t701/IbRN5zbI5Ee5CxguHR5FXwT2yRXli6dSeapcZOxpBBZPusYs4SHqLSMk0jng5O/mC9Sw== X-Google-Smtp-Source: AGHT+IHT2SjVIK6ebd7SAVlPCjvlXR750m4mtwRqZTcSdH0lo25I2wRVTLpuFggkCd2i1+L5fSxX X-Received: by 2002:a17:906:dfeb:b0:a3e:d16f:973a with SMTP id lc11-20020a170906dfeb00b00a3ed16f973amr7432886ejc.68.1708613100732; Thu, 22 Feb 2024 06:45:00 -0800 (PST) ARC-Seal: i=2; a=rsa-sha256; t=1708613100; cv=pass; d=google.com; s=arc-20160816; b=a8m+C7P6WPJYssyavVcio2R3LqdkVrIuPahyFPLwNapk3/h7994z7N4ZEPGpB9XmKh 0wKnrc8LYNL9sHgciqcDH9KRpod0zzRddbNLkaDrsZXqL0rvkA9vHfwqGW0vz/wyd1Sy g7t2+iASlkUMNn3nC2DXjmp3PdSV98x8oEG33Rb/SkD2U2b+20Eam9UpKkuRn4TpZ18u uXt1cARAtZsvrmaqUVoWc1XK6GjS7s5ZaZlC7ONG3i5+x3fVBUeLMuAyHxhAJ8VgULZn VlJs9UuN944+lo8r6659v/UBq7agZHpnwMqS/0huzQUkTdpas3vTEQQIY8mgT/uQmhN5 8usg== ARC-Message-Signature: i=2; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=in-reply-to:content-disposition:mime-version:list-unsubscribe :list-subscribe:list-id:precedence:references:message-id:subject:cc :to:from:date:dkim-signature; bh=VbAxBwbjGLI4wU8LwT7+5yLezMXg9qM4ehC9Ieptg5E=; fh=985+dJkeqbi8v80MRXaA7lmvi0nlvPDjr1nedYk8R50=; b=G4ynOaoGGTbTW0MnX0JShr3tYcoDWgIrZbC5GtVtjae0Tgf2R7y4k8FHPoJ83Khtem pNFn0EjD6Z5DTaL21sDPOP4Bvpx2SQRXCLSlALp2qGOtZoQiwJYiSWH3K6He6Bo/fg3W nYt5t/EjvJfGS/OcMhtIyo08ZxnRXyzWrF95Nf9uCnR4CYx+pHnpk4dDsqaqdK04ObUA veABqRl4lGia6QyHwmyRQoAjdDcVhxfa8itVw5p2ttlciO7r6gv6wxXETgrYACcDj3+O 2qUzB3+Rx3GL8Uw86+NZ/68D0fpMeQW2ZCZnPvZTqsER0sd7XoPvmCzM2Hv2dcsFPfa/ +Hnw==; dara=google.com ARC-Authentication-Results: i=2; mx.google.com; dkim=pass header.i=@lunn.ch header.s=20171124 header.b="T8/cdYtM"; arc=pass (i=1 spf=pass spfdomain=lunn.ch dkim=pass dkdomain=lunn.ch dmarc=pass fromdomain=lunn.ch); spf=pass (google.com: domain of linux-kernel+bounces-76720-linux.lists.archive=gmail.com@vger.kernel.org designates 147.75.80.249 as permitted sender) smtp.mailfrom="linux-kernel+bounces-76720-linux.lists.archive=gmail.com@vger.kernel.org"; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=lunn.ch Return-Path: Received: from am.mirrors.kernel.org (am.mirrors.kernel.org. [147.75.80.249]) by mx.google.com with ESMTPS id b27-20020a170906491b00b00a3f54e7d472si1239009ejq.771.2024.02.22.06.45.00 for (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Thu, 22 Feb 2024 06:45:00 -0800 (PST) Received-SPF: pass (google.com: domain of linux-kernel+bounces-76720-linux.lists.archive=gmail.com@vger.kernel.org designates 147.75.80.249 as permitted sender) client-ip=147.75.80.249; Authentication-Results: mx.google.com; dkim=pass header.i=@lunn.ch header.s=20171124 header.b="T8/cdYtM"; arc=pass (i=1 spf=pass spfdomain=lunn.ch dkim=pass dkdomain=lunn.ch dmarc=pass fromdomain=lunn.ch); spf=pass (google.com: domain of linux-kernel+bounces-76720-linux.lists.archive=gmail.com@vger.kernel.org designates 147.75.80.249 as permitted sender) smtp.mailfrom="linux-kernel+bounces-76720-linux.lists.archive=gmail.com@vger.kernel.org"; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=lunn.ch Received: from smtp.subspace.kernel.org (wormhole.subspace.kernel.org [52.25.139.140]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by am.mirrors.kernel.org (Postfix) with ESMTPS id 790B01F22A50 for ; Thu, 22 Feb 2024 14:45:00 +0000 (UTC) Received: from localhost.localdomain (localhost.localdomain [127.0.0.1]) by smtp.subspace.kernel.org (Postfix) with ESMTP id 343F61487C5; Thu, 22 Feb 2024 14:44:52 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; dkim=pass (1024-bit key) header.d=lunn.ch header.i=@lunn.ch header.b="T8/cdYtM" Received: from vps0.lunn.ch (vps0.lunn.ch [156.67.10.101]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id D39863DB9A; Thu, 22 Feb 2024 14:44:48 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=156.67.10.101 ARC-Seal:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1708613091; cv=none; b=lq7Q4B8xuRMt2L3Z9bIwjpKvERwog0zUWj9yTW55ZXlyDHL8zuZW2cwqmMneermy/eZPYZXdddx8wHmgDHIsTnaiavi66Tto32LOIkO+G7MF9V4UMmJw87G7GJHypU7TZ84gi1FXyS0i4G6/Vj8wJPnPRWfhtEIl3fwKdfFnA40= ARC-Message-Signature:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1708613091; c=relaxed/simple; bh=FzE/fBdYuA85BtFDd1++ZSMm7MtcnuXSFkSaq0BKaBQ=; h=Date:From:To:Cc:Subject:Message-ID:References:MIME-Version: Content-Type:Content-Disposition:In-Reply-To; b=oej08aWtDLHjnPY21Kz1zLnSTlsf0Q7PTgWaFgHDnSlHwRe3ZLFHc55fG84ipaMaMCx8xQlCn2aca6l/9+f78Wus358PVPQMIr7SEMorTbDGoRq+CdTP2HUSxnKWvE0cAehr4ftZnhpYQp0EWk24fABAyJ83kGj3Wo66Dqu3CsU= ARC-Authentication-Results:i=1; smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=lunn.ch; spf=pass smtp.mailfrom=lunn.ch; dkim=pass (1024-bit key) header.d=lunn.ch header.i=@lunn.ch header.b=T8/cdYtM; arc=none smtp.client-ip=156.67.10.101 Authentication-Results: smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=lunn.ch Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=lunn.ch DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=lunn.ch; s=20171124; h=In-Reply-To:Content-Disposition:Content-Type:MIME-Version: References:Message-ID:Subject:Cc:To:From:Date:From:Sender:Reply-To:Subject: Date:Message-ID:To:Cc:MIME-Version:Content-Type:Content-Transfer-Encoding: Content-ID:Content-Description:Content-Disposition:In-Reply-To:References; bh=VbAxBwbjGLI4wU8LwT7+5yLezMXg9qM4ehC9Ieptg5E=; b=T8/cdYtMn9VEuCOp4VqHtoCvT9 hfuTR5MIkJUrzpzi6md6Tqc9Oz8tg9ZheNk3zLnFv+ZuyrcgBQjZSQRtLKEAqcdEckdulWMP6/tvm hMPpTVmGAFFRTTWRKJSpAcmYLDx5EOd1wohrcd4onplhptCYpzBO+Sa6Ob7Idz0skHbU=; Received: from andrew by vps0.lunn.ch with local (Exim 4.94.2) (envelope-from ) id 1rdAJh-008RyR-U9; Thu, 22 Feb 2024 15:44:53 +0100 Date: Thu, 22 Feb 2024 15:44:53 +0100 From: Andrew Lunn To: "Sverdlin, Alexander" Cc: "linux-pm@vger.kernel.org" , "sre@kernel.org" , "linux-kernel@vger.kernel.org" Subject: Re: [PATCH RFC] power: reset: restart-poweroff: convert to module Message-ID: References: <20240221174610.3560775-1-alexander.sverdlin@siemens.com> <6964c19f-6ffb-4d9a-bc02-ffaf52aa23b5@lunn.ch> <35e30e3260f6669b28dcdde6ea58f480eac3db91.camel@siemens.com> Precedence: bulk X-Mailing-List: linux-kernel@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <35e30e3260f6669b28dcdde6ea58f480eac3db91.camel@siemens.com> > I also didn't understand what is so special about bootloader support > for this functionality if no data is passed to the bootloader. > After ARM-specifics was removed from the code quite some time ago > any platform could re-use the code for the deployments which meant > to be "always on". If i'm remembering correctly.... When the box cold boots, the bootloader can see the boot reason, and chains into Linux. When the user does a shutdown, we re-enter the bootloader, and it sees it is a warm boot. It then spins, rather than chaining into Linux. The process of getting into the bootloader, a watchdog triggered reset, probably disables a lot of clocks and other bits of hardware, so spinning in the bootloader consumes less power than if Linux was to spin. So bootloader needs this functionality, to either chain, or to spin. Andrew