linux-arm-kernel.lists.infradead.org archive mirror
 help / color / mirror / Atom feed
* "arm64: Silence gcc warnings about arch ABI drift" breaks clang
@ 2019-06-07 15:22 Qian Cai
  2019-06-07 15:25 ` Will Deacon
  0 siblings, 1 reply; 6+ messages in thread
From: Qian Cai @ 2019-06-07 15:22 UTC (permalink / raw)
  To: Dave Martin
  Cc: linux-efi, Ard Biesheuvel, Catalin Marinas, Will Deacon,
	linux-kernel@vger.kernel.org, linux-arm-kernel

The linux-next commit "arm64: Silence gcc warnings about arch ABI drift" [1]
breaks clang build where it screams that unknown option "-Wno-psabi" and
generates errors below,

[1] https://lore.kernel.org/linux-arm-kernel/1559817223-32585-1-git-send-email-D
ave.Martin@arm.com/

./drivers/firmware/efi/libstub/arm-stub.stub.o: In function
`install_memreserve_table':
./linux/drivers/firmware/efi/libstub/arm-stub.c:73: undefined reference to
`__efistub___stack_chk_guard'
./linux/drivers/firmware/efi/libstub/arm-stub.c:73: undefined reference to
`__efistub___stack_chk_guard'
./linux/drivers/firmware/efi/libstub/arm-stub.c:93: undefined reference to
`__efistub___stack_chk_guard'
./linux/drivers/firmware/efi/libstub/arm-stub.c:93: undefined reference to
`__efistub___stack_chk_guard'
./linux/drivers/firmware/efi/libstub/arm-stub.c:94: undefined reference to
`__efistub___stack_chk_fail

_______________________________________________
linux-arm-kernel mailing list
linux-arm-kernel@lists.infradead.org
http://lists.infradead.org/mailman/listinfo/linux-arm-kernel

^ permalink raw reply	[flat|nested] 6+ messages in thread

* Re: "arm64: Silence gcc warnings about arch ABI drift" breaks clang
  2019-06-07 15:22 "arm64: Silence gcc warnings about arch ABI drift" breaks clang Qian Cai
@ 2019-06-07 15:25 ` Will Deacon
  2019-06-07 15:26   ` Qian Cai
  0 siblings, 1 reply; 6+ messages in thread
From: Will Deacon @ 2019-06-07 15:25 UTC (permalink / raw)
  To: Qian Cai
  Cc: linux-efi, Ard Biesheuvel, Catalin Marinas,
	linux-kernel@vger.kernel.org, Dave Martin, linux-arm-kernel

On Fri, Jun 07, 2019 at 11:22:45AM -0400, Qian Cai wrote:
> The linux-next commit "arm64: Silence gcc warnings about arch ABI drift" [1]
> breaks clang build where it screams that unknown option "-Wno-psabi" and
> generates errors below,

So that can be easily fixed with cc-option...

> [1] https://lore.kernel.org/linux-arm-kernel/1559817223-32585-1-git-send-email-D
> ave.Martin@arm.com/
> 
> ./drivers/firmware/efi/libstub/arm-stub.stub.o: In function
> `install_memreserve_table':
> ./linux/drivers/firmware/efi/libstub/arm-stub.c:73: undefined reference to
> `__efistub___stack_chk_guard'
> ./linux/drivers/firmware/efi/libstub/arm-stub.c:73: undefined reference to
> `__efistub___stack_chk_guard'
> ./linux/drivers/firmware/efi/libstub/arm-stub.c:93: undefined reference to
> `__efistub___stack_chk_guard'
> ./linux/drivers/firmware/efi/libstub/arm-stub.c:93: undefined reference to
> `__efistub___stack_chk_guard'
> ./linux/drivers/firmware/efi/libstub/arm-stub.c:94: undefined reference to
> `__efistub___stack_chk_fail

... but this looks unrelated. Are you saying you don't see these errors if
you revert Dave's patch?

Will

_______________________________________________
linux-arm-kernel mailing list
linux-arm-kernel@lists.infradead.org
http://lists.infradead.org/mailman/listinfo/linux-arm-kernel

^ permalink raw reply	[flat|nested] 6+ messages in thread

* Re: "arm64: Silence gcc warnings about arch ABI drift" breaks clang
  2019-06-07 15:25 ` Will Deacon
@ 2019-06-07 15:26   ` Qian Cai
  2019-06-07 15:40     ` Nathan Chancellor
  0 siblings, 1 reply; 6+ messages in thread
From: Qian Cai @ 2019-06-07 15:26 UTC (permalink / raw)
  To: Will Deacon
  Cc: linux-efi, Ard Biesheuvel, Catalin Marinas,
	linux-kernel@vger.kernel.org, Dave Martin, linux-arm-kernel

On Fri, 2019-06-07 at 16:25 +0100, Will Deacon wrote:
> On Fri, Jun 07, 2019 at 11:22:45AM -0400, Qian Cai wrote:
> > The linux-next commit "arm64: Silence gcc warnings about arch ABI drift" [1]
> > breaks clang build where it screams that unknown option "-Wno-psabi" and
> > generates errors below,
> 
> So that can be easily fixed with cc-option...
> 
> > [1] https://lore.kernel.org/linux-arm-kernel/1559817223-32585-1-git-send-ema
> > il-D
> > ave.Martin@arm.com/
> > 
> > ./drivers/firmware/efi/libstub/arm-stub.stub.o: In function
> > `install_memreserve_table':
> > ./linux/drivers/firmware/efi/libstub/arm-stub.c:73: undefined reference to
> > `__efistub___stack_chk_guard'
> > ./linux/drivers/firmware/efi/libstub/arm-stub.c:73: undefined reference to
> > `__efistub___stack_chk_guard'
> > ./linux/drivers/firmware/efi/libstub/arm-stub.c:93: undefined reference to
> > `__efistub___stack_chk_guard'
> > ./linux/drivers/firmware/efi/libstub/arm-stub.c:93: undefined reference to
> > `__efistub___stack_chk_guard'
> > ./linux/drivers/firmware/efi/libstub/arm-stub.c:94: undefined reference to
> > `__efistub___stack_chk_fail
> 
> ... but this looks unrelated. Are you saying you don't see these errors if
> you revert Dave's patch?

Yes.

_______________________________________________
linux-arm-kernel mailing list
linux-arm-kernel@lists.infradead.org
http://lists.infradead.org/mailman/listinfo/linux-arm-kernel

^ permalink raw reply	[flat|nested] 6+ messages in thread

* Re: "arm64: Silence gcc warnings about arch ABI drift" breaks clang
  2019-06-07 15:26   ` Qian Cai
@ 2019-06-07 15:40     ` Nathan Chancellor
  2019-06-07 15:41       ` Will Deacon
  2019-06-07 15:42       ` Dave Martin
  0 siblings, 2 replies; 6+ messages in thread
From: Nathan Chancellor @ 2019-06-07 15:40 UTC (permalink / raw)
  To: Qian Cai
  Cc: linux-efi, Ard Biesheuvel, Catalin Marinas, Will Deacon,
	linux-kernel@vger.kernel.org, clang-built-linux, Dave Martin,
	linux-arm-kernel

On Fri, Jun 07, 2019 at 11:26:11AM -0400, Qian Cai wrote:
> On Fri, 2019-06-07 at 16:25 +0100, Will Deacon wrote:
> > On Fri, Jun 07, 2019 at 11:22:45AM -0400, Qian Cai wrote:
> > > The linux-next commit "arm64: Silence gcc warnings about arch ABI drift" [1]
> > > breaks clang build where it screams that unknown option "-Wno-psabi" and
> > > generates errors below,
> > 
> > So that can be easily fixed with cc-option...
> > 
> > > [1] https://lore.kernel.org/linux-arm-kernel/1559817223-32585-1-git-send-ema
> > > il-D
> > > ave.Martin@arm.com/
> > > 
> > > ./drivers/firmware/efi/libstub/arm-stub.stub.o: In function
> > > `install_memreserve_table':
> > > ./linux/drivers/firmware/efi/libstub/arm-stub.c:73: undefined reference to
> > > `__efistub___stack_chk_guard'
> > > ./linux/drivers/firmware/efi/libstub/arm-stub.c:73: undefined reference to
> > > `__efistub___stack_chk_guard'
> > > ./linux/drivers/firmware/efi/libstub/arm-stub.c:93: undefined reference to
> > > `__efistub___stack_chk_guard'
> > > ./linux/drivers/firmware/efi/libstub/arm-stub.c:93: undefined reference to
> > > `__efistub___stack_chk_guard'
> > > ./linux/drivers/firmware/efi/libstub/arm-stub.c:94: undefined reference to
> > > `__efistub___stack_chk_fail
> > 
> > ... but this looks unrelated. Are you saying you don't see these errors if
> > you revert Dave's patch?
> 
> Yes.

I suspect the reason for this is -Wunknown-warning-option causes
cc-option to fail. I see some disabled warnings like
-Waddress-of-packed-member and -Wunused-const-variable when -Wno-psabi
is unconditionally added.

I'll do some further triage but I think the obvious fix as Will
suggested is to use cc-disable-warning. I'll send a patch.

Cheers,
Nathan

_______________________________________________
linux-arm-kernel mailing list
linux-arm-kernel@lists.infradead.org
http://lists.infradead.org/mailman/listinfo/linux-arm-kernel

^ permalink raw reply	[flat|nested] 6+ messages in thread

* Re: "arm64: Silence gcc warnings about arch ABI drift" breaks clang
  2019-06-07 15:40     ` Nathan Chancellor
@ 2019-06-07 15:41       ` Will Deacon
  2019-06-07 15:42       ` Dave Martin
  1 sibling, 0 replies; 6+ messages in thread
From: Will Deacon @ 2019-06-07 15:41 UTC (permalink / raw)
  To: Nathan Chancellor
  Cc: linux-efi, Ard Biesheuvel, Catalin Marinas,
	linux-kernel@vger.kernel.org, clang-built-linux, Qian Cai,
	Dave Martin, linux-arm-kernel

On Fri, Jun 07, 2019 at 08:40:10AM -0700, Nathan Chancellor wrote:
> On Fri, Jun 07, 2019 at 11:26:11AM -0400, Qian Cai wrote:
> > On Fri, 2019-06-07 at 16:25 +0100, Will Deacon wrote:
> > > On Fri, Jun 07, 2019 at 11:22:45AM -0400, Qian Cai wrote:
> > > > The linux-next commit "arm64: Silence gcc warnings about arch ABI drift" [1]
> > > > breaks clang build where it screams that unknown option "-Wno-psabi" and
> > > > generates errors below,
> > > 
> > > So that can be easily fixed with cc-option...
> > > 
> > > > [1] https://lore.kernel.org/linux-arm-kernel/1559817223-32585-1-git-send-ema
> > > > il-D
> > > > ave.Martin@arm.com/
> > > > 
> > > > ./drivers/firmware/efi/libstub/arm-stub.stub.o: In function
> > > > `install_memreserve_table':
> > > > ./linux/drivers/firmware/efi/libstub/arm-stub.c:73: undefined reference to
> > > > `__efistub___stack_chk_guard'
> > > > ./linux/drivers/firmware/efi/libstub/arm-stub.c:73: undefined reference to
> > > > `__efistub___stack_chk_guard'
> > > > ./linux/drivers/firmware/efi/libstub/arm-stub.c:93: undefined reference to
> > > > `__efistub___stack_chk_guard'
> > > > ./linux/drivers/firmware/efi/libstub/arm-stub.c:93: undefined reference to
> > > > `__efistub___stack_chk_guard'
> > > > ./linux/drivers/firmware/efi/libstub/arm-stub.c:94: undefined reference to
> > > > `__efistub___stack_chk_fail
> > > 
> > > ... but this looks unrelated. Are you saying you don't see these errors if
> > > you revert Dave's patch?
> > 
> > Yes.
> 
> I suspect the reason for this is -Wunknown-warning-option causes
> cc-option to fail. I see some disabled warnings like
> -Waddress-of-packed-member and -Wunused-const-variable when -Wno-psabi
> is unconditionally added.
> 
> I'll do some further triage but I think the obvious fix as Will
> suggested is to use cc-disable-warning. I'll send a patch.

Cheers, Nathan. I've already sent the pull for -rc4, but I can send your
fix for -rc5 next week.

Will

_______________________________________________
linux-arm-kernel mailing list
linux-arm-kernel@lists.infradead.org
http://lists.infradead.org/mailman/listinfo/linux-arm-kernel

^ permalink raw reply	[flat|nested] 6+ messages in thread

* Re: "arm64: Silence gcc warnings about arch ABI drift" breaks clang
  2019-06-07 15:40     ` Nathan Chancellor
  2019-06-07 15:41       ` Will Deacon
@ 2019-06-07 15:42       ` Dave Martin
  1 sibling, 0 replies; 6+ messages in thread
From: Dave Martin @ 2019-06-07 15:42 UTC (permalink / raw)
  To: Nathan Chancellor
  Cc: linux-efi, Ard Biesheuvel, Catalin Marinas, Will Deacon,
	linux-kernel@vger.kernel.org, clang-built-linux, Qian Cai,
	linux-arm-kernel

On Fri, Jun 07, 2019 at 08:40:10AM -0700, Nathan Chancellor wrote:
> On Fri, Jun 07, 2019 at 11:26:11AM -0400, Qian Cai wrote:
> > On Fri, 2019-06-07 at 16:25 +0100, Will Deacon wrote:
> > > On Fri, Jun 07, 2019 at 11:22:45AM -0400, Qian Cai wrote:
> > > > The linux-next commit "arm64: Silence gcc warnings about arch ABI drift" [1]
> > > > breaks clang build where it screams that unknown option "-Wno-psabi" and
> > > > generates errors below,
> > > 
> > > So that can be easily fixed with cc-option...
> > > 
> > > > [1] https://lore.kernel.org/linux-arm-kernel/1559817223-32585-1-git-send-ema
> > > > il-D
> > > > ave.Martin@arm.com/
> > > > 
> > > > ./drivers/firmware/efi/libstub/arm-stub.stub.o: In function
> > > > `install_memreserve_table':
> > > > ./linux/drivers/firmware/efi/libstub/arm-stub.c:73: undefined reference to
> > > > `__efistub___stack_chk_guard'
> > > > ./linux/drivers/firmware/efi/libstub/arm-stub.c:73: undefined reference to
> > > > `__efistub___stack_chk_guard'
> > > > ./linux/drivers/firmware/efi/libstub/arm-stub.c:93: undefined reference to
> > > > `__efistub___stack_chk_guard'
> > > > ./linux/drivers/firmware/efi/libstub/arm-stub.c:93: undefined reference to
> > > > `__efistub___stack_chk_guard'
> > > > ./linux/drivers/firmware/efi/libstub/arm-stub.c:94: undefined reference to
> > > > `__efistub___stack_chk_fail
> > > 
> > > ... but this looks unrelated. Are you saying you don't see these errors if
> > > you revert Dave's patch?
> > 
> > Yes.
> 
> I suspect the reason for this is -Wunknown-warning-option causes
> cc-option to fail. I see some disabled warnings like
> -Waddress-of-packed-member and -Wunused-const-variable when -Wno-psabi
> is unconditionally added.
> 
> I'll do some further triage but I think the obvious fix as Will
> suggested is to use cc-disable-warning. I'll send a patch.

Thanks for that.

Cheers
---Dave

_______________________________________________
linux-arm-kernel mailing list
linux-arm-kernel@lists.infradead.org
http://lists.infradead.org/mailman/listinfo/linux-arm-kernel

^ permalink raw reply	[flat|nested] 6+ messages in thread

end of thread, other threads:[~2019-06-07 15:43 UTC | newest]

Thread overview: 6+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2019-06-07 15:22 "arm64: Silence gcc warnings about arch ABI drift" breaks clang Qian Cai
2019-06-07 15:25 ` Will Deacon
2019-06-07 15:26   ` Qian Cai
2019-06-07 15:40     ` Nathan Chancellor
2019-06-07 15:41       ` Will Deacon
2019-06-07 15:42       ` Dave Martin

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).