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 phobos.denx.de (phobos.denx.de [85.214.62.61]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (No client certificate requested) by smtp.lore.kernel.org (Postfix) with ESMTPS id 023C2C05027 for ; Thu, 2 Feb 2023 18:16:35 +0000 (UTC) Received: from h2850616.stratoserver.net (localhost [IPv6:::1]) by phobos.denx.de (Postfix) with ESMTP id 546AB85DDC; Thu, 2 Feb 2023 19:15:21 +0100 (CET) Authentication-Results: phobos.denx.de; dmarc=pass (p=none dis=none) header.from=gmail.com Authentication-Results: phobos.denx.de; spf=pass smtp.mailfrom=u-boot-bounces@lists.denx.de Authentication-Results: phobos.denx.de; dkim=pass (2048-bit key; unprotected) header.d=gmail.com header.i=@gmail.com header.b="N/ENjt77"; dkim-atps=neutral Received: by phobos.denx.de (Postfix, from userid 109) id 19F3885E16; Thu, 2 Feb 2023 19:14:34 +0100 (CET) Received: from mail-wm1-x32e.google.com (mail-wm1-x32e.google.com [IPv6:2a00:1450:4864:20::32e]) (using TLSv1.3 with cipher TLS_AES_128_GCM_SHA256 (128/128 bits)) (No client certificate requested) by phobos.denx.de (Postfix) with ESMTPS id 7BAF585D10 for ; Thu, 2 Feb 2023 19:14:27 +0100 (CET) Authentication-Results: phobos.denx.de; dmarc=pass (p=none dis=none) header.from=gmail.com Authentication-Results: phobos.denx.de; spf=pass smtp.mailfrom=clamor95@gmail.com Received: by mail-wm1-x32e.google.com with SMTP id hn2-20020a05600ca38200b003dc5cb96d46so4334535wmb.4 for ; Thu, 02 Feb 2023 10:14:27 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20210112; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:from:to:cc:subject:date :message-id:reply-to; bh=+vWFP4hZIPC4GvldRbRJyLgcXIXmacZjzAD6wm1ZwWs=; b=N/ENjt77GTdrPqX3a+hAOphl1YcXcTi9eVcvEBh0plt//eywjWng8kFp130j+hido+ +XO2kN2WXdoxzbNiWGC1lJDp3p6ppVuNxDRv8FAAM/pMtddH/++hVa/fVKWsxhAWI1Ub 4HSg4X3YIodw2ivvNNhkyZjM1hWF338rnrfIszcrM8pno9+qQqKUg+xPx0tfI10uUKRn RRjQ60xPDHrxTuzue9dOWXybNBQIOB/sleChxi5iXDKPSYubsbScdW+Nbu0mwy83O9uw PgL7UGmyM+9pcELv+l8PQxIOfflvCNkFFY0s7jfs5fcDgJLJwwnZW5woq0lbP6woA4Pc R9dw== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:x-gm-message-state:from:to:cc :subject:date:message-id:reply-to; bh=+vWFP4hZIPC4GvldRbRJyLgcXIXmacZjzAD6wm1ZwWs=; b=IPv4QYdyj4+bV8JlFOEKq1vXFi+tIvtzsGhwv8rZobf1GmblGtELWYAtf2GoMrKkqc laLCCRRyEFdTbiJxpBvX3tgbAWxz7Wso4pLABn6q3L/ojWyOvMwKRdljZYcSI/5XSbDV bNjyTa4J2KG6PBJVAsKVpc4qrcP7UMZvwmYsIjqDy4U4LkZs3LVxPmuRHZ/mn+Zk1cd8 jbG2LQxriCdu5fW9R7W7eTiAtyI8HKyPmC78H4EFK5ZmVe9WMpzpEG3rsnwAhjY/ukBE WpzwxbKLoMRQDhhMVEWvflx61T6Vc+duPiMMGwmCh+HrjWSyF2mlIShgZAVwvsevX6/v ebkQ== X-Gm-Message-State: AO0yUKU5DafNTm9aVfVXswifyqgnoVmFxSDqjOiIPIZVBv2TOCGEhw3W KucFn36ZvukXHfBIS0LsIs0= X-Google-Smtp-Source: AK7set+eY/xqzT0qj1pqAOeN00n/YSY2UV1HeSQuU2Y9N7LKxsm6crI7JARx6arTTyjMWYW/OIphvA== X-Received: by 2002:a05:600c:1e8d:b0:3df:deb5:6ff5 with SMTP id be13-20020a05600c1e8d00b003dfdeb56ff5mr2440468wmb.24.1675361666830; Thu, 02 Feb 2023 10:14:26 -0800 (PST) Received: from xeon.. ([188.163.112.54]) by smtp.gmail.com with ESMTPSA id x14-20020a1c7c0e000000b003daffc2ecdesm5516543wmc.13.2023.02.02.10.14.25 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Thu, 02 Feb 2023 10:14:26 -0800 (PST) From: Svyatoslav Ryhel To: Tom Warren , Alban Bedel , Stephen Warren , Marcel Ziswiler , Allen Martin , Jagan Teki , Lukasz Majewski , Marek Vasut , Svyatoslav Ryhel , Ramin Khonsari , Thierry Reding , Maxim Schwalm , Dmitry Osipenko Cc: u-boot@lists.denx.de Subject: [PATCH v2 09/16] ARM: tegra: add late init support Date: Thu, 2 Feb 2023 20:13:50 +0200 Message-Id: <20230202181357.4455-10-clamor95@gmail.com> X-Mailer: git-send-email 2.37.2 In-Reply-To: <20230202181357.4455-1-clamor95@gmail.com> References: <20230202181357.4455-1-clamor95@gmail.com> MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-BeenThere: u-boot@lists.denx.de X-Mailman-Version: 2.1.39 Precedence: list List-Id: U-Boot discussion List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: u-boot-bounces@lists.denx.de Sender: "U-Boot" X-Virus-Scanned: clamav-milter 0.103.6 at phobos.denx.de X-Virus-Status: Clean Late init function allows passing values like identifiers and perform device specific configurations of pre-boot stage. Tested-by: Andreas Westman Dorcsak # ASUS TF T30 Tested-by: Svyatoslav Ryhel # LG P895 T30 Signed-off-by: Svyatoslav Ryhel --- arch/arm/include/asm/arch-tegra/sys_proto.h | 6 ++++++ arch/arm/mach-tegra/board2.c | 2 ++ 2 files changed, 8 insertions(+) diff --git a/arch/arm/include/asm/arch-tegra/sys_proto.h b/arch/arm/include/asm/arch-tegra/sys_proto.h index c3a2673e6c..566666a9a0 100644 --- a/arch/arm/include/asm/arch-tegra/sys_proto.h +++ b/arch/arm/include/asm/arch-tegra/sys_proto.h @@ -31,4 +31,10 @@ int tegra_lcd_pmic_init(int board_id); */ int nvidia_board_init(void); +/** + * nvidia_board_late_init() - perform any board-specific + * init on late stages + */ +void nvidia_board_late_init(void); + #endif diff --git a/arch/arm/mach-tegra/board2.c b/arch/arm/mach-tegra/board2.c index c7a45f4ff8..0df18360ca 100644 --- a/arch/arm/mach-tegra/board2.c +++ b/arch/arm/mach-tegra/board2.c @@ -56,6 +56,7 @@ __weak void gpio_early_init_uart(void) {} __weak void pin_mux_display(void) {} __weak void start_cpu_fan(void) {} __weak void cboot_late_init(void) {} +__weak void nvidia_board_late_init(void) {} #if defined(CONFIG_TEGRA_NAND) __weak void pin_mux_nand(void) @@ -267,6 +268,7 @@ int board_late_init(void) #endif start_cpu_fan(); cboot_late_init(); + nvidia_board_late_init(); return 0; } -- 2.37.2