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 Received: from smtp1.osuosl.org (smtp1.osuosl.org [140.211.166.138]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.lore.kernel.org (Postfix) with ESMTPS id 7D87FC61DD3 for ; Fri, 28 Aug 2026 13:58:49 +0000 (UTC) Received: from localhost (localhost [127.0.0.1]) by smtp1.osuosl.org (Postfix) with ESMTP id 466CD80F97; Fri, 28 Aug 2026 13:58:49 +0000 (UTC) X-Virus-Scanned: amavis at osuosl.org Received: from smtp1.osuosl.org ([127.0.0.1]) by localhost (smtp1.osuosl.org [127.0.0.1]) (amavis, port 10024) with ESMTP id FFJp_O_a-H_d; Fri, 28 Aug 2026 13:58:48 +0000 (UTC) X-Comment: SPF check N/A for local connections - client-ip=140.211.166.142; helo=lists1.osuosl.org; envelope-from=u-boot-bounces@lists.u-boot-project.org; receiver= DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=lists.u-boot-project.org; s=default; t=1787925528; bh=Xd6RxdTTUWQOY6WMxOgdq0W0f83Qbu7dTg6cDuQfVCI=; h=From:To:Cc:Subject:Date:In-Reply-To:References:List-Id: List-Unsubscribe:List-Archive:List-Post:List-Help:List-Subscribe: From; b=zZeplRxN8Q1hOFfoPGUJvm1eZXECLEW5pVAeNaRwx5/9NymD2nl8iPg1EN4syvgnH RrlCHl5C6MVYHVLdwaOT1HZ6bKYi0xu/s2Vm4tQFUHHg3A3vI3Ayk+CYTlpjnFD6a8 9o8fxm/tjLxiARXL2S0Dx5u49vm2JXE2+kGLV6qhELLdCuiYcotTf5Aj3b4OuZQVEm ZeMMuCHyYh8p3zW1NKmlabNUroyXrlXnmHmYp6qh7+lI43K6enmww6k957UKZsPbEm so6Za3RMHoHaQzcYrjkcvIDa3POaZCqpkD3eR2NEAmo6+DIYCo6kvznDkC3az6tifO 8lXClC9y4nP2Q== Received: from lists1.osuosl.org (lists1.osuosl.org [140.211.166.142]) by smtp1.osuosl.org (Postfix) with ESMTP id 0E31680F6D; Fri, 28 Aug 2026 13:58:48 +0000 (UTC) Received: from smtp2.osuosl.org (smtp2.osuosl.org [140.211.166.133]) by lists1.osuosl.org (Postfix) with ESMTP id 2463B78B for ; Fri, 28 Aug 2026 13:58:46 +0000 (UTC) Received: from localhost (localhost [127.0.0.1]) by smtp2.osuosl.org (Postfix) with ESMTP id 0AE12403A1 for ; Fri, 28 Aug 2026 13:58:46 +0000 (UTC) X-Virus-Scanned: amavis at osuosl.org Received: from smtp2.osuosl.org ([127.0.0.1]) by localhost (smtp2.osuosl.org [127.0.0.1]) (amavis, port 10024) with ESMTP id F8kG1xgLyR80 for ; Fri, 28 Aug 2026 13:58:45 +0000 (UTC) Received-SPF: Pass (mailfrom) identity=mailfrom; client-ip=185.246.84.56; helo=smtpout-02.galae.net; envelope-from=richard.genoud@bootlin.com; receiver= Authentication-Results: smtp2.osuosl.org; dmarc=pass (p=reject dis=none) header.from=bootlin.com Authentication-Results: smtp2.osuosl.org; dkim=pass (2048-bit key) header.d=bootlin.com header.i=@bootlin.com header.a=rsa-sha256 header.s=dkim header.b=1uxzylxj Received: from smtpout-02.galae.net (smtpout-02.galae.net [185.246.84.56]) by smtp2.osuosl.org (Postfix) with ESMTPS id F2FA440317 for ; Fri, 28 Aug 2026 13:58:44 +0000 (UTC) Received: from smtpout-01.galae.net (smtpout-01.galae.net [212.83.139.233]) by smtpout-02.galae.net (Postfix) with ESMTPS id 2E0BE1A18A3; Fri, 28 Aug 2026 13:58:43 +0000 (UTC) Received: from mail.galae.net (mail.galae.net [212.83.136.155]) by smtpout-01.galae.net (Postfix) with ESMTPS id 0162B60537; Fri, 28 Aug 2026 13:58:43 +0000 (UTC) Received: from [127.0.0.1] (localhost [127.0.0.1]) by localhost (Mailerdaemon) with ESMTPSA id 4289C11C78068; Fri, 28 Aug 2026 15:58:39 +0200 (CEST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=bootlin.com; s=dkim; t=1787925521; h=from:subject:date:message-id:to:cc:mime-version: content-transfer-encoding:in-reply-to:references; bh=Xd6RxdTTUWQOY6WMxOgdq0W0f83Qbu7dTg6cDuQfVCI=; b=1uxzylxjxjUYU+vwXSwvAfGK9nUZEjek7C82wTKRAqX4JmOWx/zfgUaDg+VwlntMMGRb6g JxMj8hcJVnXz3+w5Gyg3HlMTqXMoRJBaoB2TkM6YhMOGPG+80qHA4IjqlLR4vZDoGc056w QcD/IzrxbkwR0MhcK5vjIMl3oPfSwbUY02C5oQLYF1u48MvA0FDPTHAsg3HxsuLrXvgzT6 ckiZ4rDa3PxdsJaU3AwV5z/C8VU7GQ0DMfJOqUN8AftGUA4lbphJYskrVmx22ET+0hPVty 0DS8bxhUJ7zoBzYLxz+e6U9W5qaJfEES5RVY2u3OUD9uHeUySX57Fb7ZLs76QQ== From: "Richard Genoud (TI)" To: Tom Rini , Manorit Chawdhry , Apurva Nandan , "Andrew F . Davis" , Vignesh Raghavendra , Bryan Brattlof , Vaishnav Achath , Jayesh Choudhary , Simon Glass , Alper Nebi Yasak Cc: Markus Schneider-Pargmann , Kendall Willis , Udit Kumar , Abhash Kumar , Thomas Richard , Gregory CLEMENT , Thomas Petazzoni , Richard Genoud , u-boot@lists.u-boot-project.org Subject: [PATCH v5 17/21] arm: mach-k3: j722s: Enable LPM resume flow Date: Fri, 28 Aug 2026 15:57:26 +0200 Message-ID: <20260828135730.1565643-18-richard.genoud@bootlin.com> X-Mailer: git-send-email 2.47.3 In-Reply-To: <20260828135730.1565643-1-richard.genoud@bootlin.com> References: <20260828135730.1565643-1-richard.genoud@bootlin.com> MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Last-TLS-Session-Version: TLSv1.3 X-BeenThere: u-boot@lists.u-boot-project.org X-Mailman-Version: 2.1.30 Precedence: list List-Id: U-Boot discussion List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: u-boot-bounces@lists.u-boot-project.org Add support for resuming from suspend in board_init_f for J722S. The resume state of the SOC is identified and lpm resume sequence is followed accordingly: - Extract context address from devicetree and send to TIFS. - Power on the rproc cluster. - Replay the certificates attached to saved images of ATF and OPTEE. - Resume sequence for context restore and rproc resume. - Image entry to DM firmware. The context address area is firewalled by TIFS to protect it from other hosts. Signed-off-by: Richard Genoud (TI) --- arch/arm/mach-k3/j722s/j722s_init.c | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/arch/arm/mach-k3/j722s/j722s_init.c b/arch/arm/mach-k3/j722s/j722s_init.c index 1180c75f551d..e98c9d93ac53 100644 --- a/arch/arm/mach-k3/j722s/j722s_init.c +++ b/arch/arm/mach-k3/j722s/j722s_init.c @@ -14,6 +14,7 @@ #include "../sysfw-loader.h" #include "../common.h" +#include "../lpm-common.h" struct fwl_data cbass_main_fwls[] = { { "FSS_DAT_REG3", 7, 8 }, @@ -37,7 +38,7 @@ static void store_boot_info_from_rom(void) sizeof(struct rom_extended_boot_data)); } -static void ctrl_mmr_unlock(void) +void ctrl_mmr_unlock(void) { /* Unlock all WKUP_CTRL_MMR0 module registers */ mmr_unlock(WKUP_CTRL_MMR0_BASE, 0); @@ -186,6 +187,9 @@ void board_init_f(ulong dummy) k3_spl_init(); k3_mem_init(); + if (j7xx_board_is_resuming()) + do_resume(); /* no return */ + setup_qos(); if (IS_ENABLED(CONFIG_ESM_K3)) {