search for: kbuild_cflag

Displaying 20 results from an estimated 66 matches for "kbuild_cflag".

Did you mean: kbuild_cflags
2020 Feb 11
0
[PATCH 07/62] x86/boot/compressed/64: Disable red-zone usage
...deletions(-) diff --git a/arch/x86/boot/Makefile b/arch/x86/boot/Makefile index 012b82fc8617..8f55e4ce1ccc 100644 --- a/arch/x86/boot/Makefile +++ b/arch/x86/boot/Makefile @@ -65,7 +65,7 @@ clean-files += cpustr.h # --------------------------------------------------------------------------- -KBUILD_CFLAGS := $(REALMODE_CFLAGS) -D_SETUP +KBUILD_CFLAGS := $(REALMODE_CFLAGS) -D_SETUP -mno-red-zone KBUILD_AFLAGS := $(KBUILD_CFLAGS) -D__ASSEMBLY__ KBUILD_CFLAGS += $(call cc-option,-fmacro-prefix-map=$(srctree)/=) GCOV_PROFILE := n diff --git a/arch/x86/boot/compressed/Makefile b/arch/x86/boot/compres...
2020 Jul 24
0
[PATCH v5 11/75] x86/boot/compressed/64: Disable red-zone usage
...), 2 deletions(-) diff --git a/arch/x86/boot/Makefile b/arch/x86/boot/Makefile index fe605205b4ce..4d6a16a47e9f 100644 --- a/arch/x86/boot/Makefile +++ b/arch/x86/boot/Makefile @@ -66,7 +66,7 @@ targets += cpustr.h # --------------------------------------------------------------------------- -KBUILD_CFLAGS := $(REALMODE_CFLAGS) -D_SETUP +KBUILD_CFLAGS := $(REALMODE_CFLAGS) -D_SETUP -mno-red-zone KBUILD_AFLAGS := $(KBUILD_CFLAGS) -D__ASSEMBLY__ KBUILD_CFLAGS += $(call cc-option,-fmacro-prefix-map=$(srctree)/=) KBUILD_CFLAGS += -fno-asynchronous-unwind-tables diff --git a/arch/x86/boot/compressed/M...
2018 Jun 01
0
[PATCH 2/3] x86/build: use -std=gnu89 for proper extern inline semantics
On June 1, 2018 9:55:49 AM PDT, Nick Desaulniers <ndesaulniers at google.com> wrote: >The top level Makefile explicitly sets the C standard used in the >kernel >to gnu89. By overriding KBUILD_CFLAGS, the C standard used for this >subdir is now implicit based on compiler and compiler version. GCC >changes this implicit default from gnu89 to gnu11 in v5.1. > >This implies that depending on compiler version, parts of the kernel >are >being linked together from object files that...
2020 Mar 29
0
[kvm-unit-tests PATCH v3 1/4] Kbuild: add support for clang builds
...ude b/scripts/Kbuild.include index a048ec7a..5604b3e3 100644 --- a/scripts/Kbuild.include +++ b/scripts/Kbuild.include @@ -110,12 +110,12 @@ as-instr = $(call try-run,\ # Usage: cflags-y += $(call cc-option,-march=winchip-c6,-march=i586) cc-option = $(call try-run,\ - $(CC) $(KBUILD_CPPFLAGS) $(KBUILD_CFLAGS) $(1) -c -xc /dev/null -o "$$TMP",$(1),$(2)) + $(CC) $(KBUILD_CPPFLAGS) $(KBUILD_CFLAGS) $(1) -Werror -c -xc /dev/null -o "$$TMP",$(1),$(2)) # cc-option-yn # Usage: flag := $(call cc-option-yn,-march=winchip-c6) cc-option-yn = $(call try-run,\ - $(CC) $(KBUILD_CPPFLAGS) $(...
2020 Jul 25
0
[klibc:master] Kbuild: add support for clang builds
...ude b/scripts/Kbuild.include index a048ec7a..5604b3e3 100644 --- a/scripts/Kbuild.include +++ b/scripts/Kbuild.include @@ -110,12 +110,12 @@ as-instr = $(call try-run,\ # Usage: cflags-y += $(call cc-option,-march=winchip-c6,-march=i586) cc-option = $(call try-run,\ - $(CC) $(KBUILD_CPPFLAGS) $(KBUILD_CFLAGS) $(1) -c -xc /dev/null -o "$$TMP",$(1),$(2)) + $(CC) $(KBUILD_CPPFLAGS) $(KBUILD_CFLAGS) $(1) -Werror -c -xc /dev/null -o "$$TMP",$(1),$(2)) # cc-option-yn # Usage: flag := $(call cc-option-yn,-march=winchip-c6) cc-option-yn = $(call try-run,\ - $(CC) $(KBUILD_CPPFLAGS) $(...
2020 Mar 29
7
[kvm-unit-tests PATCH v3 0/4] Update patch set
- Renamed IMAGE_BASE to LD_IMAGE_BASE_OPT. - Moved "-fcommon" to KLIBCREQFLAGS in scripts/Kbuild.klibc. - Remove "dash" warning fixes which have been upstreamed. - Conditionalize the inclusion of compiler flags by using the proper compiler name or "cc-option". - Added "-Werror" to "cc-option" to catch flags that cause warnings. - Retain
2020 May 12
2
[PATCH v3 23/75] x86/boot/compressed/64: Setup GHCB Based VC Exception handler
...requires an AMD processor that supports Secure Memory > diff --git a/arch/x86/boot/compressed/Makefile b/arch/x86/boot/compressed/Makefile > index a7847a1ef63a..8372b85c9c0e 100644 > --- a/arch/x86/boot/compressed/Makefile > +++ b/arch/x86/boot/compressed/Makefile > @@ -41,6 +41,9 @@ KBUILD_CFLAGS += -Wno-pointer-sign > KBUILD_CFLAGS += $(call cc-option,-fmacro-prefix-map=$(srctree)/=) > KBUILD_CFLAGS += -fno-asynchronous-unwind-tables > > +# sev-es.c inludes generated $(objtree)/arch/x86/lib/inat-tables.c "includes" > +CFLAGS_sev-es.o += -I$(objtree)/a...
2020 May 12
2
[PATCH v3 23/75] x86/boot/compressed/64: Setup GHCB Based VC Exception handler
...requires an AMD processor that supports Secure Memory > diff --git a/arch/x86/boot/compressed/Makefile b/arch/x86/boot/compressed/Makefile > index a7847a1ef63a..8372b85c9c0e 100644 > --- a/arch/x86/boot/compressed/Makefile > +++ b/arch/x86/boot/compressed/Makefile > @@ -41,6 +41,9 @@ KBUILD_CFLAGS += -Wno-pointer-sign > KBUILD_CFLAGS += $(call cc-option,-fmacro-prefix-map=$(srctree)/=) > KBUILD_CFLAGS += -fno-asynchronous-unwind-tables > > +# sev-es.c inludes generated $(objtree)/arch/x86/lib/inat-tables.c "includes" > +CFLAGS_sev-es.o += -I$(objtree)/a...
2018 Jun 05
1
[PATCH v2 2/2] x86: paravirt: make native_save_fl extern inline
On Tue, Jun 5, 2018 at 7:05 PM, Nick Desaulniers <ndesaulniers at google.com> wrote: > > The semantics of extern inline has changed since gnu89. This means that > folks using GCC versions >= 5.1 may see symbol redefinition errors at > link time for subdirs that override KBUILD_CFLAGS (making the C standard > used implicit) regardless of this patch. This has been cleaned up > earlier in the patch set, but is left as a note in the commit message > for future travelers. I think the keyword you are missing is __attribute__((gnu_inline)) which forces the gnu89 behavior...
2018 Jun 19
0
[PATCH v5 0/3] extern inline native_save_fl for paravirt
...different compilers or flags can > then add a stack guard that violates the calling conventions. > > Uses extern inline with the out-of-line definition in assembly to > prevent compilers from adding stack guards to the outlined version. > > Other parts of the codebase overwrite KBUILD_CFLAGS, which is *extremely > problematic* for extern inline, as the sematics are completely the > opposite depending on what C standard is used. > http://blahg.josefsipek.net/?p=529 > > Changes since v4: > Take Arnd's and hpa's suggestions properly feature detect gnu_inline...
2020 Apr 28
0
[PATCH v3 23/75] x86/boot/compressed/64: Setup GHCB Based VC Exception handler
...system memory. This requires an AMD processor that supports Secure Memory diff --git a/arch/x86/boot/compressed/Makefile b/arch/x86/boot/compressed/Makefile index a7847a1ef63a..8372b85c9c0e 100644 --- a/arch/x86/boot/compressed/Makefile +++ b/arch/x86/boot/compressed/Makefile @@ -41,6 +41,9 @@ KBUILD_CFLAGS += -Wno-pointer-sign KBUILD_CFLAGS += $(call cc-option,-fmacro-prefix-map=$(srctree)/=) KBUILD_CFLAGS += -fno-asynchronous-unwind-tables +# sev-es.c inludes generated $(objtree)/arch/x86/lib/inat-tables.c +CFLAGS_sev-es.o += -I$(objtree)/arch/x86/lib/ + KBUILD_AFLAGS := $(KBUILD_CFLAGS) -D__...
2018 May 23
0
[PATCH v3 23/27] x86/modules: Adapt module loading for PIE support
...l/module.lds | 3 + 5 files changed, 198 insertions(+), 5 deletions(-) create mode 100644 arch/x86/kernel/module.lds diff --git a/arch/x86/Makefile b/arch/x86/Makefile index 277ffc57ae13..20bb6cbd8938 100644 --- a/arch/x86/Makefile +++ b/arch/x86/Makefile @@ -134,7 +134,11 @@ else KBUILD_CFLAGS += $(cflags-y) KBUILD_CFLAGS += -mno-red-zone +ifdef CONFIG_X86_PIE + KBUILD_LDFLAGS_MODULE += -T $(srctree)/arch/x86/kernel/module.lds +else KBUILD_CFLAGS += -mcmodel=kernel +endif # -funit-at-a-time shrinks the kernel .text considerably # unfortunat...
2012 May 17
5
[PATCH 1/1] kbuild: sync with kernel 3.4-rc7
...hen echo "$(2)"; \ + else echo "$(3)"; \ + fi; \ + rm -f "$$TMP" "$$TMPO") + # as-option -# Usage: cflags-y += $(call as-option, -Wa$(comma)-isa=foo,) +# Usage: cflags-y += $(call as-option,-Wa$(comma)-isa=foo,) + +as-option = $(call try-run,\ + $(CC) $(KBUILD_CFLAGS) $(1) -c -xassembler /dev/null -o "$$TMP",$(1),$(2)) -as-option = $(shell if $(CC) $(CFLAGS) $(1) -Wa,-Z -c -o /dev/null \ - -xassembler /dev/null > /dev/null 2>&1; then echo "$(1)"; \ - else echo "$(2)"; fi ;) +# as-instr +# Usage: cflags-y += $...
2013 Jun 01
2
[LLVMdev] Compile Linux Kernel module into LLVM bitcode
...el modules works with clang as a front end. However, I am unable to get the "-emit-llvm" flag to work. I am using the typical Makefile system (kbuild) included with the kernel, as such: $ make V=1 CC=clang CFLAGS="-emit-llvm -c" drivers/gpu/drm/drm_drv.o I have tried setting KBUILD_CFLAGS or KCFLAGS instead of CFLAGS, but nothing I do gets it to work. Trying these few different variations gets me to the point where it doesn't actually use the "-emit-llvm" flag in the clang (previously gcc) commands that are shown with the verbose V=1 option. If the "-emit-llvm&...
2018 Jun 12
0
[PATCH v4 1/3] compiler-gcc.h: add gnu_inline to all inline declarations
...n Thu, Jun 7, 2018 at 10:49 PM, Nick Desaulniers >> > <ndesaulniers at google.com> wrote: >> >> Functions marked extern inline do not emit an externally visible >> >> function when the gnu89 C standard is used. Some KBUILD Makefiles >> >> overwrite KBUILD_CFLAGS. This is an issue for GCC 5.1+ users as >without >> >> an explicit C standard specified, the default is gnu11. Since c99, >the >> >> semantics of extern inline have changed such that an externally >visible >> >> function is always emitted. This can lead...
2020 Oct 17
1
[Cocci] [RFC] treewide: cleanup unreachable breaks
On Sat, 17 Oct 2020, Joe Perches wrote: > On Sat, 2020-10-17 at 09:09 -0700, trix at redhat.com wrote: > > From: Tom Rix <trix at redhat.com> > > > > This is a upcoming change to clean up a new warning treewide. > > I am wondering if the change could be one mega patch (see below) or > > normal patch per file about 100 patches or somewhere half way by
2020 Oct 17
1
[Cocci] [RFC] treewide: cleanup unreachable breaks
On Sat, 17 Oct 2020, Joe Perches wrote: > On Sat, 2020-10-17 at 09:09 -0700, trix at redhat.com wrote: > > From: Tom Rix <trix at redhat.com> > > > > This is a upcoming change to clean up a new warning treewide. > > I am wondering if the change could be one mega patch (see below) or > > normal patch per file about 100 patches or somewhere half way by
2013 Jun 01
0
[LLVMdev] Compile Linux Kernel module into LLVM bitcode
...clang as a front end. However, I am unable to get the "-emit-llvm" flag to work. > > I am using the typical Makefile system (kbuild) included with the kernel, as such: > $ make V=1 CC=clang CFLAGS="-emit-llvm -c" drivers/gpu/drm/drm_drv.o > > I have tried setting KBUILD_CFLAGS or KCFLAGS instead of CFLAGS, but nothing I do gets it to work. Trying these few different variations gets me to the point where it doesn't actually use the "-emit-llvm" flag in the clang (previously gcc) commands that are shown with the verbose V=1 option. If the "-emit-llvm&...
2013 Jun 08
1
[LLVMdev] Compile Linux Kernel module into LLVM bitcode
...ever, I am unable to get the "-emit-llvm" flag to work. > > > > I am using the typical Makefile system (kbuild) included with the kernel, as such: > > $ make V=1 CC=clang CFLAGS="-emit-llvm -c" drivers/gpu/drm/drm_drv.o > > > > I have tried setting KBUILD_CFLAGS or KCFLAGS instead of CFLAGS, but nothing I do gets it to work. Trying these few different variations gets me to the point where it doesn't actually use the "-emit-llvm" flag in the clang (previously gcc) commands that are shown with the verbose V=1 option. If the "-emit-llvm&...
2018 Jun 07
0
[PATCH v3 1/3] compiler-gcc.h: add gnu_inline to all inline declarations
On Thu, 2018-06-07 at 11:32 -0700, Nick Desaulniers wrote: > Functions marked extern inline do not emit an externally visible > function when the gnu89 C standard is used. Some KBUILD Makefiles > overwrite KBUILD_CFLAGS. This is an issue for GCC 5.1+ users as without > an explicit C standard specified, the default is gnu11. Since c99, the > semantics of extern inline have changed such that an externally visible > function is always emitted. This can lead to multiple definition errors > of extern inlin...