lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Date:   Mon, 27 Feb 2017 14:06:56 +0000
From:   Ben Hutchings <ben@...adent.org.uk>
To:     Masahiro Yamada <yamada.masahiro@...ionext.com>,
        linux-kbuild@...r.kernel.org
Cc:     Alessio Igor Bogani <alessio.bogani@...ttra.eu>,
        Arnd Bergmann <arnd@...db.de>,
        Rob Herring <robh+dt@...nel.org>, linux-c6x-dev@...ux-c6x.org,
        Michal Simek <monstr@...str.eu>,
        Nicolas Pitre <nicolas.pitre@...aro.org>,
        Marcin Nowakowski <marcin.nowakowski@...tec.com>,
        devicetree@...r.kernel.org,
        Stefan Kristiansson <stefan.kristiansson@...nalahti.fi>,
        Michal Marek <mmarek@...e.com>, Scott Wood <oss@...error.net>,
        Benjamin Herrenschmidt <benh@...nel.crashing.org>,
        linuxppc-dev@...ts.ozlabs.org, Paul Mackerras <paulus@...ba.org>,
        openrisc@...ts.librecores.org, Mark Salter <msalter@...hat.com>,
        Stafford Horne <shorne@...il.com>,
        Aurelien Jacquiot <a-jacquiot@...com>,
        Jonas Bonn <jonas@...thpole.se>,
        Michael Ellerman <mpe@...erman.id.au>,
        linux-kernel@...r.kernel.org, Oliver O'Halloran <oohall@...il.com>,
        Mark Rutland <mark.rutland@....com>,
        Emese Revfy <re.emese@...il.com>
Subject: Re: [PATCH] kbuild: avoid unrecognized option error for external DTC

On Mon, 2017-02-27 at 14:40 +0900, Masahiro Yamada wrote:
> Since commit 6b22b3d1614a ("kbuild: Allow using host dtc instead of
> kernel's copy"), it is possible to use an external dtc.  In this
> case, we do not know which options are supported on it.
> 
> Commit bc553986a2f7 ("dtc: turn off dtc unit address warnings by
> default") gives -Wno-unit_address_vs_reg, but this options is only
> recognized by v1.4.2 or later.
> 
> If an older version is specified, the build fails:

But the option to use an external dtc was intended to allow testing of
newer versions.  If there's no reason to use this option to run an
older version, why bother trying to support that?

[...]
> --- a/scripts/Kbuild.include
> +++ b/scripts/Kbuild.include
> @@ -171,6 +171,20 @@ ld-version = $(shell $(LD) --version | $(srctree)/scripts/ld-version.sh)
>  # Usage:  $(call ld-ifversion, -ge, 22252, y)
>  ld-ifversion = $(shell [ $(ld-version) $(1) $(2) ] && echo $(3) || echo $(4))
>  
> +# dtc-option
> +# Usage:  DTC_FLAGS += $(call dtc-option,-Wno-unit_address_vs_reg)
> +#
> +# When we use the external dtc, check if the desired options are supported.
> +# When we use the kernel's copy (scripts/dtc/dtc), just use the fixed option.
> +# Until Kbuild descends into the scripts/dtc/ directory, scripts/dtc/dtc may
> +# not exist, i.e. $(call try-run,...) may not work.
> +ifeq ("$(origin DTC)", "command line")
[...]

It could also be specified as an environment variable (assignment with
"?=" doesn't override them, but "=" does).

Ben.

-- 
Ben Hutchings
This sentence contradicts itself - no actually it doesn't.


Download attachment "signature.asc" of type "application/pgp-signature" (834 bytes)

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ