lkml.org 
[lkml]   [2020]   [Apr]   [9]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
SubjectRe: [PATCH] xfs: stop CONFIG_XFS_DEBUG from changing compiler flags
From
Date


On 4/9/20 1:08 AM, Arnd Bergmann wrote:
> I ran into a linker warning in XFS that originates from a mismatch
> between libelf, binutils and objtool when certain files in the kernel
> are built with "gcc -g":
>
> x86_64-linux-ld: fs/xfs/xfs_trace.o: unable to initialize decompress status for section .debug_info
>
> After some discussion, nobody could identify why xfs sets this flag
> here. CONFIG_XFS_DEBUG used to enable lots of unrelated settings, but
> now its main purpose is to enable extra consistency checks and assertions
> that are unrelated to the debug info.
>
> Remove the Makefile logic to set the flag here. If anyone relies
> on the debug info, this can simply be enabled again with the global
> CONFIG_DEBUG_INFO option.
>
> Suggested-by: Christoph Hellwig <hch@infradead.org>
> Link: https://urldefense.com/v3/__https://lore.kernel.org/lkml/20200409074130.GD21033@infradead.org/__;!!GqivPVa7Brio!JzJUQORI8aWjYFMvoyVmkgYSofJexLQn7p16KvP39F-NjuIzEXWqypgw0FnCyrdFtmZm$
> Signed-off-by: Arnd Bergmann <arnd@arndb.de>

Ok, looks good
Reviewed-by: Allison Collins <allison.henderson@oracle.com>

> ---
> fs/xfs/Makefile | 2 --
> 1 file changed, 2 deletions(-)
>
> diff --git a/fs/xfs/Makefile b/fs/xfs/Makefile
> index 4f95df476181..ff94fb90a2ee 100644
> --- a/fs/xfs/Makefile
> +++ b/fs/xfs/Makefile
> @@ -7,8 +7,6 @@
> ccflags-y += -I $(srctree)/$(src) # needed for trace events
> ccflags-y += -I $(srctree)/$(src)/libxfs
>
> -ccflags-$(CONFIG_XFS_DEBUG) += -g
> -
> obj-$(CONFIG_XFS_FS) += xfs.o
>
> # this one should be compiled first, as the tracing macros can easily blow up
>

\
 
 \ /
  Last update: 2020-04-09 17:52    [W:0.039 / U:0.160 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site