All of lore.kernel.org
 help / color / mirror / Atom feed
From: Tom Rini <trini@konsulko.com>
To: u-boot@lists.denx.de
Subject: [U-Boot] [PATCH 01/30] lib: Allow crc32 to be disabled.
Date: Fri, 8 Nov 2019 09:59:23 -0500	[thread overview]
Message-ID: <20191108145923.GX19317@bill-the-cat> (raw)
In-Reply-To: <5afbdd2e-c7e9-d61c-91c4-ffffc71c594e@gmx.de>

On Sun, Oct 27, 2019 at 05:48:39PM +0100, Heinrich Schuchardt wrote:
> On 10/27/19 4:53 PM, Simon Glass wrote:
> > Unfortunately this table seems to appear in TPL with gcc 7.3 even if it
> > is not used. Fix it by creating a Kconfig that can be used to disable this
> > routine.
> > 
> > It is enabled by default, since most boards use it.
> > 
> > Signed-off-by: Simon Glass <sjg@chromium.org>
> > ---
> > 
> >   lib/Kconfig  | 29 +++++++++++++++++++++++++++++
> >   lib/Makefile |  2 +-
> >   2 files changed, 30 insertions(+), 1 deletion(-)
> > 
> > diff --git a/lib/Kconfig b/lib/Kconfig
> > index 135f0b372b..be5f9d343a 100644
> > --- a/lib/Kconfig
> > +++ b/lib/Kconfig
> > @@ -353,6 +353,35 @@ config SHA_PROG_HW_ACCEL
> >   config MD5
> >   	bool
> > 
> > +config CRC32
> > +	bool "Enable crc32 routine"
> 
> env/common.c uses crc32(). I could not find how to disable building it.
> So this configuration option seems to be superfluous. Otherwise please,
> add all reverse dependencies like EFI_LOADER, CMD_UBIFS, ...
> 
> > +	default y
> > +	help
> > +	  This enables a 32-bit CRC (cyclic-redundancy check) routine. It is
> > +	  typically used to check for changes in a group of bytes. Even a
> > +	  small change typically produces a very different CRC value. This
> > +	  algorithm is simple and quite fast.
> > +
> > +config SPL_CRC32
> > +	bool "Enable crc32 routine in SPL"
> > +	depends on SPL
> 
> Reverse dependencies are missing here, e.g.
> 
> selected by SPL_EFI_PARTITION

I think the problem is that for 'CRC32' itself, we need to not have it
be a visible symbol as it's non-optional in main U-Boot.  And then it
should be select'd as needed by SPL_xxx and TPL_xxx symbols.  Thanks!

-- 
Tom
-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 833 bytes
Desc: not available
URL: <http://lists.denx.de/pipermail/u-boot/attachments/20191108/f239a2b0/attachment.sig>

      reply	other threads:[~2019-11-08 14:59 UTC|newest]

Thread overview: 45+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2019-10-27 15:53 [U-Boot] [PATCH 01/30] lib: Allow crc32 to be disabled Simon Glass
2019-10-27 15:53 ` [U-Boot] [PATCH 02/30] spi: Allow separate control of SPI_FLASH_TINY for SPL/TPL Simon Glass
2019-10-27 15:53 ` [U-Boot] [PATCH 03/30] mtd: spi-nor: Tidy up error handling / debug code Simon Glass
2019-10-27 15:53 ` [U-Boot] [PATCH 04/30] mtd: spi: Export spi_flash_std_probe() Simon Glass
2019-10-27 15:53 ` [U-Boot] [PATCH 05/30] wdt: Move code out of the header Simon Glass
2019-10-28  5:07   ` Stefan Roese
2019-10-27 15:53 ` [U-Boot] [PATCH 06/30] wdt: Drop dm.h header file Simon Glass
2019-10-28  5:44   ` Stefan Roese
2019-10-27 15:53 ` [U-Boot] [PATCH 07/30] mtd: spi-mem: " Simon Glass
2019-10-27 15:53 ` [U-Boot] [PATCH 08/30] mtd: spi: Drop SPI_XFER_MMAP* Simon Glass
2019-10-27 15:53 ` [U-Boot] [PATCH 09/30] dm: core: Drop dm.h header file from dm-demo.h Simon Glass
2019-10-27 15:53 ` [U-Boot] [PATCH 10/30] dm: core: Drop header files from dm/test.h Simon Glass
2019-10-27 15:53 ` [U-Boot] [PATCH 11/30] fs: fs-loader: Drop dm.h header file Simon Glass
2019-10-27 15:53 ` [U-Boot] [PATCH 12/30] net: Drop dm.h header file from phy.h Simon Glass
2019-10-27 15:53 ` [U-Boot] [PATCH 13/30] sf: Drop dm.h header file from spi_flash.h Simon Glass
2019-10-27 15:53 ` [U-Boot] [PATCH 14/30] thermal: Drop dm.h header file Simon Glass
2019-10-27 15:53 ` [U-Boot] [PATCH 15/30] w1: " Simon Glass
2019-10-27 15:53 ` [U-Boot] [PATCH 16/30] efi: Tidy up header includes Simon Glass
2019-10-27 17:42   ` Heinrich Schuchardt
2019-10-27 18:59     ` Simon Glass
2019-10-27 15:53 ` [U-Boot] [PATCH 17/30] power: Tidy up inclusion of regulator_common.h Simon Glass
2019-10-27 15:53 ` [U-Boot] [PATCH 18/30] mmc: Drop duplicate dm.h inclusion Simon Glass
2019-10-27 15:53 ` [U-Boot] [PATCH 19/30] spi: " Simon Glass
2019-10-27 15:54 ` [U-Boot] [PATCH 20/30] ti: am654: " Simon Glass
2019-10-29  5:43   ` Lokesh Vutla
2019-10-27 15:54 ` [U-Boot] [PATCH 21/30] liebherr: " Simon Glass
2019-11-01 22:45   ` Lukasz Majewski
2019-10-27 15:54 ` [U-Boot] [PATCH 22/30] pci: Drop dm.h inclusion from header file Simon Glass
2019-10-27 15:54 ` [PATCH 23/30] video: meson: Drop unnecessary header includes Simon Glass
2019-10-27 15:54   ` [U-Boot] " Simon Glass
2019-10-27 17:06   ` Anatolij Gustschin
2019-10-27 17:06     ` [U-Boot] " Anatolij Gustschin
2019-10-27 17:48   ` Neil Armstrong
2019-10-27 17:48     ` [U-Boot] " Neil Armstrong
2020-01-07 10:16     ` Neil Armstrong
2020-01-07 10:16       ` Neil Armstrong
2019-10-27 15:54 ` [U-Boot] [PATCH 24/30] mediatek: Drop dm.h header file Simon Glass
2019-10-27 15:54 ` [U-Boot] [PATCH 25/30] mscc: " Simon Glass
2019-10-27 15:54 ` [U-Boot] [PATCH 26/30] adc: " Simon Glass
2019-10-27 15:54 ` [U-Boot] [PATCH 27/30] nand: " Simon Glass
2019-10-27 15:54 ` [U-Boot] [PATCH 28/30] ufs: " Simon Glass
2019-10-27 15:54 ` [U-Boot] [PATCH 29/30] usb: " Simon Glass
2019-10-27 15:54 ` [U-Boot] [PATCH 30/30] dm: core: Guard against including dm.h in header files Simon Glass
2019-10-27 16:48 ` [U-Boot] [PATCH 01/30] lib: Allow crc32 to be disabled Heinrich Schuchardt
2019-11-08 14:59   ` Tom Rini [this message]

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20191108145923.GX19317@bill-the-cat \
    --to=trini@konsulko.com \
    --cc=u-boot@lists.denx.de \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.