mirror of
https://github.com/armbian/linux-cix.git
synced 2026-01-06 12:30:45 -08:00
Merge tag 'kbuild-v5.7' of git://git.kernel.org/pub/scm/linux/kernel/git/masahiroy/linux-kbuild
Pull Kbuild updates from Masahiro Yamada:
"Build system:
- add CONFIG_UNUSED_KSYMS_WHITELIST, which will be useful to define a
fixed set of export symbols for Generic Kernel Image (GKI)
- allow to run 'make dt_binding_check' without .config
- use full schema for checking DT examples in *.yaml files
- make modpost fail for missing MODULE_IMPORT_NS(), which makes more
sense because we know the produced modules are never loadable
- Remove unused 'AS' variable
Kconfig:
- sanitize DEFCONFIG_LIST, and remove ARCH_DEFCONFIG from Kconfig
files
- relax the 'imply' behavior so that symbols implied by 'y' can
become 'm'
- make 'imply' obey 'depends on' in order to make 'imply' really weak
Misc:
- add documentation on building the kernel with Clang/LLVM
- revive __HAVE_ARCH_STRLEN for 32bit sparc to use optimized strlen()
- fix warning from deb-pkg builds when CONFIG_DEBUG_INFO=n
- various script and Makefile cleanups"
* tag 'kbuild-v5.7' of git://git.kernel.org/pub/scm/linux/kernel/git/masahiroy/linux-kbuild: (34 commits)
Makefile: Update kselftest help information
kbuild: deb-pkg: fix warning when CONFIG_DEBUG_INFO is unset
kbuild: add outputmakefile to no-dot-config-targets
kbuild: remove AS variable
net: wan: wanxl: refactor the firmware rebuild rule
net: wan: wanxl: use $(M68KCC) instead of $(M68KAS) for rebuilding firmware
net: wan: wanxl: use allow to pass CROSS_COMPILE_M68k for rebuilding firmware
kbuild: add comment about grouped target
kbuild: add -Wall to KBUILD_HOSTCXXFLAGS
kconfig: remove unused variable in qconf.cc
sparc: revive __HAVE_ARCH_STRLEN for 32bit sparc
kbuild: refactor Makefile.dtbinst more
kbuild: compute the dtbs_install destination more simply
Makefile: disallow data races on gcc-10 as well
kconfig: make 'imply' obey the direct dependency
kconfig: allow symbols implied by y to become m
net: drop_monitor: use IS_REACHABLE() to guard net_dm_hw_report()
modpost: return error if module is missing ns imports and MODULE_ALLOW_MISSING_NAMESPACE_IMPORTS=n
modpost: rework and consolidate logging interface
kbuild: allow to run dt_binding_check without kernel configuration
...
This commit is contained in:
@@ -2,7 +2,8 @@
|
||||
# Makefile for Sphinx documentation
|
||||
#
|
||||
|
||||
subdir-y := devicetree/bindings/
|
||||
# for cleaning
|
||||
subdir- := devicetree/bindings
|
||||
|
||||
# Check for broken documentation file references
|
||||
ifeq ($(CONFIG_WARN_MISSING_DOCUMENTS),y)
|
||||
|
||||
2
Documentation/devicetree/bindings/.gitignore
vendored
2
Documentation/devicetree/bindings/.gitignore
vendored
@@ -1,2 +1,2 @@
|
||||
*.example.dts
|
||||
processed-schema.yaml
|
||||
processed-schema*.yaml
|
||||
|
||||
@@ -2,7 +2,6 @@
|
||||
DT_DOC_CHECKER ?= dt-doc-validate
|
||||
DT_EXTRACT_EX ?= dt-extract-example
|
||||
DT_MK_SCHEMA ?= dt-mk-schema
|
||||
DT_MK_SCHEMA_FLAGS := $(if $(DT_SCHEMA_FILES), -u)
|
||||
|
||||
quiet_cmd_chk_binding = CHKDT $(patsubst $(srctree)/%,%,$<)
|
||||
cmd_chk_binding = $(DT_DOC_CHECKER) -u $(srctree)/$(src) $< ; \
|
||||
@@ -11,26 +10,35 @@ quiet_cmd_chk_binding = CHKDT $(patsubst $(srctree)/%,%,$<)
|
||||
$(obj)/%.example.dts: $(src)/%.yaml FORCE
|
||||
$(call if_changed,chk_binding)
|
||||
|
||||
DT_TMP_SCHEMA := processed-schema.yaml
|
||||
# Use full schemas when checking %.example.dts
|
||||
DT_TMP_SCHEMA := $(obj)/processed-schema-examples.yaml
|
||||
|
||||
quiet_cmd_mk_schema = SCHEMA $@
|
||||
cmd_mk_schema = $(DT_MK_SCHEMA) $(DT_MK_SCHEMA_FLAGS) -o $@ $(real-prereqs)
|
||||
|
||||
DT_DOCS = $(shell \
|
||||
DT_DOCS = $(addprefix $(src)/, \
|
||||
$(shell \
|
||||
cd $(srctree)/$(src) && \
|
||||
find * \( -name '*.yaml' ! \
|
||||
-name $(DT_TMP_SCHEMA) ! \
|
||||
-name 'processed-schema*' ! \
|
||||
-name '*.example.dt.yaml' \) \
|
||||
)
|
||||
))
|
||||
|
||||
DT_SCHEMA_FILES ?= $(addprefix $(src)/,$(DT_DOCS))
|
||||
DT_SCHEMA_FILES ?= $(DT_DOCS)
|
||||
|
||||
ifeq ($(CHECK_DTBS),)
|
||||
extra-y += $(patsubst $(src)/%.yaml,%.example.dts, $(DT_SCHEMA_FILES))
|
||||
extra-y += $(patsubst $(src)/%.yaml,%.example.dt.yaml, $(DT_SCHEMA_FILES))
|
||||
endif
|
||||
extra-$(CHECK_DT_BINDING) += $(patsubst $(src)/%.yaml,%.example.dts, $(DT_SCHEMA_FILES))
|
||||
extra-$(CHECK_DT_BINDING) += $(patsubst $(src)/%.yaml,%.example.dt.yaml, $(DT_SCHEMA_FILES))
|
||||
extra-$(CHECK_DT_BINDING) += processed-schema-examples.yaml
|
||||
|
||||
$(obj)/$(DT_TMP_SCHEMA): $(DT_SCHEMA_FILES) FORCE
|
||||
override DTC_FLAGS := \
|
||||
-Wno-avoid_unnecessary_addr_size \
|
||||
-Wno-graph_child_address
|
||||
|
||||
$(obj)/processed-schema-examples.yaml: $(DT_DOCS) FORCE
|
||||
$(call if_changed,mk_schema)
|
||||
|
||||
extra-y += $(DT_TMP_SCHEMA)
|
||||
$(obj)/processed-schema.yaml: DT_MK_SCHEMA_FLAGS := -u
|
||||
$(obj)/processed-schema.yaml: $(DT_SCHEMA_FILES) FORCE
|
||||
$(call if_changed,mk_schema)
|
||||
|
||||
extra-y += processed-schema.yaml
|
||||
|
||||
@@ -147,6 +147,10 @@ Note that ``dtbs_check`` will skip any binding schema files with errors. It is
|
||||
necessary to use ``dt_binding_check`` to get all the validation errors in the
|
||||
binding schema files.
|
||||
|
||||
It is possible to run both in a single command::
|
||||
|
||||
make dt_binding_check dtbs_check
|
||||
|
||||
It is also possible to run checks with a single schema file by setting the
|
||||
``DT_SCHEMA_FILES`` variable to a specific schema file.
|
||||
|
||||
|
||||
@@ -20,6 +20,7 @@ Kernel Build System
|
||||
issues
|
||||
reproducible-builds
|
||||
gcc-plugins
|
||||
llvm
|
||||
|
||||
.. only:: subproject and html
|
||||
|
||||
|
||||
@@ -159,11 +159,11 @@ applicable everywhere (see syntax).
|
||||
Given the following example::
|
||||
|
||||
config FOO
|
||||
tristate
|
||||
tristate "foo"
|
||||
imply BAZ
|
||||
|
||||
config BAZ
|
||||
tristate
|
||||
tristate "baz"
|
||||
depends on BAR
|
||||
|
||||
The following values are possible:
|
||||
@@ -173,7 +173,10 @@ applicable everywhere (see syntax).
|
||||
=== === ============= ==============
|
||||
n y n N/m/y
|
||||
m y m M/y/n
|
||||
y y y Y/n
|
||||
y y y Y/m/n
|
||||
n m n N/m
|
||||
m m m M/n
|
||||
y m n M/n
|
||||
y n * N
|
||||
=== === ============= ==============
|
||||
|
||||
@@ -181,6 +184,24 @@ applicable everywhere (see syntax).
|
||||
ability to hook into a secondary subsystem while allowing the user to
|
||||
configure that subsystem out without also having to unset these drivers.
|
||||
|
||||
Note: If the combination of FOO=y and BAR=m causes a link error,
|
||||
you can guard the function call with IS_REACHABLE()::
|
||||
|
||||
foo_init()
|
||||
{
|
||||
if (IS_REACHABLE(CONFIG_BAZ))
|
||||
baz_register(&foo);
|
||||
...
|
||||
}
|
||||
|
||||
Note: If the feature provided by BAZ is highly desirable for FOO,
|
||||
FOO should imply not only BAZ, but also its dependency BAR::
|
||||
|
||||
config FOO
|
||||
tristate "foo"
|
||||
imply BAR
|
||||
imply BAZ
|
||||
|
||||
- limiting menu display: "visible if" <expr>
|
||||
|
||||
This attribute is only applicable to menu blocks, if the condition is
|
||||
|
||||
80
Documentation/kbuild/llvm.rst
Normal file
80
Documentation/kbuild/llvm.rst
Normal file
@@ -0,0 +1,80 @@
|
||||
==============================
|
||||
Building Linux with Clang/LLVM
|
||||
==============================
|
||||
|
||||
This document covers how to build the Linux kernel with Clang and LLVM
|
||||
utilities.
|
||||
|
||||
About
|
||||
-----
|
||||
|
||||
The Linux kernel has always traditionally been compiled with GNU toolchains
|
||||
such as GCC and binutils. Ongoing work has allowed for `Clang
|
||||
<https://clang.llvm.org/>`_ and `LLVM <https://llvm.org/>`_ utilities to be
|
||||
used as viable substitutes. Distributions such as `Android
|
||||
<https://www.android.com/>`_, `ChromeOS
|
||||
<https://www.chromium.org/chromium-os>`_, and `OpenMandriva
|
||||
<https://www.openmandriva.org/>`_ use Clang built kernels. `LLVM is a
|
||||
collection of toolchain components implemented in terms of C++ objects
|
||||
<https://www.aosabook.org/en/llvm.html>`_. Clang is a front-end to LLVM that
|
||||
supports C and the GNU C extensions required by the kernel, and is pronounced
|
||||
"klang," not "see-lang."
|
||||
|
||||
Clang
|
||||
-----
|
||||
|
||||
The compiler used can be swapped out via `CC=` command line argument to `make`.
|
||||
`CC=` should be set when selecting a config and during a build.
|
||||
|
||||
make CC=clang defconfig
|
||||
|
||||
make CC=clang
|
||||
|
||||
Cross Compiling
|
||||
---------------
|
||||
|
||||
A single Clang compiler binary will typically contain all supported backends,
|
||||
which can help simplify cross compiling.
|
||||
|
||||
ARCH=arm64 CROSS_COMPILE=aarch64-linux-gnu- make CC=clang
|
||||
|
||||
`CROSS_COMPILE` is not used to prefix the Clang compiler binary, instead
|
||||
`CROSS_COMPILE` is used to set a command line flag: `--target <triple>`. For
|
||||
example:
|
||||
|
||||
clang --target aarch64-linux-gnu foo.c
|
||||
|
||||
LLVM Utilities
|
||||
--------------
|
||||
|
||||
LLVM has substitutes for GNU binutils utilities. These can be invoked as
|
||||
additional parameters to `make`.
|
||||
|
||||
make CC=clang AS=clang LD=ld.lld AR=llvm-ar NM=llvm-nm STRIP=llvm-strip \\
|
||||
OBJCOPY=llvm-objcopy OBJDUMP=llvm-objdump OBJSIZE=llvm-objsize \\
|
||||
READELF=llvm-readelf HOSTCC=clang HOSTCXX=clang++ HOSTAR=llvm-ar \\
|
||||
HOSTLD=ld.lld
|
||||
|
||||
Getting Help
|
||||
------------
|
||||
|
||||
- `Website <https://clangbuiltlinux.github.io/>`_
|
||||
- `Mailing List <https://groups.google.com/forum/#!forum/clang-built-linux>`_: <clang-built-linux@googlegroups.com>
|
||||
- `Issue Tracker <https://github.com/ClangBuiltLinux/linux/issues>`_
|
||||
- IRC: #clangbuiltlinux on chat.freenode.net
|
||||
- `Telegram <https://t.me/ClangBuiltLinux>`_: @ClangBuiltLinux
|
||||
- `Wiki <https://github.com/ClangBuiltLinux/linux/wiki>`_
|
||||
- `Beginner Bugs <https://github.com/ClangBuiltLinux/linux/issues?q=is%3Aopen+is%3Aissue+label%3A%22good+first+issue%22>`_
|
||||
|
||||
Getting LLVM
|
||||
-------------
|
||||
|
||||
- http://releases.llvm.org/download.html
|
||||
- https://github.com/llvm/llvm-project
|
||||
- https://llvm.org/docs/GettingStarted.html
|
||||
- https://llvm.org/docs/CMake.html
|
||||
- https://apt.llvm.org/
|
||||
- https://www.archlinux.org/packages/extra/x86_64/llvm/
|
||||
- https://github.com/ClangBuiltLinux/tc-build
|
||||
- https://github.com/ClangBuiltLinux/linux/wiki/Building-Clang-from-source
|
||||
- https://android.googlesource.com/platform/prebuilts/clang/host/linux-x86/
|
||||
@@ -4139,6 +4139,7 @@ B: https://github.com/ClangBuiltLinux/linux/issues
|
||||
C: irc://chat.freenode.net/clangbuiltlinux
|
||||
S: Supported
|
||||
K: \b(?i:clang|llvm)\b
|
||||
F: Documentation/kbuild/llvm.rst
|
||||
|
||||
CLEANCACHE API
|
||||
M: Konrad Rzeszutek Wilk <konrad.wilk@oracle.com>
|
||||
|
||||
55
Makefile
55
Makefile
@@ -255,7 +255,8 @@ clean-targets := %clean mrproper cleandocs
|
||||
no-dot-config-targets := $(clean-targets) \
|
||||
cscope gtags TAGS tags help% %docs check% coccicheck \
|
||||
$(version_h) headers headers_% archheaders archscripts \
|
||||
%asm-generic kernelversion %src-pkg
|
||||
%asm-generic kernelversion %src-pkg dt_binding_check \
|
||||
outputmakefile
|
||||
no-sync-config-targets := $(no-dot-config-targets) install %install \
|
||||
kernelrelease
|
||||
single-targets := %.a %.i %.ko %.lds %.ll %.lst %.mod %.o %.s %.symtypes %/
|
||||
@@ -388,6 +389,9 @@ endif
|
||||
KCONFIG_CONFIG ?= .config
|
||||
export KCONFIG_CONFIG
|
||||
|
||||
# Default file for 'make defconfig'. This may be overridden by arch-Makefile.
|
||||
export KBUILD_DEFCONFIG := defconfig
|
||||
|
||||
# SHELL used by kbuild
|
||||
CONFIG_SHELL := sh
|
||||
|
||||
@@ -400,12 +404,11 @@ HOSTCXX = g++
|
||||
KBUILD_HOSTCFLAGS := -Wall -Wmissing-prototypes -Wstrict-prototypes -O2 \
|
||||
-fomit-frame-pointer -std=gnu89 $(HOST_LFS_CFLAGS) \
|
||||
$(HOSTCFLAGS)
|
||||
KBUILD_HOSTCXXFLAGS := -O2 $(HOST_LFS_CFLAGS) $(HOSTCXXFLAGS)
|
||||
KBUILD_HOSTCXXFLAGS := -Wall -O2 $(HOST_LFS_CFLAGS) $(HOSTCXXFLAGS)
|
||||
KBUILD_HOSTLDFLAGS := $(HOST_LFS_LDFLAGS) $(HOSTLDFLAGS)
|
||||
KBUILD_HOSTLDLIBS := $(HOST_LFS_LIBS) $(HOSTLDLIBS)
|
||||
|
||||
# Make variables (CC, etc...)
|
||||
AS = $(CROSS_COMPILE)as
|
||||
LD = $(CROSS_COMPILE)ld
|
||||
CC = $(CROSS_COMPILE)gcc
|
||||
CPP = $(CC) -E
|
||||
@@ -472,7 +475,7 @@ KBUILD_LDFLAGS :=
|
||||
GCC_PLUGINS_CFLAGS :=
|
||||
CLANG_FLAGS :=
|
||||
|
||||
export ARCH SRCARCH CONFIG_SHELL BASH HOSTCC KBUILD_HOSTCFLAGS CROSS_COMPILE AS LD CC
|
||||
export ARCH SRCARCH CONFIG_SHELL BASH HOSTCC KBUILD_HOSTCFLAGS CROSS_COMPILE LD CC
|
||||
export CPP AR NM STRIP OBJCOPY OBJDUMP OBJSIZE READELF PAHOLE LEX YACC AWK INSTALLKERNEL
|
||||
export PERL PYTHON PYTHON3 CHECK CHECKFLAGS MAKE UTS_MACHINE HOSTCXX
|
||||
export KBUILD_HOSTCXXFLAGS KBUILD_HOSTLDFLAGS KBUILD_HOSTLDLIBS LDFLAGS_MODULE
|
||||
@@ -535,7 +538,7 @@ endif
|
||||
ifneq ($(GCC_TOOLCHAIN),)
|
||||
CLANG_FLAGS += --gcc-toolchain=$(GCC_TOOLCHAIN)
|
||||
endif
|
||||
ifeq ($(shell $(AS) --version 2>&1 | head -n 1 | grep clang),)
|
||||
ifeq ($(if $(AS),$(shell $(AS) --version 2>&1 | head -n 1 | grep clang)),)
|
||||
CLANG_FLAGS += -no-integrated-as
|
||||
endif
|
||||
CLANG_FLAGS += -Werror=unknown-warning-option
|
||||
@@ -674,6 +677,7 @@ $(KCONFIG_CONFIG):
|
||||
#
|
||||
# This exploits the 'multi-target pattern rule' trick.
|
||||
# The syncconfig should be executed only once to make all the targets.
|
||||
# (Note: use the grouped target '&:' when we bump to GNU Make 4.3)
|
||||
%/auto.conf %/auto.conf.cmd: $(KCONFIG_CONFIG)
|
||||
$(Q)$(MAKE) -f $(srctree)/Makefile syncconfig
|
||||
else # !may-sync-config
|
||||
@@ -714,6 +718,7 @@ endif
|
||||
|
||||
# Tell gcc to never replace conditional load with a non-conditional one
|
||||
KBUILD_CFLAGS += $(call cc-option,--param=allow-store-data-races=0)
|
||||
KBUILD_CFLAGS += $(call cc-option,-fno-allow-store-data-races)
|
||||
|
||||
include scripts/Makefile.kcov
|
||||
include scripts/Makefile.gcc-plugins
|
||||
@@ -729,7 +734,7 @@ KBUILD_CFLAGS += $(call cc-option,-fno-reorder-blocks,) \
|
||||
endif
|
||||
|
||||
ifneq ($(CONFIG_FRAME_WARN),0)
|
||||
KBUILD_CFLAGS += $(call cc-option,-Wframe-larger-than=${CONFIG_FRAME_WARN})
|
||||
KBUILD_CFLAGS += -Wframe-larger-than=$(CONFIG_FRAME_WARN)
|
||||
endif
|
||||
|
||||
stackp-flags-$(CONFIG_CC_HAS_STACKPROTECTOR_NONE) := -fno-stack-protector
|
||||
@@ -1063,9 +1068,12 @@ endif
|
||||
|
||||
autoksyms_h := $(if $(CONFIG_TRIM_UNUSED_KSYMS), include/generated/autoksyms.h)
|
||||
|
||||
quiet_cmd_autoksyms_h = GEN $@
|
||||
cmd_autoksyms_h = mkdir -p $(dir $@); \
|
||||
$(CONFIG_SHELL) $(srctree)/scripts/gen_autoksyms.sh $@
|
||||
|
||||
$(autoksyms_h):
|
||||
$(Q)mkdir -p $(dir $@)
|
||||
$(Q)touch $@
|
||||
$(call cmd,autoksyms_h)
|
||||
|
||||
ARCH_POSTLINK := $(wildcard $(srctree)/arch/$(SRCARCH)/Makefile.postlink)
|
||||
|
||||
@@ -1240,14 +1248,18 @@ ifneq ($(dtstree),)
|
||||
$(Q)$(MAKE) $(build)=$(dtstree) $(dtstree)/$@
|
||||
|
||||
PHONY += dtbs dtbs_install dtbs_check
|
||||
dtbs dtbs_check: include/config/kernel.release scripts_dtc
|
||||
dtbs: include/config/kernel.release scripts_dtc
|
||||
$(Q)$(MAKE) $(build)=$(dtstree)
|
||||
|
||||
dtbs_check: export CHECK_DTBS=1
|
||||
dtbs_check: dt_binding_check
|
||||
ifneq ($(filter dtbs_check, $(MAKECMDGOALS)),)
|
||||
export CHECK_DTBS=y
|
||||
dtbs: dt_binding_check
|
||||
endif
|
||||
|
||||
dtbs_check: dtbs
|
||||
|
||||
dtbs_install:
|
||||
$(Q)$(MAKE) $(dtbinst)=$(dtstree)
|
||||
$(Q)$(MAKE) $(dtbinst)=$(dtstree) dst=$(INSTALL_DTBS_PATH)
|
||||
|
||||
ifdef CONFIG_OF_EARLY_FLATTREE
|
||||
all: dtbs
|
||||
@@ -1259,6 +1271,10 @@ PHONY += scripts_dtc
|
||||
scripts_dtc: scripts_basic
|
||||
$(Q)$(MAKE) $(build)=scripts/dtc
|
||||
|
||||
ifneq ($(filter dt_binding_check, $(MAKECMDGOALS)),)
|
||||
export CHECK_DT_BINDING=y
|
||||
endif
|
||||
|
||||
PHONY += dt_binding_check
|
||||
dt_binding_check: scripts_dtc
|
||||
$(Q)$(MAKE) $(build)=Documentation/devicetree/bindings
|
||||
@@ -1470,12 +1486,15 @@ help:
|
||||
@echo ' nsdeps - Generate missing symbol namespace dependencies'
|
||||
@echo ''
|
||||
@echo 'Kernel selftest:'
|
||||
@echo ' kselftest - Build and run kernel selftest (run as root)'
|
||||
@echo ' Build, install, and boot kernel before'
|
||||
@echo ' running kselftest on it'
|
||||
@echo ' kselftest-clean - Remove all generated kselftest files'
|
||||
@echo ' kselftest-merge - Merge all the config dependencies of kselftest to existing'
|
||||
@echo ' .config.'
|
||||
@echo ' kselftest - Build and run kernel selftest'
|
||||
@echo ' Build, install, and boot kernel before'
|
||||
@echo ' running kselftest on it'
|
||||
@echo ' Run as root for full coverage'
|
||||
@echo ' kselftest-all - Build kernel selftest'
|
||||
@echo ' kselftest-install - Build and install kernel selftest'
|
||||
@echo ' kselftest-clean - Remove all generated kselftest files'
|
||||
@echo ' kselftest-merge - Merge all the config dependencies of'
|
||||
@echo ' kselftest to existing .config.'
|
||||
@echo ''
|
||||
@$(if $(dtstree), \
|
||||
echo 'Devicetree:'; \
|
||||
|
||||
@@ -87,11 +87,6 @@ config SUPERH64
|
||||
select HAVE_EXIT_THREAD
|
||||
select KALLSYMS
|
||||
|
||||
config ARCH_DEFCONFIG
|
||||
string
|
||||
default "arch/sh/configs/shx3_defconfig" if SUPERH32
|
||||
default "arch/sh/configs/cayman_defconfig" if SUPERH64
|
||||
|
||||
config GENERIC_BUG
|
||||
def_bool y
|
||||
depends on BUG && SUPERH32
|
||||
|
||||
@@ -96,11 +96,6 @@ config SPARC64
|
||||
select PCI_DOMAINS if PCI
|
||||
select ARCH_HAS_GIGANTIC_PAGE
|
||||
|
||||
config ARCH_DEFCONFIG
|
||||
string
|
||||
default "arch/sparc/configs/sparc32_defconfig" if SPARC32
|
||||
default "arch/sparc/configs/sparc64_defconfig" if SPARC64
|
||||
|
||||
config ARCH_PROC_KCORE_TEXT
|
||||
def_bool y
|
||||
|
||||
|
||||
@@ -37,6 +37,10 @@ void *memmove(void *, const void *, __kernel_size_t);
|
||||
#define __HAVE_ARCH_MEMCMP
|
||||
int memcmp(const void *,const void *,__kernel_size_t);
|
||||
|
||||
/* Now the str*() stuff... */
|
||||
#define __HAVE_ARCH_STRLEN
|
||||
__kernel_size_t strlen(const char *);
|
||||
|
||||
#define __HAVE_ARCH_STRNCMP
|
||||
int strncmp(const char *, const char *, __kernel_size_t);
|
||||
|
||||
|
||||
@@ -12,8 +12,4 @@
|
||||
|
||||
#include <asm/asi.h>
|
||||
|
||||
/* Now the str*() stuff... */
|
||||
#define __HAVE_ARCH_STRLEN
|
||||
__kernel_size_t strlen(const char *);
|
||||
|
||||
#endif /* !(__SPARC64_STRING_H__) */
|
||||
|
||||
@@ -240,11 +240,6 @@ config OUTPUT_FORMAT
|
||||
default "elf32-i386" if X86_32
|
||||
default "elf64-x86-64" if X86_64
|
||||
|
||||
config ARCH_DEFCONFIG
|
||||
string
|
||||
default "arch/x86/configs/i386_defconfig" if X86_32
|
||||
default "arch/x86/configs/x86_64_defconfig" if X86_64
|
||||
|
||||
config LOCKDEP_SUPPORT
|
||||
def_bool y
|
||||
|
||||
|
||||
@@ -27,11 +27,6 @@ config X86_64
|
||||
def_bool 64BIT
|
||||
select MODULES_USE_ELF_RELA
|
||||
|
||||
config ARCH_DEFCONFIG
|
||||
string
|
||||
default "arch/um/configs/i386_defconfig" if X86_32
|
||||
default "arch/um/configs/x86_64_defconfig" if X86_64
|
||||
|
||||
config 3_LEVEL_PGTABLES
|
||||
bool "Three-level pagetables" if !64BIT
|
||||
default 64BIT
|
||||
|
||||
@@ -200,7 +200,7 @@ config WANXL_BUILD_FIRMWARE
|
||||
depends on WANXL && !PREVENT_FIRMWARE_BUILD
|
||||
help
|
||||
Allows you to rebuild firmware run by the QUICC processor.
|
||||
It requires as68k, ld68k and hexdump programs.
|
||||
It requires m68k toolchains and hexdump programs.
|
||||
|
||||
You should never need this option, say N.
|
||||
|
||||
|
||||
@@ -40,21 +40,30 @@ $(obj)/wanxl.o: $(obj)/wanxlfw.inc
|
||||
|
||||
ifeq ($(CONFIG_WANXL_BUILD_FIRMWARE),y)
|
||||
ifeq ($(ARCH),m68k)
|
||||
AS68K = $(AS)
|
||||
LD68K = $(LD)
|
||||
M68KCC = $(CC)
|
||||
M68KLD = $(LD)
|
||||
else
|
||||
AS68K = as68k
|
||||
LD68K = ld68k
|
||||
M68KCC = $(CROSS_COMPILE_M68K)gcc
|
||||
M68KLD = $(CROSS_COMPILE_M68K)ld
|
||||
endif
|
||||
|
||||
quiet_cmd_build_wanxlfw = BLD FW $@
|
||||
cmd_build_wanxlfw = \
|
||||
$(CPP) -D__ASSEMBLY__ -Wp,-MD,$(depfile) -I$(srctree)/include/uapi $< | $(AS68K) -m68360 -o $(obj)/wanxlfw.o; \
|
||||
$(LD68K) --oformat binary -Ttext 0x1000 $(obj)/wanxlfw.o -o $(obj)/wanxlfw.bin; \
|
||||
hexdump -ve '"\n" 16/1 "0x%02X,"' $(obj)/wanxlfw.bin | sed 's/0x ,//g;1s/^/static const u8 firmware[]={/;$$s/,$$/\n};\n/' >$(obj)/wanxlfw.inc; \
|
||||
rm -f $(obj)/wanxlfw.bin $(obj)/wanxlfw.o
|
||||
quiet_cmd_build_wanxlfw = BLDFW $@
|
||||
cmd_build_wanxlfw = hexdump -ve '"\n" 16/1 "0x%02X,"' $< | \
|
||||
sed 's/0x ,//g;1s/^/static const u8 firmware[]={/;$$s/,$$/\n};\n/' > $@
|
||||
|
||||
$(obj)/wanxlfw.inc: $(src)/wanxlfw.S
|
||||
$(call if_changed_dep,build_wanxlfw)
|
||||
targets += wanxlfw.inc
|
||||
$(obj)/wanxlfw.inc: $(obj)/wanxlfw.bin FORCE
|
||||
$(call if_changed,build_wanxlfw)
|
||||
|
||||
quiet_cmd_m68kld_bin_o = M68KLD $@
|
||||
cmd_m68kld_bin_o = $(M68KLD) --oformat binary -Ttext 0x1000 $< -o $@
|
||||
|
||||
$(obj)/wanxlfw.bin: $(obj)/wanxlfw.o FORCE
|
||||
$(call if_changed,m68kld_bin_o)
|
||||
|
||||
quiet_cmd_m68kas_o_S = M68KAS $@
|
||||
cmd_m68kas_o_S = $(M68KCC) -D__ASSEMBLY__ -Wp,-MD,$(depfile) -I$(srctree)/include/uapi -c -o $@ $<
|
||||
|
||||
$(obj)/wanxlfw.o: $(src)/wanxlfw.S FORCE
|
||||
$(call if_changed_dep,m68kas_o_S)
|
||||
endif
|
||||
targets += wanxlfw.inc wanxlfw.bin wanxlfw.o
|
||||
|
||||
@@ -19,7 +19,7 @@ struct net_dm_hw_metadata {
|
||||
struct net_device *input_dev;
|
||||
};
|
||||
|
||||
#if IS_ENABLED(CONFIG_NET_DROP_MONITOR)
|
||||
#if IS_REACHABLE(CONFIG_NET_DROP_MONITOR)
|
||||
void net_dm_hw_report(struct sk_buff *skb,
|
||||
const struct net_dm_hw_metadata *hw_metadata);
|
||||
#else
|
||||
|
||||
16
init/Kconfig
16
init/Kconfig
@@ -6,8 +6,7 @@ config DEFCONFIG_LIST
|
||||
default "/lib/modules/$(shell,uname -r)/.config"
|
||||
default "/etc/kernel-config"
|
||||
default "/boot/config-$(shell,uname -r)"
|
||||
default ARCH_DEFCONFIG
|
||||
default "arch/$(ARCH)/defconfig"
|
||||
default "arch/$(SRCARCH)/configs/$(KBUILD_DEFCONFIG)"
|
||||
|
||||
config CC_IS_GCC
|
||||
def_bool $(success,$(CC) --version | head -n 1 | grep -q gcc)
|
||||
@@ -2211,6 +2210,19 @@ config TRIM_UNUSED_KSYMS
|
||||
|
||||
If unsure, or if you need to build out-of-tree modules, say N.
|
||||
|
||||
config UNUSED_KSYMS_WHITELIST
|
||||
string "Whitelist of symbols to keep in ksymtab"
|
||||
depends on TRIM_UNUSED_KSYMS
|
||||
help
|
||||
By default, all unused exported symbols will be un-exported from the
|
||||
build when TRIM_UNUSED_KSYMS is selected.
|
||||
|
||||
UNUSED_KSYMS_WHITELIST allows to whitelist symbols that must be kept
|
||||
exported at all times, even in absence of in-tree users. The value to
|
||||
set here is the path to a text file containing the list of symbols,
|
||||
one per line. The path can be absolute, or relative to the kernel
|
||||
source tree.
|
||||
|
||||
endif # MODULES
|
||||
|
||||
config MODULES_TREE_LOOKUP
|
||||
|
||||
@@ -266,7 +266,7 @@ config ENABLE_MUST_CHECK
|
||||
attribute warn_unused_result" messages.
|
||||
|
||||
config FRAME_WARN
|
||||
int "Warn for stack frames larger than (needs gcc 4.4)"
|
||||
int "Warn for stack frames larger than"
|
||||
range 0 8192
|
||||
default 2048 if GCC_PLUGIN_LATENT_ENTROPY
|
||||
default 1280 if (!64BIT && PARISC)
|
||||
@@ -276,7 +276,6 @@ config FRAME_WARN
|
||||
Tell gcc to warn at build time for stack frames larger than this.
|
||||
Setting this too low will cause a lot of warnings.
|
||||
Setting it to 0 disables the warning.
|
||||
Requires gcc 4.4
|
||||
|
||||
config STRIP_ASM_SYMS
|
||||
bool "Strip assembler-generated symbols during link"
|
||||
|
||||
Some files were not shown because too many files have changed in this diff Show More
Reference in New Issue
Block a user