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]
Message-ID: <CAOesGMhjrYmFSEFh0mDDfL-fkSXmWnQzYAGPCbCwnHaozCOOVQ@mail.gmail.com>
Date:   Mon, 22 May 2017 22:23:17 -0700
From:   Olof Johansson <olof@...om.net>
To:     Palmer Dabbelt <palmer@...belt.com>
Cc:     "linux-kernel@...r.kernel.org" <linux-kernel@...r.kernel.org>,
        Arnd Bergmann <arnd@...db.de>, albert@...ive.com
Subject: Re: [PATCH 2/7] RISC-V: arch/riscv Makefile and Kconfigs

(new top-level subthread here since this is a separate topic):

On Mon, May 22, 2017 at 5:41 PM, Palmer Dabbelt <palmer@...belt.com> wrote:

> diff --git a/arch/riscv/Makefile b/arch/riscv/Makefile
> new file mode 100644
> index 000000000000..07ef200e0675
> --- /dev/null
> +++ b/arch/riscv/Makefile
> @@ -0,0 +1,64 @@
> +# This file is included by the global makefile so that you can add your own
> +# architecture-specific flags and dependencies. Remember to do have actions
> +# for "archclean" and "archdep" for cleaning up and making dependencies for
> +# this architecture
> +#
> +# This file is subject to the terms and conditions of the GNU General Public
> +# License.  See the file "COPYING" in the main directory of this archive
> +# for more details.
> +#
> +
> +LDFLAGS         :=
> +OBJCOPYFLAGS    := -O binary
> +LDFLAGS_vmlinux :=
> +KBUILD_AFLAGS_MODULE += -fPIC
> +KBUILD_CFLAGS_MODULE += -fPIC
> +
> +ifeq ($(ARCH),riscv)
> +       KBUILD_DEFCONFIG = riscv64_spike
> +else
> +       KBUILD_DEFCONFIG = $(ARCH)_spike
> +endif
> +
> +export BITS
> +ifeq ($(CONFIG_64BIT),y)
> +       BITS := 64
> +       UTS_MACHINE := riscv64
> +
> +       KBUILD_CFLAGS += -mabi=lp64
> +       KBUILD_AFLAGS += -mabi=lp64
> +       KBUILD_MARCH = rv64im
> +       LDFLAGS += -melf64lriscv
> +else
> +       BITS := 32
> +       UTS_MACHINE := riscv32
> +
> +       KBUILD_CFLAGS += -mabi=ilp32
> +       KBUILD_AFLAGS += -mabi=ilp32
> +       KBUILD_MARCH = rv32im
> +       LDFLAGS += -melf32lriscv
> +endif
> +
> +ifeq ($(CONFIG_RV_ATOMIC),y)
> +       KBUILD_RV_ATOMIC = a
> +endif
> +
> +KBUILD_CFLAGS += -Wall
> +
> +ifeq ($(CONFIG_RVC),y)
> +       KBUILD_RVC = c
> +endif
> +
> +KBUILD_AFLAGS += -march=$(KBUILD_MARCH)$(KBUILD_RV_ATOMIC)fd$(KBUILD_RVC)
> +
> +KBUILD_CFLAGS += -march=$(KBUILD_MARCH)$(KBUILD_RV_ATOMIC)$(KBUILD_RVC)
> +KBUILD_CFLAGS += -mno-save-restore
> +KBUILD_CFLAGS += -mstrict-align

I built a vanilla gcc-7.1.0 here, with 'riscv64-linux' as target, and I get:

riscv64-linux-gcc: error: unrecognized command line option
'-mstrict-align'; did you mean '-Wstrict-aliasing'?


The suggestion seems completely bogus, but the error is real. Looking
at the gcc sources, I only see strict-align plumbed up on rs6000,
aarch64, m68k(!) and v850. Or am I missing something here?



-Olof

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ