Skip to content

Commit

Permalink
kbuild: Drop support for include/asm-<arch> in headers_check.pl
Browse files Browse the repository at this point in the history
"include/asm-<arch>" was replaced by "arch/<arch>/include/asm" a long
time ago.  All assembler header files are now included using
"#include <asm/*>", so there is no longer a need to rewrite paths.

Signed-off-by: Geert Uytterhoeven <[email protected]>
Signed-off-by: Masahiro Yamada <[email protected]>
  • Loading branch information
geertu authored and masahir0y committed Dec 21, 2024
1 parent fac04ef commit d67393f
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 8 deletions.
2 changes: 1 addition & 1 deletion usr/include/Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -78,7 +78,7 @@ quiet_cmd_hdrtest = HDRTEST $<
cmd_hdrtest = \
$(CC) $(c_flags) -fsyntax-only -x c /dev/null \
$(if $(filter-out $(no-header-test), $*.h), -include $< -include $<); \
$(PERL) $(src)/headers_check.pl $(obj) $(SRCARCH) $<; \
$(PERL) $(src)/headers_check.pl $(obj) $<; \
touch $@

$(obj)/%.hdrtest: $(obj)/%.h FORCE
Expand Down
9 changes: 2 additions & 7 deletions usr/include/headers_check.pl
Original file line number Diff line number Diff line change
Expand Up @@ -3,9 +3,8 @@
#
# headers_check.pl execute a number of trivial consistency checks
#
# Usage: headers_check.pl dir arch [files...]
# Usage: headers_check.pl dir [files...]
# dir: dir to look for included files
# arch: architecture
# files: list of files to check
#
# The script reads the supplied files line by line and:
Expand All @@ -23,7 +22,7 @@
use strict;
use File::Basename;

my ($dir, $arch, @files) = @ARGV;
my ($dir, @files) = @ARGV;

my $ret = 0;
my $line;
Expand Down Expand Up @@ -54,10 +53,6 @@ sub check_include
my $inc = $1;
my $found;
$found = stat($dir . "/" . $inc);
if (!$found) {
$inc =~ s#asm/#asm-$arch/#;
$found = stat($dir . "/" . $inc);
}
if (!$found) {
printf STDERR "$filename:$lineno: included file '$inc' is not exported\n";
$ret = 1;
Expand Down

0 comments on commit d67393f

Please sign in to comment.