You've already forked linux-apfs
mirror of
https://github.com/linux-apfs/linux-apfs.git
synced 2026-05-01 15:00:59 -07:00
Merge tag 'kbuild-uapi-v4.12' of git://git.kernel.org/pub/scm/linux/kernel/git/masahiroy/linux-kbuild
Pull Kbuild UAPI updates from Masahiro Yamada: "Improvement of headers_install by Nicolas Dichtel. It has been long since the introduction of uapi directories, but the de-coupling of exported headers has not been completed. Headers listed in header-y are exported whether they exist in uapi directories or not. His work fixes this inconsistency. All (and only) headers under uapi directories are now exported. The asm-generic wrappers are still exceptions, but this is a big step forward" * tag 'kbuild-uapi-v4.12' of git://git.kernel.org/pub/scm/linux/kernel/git/masahiroy/linux-kbuild: arch/include: remove empty Kbuild files uapi: export all arch specifics directories uapi: export all headers under uapi directories smc_diag.h: fix include from userland btrfs_tree.h: fix include from userland uapi: includes linux/types.h before exporting files Makefile.headersinst: remove destination-y option Makefile.headersinst: cleanup input files x86: stop exporting msr-index.h to userland nios2: put setup.h in uapi h8300: put bitsperlong.h in uapi
This commit is contained in:
@@ -44,11 +44,11 @@ This document describes the Linux kernel Makefiles.
|
||||
--- 6.11 Post-link pass
|
||||
|
||||
=== 7 Kbuild syntax for exported headers
|
||||
--- 7.1 header-y
|
||||
--- 7.1 no-export-headers
|
||||
--- 7.2 genhdr-y
|
||||
--- 7.3 destination-y
|
||||
--- 7.4 generic-y
|
||||
--- 7.5 generated-y
|
||||
--- 7.3 generic-y
|
||||
--- 7.4 generated-y
|
||||
--- 7.5 mandatory-y
|
||||
|
||||
=== 8 Kbuild Variables
|
||||
=== 9 Makefile language
|
||||
@@ -1236,7 +1236,7 @@ When kbuild executes, the following steps are followed (roughly):
|
||||
that may be shared between individual architectures.
|
||||
The recommended approach how to use a generic header file is
|
||||
to list the file in the Kbuild file.
|
||||
See "7.4 generic-y" for further info on syntax etc.
|
||||
See "7.3 generic-y" for further info on syntax etc.
|
||||
|
||||
--- 6.11 Post-link pass
|
||||
|
||||
@@ -1263,53 +1263,32 @@ The pre-processing does:
|
||||
- drop include of compiler.h
|
||||
- drop all sections that are kernel internal (guarded by ifdef __KERNEL__)
|
||||
|
||||
Each relevant directory contains a file name "Kbuild" which specifies the
|
||||
headers to be exported.
|
||||
All headers under include/uapi/, include/generated/uapi/,
|
||||
arch/<arch>/include/uapi/ and arch/<arch>/include/generated/uapi/
|
||||
are exported.
|
||||
|
||||
A Kbuild file may be defined under arch/<arch>/include/uapi/asm/ and
|
||||
arch/<arch>/include/asm/ to list asm files coming from asm-generic.
|
||||
See subsequent chapter for the syntax of the Kbuild file.
|
||||
|
||||
--- 7.1 header-y
|
||||
--- 7.1 no-export-headers
|
||||
|
||||
header-y specifies header files to be exported.
|
||||
|
||||
Example:
|
||||
#include/linux/Kbuild
|
||||
header-y += usb/
|
||||
header-y += aio_abi.h
|
||||
|
||||
The convention is to list one file per line and
|
||||
preferably in alphabetic order.
|
||||
|
||||
header-y also specifies which subdirectories to visit.
|
||||
A subdirectory is identified by a trailing '/' which
|
||||
can be seen in the example above for the usb subdirectory.
|
||||
|
||||
Subdirectories are visited before their parent directories.
|
||||
no-export-headers is essentially used by include/uapi/linux/Kbuild to
|
||||
avoid exporting specific headers (e.g. kvm.h) on architectures that do
|
||||
not support it. It should be avoided as much as possible.
|
||||
|
||||
--- 7.2 genhdr-y
|
||||
|
||||
genhdr-y specifies generated files to be exported.
|
||||
Generated files are special as they need to be looked
|
||||
up in another directory when doing 'make O=...' builds.
|
||||
genhdr-y specifies asm files to be generated.
|
||||
|
||||
Example:
|
||||
#include/linux/Kbuild
|
||||
genhdr-y += version.h
|
||||
#arch/x86/include/uapi/asm/Kbuild
|
||||
genhdr-y += unistd_32.h
|
||||
genhdr-y += unistd_64.h
|
||||
genhdr-y += unistd_x32.h
|
||||
|
||||
--- 7.3 destination-y
|
||||
|
||||
When an architecture has a set of exported headers that needs to be
|
||||
exported to a different directory destination-y is used.
|
||||
destination-y specifies the destination directory for all exported
|
||||
headers in the file where it is present.
|
||||
|
||||
Example:
|
||||
#arch/xtensa/platforms/s6105/include/platform/Kbuild
|
||||
destination-y := include/linux
|
||||
|
||||
In the example above all exported headers in the Kbuild file
|
||||
will be located in the directory "include/linux" when exported.
|
||||
|
||||
--- 7.4 generic-y
|
||||
--- 7.3 generic-y
|
||||
|
||||
If an architecture uses a verbatim copy of a header from
|
||||
include/asm-generic then this is listed in the file
|
||||
@@ -1336,7 +1315,7 @@ See subsequent chapter for the syntax of the Kbuild file.
|
||||
Example: termios.h
|
||||
#include <asm-generic/termios.h>
|
||||
|
||||
--- 7.5 generated-y
|
||||
--- 7.4 generated-y
|
||||
|
||||
If an architecture generates other header files alongside generic-y
|
||||
wrappers, and not included in genhdr-y, then generated-y specifies
|
||||
@@ -1349,6 +1328,15 @@ See subsequent chapter for the syntax of the Kbuild file.
|
||||
#arch/x86/include/asm/Kbuild
|
||||
generated-y += syscalls_32.h
|
||||
|
||||
--- 7.5 mandatory-y
|
||||
|
||||
mandatory-y is essentially used by include/uapi/asm-generic/Kbuild.asm
|
||||
to define the minimun set of headers that must be exported in
|
||||
include/asm.
|
||||
|
||||
The convention is to list one subdir per line and
|
||||
preferably in alphabetic order.
|
||||
|
||||
=== 8 Kbuild Variables
|
||||
|
||||
The top Makefile exports the following variables:
|
||||
|
||||
@@ -1142,7 +1142,7 @@ firmware_install:
|
||||
export INSTALL_HDR_PATH = $(objtree)/usr
|
||||
|
||||
# If we do an all arch process set dst to asm-$(hdr-arch)
|
||||
hdr-dst = $(if $(KBUILD_HEADERS), dst=include/asm-$(hdr-arch), dst=include/asm)
|
||||
hdr-dst = $(if $(KBUILD_HEADERS), dst=include/arch-$(hdr-arch), dst=include)
|
||||
|
||||
PHONY += archheaders
|
||||
archheaders:
|
||||
@@ -1163,7 +1163,7 @@ headers_install: __headers
|
||||
$(if $(wildcard $(srctree)/arch/$(hdr-arch)/include/uapi/asm/Kbuild),, \
|
||||
$(error Headers not exportable for the $(SRCARCH) architecture))
|
||||
$(Q)$(MAKE) $(hdr-inst)=include/uapi
|
||||
$(Q)$(MAKE) $(hdr-inst)=arch/$(hdr-arch)/include/uapi/asm $(hdr-dst)
|
||||
$(Q)$(MAKE) $(hdr-inst)=arch/$(hdr-arch)/include/uapi $(hdr-dst)
|
||||
|
||||
PHONY += headers_check_all
|
||||
headers_check_all: headers_install_all
|
||||
@@ -1172,7 +1172,7 @@ headers_check_all: headers_install_all
|
||||
PHONY += headers_check
|
||||
headers_check: headers_install
|
||||
$(Q)$(MAKE) $(hdr-inst)=include/uapi HDRCHECK=1
|
||||
$(Q)$(MAKE) $(hdr-inst)=arch/$(hdr-arch)/include/uapi/asm $(hdr-dst) HDRCHECK=1
|
||||
$(Q)$(MAKE) $(hdr-inst)=arch/$(hdr-arch)/include/uapi/ $(hdr-dst) HDRCHECK=1
|
||||
|
||||
# ---------------------------------------------------------------------------
|
||||
# Kernel selftest
|
||||
|
||||
@@ -1,43 +1,2 @@
|
||||
# UAPI Header export list
|
||||
include include/uapi/asm-generic/Kbuild.asm
|
||||
|
||||
header-y += a.out.h
|
||||
header-y += auxvec.h
|
||||
header-y += bitsperlong.h
|
||||
header-y += byteorder.h
|
||||
header-y += compiler.h
|
||||
header-y += console.h
|
||||
header-y += errno.h
|
||||
header-y += fcntl.h
|
||||
header-y += fpu.h
|
||||
header-y += gentrap.h
|
||||
header-y += ioctl.h
|
||||
header-y += ioctls.h
|
||||
header-y += ipcbuf.h
|
||||
header-y += kvm_para.h
|
||||
header-y += mman.h
|
||||
header-y += msgbuf.h
|
||||
header-y += pal.h
|
||||
header-y += param.h
|
||||
header-y += poll.h
|
||||
header-y += posix_types.h
|
||||
header-y += ptrace.h
|
||||
header-y += reg.h
|
||||
header-y += regdef.h
|
||||
header-y += resource.h
|
||||
header-y += sembuf.h
|
||||
header-y += setup.h
|
||||
header-y += shmbuf.h
|
||||
header-y += sigcontext.h
|
||||
header-y += siginfo.h
|
||||
header-y += signal.h
|
||||
header-y += socket.h
|
||||
header-y += sockios.h
|
||||
header-y += stat.h
|
||||
header-y += statfs.h
|
||||
header-y += swab.h
|
||||
header-y += sysinfo.h
|
||||
header-y += termbits.h
|
||||
header-y += termios.h
|
||||
header-y += types.h
|
||||
header-y += unistd.h
|
||||
|
||||
@@ -1,5 +1,2 @@
|
||||
# UAPI Header export list
|
||||
include include/uapi/asm-generic/Kbuild.asm
|
||||
header-y += elf.h
|
||||
header-y += page.h
|
||||
header-y += cachectl.h
|
||||
|
||||
@@ -1,23 +1,6 @@
|
||||
# UAPI Header export list
|
||||
include include/uapi/asm-generic/Kbuild.asm
|
||||
|
||||
header-y += auxvec.h
|
||||
header-y += byteorder.h
|
||||
header-y += fcntl.h
|
||||
header-y += hwcap.h
|
||||
header-y += ioctls.h
|
||||
header-y += kvm_para.h
|
||||
header-y += mman.h
|
||||
header-y += perf_regs.h
|
||||
header-y += posix_types.h
|
||||
header-y += ptrace.h
|
||||
header-y += setup.h
|
||||
header-y += sigcontext.h
|
||||
header-y += signal.h
|
||||
header-y += stat.h
|
||||
header-y += statfs.h
|
||||
header-y += swab.h
|
||||
header-y += unistd.h
|
||||
genhdr-y += unistd-common.h
|
||||
genhdr-y += unistd-oabi.h
|
||||
genhdr-y += unistd-eabi.h
|
||||
|
||||
@@ -2,21 +2,3 @@
|
||||
include include/uapi/asm-generic/Kbuild.asm
|
||||
|
||||
generic-y += kvm_para.h
|
||||
|
||||
header-y += auxvec.h
|
||||
header-y += bitsperlong.h
|
||||
header-y += byteorder.h
|
||||
header-y += fcntl.h
|
||||
header-y += hwcap.h
|
||||
header-y += kvm_para.h
|
||||
header-y += perf_regs.h
|
||||
header-y += param.h
|
||||
header-y += ptrace.h
|
||||
header-y += setup.h
|
||||
header-y += sigcontext.h
|
||||
header-y += siginfo.h
|
||||
header-y += signal.h
|
||||
header-y += stat.h
|
||||
header-y += statfs.h
|
||||
header-y += ucontext.h
|
||||
header-y += unistd.h
|
||||
|
||||
@@ -1,19 +1,2 @@
|
||||
# UAPI Header export list
|
||||
include include/uapi/asm-generic/Kbuild.asm
|
||||
|
||||
header-y += bfin_sport.h
|
||||
header-y += byteorder.h
|
||||
header-y += cachectl.h
|
||||
header-y += fcntl.h
|
||||
header-y += fixed_code.h
|
||||
header-y += ioctls.h
|
||||
header-y += kvm_para.h
|
||||
header-y += poll.h
|
||||
header-y += posix_types.h
|
||||
header-y += ptrace.h
|
||||
header-y += sigcontext.h
|
||||
header-y += siginfo.h
|
||||
header-y += signal.h
|
||||
header-y += stat.h
|
||||
header-y += swab.h
|
||||
header-y += unistd.h
|
||||
|
||||
@@ -2,11 +2,3 @@
|
||||
include include/uapi/asm-generic/Kbuild.asm
|
||||
|
||||
generic-y += kvm_para.h
|
||||
|
||||
header-y += byteorder.h
|
||||
header-y += kvm_para.h
|
||||
header-y += ptrace.h
|
||||
header-y += setup.h
|
||||
header-y += sigcontext.h
|
||||
header-y += swab.h
|
||||
header-y += unistd.h
|
||||
|
||||
@@ -1 +0,0 @@
|
||||
# CRISv10 arch
|
||||
@@ -1 +0,0 @@
|
||||
# CRISv32 arch
|
||||
@@ -1,5 +0,0 @@
|
||||
# UAPI Header export list
|
||||
header-y += sv_addr.agh
|
||||
header-y += sv_addr_ag.h
|
||||
header-y += svinto.h
|
||||
header-y += user.h
|
||||
@@ -1,3 +0,0 @@
|
||||
# UAPI Header export list
|
||||
header-y += cryptocop.h
|
||||
header-y += user.h
|
||||
@@ -1,44 +1,2 @@
|
||||
# UAPI Header export list
|
||||
include include/uapi/asm-generic/Kbuild.asm
|
||||
|
||||
header-y += ../arch-v10/arch/
|
||||
header-y += ../arch-v32/arch/
|
||||
header-y += auxvec.h
|
||||
header-y += bitsperlong.h
|
||||
header-y += byteorder.h
|
||||
header-y += elf.h
|
||||
header-y += elf_v10.h
|
||||
header-y += elf_v32.h
|
||||
header-y += errno.h
|
||||
header-y += ethernet.h
|
||||
header-y += etraxgpio.h
|
||||
header-y += fcntl.h
|
||||
header-y += ioctl.h
|
||||
header-y += ioctls.h
|
||||
header-y += ipcbuf.h
|
||||
header-y += mman.h
|
||||
header-y += msgbuf.h
|
||||
header-y += param.h
|
||||
header-y += poll.h
|
||||
header-y += posix_types.h
|
||||
header-y += ptrace.h
|
||||
header-y += ptrace_v10.h
|
||||
header-y += ptrace_v32.h
|
||||
header-y += resource.h
|
||||
header-y += rs485.h
|
||||
header-y += sembuf.h
|
||||
header-y += setup.h
|
||||
header-y += shmbuf.h
|
||||
header-y += sigcontext.h
|
||||
header-y += siginfo.h
|
||||
header-y += signal.h
|
||||
header-y += socket.h
|
||||
header-y += sockios.h
|
||||
header-y += stat.h
|
||||
header-y += statfs.h
|
||||
header-y += swab.h
|
||||
header-y += sync_serial.h
|
||||
header-y += termbits.h
|
||||
header-y += termios.h
|
||||
header-y += types.h
|
||||
header-y += unistd.h
|
||||
|
||||
@@ -1,35 +1,2 @@
|
||||
# UAPI Header export list
|
||||
include include/uapi/asm-generic/Kbuild.asm
|
||||
|
||||
header-y += auxvec.h
|
||||
header-y += bitsperlong.h
|
||||
header-y += byteorder.h
|
||||
header-y += errno.h
|
||||
header-y += fcntl.h
|
||||
header-y += ioctl.h
|
||||
header-y += ioctls.h
|
||||
header-y += ipcbuf.h
|
||||
header-y += kvm_para.h
|
||||
header-y += mman.h
|
||||
header-y += msgbuf.h
|
||||
header-y += param.h
|
||||
header-y += poll.h
|
||||
header-y += posix_types.h
|
||||
header-y += ptrace.h
|
||||
header-y += registers.h
|
||||
header-y += resource.h
|
||||
header-y += sembuf.h
|
||||
header-y += setup.h
|
||||
header-y += shmbuf.h
|
||||
header-y += sigcontext.h
|
||||
header-y += siginfo.h
|
||||
header-y += signal.h
|
||||
header-y += socket.h
|
||||
header-y += sockios.h
|
||||
header-y += stat.h
|
||||
header-y += statfs.h
|
||||
header-y += swab.h
|
||||
header-y += termbits.h
|
||||
header-y += termios.h
|
||||
header-y += types.h
|
||||
header-y += unistd.h
|
||||
|
||||
@@ -1,30 +1,2 @@
|
||||
# UAPI Header export list
|
||||
include include/uapi/asm-generic/Kbuild.asm
|
||||
|
||||
header-y += auxvec.h
|
||||
header-y += bitsperlong.h
|
||||
header-y += errno.h
|
||||
header-y += fcntl.h
|
||||
header-y += ioctl.h
|
||||
header-y += ioctls.h
|
||||
header-y += ipcbuf.h
|
||||
header-y += kvm_para.h
|
||||
header-y += mman.h
|
||||
header-y += msgbuf.h
|
||||
header-y += param.h
|
||||
header-y += poll.h
|
||||
header-y += posix_types.h
|
||||
header-y += resource.h
|
||||
header-y += sembuf.h
|
||||
header-y += setup.h
|
||||
header-y += shmbuf.h
|
||||
header-y += siginfo.h
|
||||
header-y += socket.h
|
||||
header-y += sockios.h
|
||||
header-y += stat.h
|
||||
header-y += statfs.h
|
||||
header-y += swab.h
|
||||
header-y += termbits.h
|
||||
header-y += termios.h
|
||||
header-y += types.h
|
||||
header-y += unistd.h
|
||||
|
||||
@@ -1,5 +1,5 @@
|
||||
#ifndef __ASM_H8300_BITS_PER_LONG
|
||||
#define __ASM_H8300_BITS_PER_LONG
|
||||
#ifndef _UAPI__ASM_H8300_BITS_PER_LONG
|
||||
#define _UAPI__ASM_H8300_BITS_PER_LONG
|
||||
|
||||
#include <asm-generic/bitsperlong.h>
|
||||
|
||||
@@ -11,4 +11,4 @@ typedef long __kernel_ssize_t;
|
||||
typedef long __kernel_ptrdiff_t;
|
||||
#endif
|
||||
|
||||
#endif /* __ASM_H8300_BITS_PER_LONG */
|
||||
#endif /* _UAPI__ASM_H8300_BITS_PER_LONG */
|
||||
@@ -1,6 +1,3 @@
|
||||
|
||||
header-y += ucontext.h
|
||||
|
||||
generic-y += auxvec.h
|
||||
generic-y += barrier.h
|
||||
generic-y += bug.h
|
||||
|
||||
@@ -1,15 +1,2 @@
|
||||
# UAPI Header export list
|
||||
include include/uapi/asm-generic/Kbuild.asm
|
||||
|
||||
header-y += bitsperlong.h
|
||||
header-y += byteorder.h
|
||||
header-y += kvm_para.h
|
||||
header-y += param.h
|
||||
header-y += ptrace.h
|
||||
header-y += registers.h
|
||||
header-y += setup.h
|
||||
header-y += sigcontext.h
|
||||
header-y += signal.h
|
||||
header-y += swab.h
|
||||
header-y += unistd.h
|
||||
header-y += user.h
|
||||
|
||||
@@ -2,48 +2,3 @@
|
||||
include include/uapi/asm-generic/Kbuild.asm
|
||||
|
||||
generic-y += kvm_para.h
|
||||
|
||||
header-y += auxvec.h
|
||||
header-y += bitsperlong.h
|
||||
header-y += break.h
|
||||
header-y += byteorder.h
|
||||
header-y += cmpxchg.h
|
||||
header-y += errno.h
|
||||
header-y += fcntl.h
|
||||
header-y += fpu.h
|
||||
header-y += gcc_intrin.h
|
||||
header-y += ia64regs.h
|
||||
header-y += intel_intrin.h
|
||||
header-y += intrinsics.h
|
||||
header-y += ioctl.h
|
||||
header-y += ioctls.h
|
||||
header-y += ipcbuf.h
|
||||
header-y += kvm_para.h
|
||||
header-y += mman.h
|
||||
header-y += msgbuf.h
|
||||
header-y += param.h
|
||||
header-y += perfmon.h
|
||||
header-y += perfmon_default_smpl.h
|
||||
header-y += poll.h
|
||||
header-y += posix_types.h
|
||||
header-y += ptrace.h
|
||||
header-y += ptrace_offsets.h
|
||||
header-y += resource.h
|
||||
header-y += rse.h
|
||||
header-y += sembuf.h
|
||||
header-y += setup.h
|
||||
header-y += shmbuf.h
|
||||
header-y += sigcontext.h
|
||||
header-y += siginfo.h
|
||||
header-y += signal.h
|
||||
header-y += socket.h
|
||||
header-y += sockios.h
|
||||
header-y += stat.h
|
||||
header-y += statfs.h
|
||||
header-y += swab.h
|
||||
header-y += termbits.h
|
||||
header-y += termios.h
|
||||
header-y += types.h
|
||||
header-y += ucontext.h
|
||||
header-y += unistd.h
|
||||
header-y += ustack.h
|
||||
|
||||
@@ -1,33 +1,2 @@
|
||||
# UAPI Header export list
|
||||
include include/uapi/asm-generic/Kbuild.asm
|
||||
|
||||
header-y += auxvec.h
|
||||
header-y += bitsperlong.h
|
||||
header-y += byteorder.h
|
||||
header-y += errno.h
|
||||
header-y += fcntl.h
|
||||
header-y += ioctl.h
|
||||
header-y += ioctls.h
|
||||
header-y += ipcbuf.h
|
||||
header-y += mman.h
|
||||
header-y += msgbuf.h
|
||||
header-y += param.h
|
||||
header-y += poll.h
|
||||
header-y += posix_types.h
|
||||
header-y += ptrace.h
|
||||
header-y += resource.h
|
||||
header-y += sembuf.h
|
||||
header-y += setup.h
|
||||
header-y += shmbuf.h
|
||||
header-y += sigcontext.h
|
||||
header-y += siginfo.h
|
||||
header-y += signal.h
|
||||
header-y += socket.h
|
||||
header-y += sockios.h
|
||||
header-y += stat.h
|
||||
header-y += statfs.h
|
||||
header-y += swab.h
|
||||
header-y += termbits.h
|
||||
header-y += termios.h
|
||||
header-y += types.h
|
||||
header-y += unistd.h
|
||||
|
||||
Some files were not shown because too many files have changed in this diff Show More
Reference in New Issue
Block a user