Re: [PATCH] bug.h: Work around GCC PR82365 in BUG()
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
- To: Arnd Bergmann <arnd@xxxxxxxx>
- Subject: Re: [PATCH] bug.h: Work around GCC PR82365 in BUG()
- From: James Hogan <jhogan@xxxxxxxxxx>
- Date: Wed, 11 Apr 2018 11:19:27 +0100
- Authentication-results: mail.kernel.org; dmarc=none (p=none dis=none) header.from=kernel.org
- Authentication-results: mail.kernel.org; spf=none smtp.mailfrom=jhogan@xxxxxxxxxx
- Cc: "open list:RALINK MIPS ARCHITECTURE" <linux-mips@xxxxxxxxxxxxxx>, Paul Burton <paul.burton@xxxxxxxx>, Maciej Rozycki <macro@xxxxxxxx>, linux-arch <linux-arch@xxxxxxxxxxxxxxx>, Andrew Morton <akpm@xxxxxxxxxxxxxxxxxxxx>, Linux Kbuild mailing list <linux-kbuild@xxxxxxxxxxxxxxx>, Vineet Gupta <vgupta@xxxxxxxxxxxx>, Mikael Starvik <starvik@xxxxxxxx>, Jesper Nilsson <jesper.nilsson@xxxxxxxx>, Tony Luck <tony.luck@xxxxxxxxx>, Fenghua Yu <fenghua.yu@xxxxxxxxx>, Geert Uytterhoeven <geert@xxxxxxxxxxxxxx>, "David S. Miller" <davem@xxxxxxxxxxxxx>, Christopher Li <sparse@xxxxxxxxxxx>, Thomas Gleixner <tglx@xxxxxxxxxxxxx>, Peter Zijlstra <peterz@xxxxxxxxxxxxx>, Kees Cook <keescook@xxxxxxxxxxxx>, Ingo Molnar <mingo@xxxxxxxxxx>, Josh Poimboeuf <jpoimboe@xxxxxxxxxx>, Will Deacon <will.deacon@xxxxxxx>, "Steven Rostedt (VMware)" <rostedt@xxxxxxxxxxx>, Mark Rutland <mark.rutland@xxxxxxx>, "open list:SYNOPSYS ARC ARCHITECTURE" <linux-snps-arc@xxxxxxxxxxxxxxxxxxx>, Linux Kernel Mailing List <linux-kernel@xxxxxxxxxxxxxxx>, linux-cris-kernel@xxxxxxxx, linux-ia64@xxxxxxxxxxxxxxx, linux-m68k@xxxxxxxxxxxxxxx, sparclinux <sparclinux@xxxxxxxxxxxxxxx>, linux-sparse@xxxxxxxxxxxxxxx, linux-alpha@xxxxxxxxxxxxxxx
- Dmarc-filter: OpenDMARC Filter v1.3.2 mail.kernel.org 3BF6421785
- In-reply-to: <CAK8P3a2_ihWCuUvDz_SVA1TMomkO1d7pa6e2bOQkZcEVP+Ff-A@mail.gmail.com>
- References: <20171219114112.939391-1-arnd@arndb.de> <20180410224805.GA21429@saruman> <CAK8P3a0-_u7_FCj-nH0izBv4ub6krm1uA32bwi2jtBzXJePcnQ@mail.gmail.com> <20180411095359.GB21429@saruman> <CAK8P3a2_ihWCuUvDz_SVA1TMomkO1d7pa6e2bOQkZcEVP+Ff-A@mail.gmail.com>
- User-agent: Mutt/1.7.2 (2016-11-26)
On Wed, Apr 11, 2018 at 12:08:51PM +0200, Arnd Bergmann wrote:
> On Wed, Apr 11, 2018 at 11:54 AM, James Hogan <jhogan@xxxxxxxxxx> wrote:
> > On Wed, Apr 11, 2018 at 09:30:56AM +0200, Arnd Bergmann wrote:
> >> On Wed, Apr 11, 2018 at 12:48 AM, James Hogan <jhogan@xxxxxxxxxx> wrote:
> >> > Before I forward port those patches to add .insn for MIPS, is that sort
> >> > of approach (an arch specific asm/compiler-gcc.h to allow MIPS to
> >> > override barrier_before_unreachable()) an acceptable fix?
> >>
> >> That sounds fine to me. However, I would suggest making that
> >> asm/compiler.h instead of asm/compiler-gcc.h, so we can also
> >> use the same file to include workarounds for clang if needed.
> >
> > Yes, though there are a few asm/compiler.h's already, and the alpha one
> > includes linux/compiler.h before undefining inline, so seems to have its
> > own specific purpose...
>
> Interesting. For the other ones, including asm/compiler.h from linux/compiler.h
> seems appropriate though, so the question would be what to do with the
> alpha case. I think we can simply remove that header file and replace
> it with this patch:
>
> diff --git a/arch/alpha/Kconfig b/arch/alpha/Kconfig
> index b2022885ced8..5502404f54cd 100644
> --- a/arch/alpha/Kconfig
> +++ b/arch/alpha/Kconfig
> @@ -81,6 +81,9 @@ config PGTABLE_LEVELS
> int
> default 3
>
> +config OPTIMIZE_INLINING
> + def_bool y
> +
> source "init/Kconfig"
> source "kernel/Kconfig.freezer"
>
> which should have the same effect.
Hmm yes, and I suppose alpha would need ARCH_SUPPORTS_OPTIMIZED_INLINING
too. I'll give it a try.
Cheers
James
Attachment:
signature.asc
Description: Digital signature
[Index of Archives]
[Linux Kernel]
[Sparc Linux]
[DCCP]
[Linux ARM]
[Yosemite News]
[Linux SCSI]
[Linux x86_64]
[Linux for Ham Radio]