summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorLinus Torvalds <torvalds@linux-foundation.org>2019-05-19 11:53:58 -0700
committerLinus Torvalds <torvalds@linux-foundation.org>2019-05-19 11:53:58 -0700
commitff8583d6e4e33fe3856a609095c683d5dbe39120 (patch)
treea010fef192358dd3693bb0513d7b4191dd83430f
parentf23d8719e76fd32828ae6f1b55e4659144467742 (diff)
parentfc2694ec1ab7c805505bef2752aca56977a22abd (diff)
Merge tag 'kbuild-v5.2-2' of git://git.kernel.org/pub/scm/linux/kernel/git/masahiroy/linux-kbuild
Pull more Kbuild updates from Masahiro Yamada: - remove unneeded use of cc-option, cc-disable-warning, cc-ldoption - exclude tracked files from .gitignore - re-enable -Wint-in-bool-context warning - refactor samples/Makefile - stop building immediately if syncconfig fails - do not sprinkle error messages when $(CC) does not exist - move arch/alpha/defconfig to the configs subdirectory - remove crappy header search path manipulation - add comment lines to .config to clarify the end of menu blocks - check uniqueness of module names (adding new warnings intentionally) * tag 'kbuild-v5.2-2' of git://git.kernel.org/pub/scm/linux/kernel/git/masahiroy/linux-kbuild: (24 commits) kconfig: use 'else ifneq' for Makefile to improve readability kbuild: check uniqueness of module names kconfig: Terminate menu blocks with a comment in the generated config kbuild: add LICENSES to KBUILD_ALLDIRS kbuild: remove 'addtree' and 'flags' magic for header search paths treewide: prefix header search paths with $(srctree)/ media: prefix header search paths with $(srctree)/ media: remove unneeded header search paths alpha: move arch/alpha/defconfig to arch/alpha/configs/defconfig kbuild: terminate Kconfig when $(CC) or $(LD) is missing kbuild: turn auto.conf.cmd into a mandatory include file .gitignore: exclude .get_maintainer.ignore and .gitattributes kbuild: add all Clang-specific flags unconditionally kbuild: Don't try to add '-fcatch-undefined-behavior' flag kbuild: add some extra warning flags unconditionally kbuild: add -Wvla flag unconditionally arch: remove dangling asm-generic wrappers samples: guard sub-directories with CONFIG options kbuild: re-enable int-in-bool-context warning MAINTAINERS: kbuild: Add pattern for scripts/*vmlinux* ...
-rw-r--r--.gitignore8
-rw-r--r--MAINTAINERS1
-rw-r--r--Makefile21
-rw-r--r--arch/alpha/Makefile2
-rw-r--r--arch/alpha/configs/defconfig (renamed from arch/alpha/defconfig)0
l---------arch/csky/boot/dts/include/dt-bindings1
-rw-r--r--arch/csky/include/asm/Kbuild4
-rw-r--r--arch/h8300/include/asm/Kbuild1
-rw-r--r--arch/ia64/kernel/Makefile.gate2
-rw-r--r--arch/mips/pnx833x/Platform2
-rw-r--r--arch/nds32/include/asm/Kbuild3
-rw-r--r--arch/powerpc/Makefile2
-rw-r--r--arch/riscv/include/asm/Kbuild4
-rw-r--r--arch/sh/Makefile4
-rw-r--r--arch/sh/boot/.gitignore1
-rw-r--r--arch/sh/kernel/vsyscall/Makefile3
-rw-r--r--arch/x86/kernel/Makefile2
-rw-r--r--arch/x86/mm/Makefile2
-rw-r--r--arch/xtensa/boot/lib/Makefile2
-rw-r--r--arch/xtensa/include/asm/Kbuild1
-rw-r--r--drivers/hid/intel-ish-hid/Makefile2
-rw-r--r--drivers/media/common/b2c2/Makefile4
-rw-r--r--drivers/media/dvb-frontends/cxd2880/Makefile2
-rw-r--r--drivers/media/i2c/smiapp/Makefile2
-rw-r--r--drivers/media/mmc/siano/Makefile3
-rw-r--r--drivers/media/pci/b2c2/Makefile2
-rw-r--r--drivers/media/pci/bt8xx/Makefile5
-rw-r--r--drivers/media/pci/cx18/Makefile4
-rw-r--r--drivers/media/pci/cx23885/Makefile4
-rw-r--r--drivers/media/pci/cx88/Makefile4
-rw-r--r--drivers/media/pci/ddbridge/Makefile4
-rw-r--r--drivers/media/pci/dm1105/Makefile2
-rw-r--r--drivers/media/pci/mantis/Makefile2
-rw-r--r--drivers/media/pci/netup_unidvb/Makefile2
-rw-r--r--drivers/media/pci/ngene/Makefile4
-rw-r--r--drivers/media/pci/pluto2/Makefile2
-rw-r--r--drivers/media/pci/pt1/Makefile4
-rw-r--r--drivers/media/pci/pt3/Makefile4
-rw-r--r--drivers/media/pci/smipcie/Makefile5
-rw-r--r--drivers/media/pci/ttpci/Makefile4
-rw-r--r--drivers/media/platform/sti/c8sectpfe/Makefile5
-rw-r--r--drivers/media/radio/Makefile2
-rw-r--r--drivers/media/spi/Makefile4
-rw-r--r--drivers/media/usb/as102/Makefile2
-rw-r--r--drivers/media/usb/au0828/Makefile4
-rw-r--r--drivers/media/usb/b2c2/Makefile2
-rw-r--r--drivers/media/usb/cx231xx/Makefile5
-rw-r--r--drivers/media/usb/em28xx/Makefile4
-rw-r--r--drivers/media/usb/go7007/Makefile2
-rw-r--r--drivers/media/usb/pvrusb2/Makefile4
-rw-r--r--drivers/media/usb/siano/Makefile2
-rw-r--r--drivers/media/usb/tm6000/Makefile4
-rw-r--r--drivers/media/usb/ttusb-budget/Makefile2
-rw-r--r--drivers/media/usb/usbvision/Makefile2
-rw-r--r--drivers/net/ethernet/chelsio/libcxgb/Makefile2
-rw-r--r--drivers/target/iscsi/cxgbit/Makefile6
-rw-r--r--drivers/usb/storage/Makefile2
-rw-r--r--fs/ocfs2/dlm/Makefile3
-rw-r--r--fs/ocfs2/dlmfs/Makefile2
-rw-r--r--fs/xfs/Makefile4
-rw-r--r--net/bpfilter/Makefile2
-rw-r--r--samples/Makefile24
-rw-r--r--samples/seccomp/Makefile2
-rw-r--r--samples/vfs/Makefile2
-rw-r--r--scripts/Kbuild.include8
-rw-r--r--scripts/Kconfig.include8
-rw-r--r--scripts/Makefile.extrawarn25
-rw-r--r--scripts/Makefile.host12
-rw-r--r--scripts/Makefile.lib26
-rw-r--r--scripts/dtc/Makefile6
-rw-r--r--scripts/genksyms/Makefile4
-rw-r--r--scripts/kconfig/Makefile8
-rw-r--r--scripts/kconfig/confdata.c13
-rwxr-xr-xscripts/modules-check.sh16
74 files changed, 178 insertions, 172 deletions
diff --git a/.gitignore b/.gitignore
index d263ca9a276c..7587ef56b92d 100644
--- a/.gitignore
+++ b/.gitignore
@@ -81,12 +81,14 @@ modules.builtin
/tar-install/
#
-# git files that we don't want to ignore even if they are dot-files
+# We don't want to ignore the following even if they are dot-files
#
+!.clang-format
+!.cocciconfig
+!.get_maintainer.ignore
+!.gitattributes
!.gitignore
!.mailmap
-!.cocciconfig
-!.clang-format
#
# Generated include files
diff --git a/MAINTAINERS b/MAINTAINERS
index 4f4dd9413da7..5cfbea4ce575 100644
--- a/MAINTAINERS
+++ b/MAINTAINERS
@@ -8542,6 +8542,7 @@ F: scripts/Kbuild*
F: scripts/Makefile*
F: scripts/basic/
F: scripts/mk*
+F: scripts/*vmlinux*
F: scripts/mod/
F: scripts/package/
diff --git a/Makefile b/Makefile
index a61a95b6b38f..1232a1454d5c 100644
--- a/Makefile
+++ b/Makefile
@@ -537,7 +537,7 @@ endif
# Some architectures define CROSS_COMPILE in arch/$(SRCARCH)/Makefile.
# CC_VERSION_TEXT is referenced from Kconfig (so it needs export),
# and from include/config/auto.conf.cmd to detect the compiler upgrade.
-CC_VERSION_TEXT = $(shell $(CC) --version | head -n 1)
+CC_VERSION_TEXT = $(shell $(CC) --version 2>/dev/null | head -n 1)
ifeq ($(config-targets),1)
# ===========================================================================
@@ -651,7 +651,7 @@ ifeq ($(may-sync-config),1)
# Read in dependencies to all Kconfig* files, make sure to run syncconfig if
# changes are detected. This should be included after arch/$(SRCARCH)/Makefile
# because some architectures define CROSS_COMPILE there.
--include include/config/auto.conf.cmd
+include include/config/auto.conf.cmd
$(KCONFIG_CONFIG):
@echo >&2 '***'
@@ -692,7 +692,6 @@ KBUILD_CFLAGS += $(call cc-option,-fno-delete-null-pointer-checks,)
KBUILD_CFLAGS += $(call cc-disable-warning,frame-address,)
KBUILD_CFLAGS += $(call cc-disable-warning, format-truncation)
KBUILD_CFLAGS += $(call cc-disable-warning, format-overflow)
-KBUILD_CFLAGS += $(call cc-disable-warning, int-in-bool-context)
KBUILD_CFLAGS += $(call cc-disable-warning, address-of-packed-member)
ifdef CONFIG_CC_OPTIMIZE_FOR_SIZE
@@ -732,16 +731,15 @@ stackp-flags-$(CONFIG_STACKPROTECTOR_STRONG) := -fstack-protector-strong
KBUILD_CFLAGS += $(stackp-flags-y)
ifdef CONFIG_CC_IS_CLANG
-KBUILD_CPPFLAGS += $(call cc-option,-Qunused-arguments,)
-KBUILD_CFLAGS += $(call cc-disable-warning, format-invalid-specifier)
-KBUILD_CFLAGS += $(call cc-disable-warning, gnu)
+KBUILD_CPPFLAGS += -Qunused-arguments
+KBUILD_CFLAGS += -Wno-format-invalid-specifier
+KBUILD_CFLAGS += -Wno-gnu
# Quiet clang warning: comparison of unsigned expression < 0 is always false
-KBUILD_CFLAGS += $(call cc-disable-warning, tautological-compare)
+KBUILD_CFLAGS += -Wno-tautological-compare
# CLANG uses a _MergedGlobals as optimization, but this breaks modpost, as the
# source of a reference will be _MergedGlobals and not on of the whitelisted names.
# See modpost pattern 2
-KBUILD_CFLAGS += $(call cc-option, -mno-global-merge,)
-KBUILD_CFLAGS += $(call cc-option, -fcatch-undefined-behavior)
+KBUILD_CFLAGS += -mno-global-merge
else
# These warnings generated too much noise in a regular build.
@@ -842,7 +840,7 @@ NOSTDINC_FLAGS += -nostdinc -isystem $(shell $(CC) -print-file-name=include)
KBUILD_CFLAGS += -Wdeclaration-after-statement
# Variable Length Arrays (VLAs) should not be used anywhere in the kernel
-KBUILD_CFLAGS += $(call cc-option,-Wvla)
+KBUILD_CFLAGS += -Wvla
# disable pointer signed / unsigned warnings in gcc 4.0
KBUILD_CFLAGS += -Wno-pointer-sign
@@ -1018,7 +1016,7 @@ export KBUILD_VMLINUX_LIBS := $(libs-y1)
export KBUILD_LDS := arch/$(SRCARCH)/kernel/vmlinux.lds
export LDFLAGS_vmlinux
# used by scripts/package/Makefile
-export KBUILD_ALLDIRS := $(sort $(filter-out arch/%,$(vmlinux-alldirs)) arch include scripts tools)
+export KBUILD_ALLDIRS := $(sort $(filter-out arch/%,$(vmlinux-alldirs)) LICENSES arch include scripts tools)
vmlinux-deps := $(KBUILD_LDS) $(KBUILD_VMLINUX_OBJS) $(KBUILD_VMLINUX_LIBS)
@@ -1290,6 +1288,7 @@ modules: $(vmlinux-dirs) $(if $(KBUILD_BUILTIN),vmlinux) modules.builtin
$(Q)$(AWK) '!x[$$0]++' $(vmlinux-dirs:%=$(objtree)/%/modules.order) > $(objtree)/modules.order
@$(kecho) ' Building modules, stage 2.';
$(Q)$(MAKE) -f $(srctree)/scripts/Makefile.modpost
+ $(Q)$(CONFIG_SHELL) $(srctree)/scripts/modules-check.sh
modules.builtin: $(vmlinux-dirs:%=%/modules.builtin)
$(Q)$(AWK) '!x[$$0]++' $^ > $(objtree)/modules.builtin
diff --git a/arch/alpha/Makefile b/arch/alpha/Makefile
index 12dee59b011c..b3314e0dcb6f 100644
--- a/arch/alpha/Makefile
+++ b/arch/alpha/Makefile
@@ -8,6 +8,8 @@
# Copyright (C) 1994 by Linus Torvalds
#
+KBUILD_DEFCONFIG := defconfig
+
NM := $(NM) -B
LDFLAGS_vmlinux := -static -N #-relax
diff --git a/arch/alpha/defconfig b/arch/alpha/configs/defconfig
index f4ec420d7f2d..f4ec420d7f2d 100644
--- a/arch/alpha/defconfig
+++ b/arch/alpha/configs/defconfig
diff --git a/arch/csky/boot/dts/include/dt-bindings b/arch/csky/boot/dts/include/dt-bindings
deleted file mode 120000
index 08c00e4972fa..000000000000
--- a/arch/csky/boot/dts/include/dt-bindings
+++ /dev/null
@@ -1 +0,0 @@
-../../../../../include/dt-bindings \ No newline at end of file
diff --git a/arch/csky/include/asm/Kbuild b/arch/csky/include/asm/Kbuild
index a9b63efef416..c1a6c0f31150 100644
--- a/arch/csky/include/asm/Kbuild
+++ b/arch/csky/include/asm/Kbuild
@@ -1,6 +1,5 @@
generic-y += asm-offsets.h
generic-y += bugs.h
-generic-y += clkdev.h
generic-y += compat.h
generic-y += current.h
generic-y += delay.h
@@ -29,15 +28,12 @@ generic-y += local64.h
generic-y += mm-arch-hooks.h
generic-y += mmiowb.h
generic-y += module.h
-generic-y += mutex.h
generic-y += pci.h
generic-y += percpu.h
generic-y += preempt.h
generic-y += qrwlock.h
-generic-y += scatterlist.h
generic-y += sections.h
generic-y += serial.h
-generic-y += shm.h
generic-y += timex.h
generic-y += topology.h
generic-y += trace_clock.h
diff --git a/arch/h8300/include/asm/Kbuild b/arch/h8300/include/asm/Kbuild
index 79cd1e605ec4..789214ac99bf 100644
--- a/arch/h8300/include/asm/Kbuild
+++ b/arch/h8300/include/asm/Kbuild
@@ -38,7 +38,6 @@ generic-y += pci.h
generic-y += percpu.h
generic-y += pgalloc.h
generic-y += preempt.h
-generic-y += scatterlist.h
generic-y += sections.h
generic-y += serial.h
generic-y += shmparam.h
diff --git a/arch/ia64/kernel/Makefile.gate b/arch/ia64/kernel/Makefile.gate
index f53faf48b7ce..846867bff6d6 100644
--- a/arch/ia64/kernel/Makefile.gate
+++ b/arch/ia64/kernel/Makefile.gate
@@ -11,7 +11,7 @@ quiet_cmd_gate = GATE $@
cmd_gate = $(CC) -nostdlib $(GATECFLAGS_$(@F)) -Wl,-T,$(filter-out FORCE,$^) -o $@
GATECFLAGS_gate.so = -shared -s -Wl,-soname=linux-gate.so.1 \
- $(call cc-ldoption, -Wl$(comma)--hash-style=sysv)
+ -Wl,--hash-style=sysv
$(obj)/gate.so: $(obj)/gate.lds $(obj)/gate.o FORCE
$(call if_changed,gate)
diff --git a/arch/mips/pnx833x/Platform b/arch/mips/pnx833x/Platform
index 794526caab12..6b1a847d593f 100644
--- a/arch/mips/pnx833x/Platform
+++ b/arch/mips/pnx833x/Platform
@@ -1,5 +1,5 @@
# NXP STB225
platform-$(CONFIG_SOC_PNX833X) += pnx833x/
-cflags-$(CONFIG_SOC_PNX833X) += -Iarch/mips/include/asm/mach-pnx833x
+cflags-$(CONFIG_SOC_PNX833X) += -I $(srctree)/arch/mips/include/asm/mach-pnx833x
load-$(CONFIG_NXP_STB220) += 0xffffffff80001000
load-$(CONFIG_NXP_STB225) += 0xffffffff80001000
diff --git a/arch/nds32/include/asm/Kbuild b/arch/nds32/include/asm/Kbuild
index f43b44d692ca..f37d5004a01c 100644
--- a/arch/nds32/include/asm/Kbuild
+++ b/arch/nds32/include/asm/Kbuild
@@ -4,10 +4,8 @@ generic-y += bitops.h
generic-y += bug.h
generic-y += bugs.h
generic-y += checksum.h
-generic-y += clkdev.h
generic-y += cmpxchg.h
generic-y += compat.h
-generic-y += cputime.h
generic-y += device.h
generic-y += div64.h
generic-y += dma.h
@@ -26,7 +24,6 @@ generic-y += kdebug.h
generic-y += kmap_types.h
generic-y += kprobes.h
generic-y += kvm_para.h
-generic-y += limits.h
generic-y += local.h
generic-y += local64.h
generic-y += mm-arch-hooks.h
diff --git a/arch/powerpc/Makefile b/arch/powerpc/Makefile
index 258ea6b2f2e7..c345b79414a9 100644
--- a/arch/powerpc/Makefile
+++ b/arch/powerpc/Makefile
@@ -211,7 +211,7 @@ endif
asinstr := $(call as-instr,lis 9$(comma)foo@high,-DHAVE_AS_ATHIGH=1)
-KBUILD_CPPFLAGS += -Iarch/$(ARCH) $(asinstr)
+KBUILD_CPPFLAGS += -I $(srctree)/arch/$(ARCH) $(asinstr)
KBUILD_AFLAGS += $(AFLAGS-y)
KBUILD_CFLAGS += $(call cc-option,-msoft-float)
KBUILD_CFLAGS += -pipe $(CFLAGS-y)
diff --git a/arch/riscv/include/asm/Kbuild b/arch/riscv/include/asm/Kbuild
index 5a7a19d9aa7f..3d019e062c6f 100644
--- a/arch/riscv/include/asm/Kbuild
+++ b/arch/riscv/include/asm/Kbuild
@@ -1,7 +1,6 @@
generic-y += bugs.h
generic-y += checksum.h
generic-y += compat.h
-generic-y += cputime.h
generic-y += device.h
generic-y += div64.h
generic-y += extable.h
@@ -12,7 +11,6 @@ generic-y += emergency-restart.h
generic-y += exec.h
generic-y += fb.h
generic-y += hardirq.h
-generic-y += hash.h
generic-y += hw_irq.h
generic-y += irq_regs.h
generic-y += irq_work.h
@@ -22,10 +20,8 @@ generic-y += kvm_para.h
generic-y += local.h
generic-y += local64.h
generic-y += mm-arch-hooks.h
-generic-y += mutex.h
generic-y += percpu.h
generic-y += preempt.h
-generic-y += scatterlist.h
generic-y += sections.h
generic-y += serial.h
generic-y += shmparam.h
diff --git a/arch/sh/Makefile b/arch/sh/Makefile
index 4009bef62fe9..b4a86f27e048 100644
--- a/arch/sh/Makefile
+++ b/arch/sh/Makefile
@@ -191,8 +191,8 @@ cpuincdir-y += cpu-common # Must be last
drivers-y += arch/sh/drivers/
drivers-$(CONFIG_OPROFILE) += arch/sh/oprofile/
-cflags-y += $(foreach d, $(cpuincdir-y), -Iarch/sh/include/$(d)) \
- $(foreach d, $(machdir-y), -Iarch/sh/include/$(d))
+cflags-y += $(foreach d, $(cpuincdir-y), -I $(srctree)/arch/sh/include/$(d)) \
+ $(foreach d, $(machdir-y), -I $(srctree)/arch/sh/include/$(d))
KBUILD_CFLAGS += -pipe $(cflags-y)
KBUILD_CPPFLAGS += $(cflags-y)
diff --git a/arch/sh/boot/.gitignore b/arch/sh/boot/.gitignore
index 541087d2029c..f50fdd9975c5 100644
--- a/arch/sh/boot/.gitignore
+++ b/arch/sh/boot/.gitignore
@@ -1,3 +1,4 @@
zImage
vmlinux*
uImage*
+!vmlinux.scr
diff --git a/arch/sh/kernel/vsyscall/Makefile b/arch/sh/kernel/vsyscall/Makefile
index 5db6579bc44c..6e8664448048 100644
--- a/arch/sh/kernel/vsyscall/Makefile
+++ b/arch/sh/kernel/vsyscall/Makefile
@@ -15,8 +15,7 @@ quiet_cmd_syscall = SYSCALL $@
export CPPFLAGS_vsyscall.lds += -P -C -Ush
-vsyscall-flags = -shared -s -Wl,-soname=linux-gate.so.1 \
- $(call cc-ldoption, -Wl$(comma)--hash-style=sysv)
+vsyscall-flags = -shared -s -Wl,-soname=linux-gate.so.1 -Wl,--hash-style=sysv
SYSCFLAGS_vsyscall-trapa.so = $(vsyscall-flags)
diff --git a/arch/x86/kernel/Makefile b/arch/x86/kernel/Makefile
index 00b7e27bc2b7..ce1b5cc360a2 100644
--- a/arch/x86/kernel/Makefile
+++ b/arch/x86/kernel/Makefile
@@ -42,7 +42,7 @@ endif
# non-deterministic coverage.
KCOV_INSTRUMENT := n
-CFLAGS_irq.o := -I$(src)/../include/asm/trace
+CFLAGS_irq.o := -I $(srctree)/$(src)/../include/asm/trace
obj-y := process_$(BITS).o signal.o
obj-$(CONFIG_COMPAT) += signal_compat.o
diff --git a/arch/x86/mm/Makefile b/arch/x86/mm/Makefile
index 4b101dd6e52f..84373dc9b341 100644
--- a/arch/x86/mm/Makefile
+++ b/arch/x86/mm/Makefile
@@ -21,7 +21,7 @@ CFLAGS_physaddr.o := $(nostackp)
CFLAGS_setup_nx.o := $(nostackp)
CFLAGS_mem_encrypt_identity.o := $(nostackp)
-CFLAGS_fault.o := -I$(src)/../include/asm/trace
+CFLAGS_fault.o := -I $(srctree)/$(src)/../include/asm/trace
obj-$(CONFIG_X86_PAT) += pat_rbtree.o
diff --git a/arch/xtensa/boot/lib/Makefile b/arch/xtensa/boot/lib/Makefile
index 355127faade1..e3d717c7bfa1 100644
--- a/arch/xtensa/boot/lib/Makefile
+++ b/arch/xtensa/boot/lib/Makefile
@@ -7,7 +7,7 @@ zlib := inffast.c inflate.c inftrees.c
lib-y += $(zlib:.c=.o) zmem.o
-ccflags-y := -Ilib/zlib_inflate
+ccflags-y := -I $(srctree)/lib/zlib_inflate
ifdef CONFIG_FUNCTION_TRACER
CFLAGS_REMOVE_inflate.o = -pg
CFLAGS_REMOVE_zmem.o = -pg
diff --git a/arch/xtensa/include/asm/Kbuild b/arch/xtensa/include/asm/Kbuild
index 35f83c4bf239..f1686d919178 100644
--- a/arch/xtensa/include/asm/Kbuild
+++ b/arch/xtensa/include/asm/Kbuild
@@ -27,7 +27,6 @@ generic-y += preempt.h
generic-y += qrwlock.h
generic-y += qspinlock.h
generic-y += sections.h
-generic-y += socket.h
generic-y += topology.h
generic-y += trace_clock.h
generic-y += vga.h
diff --git a/drivers/hid/intel-ish-hid/Makefile b/drivers/hid/intel-ish-hid/Makefile
index 2de97e4b7740..f0a82b1c7cb9 100644
--- a/drivers/hid/intel-ish-hid/Makefile
+++ b/drivers/hid/intel-ish-hid/Makefile
@@ -23,4 +23,4 @@ intel-ishtp-hid-objs += ishtp-hid-client.o
obj-$(CONFIG_INTEL_ISH_FIRMWARE_DOWNLOADER) += intel-ishtp-loader.o
intel-ishtp-loader-objs += ishtp-fw-loader.o
-ccflags-y += -Idrivers/hid/intel-ish-hid/ishtp
+ccflags-y += -I $(srctree)/$(src)/ishtp
diff --git a/drivers/media/common/b2c2/Makefile b/drivers/media/common/b2c2/Makefile
index aa2dc2434ee5..0e32b77f349b 100644
--- a/drivers/media/common/b2c2/Makefile
+++ b/drivers/media/common/b2c2/Makefile
@@ -4,5 +4,5 @@ b2c2-flexcop-objs += flexcop-sram.o flexcop-eeprom.o flexcop-misc.