summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorNicolas Dichtel <nicolas.dichtel@6wind.com>2017-03-27 08:20:15 -0400
committerMasahiro Yamada <yamada.masahiro@socionext.com>2017-05-10 11:21:54 -0400
commitfcc8487d477a3452a1d0ccbdd4c5e0e1e3cb8bed (patch)
tree74079c37b73d6be983b3c5767babc880c103dadf
parentea6819e1f2d6c30624ea067f4b3a50a3cca79d8a (diff)
uapi: export all headers under uapi directories
Regularly, when a new header is created in include/uapi/, the developer forgets to add it in the corresponding Kbuild file. This error is usually detected after the release is out. In fact, all headers under uapi directories should be exported, thus it's useless to have an exhaustive list. After this patch, the following files, which were not exported, are now exported (with make headers_install_all): asm-arc/kvm_para.h asm-arc/ucontext.h asm-blackfin/shmparam.h asm-blackfin/ucontext.h asm-c6x/shmparam.h asm-c6x/ucontext.h asm-cris/kvm_para.h asm-h8300/shmparam.h asm-h8300/ucontext.h asm-hexagon/shmparam.h asm-m32r/kvm_para.h asm-m68k/kvm_para.h asm-m68k/shmparam.h asm-metag/kvm_para.h asm-metag/shmparam.h asm-metag/ucontext.h asm-mips/hwcap.h asm-mips/reg.h asm-mips/ucontext.h asm-nios2/kvm_para.h asm-nios2/ucontext.h asm-openrisc/shmparam.h asm-parisc/kvm_para.h asm-powerpc/perf_regs.h asm-sh/kvm_para.h asm-sh/ucontext.h asm-tile/shmparam.h asm-unicore32/shmparam.h asm-unicore32/ucontext.h asm-x86/hwcap2.h asm-xtensa/kvm_para.h drm/armada_drm.h drm/etnaviv_drm.h drm/vgem_drm.h linux/aspeed-lpc-ctrl.h linux/auto_dev-ioctl.h linux/bcache.h linux/btrfs_tree.h linux/can/vxcan.h linux/cifs/cifs_mount.h linux/coresight-stm.h linux/cryptouser.h linux/fsmap.h linux/genwqe/genwqe_card.h linux/hash_info.h linux/kcm.h linux/kcov.h linux/kfd_ioctl.h linux/lightnvm.h linux/module.h linux/nbd-netlink.h linux/nilfs2_api.h linux/nilfs2_ondisk.h linux/nsfs.h linux/pr.h linux/qrtr.h linux/rpmsg.h linux/sched/types.h linux/sed-opal.h linux/smc.h linux/smc_diag.h linux/stm.h linux/switchtec_ioctl.h linux/vfio_ccw.h linux/wil6210_uapi.h rdma/bnxt_re-abi.h Note that I have removed from this list the files which are generated in every exported directories (like .install or .install.cmd). Thanks to Julien Floret <julien.floret@6wind.com> for the tip to get all subdirs with a pure makefile command. For the record, note that exported files for asm directories are a mix of files listed by: - include/uapi/asm-generic/Kbuild.asm; - arch/<arch>/include/uapi/asm/Kbuild; - arch/<arch>/include/asm/Kbuild. Signed-off-by: Nicolas Dichtel <nicolas.dichtel@6wind.com> Acked-by: Daniel Vetter <daniel.vetter@ffwll.ch> Acked-by: Russell King <rmk+kernel@armlinux.org.uk> Acked-by: Mark Salter <msalter@redhat.com> Acked-by: Michael Ellerman <mpe@ellerman.id.au> (powerpc) Signed-off-by: Masahiro Yamada <yamada.masahiro@socionext.com>
-rw-r--r--Documentation/kbuild/makefiles.txt66
-rw-r--r--arch/alpha/include/uapi/asm/Kbuild41
-rw-r--r--arch/arc/include/uapi/asm/Kbuild3
-rw-r--r--arch/arm/include/uapi/asm/Kbuild17
-rw-r--r--arch/arm64/include/uapi/asm/Kbuild18
-rw-r--r--arch/blackfin/include/uapi/asm/Kbuild17
-rw-r--r--arch/c6x/include/uapi/asm/Kbuild8
-rw-r--r--arch/cris/include/uapi/arch-v10/arch/Kbuild5
-rw-r--r--arch/cris/include/uapi/arch-v32/arch/Kbuild3
-rw-r--r--arch/cris/include/uapi/asm/Kbuild43
-rw-r--r--arch/frv/include/uapi/asm/Kbuild33
-rw-r--r--arch/h8300/include/uapi/asm/Kbuild28
-rw-r--r--arch/hexagon/include/asm/Kbuild3
-rw-r--r--arch/hexagon/include/uapi/asm/Kbuild13
-rw-r--r--arch/ia64/include/uapi/asm/Kbuild45
-rw-r--r--arch/m32r/include/uapi/asm/Kbuild31
-rw-r--r--arch/m68k/include/uapi/asm/Kbuild24
-rw-r--r--arch/metag/include/uapi/asm/Kbuild8
-rw-r--r--arch/microblaze/include/uapi/asm/Kbuild32
-rw-r--r--arch/mips/include/uapi/asm/Kbuild37
-rw-r--r--arch/mn10300/include/uapi/asm/Kbuild32
-rw-r--r--arch/nios2/include/uapi/asm/Kbuild3
-rw-r--r--arch/openrisc/include/asm/Kbuild3
-rw-r--r--arch/openrisc/include/uapi/asm/Kbuild8
-rw-r--r--arch/parisc/include/uapi/asm/Kbuild28
-rw-r--r--arch/powerpc/include/uapi/asm/Kbuild45
-rw-r--r--arch/s390/include/uapi/asm/Kbuild46
-rw-r--r--arch/score/include/asm/Kbuild3
-rw-r--r--arch/score/include/uapi/asm/Kbuild32
-rw-r--r--arch/sh/include/uapi/asm/Kbuild23
-rw-r--r--arch/sparc/include/uapi/asm/Kbuild48
-rw-r--r--arch/tile/include/asm/Kbuild3
-rw-r--r--arch/tile/include/uapi/arch/Kbuild17
-rw-r--r--arch/tile/include/uapi/asm/Kbuild19
-rw-r--r--arch/unicore32/include/uapi/asm/Kbuild6
-rw-r--r--arch/x86/include/uapi/asm/Kbuild58
-rw-r--r--arch/xtensa/include/uapi/asm/Kbuild23
-rw-r--r--include/Kbuild2
-rw-r--r--include/asm-generic/Kbuild.asm1
-rw-r--r--include/scsi/fc/Kbuild0
-rw-r--r--include/uapi/Kbuild15
-rw-r--r--include/uapi/asm-generic/Kbuild36
-rw-r--r--include/uapi/asm-generic/Kbuild.asm76
-rw-r--r--include/uapi/drm/Kbuild23
-rw-r--r--include/uapi/linux/Kbuild494
-rw-r--r--include/uapi/linux/android/Kbuild2
-rw-r--r--include/uapi/linux/byteorder/Kbuild3
-rw-r--r--include/uapi/linux/caif/Kbuild3
-rw-r--r--include/uapi/linux/can/Kbuild6
-rw-r--r--include/uapi/linux/dvb/Kbuild9
-rw-r--r--include/uapi/linux/hdlc/Kbuild2
-rw-r--r--include/uapi/linux/hsi/Kbuild2
-rw-r--r--include/uapi/linux/iio/Kbuild3
-rw-r--r--include/uapi/linux/isdn/Kbuild2
-rw-r--r--include/uapi/linux/mmc/Kbuild2
-rw-r--r--include/uapi/linux/netfilter/Kbuild89
-rw-r--r--include/uapi/linux/netfilter/ipset/Kbuild5
-rw-r--r--include/uapi/linux/netfilter_arp/Kbuild3
-rw-r--r--include/uapi/linux/netfilter_bridge/Kbuild18
-rw-r--r--include/uapi/linux/netfilter_ipv4/Kbuild10
-rw-r--r--include/uapi/linux/netfilter_ipv6/Kbuild13
-rw-r--r--include/uapi/linux/nfsd/Kbuild6
-rw-r--r--include/uapi/linux/raid/Kbuild3
-rw-r--r--include/uapi/linux/spi/Kbuild2
-rw-r--r--include/uapi/linux/sunrpc/Kbuild2
-rw-r--r--include/uapi/linux/tc_act/Kbuild16
-rw-r--r--include/uapi/linux/tc_ematch/Kbuild5
-rw-r--r--include/uapi/linux/usb/Kbuild12
-rw-r--r--include/uapi/linux/wimax/Kbuild2
-rw-r--r--include/uapi/misc/Kbuild2
-rw-r--r--include/uapi/mtd/Kbuild6
-rw-r--r--include/uapi/rdma/Kbuild20
-rw-r--r--include/uapi/rdma/hfi/Kbuild3
-rw-r--r--include/uapi/scsi/Kbuild6
-rw-r--r--include/uapi/scsi/fc/Kbuild5
-rw-r--r--include/uapi/sound/Kbuild16
-rw-r--r--include/uapi/video/Kbuild4
-rw-r--r--include/uapi/xen/Kbuild5
-rw-r--r--include/video/Kbuild0
-rw-r--r--scripts/Makefile.headersinst55
80 files changed, 111 insertions, 1750 deletions
diff --git a/Documentation/kbuild/makefiles.txt b/Documentation/kbuild/makefiles.txt
index 37b525d329ae..b9f7ca4e62ae 100644
--- a/Documentation/kbuild/makefiles.txt
+++ b/Documentation/kbuild/makefiles.txt
@@ -44,10 +44,12 @@ This document describes the Linux kernel Makefiles.
44 --- 6.11 Post-link pass 44 --- 6.11 Post-link pass
45 45
46 === 7 Kbuild syntax for exported headers 46 === 7 Kbuild syntax for exported headers
47 --- 7.1 header-y 47 --- 7.1 no-export-headers
48 --- 7.2 genhdr-y 48 --- 7.2 genhdr-y
49 --- 7.3 generic-y 49 --- 7.3 generic-y
50 --- 7.4 generated-y 50 --- 7.4 generated-y
51 --- 7.5 mandatory-y
52 --- 7.6 subdir-y
51 53
52 === 8 Kbuild Variables 54 === 8 Kbuild Variables
53 === 9 Makefile language 55 === 9 Makefile language
@@ -1235,7 +1237,7 @@ When kbuild executes, the following steps are followed (roughly):
1235 that may be shared between individual architectures. 1237 that may be shared between individual architectures.
1236 The recommended approach how to use a generic header file is 1238 The recommended approach how to use a generic header file is
1237 to list the file in the Kbuild file. 1239 to list the file in the Kbuild file.
1238 See "7.4 generic-y" for further info on syntax etc. 1240 See "7.3 generic-y" for further info on syntax etc.
1239 1241
1240--- 6.11 Post-link pass 1242--- 6.11 Post-link pass
1241 1243
@@ -1262,37 +1264,30 @@ The pre-processing does:
1262- drop include of compiler.h 1264- drop include of compiler.h
1263- drop all sections that are kernel internal (guarded by ifdef __KERNEL__) 1265- drop all sections that are kernel internal (guarded by ifdef __KERNEL__)
1264 1266
1265Each relevant directory contains a file name "Kbuild" which specifies the 1267All headers under include/uapi/, include/generated/uapi/,
1266headers to be exported. 1268arch/<arch>/include/uapi/asm/ and arch/<arch>/include/generated/uapi/asm/
1267See subsequent chapter for the syntax of the Kbuild file. 1269are exported.
1268
1269 --- 7.1 header-y
1270
1271 header-y specifies header files to be exported.
1272
1273 Example:
1274 #include/linux/Kbuild
1275 header-y += usb/
1276 header-y += aio_abi.h
1277 1270
1278 The convention is to list one file per line and 1271A Kbuild file may be defined under arch/<arch>/include/uapi/asm/ and
1279 preferably in alphabetic order. 1272arch/<arch>/include/asm/ to list asm files coming from asm-generic.
1273See subsequent chapter for the syntax of the Kbuild file.
1280 1274
1281 header-y also specifies which subdirectories to visit. 1275 --- 7.1 no-export-headers
1282 A subdirectory is identified by a trailing '/' which
1283 can be seen in the example above for the usb subdirectory.
1284 1276
1285 Subdirectories are visited before their parent directories. 1277 no-export-headers is essentially used by include/uapi/linux/Kbuild to
1278 avoid exporting specific headers (e.g. kvm.h) on architectures that do
1279 not support it. It should be avoided as much as possible.
1286 1280
1287 --- 7.2 genhdr-y 1281 --- 7.2 genhdr-y
1288 1282
1289 genhdr-y specifies generated files to be exported. 1283 genhdr-y specifies asm files to be generated.
1290 Generated files are special as they need to be looked
1291 up in another directory when doing 'make O=...' builds.
1292 1284
1293 Example: 1285 Example:
1294 #include/linux/Kbuild 1286 #arch/x86/include/uapi/asm/Kbuild
1295 genhdr-y += version.h 1287 genhdr-y += unistd_32.h
1288 genhdr-y += unistd_64.h
1289 genhdr-y += unistd_x32.h
1290
1296 1291
1297 --- 7.3 generic-y 1292 --- 7.3 generic-y
1298 1293
@@ -1334,6 +1329,27 @@ See subsequent chapter for the syntax of the Kbuild file.
1334 #arch/x86/include/asm/Kbuild 1329 #arch/x86/include/asm/Kbuild
1335 generated-y += syscalls_32.h 1330 generated-y += syscalls_32.h
1336 1331
1332 --- 7.5 mandatory-y
1333
1334 mandatory-y is essentially used by include/uapi/asm-generic/Kbuild.asm
1335 to define the minimun set of headers that must be exported in
1336 include/asm.
1337
1338 The convention is to list one subdir per line and
1339 preferably in alphabetic order.
1340
1341 --- 7.6 subdir-y
1342
1343 subdir-y may be used to specify a subdirectory to be exported.
1344
1345 Example:
1346 #arch/cris/include/uapi/asm/Kbuild
1347 subdir-y += ../arch-v10/arch/
1348 subdir-y += ../arch-v32/arch/
1349
1350 The convention is to list one subdir per line and
1351 preferably in alphabetic order.
1352
1337=== 8 Kbuild Variables 1353=== 8 Kbuild Variables
1338 1354
1339The top Makefile exports the following variables: 1355The top Makefile exports the following variables:
diff --git a/arch/alpha/include/uapi/asm/Kbuild b/arch/alpha/include/uapi/asm/Kbuild
index d96f2ef5b639..b15bf6bc0e94 100644
--- a/arch/alpha/include/uapi/asm/Kbuild
+++ b/arch/alpha/include/uapi/asm/Kbuild
@@ -1,43 +1,2 @@
1# UAPI Header export list 1# UAPI Header export list
2include include/uapi/asm-generic/Kbuild.asm 2include include/uapi/asm-generic/Kbuild.asm
3
4header-y += a.out.h
5header-y += auxvec.h
6header-y += bitsperlong.h
7header-y += byteorder.h
8header-y += compiler.h
9header-y += console.h
10header-y += errno.h
11header-y += fcntl.h
12header-y += fpu.h
13header-y += gentrap.h
14header-y += ioctl.h
15header-y += ioctls.h
16header-y += ipcbuf.h
17header-y += kvm_para.h
18header-y += mman.h
19header-y += msgbuf.h
20header-y += pal.h
21header-y += param.h
22header-y += poll.h
23header-y += posix_types.h
24header-y += ptrace.h
25header-y += reg.h
26header-y += regdef.h
27header-y += resource.h
28header-y += sembuf.h
29header-y += setup.h
30header-y += shmbuf.h
31header-y += sigcontext.h
32header-y += siginfo.h
33header-y += signal.h
34header-y += socket.h
35header-y += sockios.h
36header-y += stat.h
37header-y += statfs.h
38header-y += swab.h
39header-y += sysinfo.h
40header-y += termbits.h
41header-y += termios.h
42header-y += types.h
43header-y += unistd.h
diff --git a/arch/arc/include/uapi/asm/Kbuild b/arch/arc/include/uapi/asm/Kbuild
index f50d02df78d5..b15bf6bc0e94 100644
--- a/arch/arc/include/uapi/asm/Kbuild
+++ b/arch/arc/include/uapi/asm/Kbuild
@@ -1,5 +1,2 @@
1# UAPI Header export list 1# UAPI Header export list
2include include/uapi/asm-generic/Kbuild.asm 2include include/uapi/asm-generic/Kbuild.asm
3header-y += elf.h
4header-y += page.h
5header-y += cachectl.h
diff --git a/arch/arm/include/uapi/asm/Kbuild b/arch/arm/include/uapi/asm/Kbuild
index 46a76cd6acb6..607f702c2d62 100644
--- a/arch/arm/include/uapi/asm/Kbuild
+++ b/arch/arm/include/uapi/asm/Kbuild
@@ -1,23 +1,6 @@
1# UAPI Header export list 1# UAPI Header export list
2include include/uapi/asm-generic/Kbuild.asm 2include include/uapi/asm-generic/Kbuild.asm
3 3
4header-y += auxvec.h
5header-y += byteorder.h
6header-y += fcntl.h
7header-y += hwcap.h
8header-y += ioctls.h
9header-y += kvm_para.h
10header-y += mman.h
11header-y += perf_regs.h
12header-y += posix_types.h
13header-y += ptrace.h
14header-y += setup.h
15header-y += sigcontext.h
16header-y += signal.h
17header-y += stat.h
18header-y += statfs.h
19header-y += swab.h
20header-y += unistd.h
21genhdr-y += unistd-common.h 4genhdr-y += unistd-common.h
22genhdr-y += unistd-oabi.h 5genhdr-y += unistd-oabi.h
23genhdr-y += unistd-eabi.h 6genhdr-y += unistd-eabi.h
diff --git a/arch/arm64/include/uapi/asm/Kbuild b/arch/arm64/include/uapi/asm/Kbuild
index 825b0fe51c2b..13a97aa2285f 100644
--- a/arch/arm64/include/uapi/asm/Kbuild
+++ b/arch/arm64/include/uapi/asm/Kbuild
@@ -2,21 +2,3 @@
2include include/uapi/asm-generic/Kbuild.asm 2include include/uapi/asm-generic/Kbuild.asm
3 3
4generic-y += kvm_para.h 4generic-y += kvm_para.h
5
6header-y += auxvec.h
7header-y += bitsperlong.h
8header-y += byteorder.h
9header-y += fcntl.h
10header-y += hwcap.h
11header-y += kvm_para.h
12header-y += perf_regs.h
13header-y += param.h
14header-y += ptrace.h
15header-y += setup.h
16header-y += sigcontext.h
17header-y += siginfo.h
18header-y += signal.h
19header-y += stat.h
20header-y += statfs.h
21header-y += ucontext.h
22header-y += unistd.h
diff --git a/arch/blackfin/include/uapi/asm/Kbuild b/arch/blackfin/include/uapi/asm/Kbuild
index 0bd28f77abc3..b15bf6bc0e94 100644
--- a/arch/blackfin/include/uapi/asm/Kbuild
+++ b/arch/blackfin/include/uapi/asm/Kbuild
@@ -1,19 +1,2 @@
1# UAPI Header export list 1# UAPI Header export list
2include include/uapi/asm-generic/Kbuild.asm 2include include/uapi/asm-generic/Kbuild.asm
3
4header-y += bfin_sport.h
5header-y += byteorder.h
6header-y += cachectl.h
7header-y += fcntl.h
8header-y += fixed_code.h
9header-y += ioctls.h
10header-y += kvm_para.h
11header-y += poll.h
12header-y += posix_types.h
13header-y += ptrace.h
14header-y += sigcontext.h
15header-y += siginfo.h
16header-y += signal.h
17header-y += stat.h
18header-y += swab.h
19header-y += unistd.h
diff --git a/arch/c6x/include/uapi/asm/Kbuild b/arch/c6x/include/uapi/asm/Kbuild
index e9bc2b2b8147..13a97aa2285f 100644
--- a/arch/c6x/include/uapi/asm/Kbuild
+++ b/arch/c6x/include/uapi/asm/Kbuild
@@ -2,11 +2,3 @@
2include include/uapi/asm-generic/Kbuild.asm 2include include/uapi/asm-generic/Kbuild.asm
3 3
4generic-y += kvm_para.h 4generic-y += kvm_para.h
5
6header-y += byteorder.h
7header-y += kvm_para.h
8header-y += ptrace.h
9header-y += setup.h
10header-y += sigcontext.h
11header-y += swab.h
12header-y += unistd.h
diff --git a/arch/cris/include/uapi/arch-v10/arch/Kbuild b/arch/cris/include/uapi/arch-v10/arch/Kbuild
deleted file mode 100644
index 9048c87a782b..000000000000
--- a/arch/cris/include/uapi/arch-v10/arch/Kbuild
+++ /dev/null
@@ -1,5 +0,0 @@
1# UAPI Header export list
2header-y += sv_addr.agh
3header-y += sv_addr_ag.h
4header-y += svinto.h
5header-y += user.h
diff --git a/arch/cris/include/uapi/arch-v32/arch/Kbuild b/arch/cris/include/uapi/arch-v32/arch/Kbuild
deleted file mode 100644
index 59efffd16b61..000000000000
--- a/arch/cris/include/uapi/arch-v32/arch/Kbuild
+++ /dev/null
@@ -1,3 +0,0 @@
1# UAPI Header export list
2header-y += cryptocop.h
3header-y += user.h
diff --git a/arch/cris/include/uapi/asm/Kbuild b/arch/cris/include/uapi/asm/Kbuild
index d5564a0ae66a..d0c5471856e0 100644
--- a/arch/cris/include/uapi/asm/Kbuild
+++ b/arch/cris/include/uapi/asm/Kbuild
@@ -1,44 +1,5 @@
1# UAPI Header export list 1# UAPI Header export list
2include include/uapi/asm-generic/Kbuild.asm 2include include/uapi/asm-generic/Kbuild.asm
3 3
4header-y += ../arch-v10/arch/ 4subdir-y += ../arch-v10/arch/
5header-y += ../arch-v32/arch/ 5subdir-y += ../arch-v32/arch/
6header-y += auxvec.h
7header-y += bitsperlong.h
8header-y += byteorder.h
9header-y += elf.h
10header-y += elf_v10.h
11header-y += elf_v32.h
12header-y += errno.h
13header-y += ethernet.h
14header-y += etraxgpio.h
15header-y += fcntl.h
16header-y += ioctl.h
17header-y += ioctls.h
18header-y += ipcbuf.h
19header-y += mman.h
20header-y += msgbuf.h
21header-y += param.h
22header-y += poll.h
23header-y += posix_types.h
24header-y += ptrace.h
25header-y += ptrace_v10.h
26header-y += ptrace_v32.h
27header-y += resource.h
28header-y += rs485.h
29header-y += sembuf.h
30header-y += setup.h
31header-y += shmbuf.h
32header-y += sigcontext.h
33header-y += siginfo.h
34header-y += signal.h
35header-y += socket.h
36header-y += sockios.h
37header-y += stat.h
38header-y += statfs.h
39header-y += swab.h
40header-y += sync_serial.h
41header-y += termbits.h
42header-y += termios.h
43header-y += types.h
44header-y += unistd.h
diff --git a/arch/frv/include/uapi/asm/Kbuild b/arch/frv/include/uapi/asm/Kbuild
index 42a2b33461c0..b15bf6bc0e94 100644
--- a/arch/frv/include/uapi/asm/Kbuild
+++ b/arch/frv/include/uapi/asm/Kbuild
@@ -1,35 +1,2 @@
1# UAPI Header export list 1# UAPI Header export list
2include include/uapi/asm-generic/Kbuild.asm 2include include/uapi/asm-generic/Kbuild.asm
3
4header-y += auxvec.h
5header-y += bitsperlong.h
6header-y += byteorder.h
7header-y += errno.h
8header-y += fcntl.h
9header-y += ioctl.h
10header-y += ioctls.h
11header-y += ipcbuf.h
12header-y += kvm_para.h
13header-y += mman.h
14header-y += msgbuf.h
15header-y += param.h
16header-y += poll.h
17header-y += posix_types.h
18header-y += ptrace.h
19header-y += registers.h
20header-y += resource.h
21header-y += sembuf.h
22header-y += setup.h
23header-y += shmbuf.h
24header-y += sigcontext.h
25header-y += siginfo.h
26header-y += signal.h
27header-y += socket.h
28header-y += sockios.h
29header-y += stat.h
30header-y += statfs.h
31header-y += swab.h
32header-y += termbits.h
33header-y += termios.h
34header-y += types.h
35header-y += unistd.h
diff --git a/arch/h8300/include/uapi/asm/Kbuild b/arch/h8300/include/uapi/asm/Kbuild
index fb6101a5d4f1..b15bf6bc0e94 100644
--- a/arch/h8300/include/uapi/asm/Kbuild
+++ b/arch/h8300/include/uapi/asm/Kbuild
@@ -1,30 +1,2 @@
1# UAPI Header export list 1# UAPI Header export list
2include include/uapi/asm-generic/Kbuild.asm 2include include/uapi/asm-generic/Kbuild.asm
3
4header-y += auxvec.h
5header-y += bitsperlong.h
6header-y += errno.h
7header-y += fcntl.h
8header-y += ioctl.h
9header-y += ioctls.h
10header-y += ipcbuf.h
11header-y += kvm_para.h
12header-y += mman.h
13header-y += msgbuf.h
14header-y += param.h
15header-y += poll.h
16header-y += posix_types.h
17header-y += resource.h
18header-y += sembuf.h
19header-y += setup.h
20header-y += shmbuf.h
21header-y += siginfo.h
22header-y += socket.h
23header-y += sockios.h
24header-y += stat.h
25header-y += statfs.h
26header-y += swab.h
27header-y += termbits.h
28header-y += termios.h
29header-y += types.h
30header-y += unistd.h
diff --git a/arch/hexagon/include/asm/Kbuild b/arch/hexagon/include/asm/Kbuild
index a2036bfda8af..6b45ef79eb8f 100644
--- a/arch/hexagon/include/asm/Kbuild
+++ b/arch/hexagon/include/asm/Kbuild
@@ -1,6 +1,3 @@
1
2header-y += ucontext.h
3
4generic-y += auxvec.h 1generic-y += auxvec.h
5generic-y += barrier.h 2generic-y += barrier.h
6generic-y += bug.h 3generic-y += bug.h
diff --git a/arch/hexagon/include/uapi/asm/Kbuild b/arch/hexagon/include/uapi/asm/Kbuild
index c31706c38631..b15bf6bc0e94 100644
--- a/arch/hexagon/include/uapi/asm/Kbuild
+++ b/arch/hexagon/include/uapi/asm/Kbuild
@@ -1,15 +1,2 @@
1# UAPI Header export list 1# UAPI Header export list
2include include/uapi/asm-generic/Kbuild.asm 2include include/uapi/asm-generic/Kbuild.asm
3
4header-y += bitsperlong.h
5header-y += byteorder.h
6header-y += kvm_para.h
7header-y += param.h
8header-y += ptrace.h
9header-y += registers.h
10header-y += setup.h
11header-y += sigcontext.h
12header-y += signal.h
13header-y += swab.h
14header-y += unistd.h
15header-y += user.h
diff --git a/arch/ia64/include/uapi/asm/Kbuild b/arch/ia64/include/uapi/asm/Kbuild
index 891002bbb995..13a97aa2285f 100644
--- a/arch/ia64/include/uapi/asm/Kbuild
+++ b/arch/ia64/include/uapi/asm/Kbuild
@@ -2,48 +2,3 @@
2include include/uapi/asm-generic/Kbuild.asm 2include include/uapi/asm-generic/Kbuild.asm
3 3
4generic-y += kvm_para.h 4generic-y += kvm_para.h
5
6header-y += auxvec.h
7header-y += bitsperlong.h
8header-y += break.h
9header-y += byteorder.h
10header-y += cmpxchg.h
11header-y += errno.h
12header-y += fcntl.h
13header-y += fpu.h
14header-y += gcc_intrin.h
15header-y += ia64regs.h
16header-y += intel_intrin.h
17header-y += intrinsics.h
18header-y += ioctl.h
19header-y += ioctls.h
20header-y += ipcbuf.h
21header-y += kvm_para.h
22header-y += mman.h
23header-y += msgbuf.h
24header-y += param.h
25header-y += perfmon.h
26header-y += perfmon_default_smpl.h
27header-y += poll.h
28header-y += posix_types.h
29header-y += ptrace.h
30header-y += ptrace_offsets.h
31header-y += resource.h
32header-y += rse.h
33header-y += sembuf.h
34header-y += setup.h
35header-y += shmbuf.h
36header-y += sigcontext.h
37header-y += siginfo.h
38header-y += signal.h
39header-y += socket.h
40header-y += sockios.h
41header-y += stat.h
42header-y += statfs.h
43header-y += swab.h
44header-y += termbits.h
45header-y += termios.h
46header-y += types.h
47header-y += ucontext.h
48header-y += unistd.h
49header-y += ustack.h
diff --git a/arch/m32r/include/uapi/asm/Kbuild b/arch/m32r/include/uapi/asm/Kbuild
index 43937a61d6cf..b15bf6bc0e94 100644
--- a/arch/m32r/include/uapi/asm/Kbuild
+++ b/arch/m32r/include/uapi/asm/Kbuild
@@ -1,33 +1,2 @@
1# UAPI Header export list 1# UAPI Header export list
2include include/uapi/asm-generic/Kbuild.asm 2include include/uapi/asm-generic/Kbuild.asm
3
4header-y += auxvec.h
5header-y += bitsperlong.h
6header-y += byteorder.h
7header-y += errno.h
8header-y += fcntl.h
9header-y += ioctl.h
10header-y += ioctls.h
11header-y += ipcbuf.h
12header-y += mman.h
13header-y += msgbuf.h
14header-y += param.h
15header-y += poll.h
16header-y += posix_types.h
17header-y += ptrace.h
18header-y += resource.h
19header-y += sembuf.h
20header-y += setup.h
21header-y += shmbuf.h
22header-y += sigcontext.h
23header-y += siginfo.h
24header-y += signal.h
25header-y += socket.h
26header-y += sockios.h
27header-y += stat.h
28header-y += statfs.h
29header-y += swab.h
30header-y += termbits.h
31header-y += termios.h
32header-y += types.h
33header-y += unistd.h
diff --git a/arch/m68k/include/uapi/asm/Kbuild b/arch/m68k/include/uapi/asm/Kbuild
index 6a2d257bdfb2..64368077235a 100644
--- a/arch/m68k/include/uapi/asm/Kbuild
+++ b/arch/m68k/include/uapi/asm/Kbuild
@@ -9,27 +9,3 @@ generic-y += socket.h
9generic-y += sockios.h 9generic-y += sockios.h
10generic-y += termbits.h 10generic-y += termbits.h
11generic-y += termios.h 11generic-y += termios.h
12
13header-y += a.out.h
14header-y += bootinfo.h
15header-y += bootinfo-amiga.h
16header-y += bootinfo-apollo.h
17header-y += bootinfo-atari.h
18header-y += bootinfo-hp300.h
19header-y += bootinfo-mac.h
20header-y += bootinfo-q40.h
21header-y += bootinfo-vme.h
22header-y += byteorder.h
23header-y += cachectl.h
24header-y += fcntl.h
25header-y += ioctls.h
26header-y += param.h
27header-y += poll.h
28header-y += posix_types.h
29header-y += ptrace.h
30header-y += setup.h
31header-y += sigcontext.h
32header-y += signal.h
33header-y += stat.h
34header-y += swab.h
35header-y += unistd.h
diff --git a/arch/metag/include/uapi/asm/Kbuild b/arch/metag/include/uapi/asm/Kbuild
index ab78be2b6eb0..b29731ebd7a9 100644
--- a/arch/metag/include/uapi/asm/Kbuild
+++ b/arch/metag/include/uapi/asm/Kbuild
@@ -1,14 +1,6 @@
1# UAPI Header export list 1# UAPI Header export list
2include include/uapi/asm-generic/Kbuild.asm 2include include/uapi/asm-generic/Kbuild.asm
3 3
4header-y += byteorder.h
5header-y += ech.h
6header-y += ptrace.h
7header-y += sigcontext.h
8header-y += siginfo.h
9header-y += swab.h
10header-y += unistd.h
11
12generic-y += mman.h 4generic-y += mman.h
13generic-y += resource.h 5generic-y += resource.h
14generic-y += setup.h 6generic-y += setup.h
diff --git a/arch/microblaze/include/uapi/asm/Kbuild b/arch/microblaze/include/uapi/asm/Kbuild
index 1aac99f87df1..2178c78c7c1a 100644
--- a/arch/microblaze/include/uapi/asm/Kbuild
+++ b/arch/microblaze/include/uapi/asm/Kbuild
@@ -2,35 +2,3 @@
2include include/uapi/asm-generic/Kbuild.asm 2include include/uapi/asm-generic/Kbuild.asm
3 3
4generic-y += types.h 4generic-y += types.h
5
6header-y += auxvec.h
7header-y += bitsperlong.h
8header-y += byteorder.h
9header-y += elf.h
10header-y += errno.h
11header-y += fcntl.h
12header-y += ioctl.h
13header-y += ioctls.h
14header-y += ipcbuf.h
15header-y += kvm_para.h
16header-y += mman.h
17header-y += msgbuf.h
18header-y += param.h
19header-y += poll.h
20header-y += posix_types.h
21header-y += ptrace.h
22header-y += resource.h
23header-y += sembuf.h
24header-y += setup.h
25header-y += shmbuf.h
26header-y += sigcontext.h
27header-y += siginfo.h
28header-y += signal.h
29header-y += socket.h
30header-y += sockios.h
31header-y += stat.h
32header-y += statfs.h
33header-y += swab.h
34header-y += termbits.h
35header-y += termios.h
36header-y += unistd.h
diff --git a/arch/mips/include/uapi/asm/Kbuild b/arch/mips/include/uapi/asm/Kbuild
index f2cf41461146..a0266feba9e6 100644
--- a/arch/mips/include/uapi/asm/Kbuild
+++ b/arch/mips/include/uapi/asm/Kbuild
@@ -2,40 +2,3 @@
2include include/uapi/asm-generic/Kbuild.asm 2include include/uapi/asm-generic/Kbuild.asm
3 3
4generic-y += ipcbuf.h 4generic-y += ipcbuf.h
5
6header-y += auxvec.h
7header-y += bitfield.h
8header-y += bitsperlong.h
9header-y += break.h
10header-y += byteorder.h
11header-y += cachectl.h
12header-y += errno.h
13header-y += fcntl.h
14header-y += inst.h
15header-y += ioctl.h
16header-y += ioctls.h
17header-y += kvm_para.h
18header-y += mman.h
19header-y += msgbuf.h
20header-y += param.h
21header-y += poll.h
22header-y += posix_types.h
23header-y += ptrace.h
24header-y += resource.h
25header-y += sembuf.h
26header-y += setup.h
27header-y += sgidefs.h
28header-y += shmbuf.h
29header-y += sigcontext.h
30header-y += siginfo.h
31header-y += signal.h
32header-y += socket.h
33header-y += sockios.h
34header-y += stat.h
35header-y += statfs.h
36header-y += swab.h
37header-y += sysmips.h
38header-y += termbits.h
39header-y += termios.h
40header-y += types.h
41header-y += unistd.h
diff --git a/arch/mn10300/include/uapi/asm/Kbuild b/arch/mn10300/include/uapi/asm/Kbuild
index 040178cdb3eb..b15bf6bc0e94 100644
--- a/arch/mn10300/include/uapi/asm/Kbuild
+++ b/arch/mn10300/include/uapi/asm/Kbuild
@@ -1,34 +1,2 @@
1# UAPI Header export list 1# UAPI Header export list
2include include/uapi/asm-generic/Kbuild.asm 2include include/uapi/asm-generic/Kbuild.asm
3
4header-y += auxvec.h
5header-y += bitsperlong.h
6header-y += byteorder.h
7header-y += errno.h
8header-y += fcntl.h
9header-y += ioctl.h
10header-y += ioctls.h
11header-y += ipcbuf.h
12header-y += kvm_para.h
13header-y += mman.h
14header-y += msgbuf.h
15header-y += param.h
16header-y += poll.h
17header-y += posix_types.h
18header-y += ptrace.h
19header-y += resource.h
20header-y += sembuf.h
21header-y += setup.h
22header-y += shmbuf.h
23header-y += sigcontext.h
24header-y += siginfo.h
25header-y += signal.h
26header-y += socket.h
27header-y += sockios.h
28header-y += stat.h
29header-y += statfs.h
30header-y += swab.h
31header-y += termbits.h
32header-y += termios.h
33header-y += types.h
34header-y += unistd.h
diff --git a/arch/nios2/include/uapi/asm/Kbuild b/arch/nios2/include/uapi/asm/Kbuild
index 69c965304146..374bd123329f 100644
--- a/arch/nios2/include/uapi/asm/Kbuild
+++ b/arch/nios2/include/uapi/asm/Kbuild
@@ -1,6 +1,5 @@
1# UAPI Header export list
1include include/uapi/asm-generic/Kbuild.asm 2include include/uapi/asm-generic/Kbuild.asm
2 3
3header-y += elf.h
4
5generic-y += setup.h 4generic-y += setup.h
6generic-y += ucontext.h 5generic-y += ucontext.h
diff --git a/arch/openrisc/include/asm/Kbuild b/arch/openrisc/include/asm/Kbuild
index df8e2f7bc7dd..fdbcf0bf44a4 100644
--- a/arch/openrisc/include/asm/Kbuild
+++ b/arch/openrisc/include/asm/Kbuild
@@ -1,6 +1,3 @@
1
2header-y += ucontext.h
3
4generic-y += auxvec.h 1generic-y += auxvec.h
5generic-y += barrier.h 2generic-y += barrier.h
6generic-y += bitsperlong.h 3generic-y += bitsperlong.h
diff --git a/arch/openrisc/include/uapi/asm/Kbuild b/arch/openrisc/include/uapi/asm/Kbuild
index 80761eb82b5f..b15bf6bc0e94 100644
--- a/arch/openrisc/include/uapi/asm/Kbuild
+++ b/arch/openrisc/include/uapi/asm/Kbuild
@@ -1,10 +1,2 @@
1# UAPI Header export list 1# UAPI Header export list
2include include/uapi/asm-generic/Kbuild.asm 2include include/uapi/asm-generic/Kbuild.asm
3
4header-y += byteorder.h
5header-y += elf.h
6header-y += kvm_para.h
7header-y += param.h
8header-y += ptrace.h
9header-y += sigcontext.h
10header-y += unistd.h
diff --git a/arch/parisc/include/uapi/asm/Kbuild b/arch/parisc/include/uapi/asm/Kbuild
index 348356c99514..3971c60a7e7f 100644
--- a/arch/parisc/include/uapi/asm/Kbuild
+++ b/arch/parisc/include/uapi/asm/Kbuild
@@ -2,31 +2,3 @@
2include include/uapi/asm-generic/Kbuild.asm 2include include/uapi/asm-generic/Kbuild.asm
3 3
4generic-y += resource.h 4generic-y += resource.h
5
6header-y += bitsperlong.h
7header-y += byteorder.h
8header-y += errno.h
9header-y += fcntl.h
10header-y += ioctl.h
11header-y += ioctls.h
12header-y += ipcbuf.h
13header-y += mman.h
14header-y += msgbuf.h
15header-y += pdc.h
16header-y += posix_types.h
17header-y += ptrace.h
18header-y += sembuf.h
19header-y += setup.h
20header-y += shmbuf.h
21header-y += sigcontext.h
22header-y += siginfo.h
23header-y += signal.h
24header-y += socket.h
25header-y += sockios.h
26header-y += stat.h
27header-y += statfs.h
28header-y += swab.h
29header-y += termbits.h
30header-y += termios.h
31header-y += types.h
32header-y += unistd.h
diff --git a/arch/powerpc/include/uapi/asm/Kbuild b/arch/powerpc/include/uapi/asm/Kbuild
index dab3717e3ea0..b15bf6bc0e94 100644
--- a/arch/powerpc/include/uapi/asm/Kbuild
+++ b/arch/powerpc/include/uapi/asm/Kbuild
@@ -1,47 +1,2 @@
1# UAPI Header export list 1# UAPI Header export list
2include include/uapi/asm-generic/Kbuild.asm 2include include/uapi/asm-generic/Kbuild.asm
3
4header-y += auxvec.h
5header-y += bitsperlong.h
6header-y += bootx.h
7header-y += byteorder.h
8header-y += cputable.h
9header-y += eeh.h
10header-y += elf.h
11header-y += epapr_hcalls.h
12header-y += errno.h
13header-y += fcntl.h
14header-y += ioctl.h
15header-y += ioctls.h
16header-y += ipcbuf.h
17header-y += kvm.h
18header-y += kvm_para.h
19header-y += mman.h
20header-y += msgbuf.h
21header-y += nvram.h
22header-y += opal-prd.h
23header-y += param.h
24header-y += perf_event.h
25header-y += poll.h
26header-y += posix_types.h
27header-y += ps3fb.h
28header-y += ptrace.h
29header-y += resource.h
30header-y += sembuf.h
31header-y += setup.h
32header-y += shmbuf.h
33header-y += sigcontext.h
34header-y += siginfo.h
35header-y += signal.h
36header-y += socket.h
37header-y += sockios.h
38header-y += spu_info.h
39header-y += stat.h
40header-y += statfs.h
41header-y += swab.h
42header-y += termbits.h
43header-y += termios.h
44header-y += tm.h
45header-y += types.h
46header-y += ucontext.h
47header-y += unistd.h
diff --git a/arch/s390/include/uapi/asm/Kbuild b/arch/s390/include/uapi/asm/Kbuild
index addb09cee0f5..ca62066895e0 100644
--- a/arch/s390/include/uapi/asm/Kbuild
+++ b/arch/s390/include/uapi/asm/Kbuild
@@ -10,49 +10,3 @@ generic-y += poll.h
10generic-y += resource.h 10generic-y += resource.h
11generic-y += sockios.h 11generic-y += sockios.h
12generic-y += termbits.h 12generic-y += termbits.h
13
14header-y += auxvec.h
15header-y += bitsperlong.h
16header-y += byteorder.h
17header-y += chpid.h
18header-y += chsc.h
19header-y += clp.h
20header-y += cmb.h
21header-y += dasd.h
22header-y += debug.h
23header-y += errno.h
24header-y += guarded_storage.h
25header-y += hypfs.h
26header-y += ioctls.h
27header-y += ipcbuf.h
28header-y += kvm.h
29header-y += kvm_para.h
30header-y += kvm_perf.h
31header-y += kvm_virtio.h
32header-y += monwriter.h
33header-y += msgbuf.h
34header-y += pkey.h
35header-y += posix_types.h
36header-y += ptrace.h
37header-y += qeth.h
38header-y += schid.h
39header-y += sclp_ctl.h
40header-y += sembuf.h
41header-y += setup.h
42header-y += shmbuf.h
43header-y += sie.h
44header-y += sigcontext.h
45header-y += siginfo.h
46header-y += signal.h
47header-y += socket.h
48header-y += stat.h
49header-y += statfs.h
50header-y += swab.h
51header-y += tape390.h
52header-y += termios.h
53header-y += types.h
54header-y += ucontext.h
55header-y += unistd.h
56header-y += virtio-ccw.h
57header-y += vtoc.h
58header-y += zcrypt.h
diff --git a/arch/score/include/asm/Kbuild b/arch/score/include/asm/Kbuild
index e3a8d0f96652..54b3b2039af1 100644
--- a/arch/score/include/asm/Kbuild
+++ b/arch/score/include/asm/Kbuild
@@ -1,6 +1,3 @@
1
2header-y +=
3
4generic-y += barrier.h 1generic-y += barrier.h
5generic-y += clkdev.h 2generic-y += clkdev.h
6generic-y += current.h 3generic-y += current.h
diff --git a/arch/score/include/uapi/asm/Kbuild b/arch/score/include/uapi/asm/Kbuild
index 040178cdb3eb..b15bf6bc0e94 100644
--- a/arch/score/include/uapi/asm/Kbuild
+++ b/arch/score/include/uapi/asm/Kbuild
@@ -1,34 +1,2 @@
1# UAPI Header export list 1# UAPI Header export list
2include include/uapi/asm-generic/Kbuild.asm 2include include/uapi/asm-generic/Kbuild.asm
3
4header-y += auxvec.h
5header-y += bitsperlong.h
6header-y += byteorder.h
7header-y += errno.h
8header-y += fcntl.h
9header-y += ioctl.h
10header-y += ioctls.h
11header-y += ipcbuf.h
12header-y += kvm_para.h
13header-y += mman.h
14header-y += msgbuf.h
15header-y += param.h
16header-y += poll.h
17header-y += posix_types.h
18header-y += ptrace.h
19header-y += resource.h
20header-y += sembuf.h
21header-y += setup.h
22header-y += shmbuf.h
23header-y += sigcontext.h
24header-y += siginfo.h
25header-y += signal.h
26header-y += socket.h
27header-y += sockios.h
28header-y += stat.h
29header-y += statfs.h
30header-y += swab.h
31header-y += termbits.h
32header-y += termios.h
33header-y += types.h
34header-y += unistd.h
diff --git a/arch/sh/include/uapi/asm/Kbuild b/arch/sh/include/uapi/asm/Kbuild
index 60613ae78513..b15bf6bc0e94 100644
--- a/arch/sh/include/uapi/asm/Kbuild
+++ b/arch/sh/include/uapi/asm/Kbuild
@@ -1,25 +1,2 @@
1# UAPI Header export list 1# UAPI Header export list
2include include/uapi/asm-generic/Kbuild.asm 2include include/uapi/asm-generic/Kbuild.asm
3
4header-y += auxvec.h
5header-y += byteorder.h
6header-y += cachectl.h
7header-y += cpu-features.h
8header-y += hw_breakpoint.h
9header-y += ioctls.h
10header-y += posix_types.h
11header-y += posix_types_32.h
12header-y += posix_types_64.h
13header-y += ptrace.h
14header-y += ptrace_32.h
15header-y += ptrace_64.h
16header-y += setup.h
17header-y += sigcontext.h
18header-y += signal.h
19header-y += sockios.h
20header-y += stat.h
21header-y += swab.h
22header-y += types.h
23header-y += unistd.h
24header-y += unistd_32.h
25header-y += unistd_64.h
diff --git a/arch/sparc/include/uapi/asm/Kbuild b/arch/sparc/include/uapi/asm/Kbuild
index b5843ee09fb5..b15bf6bc0e94 100644
--- a/arch/sparc/include/uapi/asm/Kbuild
+++ b/arch/sparc/include/uapi/asm/Kbuild
@@ -1,50 +1,2 @@
1# UAPI Header export list 1# UAPI Header export list
2# User exported sparc header files
3
4include include/uapi/asm-generic/Kbuild.asm 2include include/uapi/asm-generic/Kbuild.asm
5
6header-y += apc.h
7header-y += asi.h
8header-y += auxvec.h
9header-y += bitsperlong.h
10header-y += byteorder.h
11header-y += display7seg.h
12header-y += envctrl.h
13header-y += errno.h
14header-y += fbio.h
15header-y += fcntl.h
16header-y += ioctl.h
17header-y += ioctls.h
18header-y += ipcbuf.h
19header-y += jsflash.h
20header-y += kvm_para.h
21header-y += mman.h
22header-y += msgbuf.h
23header-y += openpromio.h
24header-y += param.h
25header-y += perfctr.h
26header-y += poll.h
27header-y += posix_types.h
28header-y += psr.h
29header-y += psrcompat.h
30header-y += pstate.h
31header-y += ptrace.h
32header-y += resource.h
33header-y += sembuf.h
34header-y += setup.h
35header-y += shmbuf.h
36header-y += sigcontext.h
37header-y += siginfo.h
38header-y += signal.h
39header-y += socket.h
40header-y += sockios.h
41header-y += stat.h
42header-y += statfs.h
43header-y += swab.h
44header-y += termbits.h
45header-y += termios.h
46header-y += traps.h
47header-y += uctx.h
48header-y += unistd.h
49header-y += utrap.h
50header-y += watchdog.h
diff --git a/arch/tile/include/asm/Kbuild b/arch/tile/include/asm/Kbuild
index 24c44e93804d..16f0b08c8ce9 100644
--- a/arch/tile/include/asm/Kbuild
+++ b/arch/tile/include/asm/Kbuild
@@ -1,6 +1,3 @@
1
2header-y += ../arch/
3
4generic-y += bug.h 1generic-y += bug.h
5generic-y += bugs.h 2generic-y += bugs.h
6generic-y += clkdev.h 3generic-y += clkdev.h
diff --git a/arch/tile/include/uapi/arch/Kbuild b/arch/tile/include/uapi/arch/Kbuild
deleted file mode 100644
index 97dfbecec6b6..000000000000
--- a/arch/tile/include/uapi/arch/Kbuild
+++ /dev/null
@@ -1,17 +0,0 @@
1# UAPI Header export list
2header-y += abi.h
3header-y += chip.h
4header-y += chip_tilegx.h
5header-y += chip_tilepro.h
6header-y += icache.h
7header-y += interrupts.h
8header-y += interrupts_32.h
9header-y += interrupts_64.h
10header-y += opcode.h
11header-y += opcode_tilegx.h
12header-y += opcode_tilepro.h
13header-y += sim.h
14header-y += sim_def.h
15header-y += spr_def.h
16header-y += spr_def_32.h
17header-y += spr_def_64.h
diff --git a/arch/tile/include/uapi/asm/Kbuild b/arch/tile/include/uapi/asm/Kbuild
index c20db8e428bf..e0a50111e07f 100644
--- a/arch/tile/include/uapi/asm/Kbuild
+++ b/arch/tile/include/uapi/asm/Kbuild
@@ -1,21 +1,6 @@
1# UAPI Header export list 1# UAPI Header export list
2include include/uapi/asm-generic/Kbuild.asm 2include include/uapi/asm-generic/Kbuild.asm
3 3
4header-y += auxvec.h
5header-y += bitsperlong.h
6header-y += byteorder.h
7header-y += cachectl.h
8header-y += hardwall.h
9header-y += kvm_para.h
10header-y += mman.h
11header-y += ptrace.h
12header-y += setup.h
13header-y += sigcontext.h
14header-y += siginfo.h
15header-y += signal.h
16header-y += stat.h
17header-y += swab.h
18header-y += ucontext.h
19header-y += unistd.h
20
21generic-y += ucontext.h 4generic-y += ucontext.h
5
6subdir-y += ../arch
diff --git a/arch/unicore32/include/uapi/asm/Kbuild b/arch/unicore32/include/uapi/asm/Kbuild
index 0514d7ad6855..13a97aa2285f 100644
--- a/arch/unicore32/include/uapi/asm/Kbuild
+++ b/arch/unicore32/include/uapi/asm/Kbuild
@@ -1,10 +1,4 @@
1# UAPI Header export list 1# UAPI Header export list
2include include/uapi/asm-generic/Kbuild.asm 2include include/uapi/asm-generic/Kbuild.asm
3 3
4header-y += byteorder.h
5header-y += kvm_para.h
6header-y += ptrace.h
7header-y += sigcontext.h
8header-y += unistd.h
9
10generic-y += kvm_para.h 4generic-y += kvm_para.h
diff --git a/arch/x86/include/uapi/asm/Kbuild b/arch/x86/include/uapi/asm/Kbuild
index 1c532b3f18ea..83b6e9a0dce4 100644
--- a/arch/x86/include/uapi/asm/Kbuild
+++ b/arch/x86/include/uapi/asm/Kbuild
@@ -4,61 +4,3 @@ include include/uapi/asm-generic/Kbuild.asm
4genhdr-y += unistd_32.h 4genhdr-y += unistd_32.h
5genhdr-y += unistd_64.h 5genhdr-y += unistd_64.h
6genhdr-y += unistd_x32.h 6genhdr-y += unistd_x32.h
7header-y += a.out.h
8header-y += auxvec.h
9header-y += bitsperlong.h
10header-y += boot.h
11header-y += bootparam.h
12header-y += byteorder.h
13header-y += debugreg.h
14header-y += e820.h
15header-y += errno.h
16header-y += fcntl.h
17header-y += hw_breakpoint.h
18header-y += hyperv.h
19header-y += ioctl.h
20header-y += ioctls.h
21header-y += ipcbuf.h
22header-y += ist.h
23header-y += kvm.h
24header-y += kvm_para.h
25header-y += kvm_perf.h
26header-y += ldt.h
27header-y += mce.h
28header-y += mman.h
29header-y += msgbuf.h
30header-y += msr.h
31header-y += mtrr.h
32header-y += param.h
33header-y += perf_regs.h
34header-y += poll.h
35header-y += posix_types.h
36header-y += posix_types_32.h
37header-y += posix_types_64.h
38header-y += posix_types_x32.h
39header-y += prctl.h
40header-y += processor-flags.h
41header-y += ptrace-abi.h
42header-y += ptrace.h
43header-y += resource.h
44header-y += sembuf.h
45header-y += setup.h
46header-y += shmbuf.h
47header-y += sigcontext.h
48header-y += sigcontext32.h
49header-y += siginfo.h
50header-y += signal.h
51header-y += socket.h
52header-y += sockios.h
53header-y += stat.h
54header-y += statfs.h
55header-y += svm.h
56header-y += swab.h
57header-y += termbits.h
58header-y += termios.h
59header-y += types.h
60header-y += ucontext.h
61header-y += unistd.h
62header-y += vm86.h
63header-y += vmx.h
64header-y += vsyscall.h
diff --git a/arch/xtensa/include/uapi/asm/Kbuild b/arch/xtensa/include/uapi/asm/Kbuild
index 56aad54e7fb7..b15bf6bc0e94 100644
--- a/arch/xtensa/include/uapi/asm/Kbuild
+++ b/arch/xtensa/include/uapi/asm/Kbuild
@@ -1,25 +1,2 @@
1# UAPI Header export list 1# UAPI Header export list
2include include/uapi/asm-generic/Kbuild.asm 2include include/uapi/asm-generic/Kbuild.asm
3
4header-y += auxvec.h
5header-y += byteorder.h
6header-y += ioctls.h
7header-y += ipcbuf.h
8header-y += mman.h
9header-y += msgbuf.h
10header-y += param.h
11header-y += poll.h
12header-y += posix_types.h
13header-y += ptrace.h
14header-y += sembuf.h
15header-y += setup.h
16header-y += shmbuf.h
17header-y += sigcontext.h
18header-y += signal.h
19header-y += socket.h
20header-y += sockios.h
21header-y += stat.h
22header-y += swab.h
23header-y += termbits.h
24header-y += types.h
25header-y += unistd.h
diff --git a/include/Kbuild b/include/Kbuild
deleted file mode 100644
index bab1145bc7a7..000000000000
--- a/include/Kbuild
+++ /dev/null
@@ -1,2 +0,0 @@
1# Top-level Makefile calls into asm-$(ARCH)
2# List only non-arch directories below
diff --git a/include/asm-generic/Kbuild.asm b/include/asm-generic/Kbuild.asm
deleted file mode 100644
index d2ee86b4c091..000000000000
--- a/include/asm-generic/Kbuild.asm
+++ /dev/null
@@ -1 +0,0 @@
1include include/uapi/asm-generic/Kbuild.asm
diff --git a/include/scsi/fc/Kbuild b/include/scsi/fc/Kbuild
deleted file mode 100644
index e69de29bb2d1..000000000000
--- a/include/scsi/fc/Kbuild
+++ /dev/null
diff --git a/include/uapi/Kbuild b/include/uapi/Kbuild
deleted file mode 100644
index 245aa6e05e6a..000000000000
--- a/include/uapi/Kbuild
+++ /dev/null
@@ -1,15 +0,0 @@
1# UAPI Header export list
2# Top-level Makefile calls into asm-$(ARCH)
3# List only non-arch directories below
4
5
6header-y += asm-generic/
7header-y += linux/
8header-y += sound/
9header-y += mtd/
10header-y += rdma/
11header-y += video/
12header-y += drm/
13header-y += xen/
14header-y += scsi/
15header-y += misc/
diff --git a/include/uapi/asm-generic/Kbuild b/include/uapi/asm-generic/Kbuild
deleted file mode 100644
index b73de7bb7a62..000000000000
--- a/include/uapi/asm-generic/Kbuild
+++ /dev/null
@@ -1,36 +0,0 @@
1# UAPI Header export list
2header-y += auxvec.h
3header-y += bitsperlong.h
4header-y += errno-base.h
5header-y += errno.h
6header-y += fcntl.h
7header-y += int-l64.h
8header-y += int-ll64.h
9header-y += ioctl.h
10header-y += ioctls.h
11header-y += ipcbuf.h
12header-y += kvm_para.h
13header-y += mman-common.h
14header-y += mman.h
15header-y += msgbuf.h
16header-y += param.h
17header-y += poll.h
18header-y += posix_types.h
19header-y += resource.h
20header-y += sembuf.h
21header-y += setup.h
22header-y += shmbuf.h
23header-y += shmparam.h
24header-y += siginfo.h
25header-y += signal-defs.h
26header-y += signal.h
27header-y += socket.h
28header-y += sockios.h
29header-y += stat.h
30header-y += statfs.h
31header-y += swab.h
32header-y += termbits.h
33header-y += termios.h
34header-y += types.h
35header-y += ucontext.h
36header-y += unistd.h
diff --git a/include/uapi/asm-generic/Kbuild.asm b/include/uapi/asm-generic/Kbuild.asm
index fcd50b759217..21381449d98a 100644
--- a/include/uapi/asm-generic/Kbuild.asm
+++ b/include/uapi/asm-generic/Kbuild.asm
@@ -1,49 +1,33 @@
1# 1#
2# Headers that are optional in usr/include/asm/
3#
4opt-header += kvm.h
5opt-header += kvm_para.h
6opt-header += a.out.h
7
8#
9# Headers that are mandatory in usr/include/asm/ 2# Headers that are mandatory in usr/include/asm/
10# 3#
11header-y += auxvec.h 4mandatory-y += auxvec.h
12header-y += bitsperlong.h 5mandatory-y += bitsperlong.h
13header-y += byteorder.h 6mandatory-y += byteorder.h
14header-y += errno.h 7mandatory-y += errno.h
15header-y += fcntl.h 8mandatory-y += fcntl.h
16header-y += ioctl.h 9mandatory-y += ioctl.h
17header-y += ioctls.h 10mandatory-y += ioctls.h
18header-y += ipcbuf.h 11mandatory-y += ipcbuf.h
19header-y += mman.h 12mandatory-y += mman.h
20header-y += msgbuf.h 13mandatory-y += msgbuf.h
21header-y += param.h 14mandatory-y += param.h
22header-y += poll.h 15mandatory-y += poll.h
23header-y += posix_types.h 16mandatory-y += posix_types.h
24header-y += ptrace.h 17mandatory-y += ptrace.h
25header-y += resource.h 18mandatory-y += resource.h
26header-y += sembuf.h 19mandatory-y += sembuf.h
27header-y += setup.h 20mandatory-y += setup.h
28header-y += shmbuf.h 21mandatory-y += shmbuf.h
29header-y += sigcontext.h 22mandatory-y += sigcontext.h
30header-y += siginfo.h 23mandatory-y += siginfo.h
31header-y += signal.h 24mandatory-y += signal.h
32header-y += socket.h 25mandatory-y += socket.h
33header-y += sockios.h 26mandatory-y += sockios.h
34header-y += stat.h 27mandatory-y += stat.h
35header-y += statfs.h 28mandatory-y += statfs.h
36header-y += swab.h 29mandatory-y += swab.h
37header-y += termbits.h 30mandatory-y += termbits.h
38header-y += termios.h 31mandatory-y += termios.h
39header-y += types.h 32mandatory-y += types.h
40header-y += unistd.h 33mandatory-y += unistd.h
41
42header-y += $(foreach hdr,$(opt-header), \
43 $(if \
44 $(wildcard \
45 $(srctree)/arch/$(SRCARCH)/include/uapi/asm/$(hdr) \
46 $(srctree)/arch/$(SRCARCH)/include/asm/$(hdr) \
47 ), \
48 $(hdr) \
49 ))
diff --git a/include/uapi/drm/Kbuild b/include/uapi/drm/Kbuild
deleted file mode 100644
index c97addd08f8c..000000000000
--- a/include/uapi/drm/Kbuild
+++ /dev/null
@@ -1,23 +0,0 @@
1# UAPI Header export list
2header-y += drm.h
3header-y += drm_fourcc.h
4header-y += drm_mode.h
5header-y += drm_sarea.h
6header-y += amdgpu_drm.h
7header-y += exynos_drm.h
8header-y += i810_drm.h
9header-y += i915_drm.h
10header-y += mga_drm.h
11header-y += nouveau_drm.h
12header-y += omap_drm.h
13header-y += qxl_drm.h
14header-y += r128_drm.h
15header-y += radeon_drm.h
16header-y += savage_drm.h
17header-y += sis_drm.h
18header-y += tegra_drm.h
19header-y += via_drm.h
20header-y += vmwgfx_drm.h
21header-y += msm_drm.h
22header-y += vc4_drm.h
23header-y += virtgpu_drm.h
diff --git a/include/uapi/linux/Kbuild b/include/uapi/linux/Kbuild
index 662c592b74dd..ca2787d9bf0f 100644
--- a/include/uapi/linux/Kbuild
+++ b/include/uapi/linux/Kbuild
@@ -1,495 +1,13 @@
1# UAPI Header export list 1# UAPI Header export list
2header-y += android/
3header-y += byteorder/
4header-y += can/
5header-y += caif/
6header-y += dvb/
7header-y += hdlc/
8header-y += hsi/
9header-y += iio/
10header-y += isdn/
11header-y += mmc/
12header-y += nfsd/
13header-y += raid/
14header-y += spi/
15header-y += sunrpc/
16header-y += tc_act/
17header-y += tc_ematch/
18header-y += netfilter/
19header-y += netfilter_arp/
20header-y += netfilter_bridge/
21header-y += netfilter_ipv4/
22header-y += netfilter_ipv6/
23header-y += usb/
24header-y += wimax/
25 2
26genhdr-y += version.h 3ifeq ($(wildcard $(srctree)/arch/$(SRCARCH)/include/uapi/asm/a.out.h),)
27 4no-export-headers += a.out.h
28ifneq ($(wildcard $(srctree)/arch/$(SRCARCH)/include/uapi/asm/a.out.h \
29 $(srctree)/arch/$(SRCARCH)/include/asm/a.out.h),)
30header-y += a.out.h
31endif 5endif
32 6
33header-y += acct.h 7ifeq ($(wildcard $(srctree)/arch/$(SRCARCH)/include/uapi/asm/kvm.h),)
34header-y += adb.h 8no-export-headers += kvm.h
35header-y += adfs_fs.h
36header-y += affs_hardblocks.h
37header-y += agpgart.h
38header-y += aio_abi.h
39header-y += am437x-vpfe.h
40header-y += apm_bios.h
41header-y += arcfb.h
42header-y += atalk.h
43header-y += atmapi.h
44header-y += atmarp.h
45header-y += atmbr2684.h
46header-y += atmclip.h
47header-y += atmdev.h
48header-y += atm_eni.h
49header-y += atm.h
50header-y += atm_he.h
51header-y += atm_idt77105.h
52header-y += atmioc.h
53header-y += atmlec.h
54header-y += atmmpc.h
55header-y += atm_nicstar.h
56header-y += atmppp.h
57header-y += atmsap.h
58header-y += atmsvc.h
59header-y += atm_tcp.h
60header-y += atm_zatm.h
61header-y += audit.h
62header-y += auto_fs4.h
63header-y += auto_fs.h
64header-y += auxvec.h
65header-y += ax25.h
66header-y += b1lli.h
67header-y += batman_adv.h
68header-y += baycom.h
69header-y += bcm933xx_hcs.h
70header-y += bfs_fs.h
71header-y += binfmts.h
72header-y += blkpg.h
73header-y += blktrace_api.h
74header-y += blkzoned.h
75header-y += bpf_common.h
76header-y += bpf_perf_event.h
77header-y += bpf.h
78header-y += bpqether.h
79header-y += bsg.h
80header-y += bt-bmc.h
81header-y += btrfs.h
82header-y += can.h
83header-y += capability.h
84header-y += capi.h
85header-y += cciss_defs.h
86header-y += cciss_ioctl.h
87header-y += cdrom.h
88header-y += cec.h
89header-y += cec-funcs.h
90header-y += cgroupstats.h
91header-y += chio.h
92header-y += cm4000_cs.h
93header-y += cn_proc.h
94header-y += coda.h
95header-y += coda_psdev.h
96header-y += coff.h
97header-y += connector.h
98header-y += const.h
99header-y += cramfs_fs.h
100header-y += cuda.h
101header-y += cyclades.h
102header-y += cycx_cfm.h
103header-y += dcbnl.h
104header-y += dccp.h
105header-y += devlink.h
106header-y += dlmconstants.h
107header-y += dlm_device.h
108header-y += dlm.h
109header-y += dlm_netlink.h
110header-y += dlm_plock.h
111header-y += dm-ioctl.h
112header-y += dm-log-userspace.h
113header-y += dma-buf.h
114header-y += dn.h
115header-y += dqblk_xfs.h
116header-y += edd.h
117header-y += efs_fs_sb.h
118header-y += elfcore.h
119header-y += elf-em.h
120header-y += elf-fdpic.h
121header-y += elf.h
122header-y += errno.h
123header-y += errqueue.h
124header-y += ethtool.h
125header-y += eventpoll.h
126header-y += fadvise.h
127header-y += falloc.h
128header-y += fanotify.h
129header-y += fb.h
130header-y += fcntl.h
131header-y += fd.h
132header-y += fdreg.h
133header-y += fib_rules.h
134header-y += fiemap.h
135header-y += filter.h
136header-y += firewire-cdev.h
137header-y += firewire-constants.h
138header-y += flat.h
139header-y += fou.h
140header-y += fs.h
141header-y += fsl_hypervisor.h
142header-y += fuse.h
143header-y += futex.h
144header-y += gameport.h
145header-y += genetlink.h
146header-y += gen_stats.h
147header-y += gfs2_ondisk.h
148header-y += gigaset_dev.h
149header-y += gpio.h
150header-y += gsmmux.h
151header-y += gtp.h
152header-y += hdlcdrv.h
153header-y += hdlc.h
154header-y += hdreg.h
155header-y += hiddev.h
156header-y += hid.h
157header-y += hidraw.h
158header-y += hpet.h
159header-y += hsr_netlink.h
160header-y += hyperv.h
161header-y += hysdn_if.h
162header-y += i2c-dev.h
163header-y += i2c.h
164header-y += i2o-dev.h
165header-y += i8k.h
166header-y += icmp.h
167header-y += icmpv6.h
168header-y += if_addr.h
169header-y += if_addrlabel.h
170header-y += if_alg.h
171header-y += if_arcnet.h
172header-y += if_arp.h
173header-y += if_bonding.h
174header-y += if_bridge.h
175header-y += if_cablemodem.h
176header-y += if_eql.h
177header-y += if_ether.h
178header-y += if_fc.h
179header-y += if_fddi.h
180header-y += if_frad.h
181header-y += if.h
182header-y += if_hippi.h
183header-y += if_infiniband.h
184header-y += if_link.h
185header-y += if_ltalk.h
186header-y += if_macsec.h
187header-y += if_packet.h
188header-y += if_phonet.h
189header-y += if_plip.h
190header-y += if_ppp.h
191header-y += if_pppol2tp.h
192header-y += if_pppox.h
193header-y += if_slip.h
194header-y += if_team.h
195header-y += if_tun.h
196header-y += if_tunnel.h
197header-y += if_vlan.h
198header-y += if_x25.h
199header-y += ife.h
200header-y += igmp.h
201header-y += ila.h
202header-y += in6.h
203header-y += inet_diag.h
204header-y += in.h
205header-y += inotify.h
206header-y += input.h
207header-y += input-event-codes.h
208header-y += in_route.h
209header-y += ioctl.h
210header-y += ip6_tunnel.h
211header-y += ipc.h
212header-y += ip.h
213header-y += ipmi.h
214header-y += ipmi_msgdefs.h
215header-y += ipsec.h
216header-y += ipv6.h
217header-y += ipv6_route.h
218header-y += ip_vs.h
219header-y += ipx.h
220header-y += irda.h
221header-y += irqnr.h
222header-y += isdn_divertif.h
223header-y += isdn.h
224header-y += isdnif.h
225header-y += isdn_ppp.h
226header-y += iso_fs.h
227header-y += ivtvfb.h
228header-y += ivtv.h
229header-y += ixjuser.h
230header-y += jffs2.h
231header-y += joystick.h
232header-y += kcmp.h
233header-y += kdev_t.h
234header-y += kd.h
235header-y += kernelcapi.h
236header-y += kernel.h
237header-y += kernel-page-flags.h
238header-y += kexec.h
239header-y += keyboard.h
240header-y += keyctl.h
241
242ifneq ($(wildcard $(srctree)/arch/$(SRCARCH)/include/uapi/asm/kvm.h \
243 $(srctree)/arch/$(SRCARCH)/include/asm/kvm.h),)
244header-y += kvm.h
245endif 9endif
246 10
247 11ifeq ($(wildcard $(srctree)/arch/$(SRCARCH)/include/uapi/asm/kvm_para.h),)
248ifneq ($(wildcard $(srctree)/arch/$(SRCARCH)/include/uapi/asm/kvm_para.h \ 12no-export-headers += kvm_para.h
249 $(srctree)/arch/$(SRCARCH)/include/asm/kvm_para.h),)
250header-y += kvm_para.h
251endif 13endif
252
253header-y += hw_breakpoint.h
254header-y += l2tp.h
255header-y += libc-compat.h
256header-y += lirc.h
257header-y += limits.h
258header-y += llc.h
259header-y += loop.h
260header-y += lp.h
261header-y += lwtunnel.h
262header-y += magic.h
263header-y += major.h
264header-y += map_to_7segment.h
265header-y += matroxfb.h
266header-y += mdio.h
267header-y += media.h
268header-y += media-bus-format.h
269header-y += mei.h
270header-y += membarrier.h
271header-y += memfd.h
272header-y += mempolicy.h
273header-y += meye.h
274header-y += mic_common.h
275header-y += mic_ioctl.h
276header-y += mii.h
277header-y += minix_fs.h
278header-y += mman.h
279header-y += mmtimer.h
280header-y += mpls.h
281header-y += mpls_iptunnel.h
282header-y += mqueue.h
283header-y += mroute6.h
284header-y += mroute.h
285header-y += msdos_fs.h
286header-y += msg.h
287header-y += mtio.h
288header-y += nbd.h
289header-y += ncp_fs.h
290header-y += ncp.h
291header-y += ncp_mount.h
292header-y += ncp_no.h
293header-y += ndctl.h
294header-y += neighbour.h
295header-y += netconf.h
296header-y += netdevice.h
297header-y += net_dropmon.h
298header-y += netfilter_arp.h
299header-y += netfilter_bridge.h
300header-y += netfilter_decnet.h
301header-y += netfilter.h
302header-y += netfilter_ipv4.h
303header-y += netfilter_ipv6.h
304header-y += net.h
305header-y += netlink_diag.h
306header-y += netlink.h
307header-y += netrom.h
308header-y += net_namespace.h
309header-y += net_tstamp.h
310header-y += nfc.h
311header-y += psample.h
312header-y += nfs2.h
313header-y += nfs3.h
314header-y += nfs4.h
315header-y += nfs4_mount.h
316header-y += nfsacl.h
317header-y += nfs_fs.h
318header-y += nfs.h
319header-y += nfs_idmap.h
320header-y += nfs_mount.h
321header-y += nl80211.h
322header-y += n_r3964.h
323header-y += nubus.h
324header-y += nvme_ioctl.h
325header-y += nvram.h
326header-y += omap3isp.h
327header-y += omapfb.h
328header-y += oom.h
329header-y += openvswitch.h
330header-y += packet_diag.h
331header-y += param.h
332header-y += parport.h
333header-y += patchkey.h
334header-y += pci.h
335header-y += pci_regs.h
336header-y += pcitest.h
337header-y += perf_event.h
338header-y += personality.h
339header-y += pfkeyv2.h
340header-y += pg.h
341header-y += phantom.h
342header-y += phonet.h
343header-y += pktcdvd.h
344header-y += pkt_cls.h
345header-y += pkt_sched.h
346header-y += pmu.h
347header-y += poll.h
348header-y += posix_acl.h
349header-y += posix_acl_xattr.h
350header-y += posix_types.h
351header-y += ppdev.h
352header-y += ppp-comp.h
353header-y += ppp_defs.h
354header-y += ppp-ioctl.h
355header-y += pps.h
356header-y += prctl.h
357header-y += psci.h
358header-y += ptp_clock.h
359header-y += ptrace.h
360header-y += qnx4_fs.h
361header-y += qnxtypes.h
362header-y += quota.h
363header-y += radeonfb.h
364header-y += random.h
365header-y += raw.h
366header-y += rds.h
367header-y += reboot.h
368header-y += reiserfs_fs.h
369header-y += reiserfs_xattr.h
370header-y += resource.h
371header-y += rfkill.h
372header-y += rio_cm_cdev.h
373header-y += rio_mport_cdev.h
374header-y += romfs_fs.h
375header-y += rose.h
376header-y += route.h
377header-y += rtc.h
378header-y += rtnetlink.h
379header-y += scc.h
380header-y += sched.h
381header-y += scif_ioctl.h
382header-y += screen_info.h
383header-y += sctp.h
384header-y += sdla.h
385header-y += seccomp.h
386header-y += securebits.h
387header-y += seg6_genl.h
388header-y += seg6.h
389header-y += seg6_hmac.h
390header-y += seg6_iptunnel.h
391header-y += selinux_netlink.h
392header-y += sem.h
393header-y += serial_core.h
394header-y += serial.h
395header-y += serial_reg.h
396header-y += serio.h
397header-y += shm.h
398header-y += signalfd.h
399header-y += signal.h
400header-y += smiapp.h
401header-y += snmp.h
402header-y += sock_diag.h
403header-y += socket.h
404header-y += sockios.h
405header-y += sonet.h
406header-y += sonypi.h
407header-y += soundcard.h
408header-y += sound.h
409header-y += stat.h
410header-y += stddef.h
411header-y += string.h
412header-y += suspend_ioctls.h
413header-y += swab.h
414header-y += synclink.h
415header-y += sync_file.h
416header-y += sysctl.h
417header-y += sysinfo.h
418header-y += target_core_user.h
419header-y += taskstats.h
420header-y += tcp.h
421header-y += tcp_metrics.h
422header-y += telephony.h
423header-y += termios.h
424header-y += thermal.h
425header-y += time.h
426header-y += timerfd.h
427header-y += times.h
428header-y += timex.h
429header-y += tiocl.h
430header-y += tipc_config.h
431header-y += tipc_netlink.h
432header-y += tipc.h
433header-y += toshiba.h
434header-y += tty_flags.h
435header-y += tty.h
436header-y += types.h
437header-y += udf_fs_i.h
438header-y += udp.h
439header-y += uhid.h
440header-y += uinput.h
441header-y += uio.h
442header-y += uleds.h
443header-y += ultrasound.h
444header-y += un.h
445header-y += unistd.h
446header-y += unix_diag.h
447header-y += usbdevice_fs.h
448header-y += usbip.h
449header-y += userio.h
450header-y += utime.h
451header-y += utsname.h
452header-y += uuid.h
453header-y += uvcvideo.h
454header-y += v4l2-common.h
455header-y += v4l2-controls.h
456header-y += v4l2-dv-timings.h
457header-y += v4l2-mediabus.h
458header-y += v4l2-subdev.h
459header-y += veth.h
460header-y += vfio.h
461header-y += vhost.h
462header-y += videodev2.h
463header-y += virtio_9p.h
464header-y += virtio_balloon.h
465header-y += virtio_blk.h
466header-y += virtio_config.h
467header-y += virtio_console.h
468header-y += virtio_gpu.h
469header-y += virtio_ids.h
470header-y += virtio_input.h
471header-y += virtio_mmio.h
472header-y += virtio_net.h
473header-y += virtio_pci.h
474header-y += virtio_ring.h
475header-y += virtio_rng.h
476header-y += virtio_scsi.h
477header-y += virtio_types.h
478header-y += virtio_vsock.h
479header-y += virtio_crypto.h
480header-y += vm_sockets.h
481header-y += vsockmon.h
482header-y += vt.h
483header-y += vtpm_proxy.h
484header-y += wait.h
485header-y += wanrouter.h
486header-y += watchdog.h
487header-y += wimax.h
488header-y += wireless.h
489header-y += x25.h
490header-y += xattr.h
491header-y += xfrm.h
492header-y += xilinx-v4l2-controls.h
493header-y += zorro.h
494header-y += zorro_ids.h
495header-y += userfaultfd.h
diff --git a/include/uapi/linux/android/Kbuild b/include/uapi/linux/android/Kbuild
deleted file mode 100644
index ca011eec252a..000000000000
--- a/include/uapi/linux/android/Kbuild
+++ /dev/null
@@ -1,2 +0,0 @@
1# UAPI Header export list
2header-y += binder.h
diff --git a/include/uapi/linux/byteorder/Kbuild b/include/uapi/linux/byteorder/Kbuild
deleted file mode 100644
index 619225b9ff2e..000000000000
--- a/include/uapi/linux/byteorder/Kbuild
+++ /dev/null
@@ -1,3 +0,0 @@
1# UAPI Header export list
2header-y += big_endian.h
3header-y += little_endian.h
diff --git a/include/uapi/linux/caif/Kbuild b/include/uapi/linux/caif/Kbuild
deleted file mode 100644
index 43396612d3a3..000000000000
--- a/include/uapi/linux/caif/Kbuild
+++ /dev/null
@@ -1,3 +0,0 @@
1# UAPI Header export list
2header-y += caif_socket.h
3header-y += if_caif.h
diff --git a/include/uapi/linux/can/Kbuild b/include/uapi/linux/can/Kbuild
deleted file mode 100644
index 21c91bf25a29..000000000000
--- a/include/uapi/linux/can/Kbuild
+++ /dev/null
@@ -1,6 +0,0 @@
1# UAPI Header export list
2header-y += bcm.h
3header-y += error.h
4header-y += gw.h
5header-y += netlink.h
6header-y += raw.h
diff --git a/include/uapi/linux/dvb/Kbuild b/include/uapi/linux/dvb/Kbuild
deleted file mode 100644
index d40942cfc627..000000000000
--- a/include/uapi/linux/dvb/Kbuild
+++ /dev/null
@@ -1,9 +0,0 @@
1# UAPI Header export list
2header-y += audio.h
3header-y += ca.h
4header-y += dmx.h
5header-y += frontend.h
6header-y += net.h
7header-y += osd.h
8header-y += version.h
9header-y += video.h
diff --git a/include/uapi/linux/hdlc/Kbuild b/include/uapi/linux/hdlc/Kbuild
deleted file mode 100644
index 8c1d2cb75e33..000000000000
--- a/include/uapi/linux/hdlc/Kbuild
+++ /dev/null
@@ -1,2 +0,0 @@
1# UAPI Header export list
2header-y += ioctl.h
diff --git a/include/uapi/linux/hsi/Kbuild b/include/uapi/linux/hsi/Kbuild
deleted file mode 100644
index a16a00544258..000000000000
--- a/include/uapi/linux/hsi/Kbuild
+++ /dev/null
@@ -1,2 +0,0 @@
1# UAPI Header export list
2header-y += hsi_char.h cs-protocol.h
diff --git a/include/uapi/linux/iio/Kbuild b/include/uapi/linux/iio/Kbuild
deleted file mode 100644
index 86f76d84c44f..000000000000
--- a/include/uapi/linux/iio/Kbuild
+++ /dev/null
@@ -1,3 +0,0 @@
1# UAPI Header export list
2header-y += events.h
3header-y += types.h
diff --git a/include/uapi/linux/isdn/Kbuild b/include/uapi/linux/isdn/Kbuild
deleted file mode 100644
index 89e52850bf29..000000000000
--- a/include/uapi/linux/isdn/Kbuild
+++ /dev/null
@@ -1,2 +0,0 @@
1# UAPI Header export list
2header-y += capicmd.h
diff --git a/include/uapi/linux/mmc/Kbuild b/include/uapi/linux/mmc/Kbuild
deleted file mode 100644
index 8c1d2cb75e33..000000000000
--- a/include/uapi/linux/mmc/Kbuild
+++ /dev/null
@@ -1,2 +0,0 @@
1# UAPI Header export list
2header-y += ioctl.h
diff --git a/include/uapi/linux/netfilter/Kbuild b/include/uapi/linux/netfilter/Kbuild
deleted file mode 100644
index 03f194aeadc5..000000000000
--- a/include/uapi/linux/netfilter/Kbuild
+++ /dev/null
@@ -1,89 +0,0 @@
1# UAPI Header export list
2header-y += ipset/
3header-y += nf_conntrack_common.h
4header-y += nf_conntrack_ftp.h
5header-y += nf_conntrack_sctp.h
6header-y += nf_conntrack_tcp.h
7header-y += nf_conntrack_tuple_common.h
8header-y += nf_log.h
9header-y += nf_tables.h
10header-y += nf_tables_compat.h
11header-y += nf_nat.h
12header-y += nfnetlink.h
13header-y += nfnetlink_acct.h
14header-y += nfnetlink_compat.h
15header-y += nfnetlink_conntrack.h
16header-y += nfnetlink_cthelper.h
17header-y += nfnetlink_cttimeout.h
18header-y += nfnetlink_log.h
19header-y += nfnetlink_queue.h
20header-y += x_tables.h
21header-y += xt_AUDIT.h
22header-y += xt_CHECKSUM.h
23header-y += xt_CLASSIFY.h
24header-y += xt_CONNMARK.h
25header-y += xt_CONNSECMARK.h
26header-y += xt_CT.h
27header-y += xt_DSCP.h
28header-y += xt_HMARK.h
29header-y += xt_IDLETIMER.h
30header-y += xt_LED.h
31header-y += xt_LOG.h
32header-y += xt_MARK.h
33header-y += xt_NFLOG.h
34header-y += xt_NFQUEUE.h
35header-y += xt_RATEEST.h
36header-y += xt_SECMARK.h
37header-y += xt_SYNPROXY.h
38header-y += xt_TCPMSS.h
39header-y += xt_TCPOPTSTRIP.h
40header-y += xt_TEE.h
41header-y += xt_TPROXY.h
42header-y += xt_addrtype.h
43header-y += xt_bpf.h
44header-y += xt_cgroup.h
45header-y += xt_cluster.h
46header-y += xt_comment.h
47header-y += xt_connbytes.h
48header-y += xt_connlabel.h
49header-y += xt_connlimit.h
50header-y += xt_connmark.h
51header-y += xt_conntrack.h
52header-y += xt_cpu.h
53header-y += xt_dccp.h
54header-y += xt_devgroup.h
55header-y += xt_dscp.h
56header-y += xt_ecn.h
57header-y += xt_esp.h
58header-y += xt_hashlimit.h
59header-y += xt_helper.h
60header-y += xt_ipcomp.h
61header-y += xt_iprange.h
62header-y += xt_ipvs.h
63header-y += xt_l2tp.h
64header-y += xt_length.h
65header-y += xt_limit.h
66header-y += xt_mac.h
67header-y += xt_mark.h
68header-y += xt_multiport.h
69header-y += xt_nfacct.h
70header-y += xt_osf.h
71header-y += xt_owner.h
72header-y += xt_physdev.h
73header-y += xt_pkttype.h
74header-y += xt_policy.h
75header-y += xt_quota.h
76header-y += xt_rateest.h
77header-y += xt_realm.h
78header-y += xt_recent.h
79header-y += xt_rpfilter.h
80header-y += xt_sctp.h
81header-y += xt_set.h
82header-y += xt_socket.h
83header-y += xt_state.h
84header-y += xt_statistic.h
85header-y += xt_string.h
86header-y += xt_tcpmss.h
87header-y += xt_tcpudp.h
88header-y += xt_time.h
89header-y += xt_u32.h
diff --git a/include/uapi/linux/netfilter/ipset/Kbuild b/include/uapi/linux/netfilter/ipset/Kbuild
deleted file mode 100644
index d2680423d9ab..000000000000
--- a/include/uapi/linux/netfilter/ipset/Kbuild
+++ /dev/null
@@ -1,5 +0,0 @@
1# UAPI Header export list
2header-y += ip_set.h
3header-y += ip_set_bitmap.h
4header-y += ip_set_hash.h
5header-y += ip_set_list.h
diff --git a/include/uapi/linux/netfilter_arp/Kbuild b/include/uapi/linux/netfilter_arp/Kbuild
deleted file mode 100644
index 62d5637cc0ac..000000000000
--- a/include/uapi/linux/netfilter_arp/Kbuild
+++ /dev/null
@@ -1,3 +0,0 @@
1# UAPI Header export list
2header-y += arp_tables.h
3header-y += arpt_mangle.h
diff --git a/include/uapi/linux/netfilter_bridge/Kbuild b/include/uapi/linux/netfilter_bridge/Kbuild
deleted file mode 100644
index 0fbad8ef96de..000000000000
--- a/include/uapi/linux/netfilter_bridge/Kbuild
+++ /dev/null
@@ -1,18 +0,0 @@
1# UAPI Header export list
2header-y += ebt_802_3.h
3header-y += ebt_among.h
4header-y += ebt_arp.h
5header-y += ebt_arpreply.h
6header-y += ebt_ip.h
7header-y += ebt_ip6.h
8header-y += ebt_limit.h
9header-y += ebt_log.h
10header-y += ebt_mark_m.h
11header-y += ebt_mark_t.h
12header-y += ebt_nat.h
13header-y += ebt_nflog.h
14header-y += ebt_pkttype.h
15header-y += ebt_redirect.h
16header-y += ebt_stp.h
17header-y += ebt_vlan.h
18header-y += ebtables.h
diff --git a/include/uapi/linux/netfilter_ipv4/Kbuild b/include/uapi/linux/netfilter_ipv4/Kbuild
deleted file mode 100644
index ecb291df390e..000000000000
--- a/include/uapi/linux/netfilter_ipv4/Kbuild
+++ /dev/null
@@ -1,10 +0,0 @@
1# UAPI Header export list
2header-y += ip_tables.h
3header-y += ipt_CLUSTERIP.h
4header-y += ipt_ECN.h
5header-y += ipt_LOG.h
6header-y += ipt_REJECT.h
7header-y += ipt_TTL.h
8header-y += ipt_ah.h
9header-y += ipt_ecn.h
10header-y += ipt_ttl.h
diff --git a/include/uapi/linux/netfilter_ipv6/Kbuild b/include/uapi/linux/netfilter_ipv6/Kbuild
deleted file mode 100644
index 75a668ca2353..000000000000
--- a/include/uapi/linux/netfilter_ipv6/Kbuild
+++ /dev/null
@@ -1,13 +0,0 @@
1# UAPI Header export list
2header-y += ip6_tables.h
3header-y += ip6t_HL.h
4header-y += ip6t_LOG.h
5header-y += ip6t_NPT.h
6header-y += ip6t_REJECT.h
7header-y += ip6t_ah.h
8header-y += ip6t_frag.h
9header-y += ip6t_hl.h
10header-y += ip6t_ipv6header.h
11header-y += ip6t_mh.h
12header-y += ip6t_opts.h
13header-y += ip6t_rt.h
diff --git a/include/uapi/linux/nfsd/Kbuild b/include/uapi/linux/nfsd/Kbuild
deleted file mode 100644
index c11bc404053c..000000000000
--- a/include/uapi/linux/nfsd/Kbuild
+++ /dev/null
@@ -1,6 +0,0 @@
1# UAPI Header export list
2header-y += cld.h
3header-y += debug.h
4header-y += export.h
5header-y += nfsfh.h
6header-y += stats.h
diff --git a/include/uapi/linux/raid/Kbuild b/include/uapi/linux/raid/Kbuild
deleted file mode 100644
index e2c3d25405d7..000000000000
--- a/include/uapi/linux/raid/Kbuild
+++ /dev/null
@@ -1,3 +0,0 @@
1# UAPI Header export list
2header-y += md_p.h
3header-y += md_u.h
diff --git a/include/uapi/linux/spi/Kbuild b/include/uapi/linux/spi/Kbuild
deleted file mode 100644
index 0cc747eff165..000000000000
--- a/include/uapi/linux/spi/Kbuild
+++ /dev/null
@@ -1,2 +0,0 @@
1# UAPI Header export list
2header-y += spidev.h
diff --git a/include/uapi/linux/sunrpc/Kbuild b/include/uapi/linux/sunrpc/Kbuild
deleted file mode 100644
index 8e02e47c20fb..000000000000
--- a/include/uapi/linux/sunrpc/Kbuild
+++ /dev/null
@@ -1,2 +0,0 @@
1# UAPI Header export list
2header-y += debug.h
diff --git a/include/uapi/linux/tc_act/Kbuild b/include/uapi/linux/tc_act/Kbuild
deleted file mode 100644
index ba62ddf0e58a..000000000000
--- a/include/uapi/linux/tc_act/Kbuild
+++ /dev/null
@@ -1,16 +0,0 @@
1# UAPI Header export list
2header-y += tc_csum.h
3header-y += tc_defact.h
4header-y += tc_gact.h
5header-y += tc_ipt.h
6header-y += tc_mirred.h
7header-y += tc_sample.h
8header-y += tc_nat.h
9header-y += tc_pedit.h
10header-y += tc_skbedit.h
11header-y += tc_vlan.h
12header-y += tc_bpf.h
13header-y += tc_connmark.h
14header-y += tc_ife.h
15header-y += tc_tunnel_key.h
16header-y += tc_skbmod.h
diff --git a/include/uapi/linux/tc_ematch/Kbuild b/include/uapi/linux/tc_ematch/Kbuild
deleted file mode 100644
index 53fca3925535..000000000000
--- a/include/uapi/linux/tc_ematch/Kbuild
+++ /dev/null
@@ -1,5 +0,0 @@
1# UAPI Header export list
2header-y += tc_em_cmp.h
3header-y += tc_em_meta.h
4header-y += tc_em_nbyte.h
5header-y += tc_em_text.h
diff --git a/include/uapi/linux/usb/Kbuild b/include/uapi/linux/usb/Kbuild
deleted file mode 100644
index 4cc4d6e7e523..000000000000
--- a/include/uapi/linux/usb/Kbuild
+++ /dev/null
@@ -1,12 +0,0 @@
1# UAPI Header export list
2header-y += audio.h
3header-y += cdc.h
4header-y += cdc-wdm.h
5header-y += ch11.h
6header-y += ch9.h
7header-y += functionfs.h
8header-y += g_printer.h
9header-y += gadgetfs.h
10header-y += midi.h
11header-y += tmc.h
12header-y += video.h
diff --git a/include/uapi/linux/wimax/Kbuild b/include/uapi/linux/wimax/Kbuild
deleted file mode 100644
index 1c97be49971f..000000000000
--- a/include/uapi/linux/wimax/Kbuild
+++ /dev/null
@@ -1,2 +0,0 @@
1# UAPI Header export list
2header-y += i2400m.h
diff --git a/include/uapi/misc/Kbuild b/include/uapi/misc/Kbuild
deleted file mode 100644
index e96cae7d58c9..000000000000
--- a/include/uapi/misc/Kbuild
+++ /dev/null
@@ -1,2 +0,0 @@
1# misc Header export list
2header-y += cxl.h
diff --git a/include/uapi/mtd/Kbuild b/include/uapi/mtd/Kbuild
deleted file mode 100644
index 5a691e10cd0e..000000000000
--- a/include/uapi/mtd/Kbuild
+++ /dev/null
@@ -1,6 +0,0 @@
1# UAPI Header export list
2header-y += inftl-user.h
3header-y += mtd-abi.h
4header-y += mtd-user.h
5header-y += nftl-user.h
6header-y += ubi-user.h
diff --git a/include/uapi/rdma/Kbuild b/include/uapi/rdma/Kbuild
deleted file mode 100644
index 1e0af1ff75c3..000000000000
--- a/include/uapi/rdma/Kbuild
+++ /dev/null
@@ -1,20 +0,0 @@
1# UAPI Header export list
2header-y += ib_user_cm.h
3header-y += rdma_user_ioctl.h
4header-y += ib_user_mad.h
5header-y += ib_user_sa.h
6header-y += ib_user_verbs.h
7header-y += rdma_netlink.h
8header-y += rdma_user_cm.h
9header-y += hfi/
10header-y += rdma_user_rxe.h
11header-y += cxgb3-abi.h
12header-y += cxgb4-abi.h
13header-y += mlx4-abi.h
14header-y += mlx5-abi.h
15header-y += mthca-abi.h
16header-y += nes-abi.h
17header-y += ocrdma-abi.h
18header-y += hns-abi.h
19header-y += vmw_pvrdma-abi.h
20header-y += qedr-abi.h
diff --git a/include/uapi/rdma/hfi/Kbuild b/include/uapi/rdma/hfi/Kbuild
deleted file mode 100644
index b65b0b3a5f63..000000000000
--- a/include/uapi/rdma/hfi/Kbuild
+++ /dev/null
@@ -1,3 +0,0 @@
1# UAPI Header export list
2header-y += hfi1_user.h
3header-y += hfi1_ioctl.h
diff --git a/include/uapi/scsi/Kbuild b/include/uapi/scsi/Kbuild
deleted file mode 100644
index d791e0ad509d..000000000000
--- a/include/uapi/scsi/Kbuild
+++ /dev/null
@@ -1,6 +0,0 @@
1# UAPI Header export list
2header-y += fc/
3header-y += scsi_bsg_fc.h
4header-y += scsi_netlink.h
5header-y += scsi_netlink_fc.h
6header-y += cxlflash_ioctl.h
diff --git a/include/uapi/scsi/fc/Kbuild b/include/uapi/scsi/fc/Kbuild
deleted file mode 100644
index 5ead9fac265c..000000000000
--- a/include/uapi/scsi/fc/Kbuild
+++ /dev/null
@@ -1,5 +0,0 @@
1# UAPI Header export list
2header-y += fc_els.h
3header-y += fc_fs.h
4header-y += fc_gs.h
5header-y += fc_ns.h
diff --git a/include/uapi/sound/Kbuild b/include/uapi/sound/Kbuild
deleted file mode 100644
index 9578d8bdbf31..000000000000
--- a/include/uapi/sound/Kbuild
+++ /dev/null
@@ -1,16 +0,0 @@
1# UAPI Header export list
2header-y += asequencer.h
3header-y += asoc.h
4header-y += asound.h
5header-y += asound_fm.h
6header-y += compress_offload.h
7header-y += compress_params.h
8header-y += emu10k1.h
9header-y += firewire.h
10header-y += hdsp.h
11header-y += hdspm.h
12header-y += sb16_csp.h
13header-y += sfnt_info.h
14header-y += tlv.h
15header-y += usb_stream.h
16header-y += snd_sst_tokens.h
diff --git a/include/uapi/video/Kbuild b/include/uapi/video/Kbuild
deleted file mode 100644
index ac7203bb32cc..000000000000
--- a/include/uapi/video/Kbuild
+++ /dev/null
@@ -1,4 +0,0 @@
1# UAPI Header export list
2header-y += edid.h
3header-y += sisfb.h
4header-y += uvesafb.h
diff --git a/include/uapi/xen/Kbuild b/include/uapi/xen/Kbuild
deleted file mode 100644
index 5c459628e8c7..000000000000
--- a/include/uapi/xen/Kbuild
+++ /dev/null
@@ -1,5 +0,0 @@
1# UAPI Header export list
2header-y += evtchn.h
3header-y += gntalloc.h
4header-y += gntdev.h
5header-y += privcmd.h
diff --git a/include/video/Kbuild b/include/video/Kbuild
deleted file mode 100644
index e69de29bb2d1..000000000000
--- a/include/video/Kbuild
+++ /dev/null
diff --git a/scripts/Makefile.headersinst b/scripts/Makefile.headersinst
index ca5d439c9abf..20be1fbc19cc 100644
--- a/scripts/Makefile.headersinst
+++ b/scripts/Makefile.headersinst
@@ -1,17 +1,19 @@
1# ========================================================================== 1# ==========================================================================
2# Installing headers 2# Installing headers
3# 3#
4# header-y - list files to be installed. They are preprocessed 4# All headers under include/uapi, include/generated/uapi,
5# to remove __KERNEL__ section of the file 5# arch/<arch>/include/uapi/asm and arch/<arch>/include/generated/uapi/asm are
6# genhdr-y - Same as header-y but in a generated/ directory 6# exported.
7# They are preprocessed to remove __KERNEL__ section of the file.
7# 8#
8# ========================================================================== 9# ==========================================================================
9 10
10# generated header directory 11# generated header directory
11gen := $(if $(gen),$(gen),$(subst include/,include/generated/,$(obj))) 12gen := $(if $(gen),$(gen),$(subst include/,include/generated/,$(obj)))
12 13
14# Kbuild file is optional
13kbuild-file := $(srctree)/$(obj)/Kbuild 15kbuild-file := $(srctree)/$(obj)/Kbuild
14include $(kbuild-file) 16-include $(kbuild-file)
15 17
16# called may set destination dir (when installing to asm/) 18# called may set destination dir (when installing to asm/)
17_dst := $(if $(dst),$(dst),$(obj)) 19_dst := $(if $(dst),$(dst),$(obj))
@@ -25,9 +27,15 @@ include scripts/Kbuild.include
25 27
26installdir := $(INSTALL_HDR_PATH)/$(subst uapi/,,$(_dst)) 28installdir := $(INSTALL_HDR_PATH)/$(subst uapi/,,$(_dst))
27 29
28header-y := $(sort $(header-y)) 30srcdir := $(srctree)/$(obj)
29subdirs := $(patsubst %/,%,$(filter %/, $(header-y))) 31gendir := $(objtree)/$(gen)
30header-y := $(filter-out %/, $(header-y)) 32subdirs := $(patsubst $(srcdir)/%/.,%,$(wildcard $(srcdir)/*/.))
33subdirs += $(subdir-y)
34header-files := $(notdir $(wildcard $(srcdir)/*.h))
35header-files += $(notdir $(wildcard $(srcdir)/*.agh))
36header-files := $(filter-out $(no-export-headers), $(header-files))
37genhdr-files := $(notdir $(wildcard $(gendir)/*.h))
38genhdr-files := $(filter-out $(header-files), $(genhdr-files))
31 39
32# files used to track state of install/check 40# files used to track state of install/check
33install-file := $(installdir)/.install 41install-file := $(installdir)/.install
@@ -35,25 +43,20 @@ check-file := $(installdir)/.check
35 43
36# generic-y list all files an architecture uses from asm-generic 44# generic-y list all files an architecture uses from asm-generic
37# Use this to build a list of headers which require a wrapper 45# Use this to build a list of headers which require a wrapper
38wrapper-files := $(filter $(header-y), $(generic-y)) 46generic-files := $(notdir $(wildcard $(srctree)/include/uapi/asm-generic/*.h))
39 47wrapper-files := $(filter $(generic-files), $(generic-y))
40srcdir := $(srctree)/$(obj) 48wrapper-files := $(filter-out $(header-files), $(wrapper-files))
41gendir := $(objtree)/$(gen)
42 49
43# all headers files for this dir 50# all headers files for this dir
44header-y := $(filter-out $(generic-y), $(header-y)) 51all-files := $(header-files) $(genhdr-files) $(wrapper-files)
45all-files := $(header-y) $(genhdr-y) $(wrapper-files)
46output-files := $(addprefix $(installdir)/, $(all-files)) 52output-files := $(addprefix $(installdir)/, $(all-files))
47 53
48# Check that all expected files exist 54ifneq ($(mandatory-y),)
49$(foreach hdr, $(header-y), \ 55missing := $(filter-out $(all-files),$(mandatory-y))
50 $(if $(wildcard $(srcdir)/$(hdr)),, \ 56ifneq ($(missing),)
51 $(error Missing UAPI file $(srcdir)/$(hdr)) \ 57$(error Some mandatory headers ($(missing)) are missing in $(obj))
52 )) 58endif
53$(foreach hdr, $(genhdr-y), \ 59endif
54 $(if $(wildcard $(gendir)/$(hdr)),, \
55 $(error Missing generated UAPI file $(gendir)/$(hdr)) \
56 ))
57 60
58# Work out what needs to be removed 61# Work out what needs to be removed
59oldheaders := $(patsubst $(installdir)/%,%,$(wildcard $(installdir)/*.h)) 62oldheaders := $(patsubst $(installdir)/%,%,$(wildcard $(installdir)/*.h))
@@ -67,8 +70,8 @@ printdir = $(patsubst $(INSTALL_HDR_PATH)/%/,%,$(dir $@))
67quiet_cmd_install = INSTALL $(printdir) ($(words $(all-files))\ 70quiet_cmd_install = INSTALL $(printdir) ($(words $(all-files))\
68 file$(if $(word 2, $(all-files)),s)) 71 file$(if $(word 2, $(all-files)),s))
69 cmd_install = \ 72 cmd_install = \
70 $(CONFIG_SHELL) $< $(installdir) $(srcdir) $(header-y); \ 73 $(CONFIG_SHELL) $< $(installdir) $(srcdir) $(header-files); \
71 $(CONFIG_SHELL) $< $(installdir) $(gendir) $(genhdr-y); \ 74 $(CONFIG_SHELL) $< $(installdir) $(gendir) $(genhdr-files); \
72 for F in $(wrapper-files); do \ 75 for F in $(wrapper-files); do \
73 echo "\#include <asm-generic/$$F>" > $(installdir)/$$F; \ 76 echo "\#include <asm-generic/$$F>" > $(installdir)/$$F; \
74 done; \ 77 done; \
@@ -95,8 +98,8 @@ __headersinst: $(subdirs) $(install-file)
95 98
96targets += $(install-file) 99targets += $(install-file)
97$(install-file): scripts/headers_install.sh \ 100$(install-file): scripts/headers_install.sh \
98 $(addprefix $(srcdir)/,$(header-y)) \ 101 $(addprefix $(srcdir)/,$(header-files)) \
99 $(addprefix $(gendir)/,$(genhdr-y)) FORCE 102 $(addprefix $(gendir)/,$(genhdr-files)) FORCE
100 $(if $(unwanted),$(call cmd,remove),) 103 $(if $(unwanted),$(call cmd,remove),)
101 $(if $(wildcard $(dir $@)),,$(shell mkdir -p $(dir $@))) 104 $(if $(wildcard $(dir $@)),,$(shell mkdir -p $(dir $@)))
102 $(call if_changed,install) 105 $(call if_changed,install)