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 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 49AA3C433F5 for ; Tue, 11 Jan 2022 20:19:33 +0000 (UTC) Received: from h2850616.stratoserver.net (localhost [IPv6:::1]) by phobos.denx.de (Postfix) with ESMTP id BC4C882EBB; Tue, 11 Jan 2022 21:19:30 +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="Hmjp3v1Q"; dkim-atps=neutral Received: by phobos.denx.de (Postfix, from userid 109) id 1B2D783041; Tue, 11 Jan 2022 21:19:28 +0100 (CET) Received: from mail-ed1-x52f.google.com (mail-ed1-x52f.google.com [IPv6:2a00:1450:4864:20::52f]) (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 0847A811DE for ; Tue, 11 Jan 2022 21:19:25 +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=tomm.merciai@gmail.com Received: by mail-ed1-x52f.google.com with SMTP id z22so800265edd.12 for ; Tue, 11 Jan 2022 12:19:24 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20210112; h=date:from:to:cc:subject:message-id:references:mime-version :content-disposition:content-transfer-encoding:in-reply-to; bh=zdbieTHkdCGQgtCTNLOWdIUHTors7FoGTuyeuWfJcQw=; b=Hmjp3v1QIboVHM86tmQp8lBypQwUH55ptY89mVdzB8+vwXPzzS80lC1CHzIj36EOLp LIstp1QXUokkoPdmp4kxDZgIghajNcacbxJf7YTNR3WOI3S8eCokjnnnROXwdsEJsFMi /NmOIrnEbwydxuzLwN2rxQvCeEEGrOpgg3rkC8b8cIO5CKX8l1Jn87Wg7ieWI89Zt4nz tuS5FZKaeHbvLXjHThYH5RIBPT2hnIFjDwhfkHQB0ri8HM7MZWnupNyjXaA/jdCtEEAv RjbkTiAOwCwEO0FcOv8es6AN0BFYtM4eSJ7UdYCBDML3xN5qJ2y5wEugasYnVTqcAtXr vYOw== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; h=x-gm-message-state:date:from:to:cc:subject:message-id:references :mime-version:content-disposition:content-transfer-encoding :in-reply-to; bh=zdbieTHkdCGQgtCTNLOWdIUHTors7FoGTuyeuWfJcQw=; b=GJl+KgVJeW/zc2ohMxiY2oMcb8LnGh9ZjVtSZ7Eglbud5zmKauhuNWD+Xrwd+w6Qck 8yyNa5uZ4FTOipQ3d35N7OiGdHPMIW3JfCMJDKuGfwWcQERsgOL9iKy0JIUHgPpp+tCH Hcjk8Ule+yjd5zsYqLgfW/jC4Pwj5FGLVvVpW5kZElXZeMBeK8tDw9uAsq3fT6jZyu3w uriWFmJGa73P7EwRKprIUWD1ji9NpFAP0f66+TbQD9h0tEdwMPYyQEZ8pRwPmcQyWWQR fQXIJOk/wYSH1NqccMPdljxjwvKX51WsO2XiIzaeDP8oFCntgonP8yv0PK3243SrWo2L bd3w== X-Gm-Message-State: AOAM532LhclaQ89EvyhSXZZJlem0BExn9VDQItW9cav8uLgBkduKKOvb 6Ombd4ppqXDBP+sxF0xIClA= X-Google-Smtp-Source: ABdhPJzq05JbXrKZwW1QXuKWS6FlCZ9EJvNAhNJLKnASRbzZ8MTAfBXU63VQRUsa19YuRMXRen/QXg== X-Received: by 2002:a17:906:58c8:: with SMTP id e8mr4825300ejs.380.1641932364177; Tue, 11 Jan 2022 12:19:24 -0800 (PST) Received: from tom-desktop (net-93-71-218-227.cust.vodafonedsl.it. [93.71.218.227]) by smtp.gmail.com with ESMTPSA id sc3sm3939798ejc.93.2022.01.11.12.19.22 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Tue, 11 Jan 2022 12:19:23 -0800 (PST) Date: Tue, 11 Jan 2022 21:19:21 +0100 From: Tommaso Merciai To: Teresa Remmet Cc: "ye.li@nxp.com" , "uboot-imx@nxp.com" , "festevam@gmail.com" , "peng.fan@nxp.com" , "michael@amarulasolutions.com" , "sbabic@denx.de" , "hws@denx.de" , "marex@denx.de" , "sjg@chromium.org" , "frieder.schrempf@kontron.de" , "u-boot@lists.denx.de" Subject: Re: [RFC PATCH v3 1/5] imx8m: drop env_get_location for imx8mn and imx8mp Message-ID: <20220111201921.GA4503@tom-desktop> References: <20211225202554.47853-1-tomm.merciai@gmail.com> <20211225202554.47853-2-tomm.merciai@gmail.com> <2f14182478aa4d2c0d0c03906beab1ee3483b4a6.camel@phytec.de> <20220108190851.GB2633@tom-desktop> MIME-Version: 1.0 Content-Type: text/plain; charset=iso-8859-1 Content-Disposition: inline Content-Transfer-Encoding: 8bit In-Reply-To: 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.2 at phobos.denx.de X-Virus-Status: Clean On Tue, Jan 11, 2022 at 09:35:54AM +0000, Teresa Remmet wrote: > Hello Tommaso, > > Am Samstag, dem 08.01.2022 um 20:08 +0100 schrieb Tommaso Merciai: > > On Tue, Jan 04, 2022 at 11:04:10AM +0000, Teresa Remmet wrote: > > > Hello Tommaso, > > > > > > Am Samstag, dem 25.12.2021 um 21:25 +0100 schrieb Tommaso Merciai: > > > > This function defined for two architecture is not really generic > > > > and can generate problem when people add a new board. > > > > > > > > Signed-off-by: Tommaso Merciai > > > > --- > > > > arch/arm/mach-imx/imx8m/soc.c | 39 --------------------------- > > > > ---- > > > > ---- > > > > 1 file changed, 39 deletions(-) > > > > > > > > diff --git a/arch/arm/mach-imx/imx8m/soc.c b/arch/arm/mach- > > > > imx/imx8m/soc.c > > > > index 863508776d..f0030a557a 100644 > > > > --- a/arch/arm/mach-imx/imx8m/soc.c > > > > +++ b/arch/arm/mach-imx/imx8m/soc.c > > > > @@ -1313,45 +1313,6 @@ void do_error(struct pt_regs *pt_regs, > > > > unsigned int esr) > > > > #endif > > > > > > > > #if defined(CONFIG_IMX8MN) || defined(CONFIG_IMX8MP) > > > > -enum env_location env_get_location(enum env_operation op, int > > > > prio) > > > > -{ > > > > - enum boot_device dev = get_boot_device(); > > > > - enum env_location env_loc = ENVL_UNKNOWN; > > > > - > > > > - if (prio) > > > > - return env_loc; > > > > - > > > > - switch (dev) { > > > > -#ifdef CONFIG_ENV_IS_IN_SPI_FLASH > > > > - case QSPI_BOOT: > > > > - env_loc = ENVL_SPI_FLASH; > > > > - break; > > > > -#endif > > > > -#ifdef CONFIG_ENV_IS_IN_NAND > > > > - case NAND_BOOT: > > > > - env_loc = ENVL_NAND; > > > > - break; > > > > -#endif > > > > -#ifdef CONFIG_ENV_IS_IN_MMC > > > > - case SD1_BOOT: > > > > - case SD2_BOOT: > > > > - case SD3_BOOT: > > > > - case MMC1_BOOT: > > > > - case MMC2_BOOT: > > > > - case MMC3_BOOT: > > > > - env_loc = ENVL_MMC; > > > > - break; > > > > -#endif > > > > - default: > > > > -#if defined(CONFIG_ENV_IS_NOWHERE) > > > > - env_loc = ENVL_NOWHERE; > > > > -#endif > > > > - break; > > > > - } > > > > - > > > > - return env_loc; > > > > -} > > > > - > > > > #ifndef ENV_IS_EMBEDDED > > > > long long env_get_offset(long long defautl_offset) > > > > > > would it not make sense to move also env_get_offset() to board > > > level? > > > > Hi Teresa, > > I think is better to put this function at board level. In this way > > others boards that use i.MX8MN/i.MX8MM SOC can customize > > env_get_location > > function. For example: maybe one user want store U-Boot env on a > > device > > other than the boot device. > > Michael send a patch to remove the function. Which I missed. See: > https://lore.kernel.org/u-boot/20211117143456.34441-1-michael@amarulasolutions.com/ > > So everything is fine then. > > Thanks, > Teresa Hi Teresa, Perfect. Thanks, Tommaso > > > > > Tommaso > > > Regards, > > > Teresa > > > > > > > > > > { > > > -- > > > PHYTEC Messtechnik GmbH | Robert-Koch-Str. 39 | 55129 Mainz, > > > Germany > > > > > > Geschäftsführer: Dipl.-Ing. Michael Mitezki, Dipl.-Ing. Bodo Huber > > > | > > > Handelsregister Mainz HRB 4656 | Finanzamt Mainz | St.Nr. > > > 266500608, DE > > > 149059855 > -- > PHYTEC Messtechnik GmbH | Robert-Koch-Str. 39 | 55129 Mainz, Germany > > Geschäftsführer: Dipl.-Ing. Michael Mitezki, Dipl.-Ing. Bodo Huber | > Handelsregister Mainz HRB 4656 | Finanzamt Mainz | St.Nr. 266500608, DE > 149059855