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 764DBC4332F for ; Tue, 18 Oct 2022 22:35:48 +0000 (UTC) Received: from h2850616.stratoserver.net (localhost [IPv6:::1]) by phobos.denx.de (Postfix) with ESMTP id 2CD4C84EA3; Wed, 19 Oct 2022 00:35:46 +0200 (CEST) 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="AyOOOjz3"; dkim-atps=neutral Received: by phobos.denx.de (Postfix, from userid 109) id 56E7C84EA7; Wed, 19 Oct 2022 00:35:44 +0200 (CEST) Received: from mail-ed1-x52d.google.com (mail-ed1-x52d.google.com [IPv6:2a00:1450:4864:20::52d]) (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 6C67384E9B for ; Wed, 19 Oct 2022 00:35:41 +0200 (CEST) Authentication-Results: phobos.denx.de; dmarc=pass (p=none dis=none) header.from=gmail.com Authentication-Results: phobos.denx.de; spf=pass smtp.mailfrom=jbx6244@gmail.com Received: by mail-ed1-x52d.google.com with SMTP id s30so22650537eds.1 for ; Tue, 18 Oct 2022 15:35:41 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20210112; h=content-transfer-encoding:in-reply-to:from:content-language :references:cc:to:subject:user-agent:mime-version:date:message-id :from:to:cc:subject:date:message-id:reply-to; bh=ZFMvdNOWrETIdB2HyBWagBXCziF/fMY3oPo5ucLdPtk=; b=AyOOOjz3srChpm7v8jEfykzbvlPMTKzaERP3f/Uak6JqnL5feR1/MdKYhkJgcjYSGw Djn3R01TjnQa3ZJ5G4CYz+EBph14T/0uB/3JAIDI50SKVZOOLimw5ifhT46YTSP4bM98 YY0XXYOxHgA7YWKnheIdC+yYzSxggafoo3sBHaX99vS0n+X2WbtVs2y7eVDygb+l+5L4 /zJDuNzVcfR6AENeDFEfR3LQJrWEMJAxq8w3t9t8FlOh5ySLsplVIaD0/rZughwFkMTz nZifQveIPtvnm5Eqhmn/sQIeKMD+1DbuybI5nu+hQuKH960YJXd44MmSKqCVTdssIc/m 3sOg== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; h=content-transfer-encoding:in-reply-to:from:content-language :references:cc:to:subject:user-agent:mime-version:date:message-id :x-gm-message-state:from:to:cc:subject:date:message-id:reply-to; bh=ZFMvdNOWrETIdB2HyBWagBXCziF/fMY3oPo5ucLdPtk=; b=Fq366PayZ4vskGD4FpyTMWLA2Plgac458+ojf5cyIgMrxY9wKjPwYs9Yh1w17g+3ze 3r97ds0OlDh+YKpMMLi9H6QbHFC1eV6xn1GOu0coIQSoSQDrro74wjWVkEUR1ThghqfC GVw14e8YnMZ0hBfSH/qA4zLZ+3Pm9BwAa1aJlOqzwaGdc01qhqhXDPgtUNjkfe8/tpaU xBI0fW0jo2o5Wr0jzt9ucXpUN4f4UYa25hithwL5LeVGezJcAOH+3S+/Me13Q9zN7GDe qKAT8IRAqtGqWj0yGa80aRFE2WdtRAEpKVo6RXqN59QH5NcsgiU5aB/aRHwme8lLjAbI GVSw== X-Gm-Message-State: ACrzQf2VZHzn/oAJ4Ma21SOhRrbscBtzTx9y/xEaErsQRWDrWm1GUxXK aRQHVodBjo29gIgMoFcEnYhwtuGH2gY= X-Google-Smtp-Source: AMsMyM4MGnbPDKOByGqJdhmmRtoXL8X48f1JjnPk1toW/MaSubQNgXfxo8oKjAgoLdrpcul1FUVMxw== X-Received: by 2002:a05:6402:90a:b0:458:ca4d:a2f8 with SMTP id g10-20020a056402090a00b00458ca4da2f8mr4673944edz.230.1666132540832; Tue, 18 Oct 2022 15:35:40 -0700 (PDT) Received: from [192.168.2.4] (81-204-249-205.fixed.kpn.net. [81.204.249.205]) by smtp.gmail.com with ESMTPSA id p4-20020a056402074400b0045bccd8ab83sm9533191edy.1.2022.10.18.15.35.39 (version=TLS1_3 cipher=TLS_AES_128_GCM_SHA256 bits=128/128); Tue, 18 Oct 2022 15:35:40 -0700 (PDT) Message-ID: <987a258f-d9e8-bd9c-4f85-8c93d4259e8c@gmail.com> Date: Wed, 19 Oct 2022 00:35:39 +0200 MIME-Version: 1.0 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:102.0) Gecko/20100101 Thunderbird/102.3.0 Subject: Re: [PATCH v1] rockchip: phycore_rk3288: remove phycore_init() function To: Wadim Egorov , "kever.yang@rock-chips.com" Cc: "sjg@chromium.org" , "philipp.tomsich@vrull.eu" , "u-boot@lists.denx.de" References: <42876044-e20f-81fd-2bc7-96ff2268d19d@gmail.com> <150a53e9-d753-6f50-134e-e61e1d194019@phytec.de> Content-Language: en-US From: Johan Jonker In-Reply-To: <150a53e9-d753-6f50-134e-e61e1d194019@phytec.de> Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 7bit 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 On 10/18/22 13:43, Wadim Egorov wrote: > Hi Johan, > > thanks for this Patch. You were faster with the patch. > > I hope the size reduction is enough to make it buildable with Kevers patch. This patch only reduces the SPL size a few hundred bytes. U-boot tend to grow over time. To be future proof your SPL > TPL size must be significantly reduced (>kB) below this limit. Only someone with hardware can check that. People with a recent DT are unable to sync from Linux, because of inactive board maintainers. Could you indicate if Phytec is interested to take up that task? Johan > > > Am 18.10.22 um 13:25 schrieb Johan Jonker: >> The phycore_rk3288 board has a SPL size problem, >> so remove phycore_init() function to stay within the limits. >> >> Signed-off-by: Johan Jonker > > Reviewed-by: Wadim Egorov > > >> --- >> arch/arm/mach-rockchip/rk3288/Kconfig | 1 - >> board/phytec/phycore_rk3288/phycore-rk3288.c | 46 -------------------- >> 2 files changed, 47 deletions(-) >> >> diff --git a/arch/arm/mach-rockchip/rk3288/Kconfig b/arch/arm/mach-rockchip/rk3288/Kconfig >> index e8c57843..1be2b585 100644 >> --- a/arch/arm/mach-rockchip/rk3288/Kconfig >> +++ b/arch/arm/mach-rockchip/rk3288/Kconfig >> @@ -89,7 +89,6 @@ config TARGET_MIQI_RK3288 >> config TARGET_PHYCORE_RK3288 >> bool "phyCORE-RK3288" >> select BOARD_LATE_INIT >> - select SPL_BOARD_INIT if SPL >> help >> Add basic support for the PCM-947 carrier board, a RK3288 based >> development board made by PHYTEC. This board works in a combination >> diff --git a/board/phytec/phycore_rk3288/phycore-rk3288.c b/board/phytec/phycore_rk3288/phycore-rk3288.c >> index 17b987f6..3f49f39e 100644 >> --- a/board/phytec/phycore_rk3288/phycore-rk3288.c >> +++ b/board/phytec/phycore_rk3288/phycore-rk3288.c >> @@ -19,8 +19,6 @@ >> #include >> #include >> #include "som.h" >> -#include >> -#include >> >> static int valid_rk3288_som(struct rk3288_som *som) >> { >> @@ -77,47 +75,3 @@ int rk3288_board_late_init(void) >> >> return 0; >> } >> - >> -#ifdef CONFIG_SPL_BUILD >> -#if !defined(CONFIG_SPL_OF_PLATDATA) >> -static int phycore_init(void) >> -{ >> - struct udevice *pmic; >> - int ret; >> - >> - ret = uclass_first_device_err(UCLASS_PMIC, &pmic); >> - if (ret) >> - return ret; >> - >> -#if defined(CONFIG_SPL_POWER) >> - /* Increase USB input current to 2A */ >> - ret = rk818_spl_configure_usb_input_current(pmic, 2000); >> - if (ret) >> - return ret; >> - >> - /* Close charger when USB lower then 3.26V */ >> - ret = rk818_spl_configure_usb_chrg_shutdown(pmic, 3260000); >> - if (ret) >> - return ret; >> -#endif >> - >> - return 0; >> -} >> -#endif >> - >> -void spl_board_init(void) >> -{ >> -#if !defined(CONFIG_SPL_OF_PLATDATA) >> - int ret; >> - >> - if (of_machine_is_compatible("phytec,rk3288-phycore-som")) { >> - ret = phycore_init(); >> - if (ret) { >> - debug("Failed to set up phycore power settings: %d\n", >> - ret); >> - return; >> - } >> - } >> -#endif >> -} >> -#endif > >