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 94C14C433EF for ; Mon, 30 May 2022 08:45:59 +0000 (UTC) Received: from h2850616.stratoserver.net (localhost [IPv6:::1]) by phobos.denx.de (Postfix) with ESMTP id 4D2CF842A3; Mon, 30 May 2022 10:45:57 +0200 (CEST) Authentication-Results: phobos.denx.de; dmarc=pass (p=none dis=none) header.from=kernel.org 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=kernel.org header.i=@kernel.org header.b="qGwVktJS"; dkim-atps=neutral Received: by phobos.denx.de (Postfix, from userid 109) id E9EA3842B2; Mon, 30 May 2022 10:45:55 +0200 (CEST) Received: from dfw.source.kernel.org (dfw.source.kernel.org [139.178.84.217]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by phobos.denx.de (Postfix) with ESMTPS id 8AB17842A1 for ; Mon, 30 May 2022 10:45:52 +0200 (CEST) Authentication-Results: phobos.denx.de; dmarc=pass (p=none dis=none) header.from=kernel.org Authentication-Results: phobos.denx.de; spf=pass smtp.mailfrom=pali@kernel.org Received: from smtp.kernel.org (relay.kernel.org [52.25.139.140]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by dfw.source.kernel.org (Postfix) with ESMTPS id 5190860F33; Mon, 30 May 2022 08:45:51 +0000 (UTC) Received: by smtp.kernel.org (Postfix) with ESMTPSA id 64EFEC34119; Mon, 30 May 2022 08:45:50 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=k20201202; t=1653900350; bh=8SVv/wZ3h4KFgiJpf1lirzoPBZRvxmH/0a3hKv9sDDA=; h=Date:From:To:Cc:Subject:References:In-Reply-To:From; b=qGwVktJS/gI4xO8PnQwkjVz93jKLl78ApmUFJvNNUOMzv+N50p9JEO6y1l24KAuJd Eefu4g5/B31i+a3/0yA+qOSeB6tx+cRVOeWUGkeAeeCpJfqjq7F1G/q0cZMKVjfaah u7cYg/6poaaKHWCrdBXgicFqY/mcCIzHQiedSkFxJsaYf9ufMMnvXLrYUqDSLi0As4 PvgFaK4TE79l2OyEnY9Qn5jW3RPIpZ+SdWMJy2L3U2VpzhVTwGyJO9oeUYsCTRR9iP FcX2hOooeir/GWT2J06NyWh7yV9KHrnSqyYlBPmflVGF4LYLJeb9ctVbdDpRsFkmRd voeOKGcokGG/A== Received: by pali.im (Postfix) id 23DE9731; Mon, 30 May 2022 10:45:48 +0200 (CEST) Date: Mon, 30 May 2022 10:45:48 +0200 From: Pali =?utf-8?B?Um9ow6Fy?= To: Stefan Roese Cc: u-boot@lists.denx.de Subject: Re: [PATCH] arch: mvebu: Disable by default unused peripherals in SPL Message-ID: <20220530084548.yzmvo6pj6uvsg44z@pali> References: <20220524085842.2823-1-pali@kernel.org> <40a30f47-2461-7ae6-e46c-7e913e9c2a19@denx.de> <54b932f0-2d1b-0289-7c0c-2133048e1ff7@denx.de> MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Disposition: inline Content-Transfer-Encoding: 8bit In-Reply-To: <54b932f0-2d1b-0289-7c0c-2133048e1ff7@denx.de> User-Agent: NeoMutt/20180716 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 On Monday 30 May 2022 10:26:37 Stefan Roese wrote: > On 30.05.22 08:31, Stefan Roese wrote: > > On 24.05.22 10:58, Pali Rohár wrote: > > > SPL on mvebu loads proper U-Boot from custom Marvell kwbimage format and > > > therefore support for other binary formats is not required to be > > > present in > > > SPL. Boot source of proper U-Boot is defined by compile time options and > > > therefore it is not required to enable all possible and unused > > > peripherals > > > in SPL by default. > > > > > > This change decrease size of SPL binaries. > > > > > > Signed-off-by: Pali Rohár > > > > Reviewed-by: Stefan Roese > > > > Thanks, > > Stefan > > This patch causes some regressions, like on clearfog: > > $ make clearfog_defconfig > $ make -s -j20 > ===================== WARNING ====================== > This board does not use CONFIG_TIMER (Driver Model > for Timer drivers). Please update the board to use > CONFIG_TIMER before the v2023.01 release. Failure to > update by the deadline may result in board removal. > See doc/develop/driver-model/migration.rst for more info. > ==================================================== > /opt/kernel.org/gcc-11.1.0-nolibc/arm-linux-gnueabi/bin/arm-linux-gnueabi-ld.bfd: > cmd/tlv_eeprom.o: in function `is_checksum_valid': > /home/stefan/git/u-boot/u-boot-marvell/cmd/tlv_eeprom.c:114: undefined > reference to `crc32' > /opt/kernel.org/gcc-11.1.0-nolibc/arm-linux-gnueabi/bin/arm-linux-gnueabi-ld.bfd: > cmd/tlv_eeprom.o: in function `update_crc': > /home/stefan/git/u-boot/u-boot-marvell/cmd/tlv_eeprom.c:379: undefined > reference to `crc32' > make[1]: *** [scripts/Makefile.spl:525: spl/u-boot-spl] Error 1 > make: *** [Makefile:2106: spl/u-boot-spl] Error 2 > > Could you please have a look? Yes! It is missing dependency in Kconfig. Now I sent patch which is fixing it: https://patchwork.ozlabs.org/project/uboot/patch/20220530084235.13027-1-pali@kernel.org/ > Thanks, > Stefan > > > > > > --- > > >   common/spl/Kconfig  | 2 ++ > > >   disk/Kconfig        | 2 ++ > > >   drivers/mmc/Kconfig | 1 + > > >   drivers/usb/Kconfig | 1 + > > >   4 files changed, 6 insertions(+) > > > > > > diff --git a/common/spl/Kconfig b/common/spl/Kconfig > > > index 50ff113cab21..0c8df271aa59 100644 > > > --- a/common/spl/Kconfig > > > +++ b/common/spl/Kconfig > > > @@ -218,6 +218,7 @@ config SPL_BOOTCOUNT_LIMIT > > >   config SPL_RAW_IMAGE_SUPPORT > > >       bool "Support SPL loading and booting of RAW images" > > > +    default n if ARCH_MVEBU > > >       default n if (ARCH_MX6 && (SPL_MMC || SPL_SATA)) > > >       default y > > >       depends on !TI_SECURE_DEVICE > > > @@ -228,6 +229,7 @@ config SPL_RAW_IMAGE_SUPPORT > > >   config SPL_LEGACY_IMAGE_FORMAT > > >       bool "Support SPL loading and booting of Legacy images" > > > +    default n if ARCH_MVEBU > > >       default y if !SPL_LOAD_FIT > > >       depends on !TI_SECURE_DEVICE > > >       help > > > diff --git a/disk/Kconfig b/disk/Kconfig > > > index 359af3b27e6d..81d8867ed7fc 100644 > > > --- a/disk/Kconfig > > > +++ b/disk/Kconfig > > > @@ -60,6 +60,7 @@ config DOS_PARTITION > > >   config SPL_DOS_PARTITION > > >       bool "Enable MS Dos partition table for SPL" > > >       depends on SPL > > > +    default n if ARCH_MVEBU > > >       default n if ARCH_SUNXI > > >       default y if DOS_PARTITION > > >       select SPL_PARTITIONS > > > @@ -130,6 +131,7 @@ config EFI_PARTITION_ENTRIES_OFF > > >   config SPL_EFI_PARTITION > > >       bool "Enable EFI GPT partition table for SPL" > > >       depends on  SPL > > > +    default n if ARCH_MVEBU > > >       default n if ARCH_SUNXI > > >       default y if EFI_PARTITION > > >       select SPL_PARTITIONS > > > diff --git a/drivers/mmc/Kconfig b/drivers/mmc/Kconfig > > > index f04cc44e1973..847c0ef0acc7 100644 > > > --- a/drivers/mmc/Kconfig > > > +++ b/drivers/mmc/Kconfig > > > @@ -45,6 +45,7 @@ config DM_MMC > > >   config SPL_DM_MMC > > >       bool "Enable MMC controllers using Driver Model in SPL" > > >       depends on SPL_DM && DM_MMC > > > +    default n if ARCH_MVEBU && !MVEBU_SPL_BOOT_DEVICE_MMC > > >       default y > > >       help > > >         This enables the MultiMediaCard (MMC) uclass which supports > > > MMC and > > > diff --git a/drivers/usb/Kconfig b/drivers/usb/Kconfig > > > index ab1d061bd0d5..075e9682c435 100644 > > > --- a/drivers/usb/Kconfig > > > +++ b/drivers/usb/Kconfig > > > @@ -50,6 +50,7 @@ config DM_USB > > >   config SPL_DM_USB > > >       bool "Enable driver model for USB host most in SPL" > > >       depends on SPL_DM && DM_USB > > > +    default n if ARCH_MVEBU > > >       default y > > >   config DM_USB_GADGET > > > > Viele Grüße, > > Stefan Roese > > > > Viele Grüße, > Stefan Roese > > -- > DENX Software Engineering GmbH, Managing Director: Wolfgang Denk > HRB 165235 Munich, Office: Kirchenstr.5, D-82194 Groebenzell, Germany > Phone: (+49)-8142-66989-51 Fax: (+49)-8142-66989-80 Email: sr@denx.de