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 AC543C433F5 for ; Tue, 31 May 2022 16:17:46 +0000 (UTC) Received: from h2850616.stratoserver.net (localhost [IPv6:::1]) by phobos.denx.de (Postfix) with ESMTP id 42F7984304; Tue, 31 May 2022 18:17:34 +0200 (CEST) Authentication-Results: phobos.denx.de; dmarc=fail (p=none dis=none) header.from=konsulko.com Authentication-Results: phobos.denx.de; spf=pass smtp.mailfrom=u-boot-bounces@lists.denx.de Received: by phobos.denx.de (Postfix, from userid 109) id 2A8C1841A5; Tue, 31 May 2022 18:17:24 +0200 (CEST) Received: from mail-qv1-f52.google.com (mail-qv1-f52.google.com [209.85.219.52]) (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 A74C8832C3 for ; Tue, 31 May 2022 18:17:20 +0200 (CEST) Authentication-Results: phobos.denx.de; dmarc=fail (p=none dis=none) header.from=konsulko.com Authentication-Results: phobos.denx.de; spf=pass smtp.mailfrom=tom.rini@gmail.com Received: by mail-qv1-f52.google.com with SMTP id h18so12260090qvj.11 for ; Tue, 31 May 2022 09:17:20 -0700 (PDT) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; h=x-gm-message-state:from:to:subject:date:message-id:in-reply-to :references:mime-version:content-transfer-encoding; bh=ZLa04HnzQ4c91BY/vjJarwSUEr4IH3twgy6KZwFYHkA=; b=2u0IJkN4EfAVTTxbIaVSCU3zjGkvLdI0uLKr4SmxQRG6GTqaEvccdVJT+c0kMqKJuZ FupXSMeKpwrYKl7o/xiz/YBYRHjFCQ364oy6CEuiOq4LrkB9rsBzG4wrKiJUtNaUUAtk vmBxBTJPqp82asqBjVZgc6EZC2GK3dWl0H4BOMVLdUDWSCJTEem9V3PqSTHL+tfwmhW+ zjMKxlKFr8fBMhTvNF8xlS5GZ03tNpDh4UIW5tpkuJv0dtYw1JtXfd5KiDAeWuZpUGDG tHj9CoJb+atDysUs8+Jbz0gF1X/tTpdxU+sKRu34jrFmR8DvBjjSYLGzKmc0hlBJ8wM2 QPNw== X-Gm-Message-State: AOAM533DpdsdCBB1rKsaj07Oo2hRxrtcopkb6/4XUYSOdDFA73bSY4ML 5bQbLUMgXjfcX75NHt6c6SBfKsJRyQ== X-Google-Smtp-Source: ABdhPJwW/bznO6g6jSkiz79/8O0XMryCDs/dGm/dTK4W0qD7jLAnIBUwUsDmmSy8r9fSHBAVbWRu1g== X-Received: by 2002:ad4:5bee:0:b0:461:f39a:5344 with SMTP id k14-20020ad45bee000000b00461f39a5344mr51622107qvc.72.1654013839248; Tue, 31 May 2022 09:17:19 -0700 (PDT) Received: from localhost.localdomain (2603-6081-7b00-25fd-0000-0000-0000-1003.res6.spectrum.com. [2603:6081:7b00:25fd::1003]) by smtp.gmail.com with ESMTPSA id a85-20020ae9e858000000b0069fc13ce257sm9501847qkg.136.2022.05.31.09.17.18 for (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Tue, 31 May 2022 09:17:18 -0700 (PDT) From: Tom Rini To: u-boot@lists.denx.de Subject: [PATCH 3/3] spl: Rework and tighten some dependencies Date: Tue, 31 May 2022 12:17:05 -0400 Message-Id: <20220531161705.717658-4-trini@konsulko.com> X-Mailer: git-send-email 2.25.1 In-Reply-To: <20220531161705.717658-1-trini@konsulko.com> References: <20220531161705.717658-1-trini@konsulko.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.5 at phobos.denx.de X-Virus-Status: Clean - In a few places, add missing "depends on" that can be implied from the option name (i.e. SPL_DM_xxx depends on SPL_DM). - Make less use of "if SPL_xxx ... endif" clauses as most of the time this reads better as depends on. In the case of UBI however, move it all to a sub-menu. - Rework SPL_NO_CPU_SUPPORT as it's very specific to the non-SPL_FRAMEWORK implementation used on those platforms, and a tangent to how CONFIG_SPL_START_S_PATH was used. Signed-off-by: Tom Rini --- common/spl/Kconfig | 55 ++++++++++++++++++++-------------------------- 1 file changed, 24 insertions(+), 31 deletions(-) diff --git a/common/spl/Kconfig b/common/spl/Kconfig index 9952a9b94c18..2ad2351c6eb3 100644 --- a/common/spl/Kconfig +++ b/common/spl/Kconfig @@ -750,6 +750,7 @@ config SPL_LIBGENERIC_SUPPORT config SPL_DM_MAILBOX bool "Support Mailbox" + depends on SPL_DM help Enable support for Mailbox within SPL. This enable the inter processor communication protocols tobe used within SPL. Enable @@ -874,19 +875,9 @@ config SPL_UBI Enable support for loading payloads from UBI. See README.ubispl for more info. -if SPL_DM -config SPL_DM_SPI - bool "Support SPI DM drivers in SPL" - help - Enable support for SPI DM drivers in SPL. - -config SPL_DM_SPI_FLASH - bool "Support SPI DM FLASH drivers in SPL" - help - Enable support for SPI DM flash drivers in SPL. +menu "UBI configuration for SPL" + depends on SPL_UBI -endif -if SPL_UBI config SPL_UBI_LOAD_BY_VOLNAME bool "Support loading volumes by name" help @@ -896,58 +887,49 @@ config SPL_UBI_LOAD_BY_VOLNAME config SPL_UBI_MAX_VOL_LEBS int "Maximum number of LEBs per volume" - depends on SPL_UBI help The maximum number of logical eraseblocks which a static volume to load can contain. Used for sizing the scan data structure. config SPL_UBI_MAX_PEB_SIZE int "Maximum PEB size" - depends on SPL_UBI help The maximum physical erase block size. config SPL_UBI_MAX_PEBS int "Maximum number of PEBs" - depends on SPL_UBI help The maximum physical erase block size. If not overridden by board code, this value will be used as the actual number of PEBs. config SPL_UBI_PEB_OFFSET int "Offset to first UBI PEB" - depends on SPL_UBI help The offset in number of PEBs from the start of flash to the first PEB part of the UBI image. config SPL_UBI_VID_OFFSET int "Offset to VID header" - depends on SPL_UBI config SPL_UBI_LEB_START int "Offset to LEB in PEB" - depends on SPL_UBI help The offset in bytes to the LEB within a PEB. config SPL_UBI_INFO_ADDR hex "Address to place UBI scan info" - depends on SPL_UBI help Address for ubispl to place the scan info. Read README.ubispl to determine the required size config SPL_UBI_VOL_IDS int "Maximum volume id" - depends on SPL_UBI help The maximum volume id which can be loaded. Used for sizing the scan data structure. config SPL_UBI_LOAD_MONITOR_ID int "id of U-Boot volume" - depends on SPL_UBI help The UBI volume id from which to load U-Boot @@ -959,13 +941,13 @@ config SPL_UBI_LOAD_MONITOR_VOLNAME config SPL_UBI_LOAD_KERNEL_ID int "id of kernel volume" - depends on SPL_OS_BOOT && SPL_UBI + depends on SPL_OS_BOOT help The UBI volume id from which to load the kernel config SPL_UBI_LOAD_ARGS_ID int "id of kernel args volume" - depends on SPL_OS_BOOT && SPL_UBI + depends on SPL_OS_BOOT help The UBI volume id from which to load the device tree @@ -975,7 +957,19 @@ config UBI_SPL_SILENCE_MSG Disable messages from UBI SPL. This leaves warnings and errors enabled. -endif # if SPL_UBI +endmenu + +config SPL_DM_SPI + bool "Support SPI DM drivers in SPL" + depends on SPL_DM + help + Enable support for SPI DM drivers in SPL. + +config SPL_DM_SPI_FLASH + bool "Support SPI DM FLASH drivers in SPL" + depends on SPL_DM + help + Enable support for SPI DM flash drivers in SPL. config SPL_NET bool "Support networking" @@ -986,19 +980,19 @@ config SPL_NET the network stack uses a number of environment variables. See also SPL_ETH. -if SPL_NET config SPL_NET_VCI_STRING string "BOOTP Vendor Class Identifier string sent by SPL" + depends on SPL_NET help As defined by RFC 2132 the vendor class identifier field can be sent by the client to identify the vendor type and configuration of a client. This is often used in practice to allow for the DHCP server to specify different files to load depending on if the ROM, SPL or U-Boot itself makes the request -endif # if SPL_NET config SPL_NO_CPU_SUPPORT - bool "Drop CPU code in SPL" + def_bool y + depends on (ARCH_MX23 || ARCH_MX28) && !SPL_FRAMEWORK help This is specific to the ARM926EJ-S CPU. It disables the standard start.S start-up code, presumably so that a replacement can be @@ -1048,16 +1042,13 @@ config SYS_NAND_SPL_KERNEL_OFFS hex "Address in memory to load the OS file for Falcon mode to" depends on SPL_OS_BOOT && SPL_NAND_SUPPORT -if SPL_OS_BOOT config SYS_OS_BASE hex "addr, where OS is found" - depends on SPL_NOR_SUPPORT + depends on SPL_OS_BOOT && SPL_NOR_SUPPORT help Specify the address, where the OS image is found, which gets booted. -endif # SPL_OS_BOOT - config SPL_FALCON_BOOT_MMCSD bool "Enable Falcon boot from MMC or SD media" depends on SPL_OS_BOOT && SPL_MMC @@ -1125,6 +1116,7 @@ config SPL_POST_MEM_SUPPORT config SPL_DM_RESET bool "Support reset drivers" + depends on SPL_DM help Enable support for reset control in SPL. That can be useful in SPL to handle IP reset in driver, as in U-Boot, @@ -1427,6 +1419,7 @@ config SPL_ATF_NO_PLATFORM_PARAM config SPL_AM33XX_ENABLE_RTC32K_OSC bool "Enable the RTC32K OSC on AM33xx based platforms" + depends on AM33XX default y if AM33XX help Enable access to the AM33xx RTC and select the external 32kHz clock -- 2.25.1