$(Q)$(MAKE) $(hdr-inst)=include/uapi
        $(Q)$(MAKE) $(hdr-inst)=arch/$(SRCARCH)/include/uapi
 
+# Deprecated. It is no-op now.
 PHONY += headers_check
-headers_check: headers
-       $(Q)$(MAKE) $(hdr-inst)=include/uapi HDRCHECK=1
-       $(Q)$(MAKE) $(hdr-inst)=arch/$(SRCARCH)/include/uapi HDRCHECK=1
+headers_check:
+       @:
 
 ifdef CONFIG_HEADERS_INSTALL
 prepare: headers
 endif
 
-ifdef CONFIG_HEADERS_CHECK
-all: headers_check
-endif
-
 PHONY += scripts_unifdef
 scripts_unifdef: scripts_basic
        $(Q)$(MAKE) $(build)=scripts scripts/unifdef
        @echo  '  versioncheck    - Sanity check on version.h usage'
        @echo  '  includecheck    - Check for duplicate included header files'
        @echo  '  export_report   - List the usages of all exported symbols'
-       @echo  '  headers_check   - Sanity check on exported headers'
        @echo  '  headerdep       - Detect inclusion cycles in headers'
        @echo  '  coccicheck      - Check with Coccinelle'
        @echo  ''
 
          user-space program samples. It is also needed by some features such
          as uapi header sanity checks.
 
-config HEADERS_CHECK
-       bool "Run sanity checks on uapi headers when building 'all'"
-       depends on HEADERS_INSTALL
-       help
-         This option will run basic sanity checks on uapi headers when
-         building the 'all' target, for example, ensure that they do not
-         attempt to include files which were not exported, etc.
-
-         If you're making modifications to header files which are
-         relevant for userspace, say 'Y'.
-
 config OPTIMIZE_INLINING
        def_bool y
        help
 
 $(if $(new-dirs), $(shell mkdir -p $(new-dirs)))
 
 # Rules
-
-ifndef HDRCHECK
-
 quiet_cmd_install = HDRINST $@
       cmd_install = $(CONFIG_SHELL) $(srctree)/scripts/headers_install.sh $< $@
 
 
 -include $(foreach f,$(existing-headers),$(dir $(f)).$(notdir $(f)).cmd)
 
-else
-
-quiet_cmd_check = HDRCHK  $<
-      cmd_check = $(PERL) $(srctree)/scripts/headers_check.pl $(dst) $(SRCARCH) $<; touch $@
-
-check-files := $(addsuffix .chk, $(all-headers))
-
-$(check-files): $(dst)/%.chk : $(dst)/% $(srctree)/scripts/headers_check.pl
-       $(call cmd,check)
-
-__headers: $(check-files)
-       @:
-
-endif
-
 PHONY += FORCE
 FORCE:
 
 
 # asm-generic/*.h is used by asm/*.h, and should not be included directly
 header-test- += asm-generic/%
 
-extra-y := $(patsubst %.h,%.hdrtest, $(filter-out $(header-test-), \
-               $(patsubst $(obj)/%,%, $(shell find $(obj) -name '*.h'))))
+extra-y := $(patsubst $(obj)/%.h,%.hdrtest, $(shell find $(obj) -name '*.h'))
 
 quiet_cmd_hdrtest = HDRTEST $<
-      cmd_hdrtest = $(CC) $(c_flags) -S -o /dev/null -x c /dev/null -include $<; touch $@
+      cmd_hdrtest = \
+               $(CC) $(c_flags) -S -o /dev/null -x c /dev/null \
+                       $(if $(filter-out $(header-test-), $*.h), -include $<); \
+               $(PERL) $(srctree)/scripts/headers_check.pl $(obj) $(SRCARCH) $<; \
+               touch $@
 
 $(obj)/%.hdrtest: $(obj)/%.h FORCE
        $(call if_changed_dep,hdrtest)