All of lore.kernel.org
 help / color / mirror / Atom feed
From: Simon Glass <sjg@chromium.org>
To: u-boot@lists.denx.de
Subject: [U-Boot] [PATCH v3 0/2] Detect and reject new ad-hoc CONFIG options
Date: Tue, 13 Sep 2016 21:46:18 -0600	[thread overview]
Message-ID: <CAPnjgZ0eoddn-eZnSaBXRPDTf-f3rpbe=+W8LuUVs-gD_ggNGw@mail.gmail.com> (raw)
In-Reply-To: <1473824647-4897-1-git-send-email-sjg@chromium.org>

Hi Tom,

On 13 September 2016 at 21:44, Simon Glass <sjg@chromium.org> wrote:
> Despite the availability of Kconfig, the number of ad-hoc CONFIG options in
> U-Boot is still at over 8000.
>
> In February 2015 (commit 741e58e0) there were around 8387 ad-hoc CONFIGs.
> As of this patch there are about 8336, only a little fewer.
>
> One problem is that new ones are still being added, admittedly at a slower
> rate. This series adds a Makefile check to detect that and produce a build
> error. This provides immediate feedback that new CONFIG options should go in
> Kconfig.
>
> Changes in v3:
> - Update the whitelist with mainline
> - Fix the match partern to exclude .py files, not anything containing "py"
> - Handle Kconfig files with extensions (e.g. Kconfig.64)
> - Handle CONFIG_SYS_EXTRA_OPTIONS containing lower case
> - Include lower-case letters in the CONFIG match string
> - Write error output to stderr so that buildman shows it
> - Handle Kconfig files with extensions (e.g. Kconfig.64)
> - Handle extra whitespace after 'config' / 'menuconfig'
>
> Changes in v2:
> - Rebase to mainline
> - Fix scripts so that there are no errors
> - Add the 'build-whitelist.sh' script to the tree
>
> Simon Glass (2):
>   Kconfig: Add a whitelist of ad-hoc CONFIG options
>   Makefile: Give a build error if ad-hoc CONFIG options are added
>
>  Makefile                     |   10 +-
>  scripts/build-whitelist.sh   |   51 +
>  scripts/check-config.sh      |   55 +
>  scripts/config_whitelist.txt | 8420 ++++++++++++++++++++++++++++++++++++++++++
>  4 files changed, 8535 insertions(+), 1 deletion(-)
>  create mode 100755 scripts/build-whitelist.sh
>  create mode 100755 scripts/check-config.sh
>  create mode 100644 scripts/config_whitelist.txt
>
> --
> 2.8.0.rc3.226.g39d4020
>

I build-tested this on top of the SPL series (see u-boot-dm/kconfig-working2):

buildman -b kc4 -fC --step 0 -s
boards.cfg is up to date. Nothing to do.
Summary of 2 commits for 1196 boards (32 threads, 1 job per thread)
01: buildman
  blackfin:  +   cm-bf527 bf609-ezkit bf537-stamp
     sparc:  +   grsim grsim_leon2 gr_cpci_ax2000 gr_xc3s_1500 gr_ep2s60
     nios2:  +   10m50 3c120
microblaze:  +   microblaze-generic
  openrisc:  +   openrisc-generic
48: Makefile: Give a build error if ad-hoc CONFIG options are added
(kc4=74f3ab: -- asc asc2 asc3 b/ sandbox/ test/) u>

There were a number of tweaked needed to get the config checker to
build all boards without error. My previous tested omitted the -C
flag, meaning that it did not reconfigure all of the boards, so
missing loads of problems.

Regards,
Simon

  parent reply	other threads:[~2016-09-14  3:46 UTC|newest]

Thread overview: 7+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2016-09-14  3:44 [U-Boot] [PATCH v3 0/2] Detect and reject new ad-hoc CONFIG options Simon Glass
2016-09-14  3:44 ` [U-Boot] [PATCH v3 1/2] Kconfig: Add a whitelist of " Simon Glass
2016-09-18 16:01   ` [U-Boot] [U-Boot, v3, " Tom Rini
2016-09-14  3:44 ` [U-Boot] [PATCH v3 2/2] Makefile: Give a build error if ad-hoc CONFIG options are added Simon Glass
2016-09-18 16:01   ` [U-Boot] [U-Boot, v3, " Tom Rini
2016-09-14  3:46 ` Simon Glass [this message]
2016-09-14 19:13   ` [U-Boot] [PATCH v3 0/2] Detect and reject new ad-hoc CONFIG options Tom Rini

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='CAPnjgZ0eoddn-eZnSaBXRPDTf-f3rpbe=+W8LuUVs-gD_ggNGw@mail.gmail.com' \
    --to=sjg@chromium.org \
    --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.