diff options
| author | Ingo Molnar <mingo@elte.hu> | 2010-06-18 04:53:12 -0400 |
|---|---|---|
| committer | Ingo Molnar <mingo@elte.hu> | 2010-06-18 04:53:19 -0400 |
| commit | 646b1db4956ba8bf748b835b5eba211133d91c2e (patch) | |
| tree | 061166d873d9da9cf83044a7593ad111787076c5 /scripts | |
| parent | 0f2c3de2ba110626515234d5d584fb1b0c0749a2 (diff) | |
| parent | 7e27d6e778cd87b6f2415515d7127eba53fe5d02 (diff) | |
Merge commit 'v2.6.35-rc3' into perf/core
Merge reason: Go from -rc1 base to -rc3 base, merge in fixes.
Diffstat (limited to 'scripts')
42 files changed, 2824 insertions, 370 deletions
diff --git a/scripts/Makefile.build b/scripts/Makefile.build index 0b94d2fa3a88..e4deb73e9a84 100644 --- a/scripts/Makefile.build +++ b/scripts/Makefile.build | |||
| @@ -82,7 +82,7 @@ ifneq ($(strip $(lib-y) $(lib-m) $(lib-n) $(lib-)),) | |||
| 82 | lib-target := $(obj)/lib.a | 82 | lib-target := $(obj)/lib.a |
| 83 | endif | 83 | endif |
| 84 | 84 | ||
| 85 | ifneq ($(strip $(obj-y) $(obj-m) $(obj-n) $(obj-) $(lib-target)),) | 85 | ifneq ($(strip $(obj-y) $(obj-m) $(obj-n) $(obj-) $(subdir-m) $(lib-target)),) |
| 86 | builtin-target := $(obj)/built-in.o | 86 | builtin-target := $(obj)/built-in.o |
| 87 | endif | 87 | endif |
| 88 | 88 | ||
diff --git a/scripts/Makefile.lib b/scripts/Makefile.lib index cbcd654215e6..54fd1b700131 100644 --- a/scripts/Makefile.lib +++ b/scripts/Makefile.lib | |||
| @@ -241,7 +241,7 @@ cmd_lzma = (cat $(filter-out FORCE,$^) | \ | |||
| 241 | lzma -9 && $(call size_append, $(filter-out FORCE,$^))) > $@ || \ | 241 | lzma -9 && $(call size_append, $(filter-out FORCE,$^))) > $@ || \ |
| 242 | (rm -f $@ ; false) | 242 | (rm -f $@ ; false) |
| 243 | 243 | ||
| 244 | quiet_cmd_lzo = LZO $@ | 244 | quiet_cmd_lzo = LZO $@ |
| 245 | cmd_lzo = (cat $(filter-out FORCE,$^) | \ | 245 | cmd_lzo = (cat $(filter-out FORCE,$^) | \ |
| 246 | lzop -9 && $(call size_append, $(filter-out FORCE,$^))) > $@ || \ | 246 | lzop -9 && $(call size_append, $(filter-out FORCE,$^))) > $@ || \ |
| 247 | (rm -f $@ ; false) | 247 | (rm -f $@ ; false) |
diff --git a/scripts/Makefile.modbuiltin b/scripts/Makefile.modbuiltin index 102a276f6eea..1adb974e6950 100644 --- a/scripts/Makefile.modbuiltin +++ b/scripts/Makefile.modbuiltin | |||
| @@ -14,6 +14,11 @@ __modbuiltin: | |||
| 14 | 14 | ||
| 15 | include scripts/Kbuild.include | 15 | include scripts/Kbuild.include |
| 16 | 16 | ||
| 17 | ifneq ($(KBUILD_SRC),) | ||
| 18 | # Create output directory if not already present | ||
| 19 | _dummy := $(shell [ -d $(obj) ] || mkdir -p $(obj)) | ||
| 20 | endif | ||
| 21 | |||
| 17 | # The filename Kbuild has precedence over Makefile | 22 | # The filename Kbuild has precedence over Makefile |
| 18 | kbuild-dir := $(if $(filter /%,$(src)),$(src),$(srctree)/$(src)) | 23 | kbuild-dir := $(if $(filter /%,$(src)),$(src),$(srctree)/$(src)) |
| 19 | kbuild-file := $(if $(wildcard $(kbuild-dir)/Kbuild),$(kbuild-dir)/Kbuild,$(kbuild-dir)/Makefile) | 24 | kbuild-file := $(if $(wildcard $(kbuild-dir)/Kbuild),$(kbuild-dir)/Kbuild,$(kbuild-dir)/Makefile) |
diff --git a/scripts/checkincludes.pl b/scripts/checkincludes.pl index 676ddc07d6fa..97b2c6143fe4 100755 --- a/scripts/checkincludes.pl +++ b/scripts/checkincludes.pl | |||
| @@ -11,6 +11,8 @@ | |||
| 11 | # you do have real dups and do not have them under #ifdef's. You | 11 | # you do have real dups and do not have them under #ifdef's. You |
| 12 | # could also just review the results. | 12 | # could also just review the results. |
| 13 | 13 | ||
| 14 | use strict; | ||
| 15 | |||
| 14 | sub usage { | 16 | sub usage { |
| 15 | print "Usage: checkincludes.pl [-r]\n"; | 17 | print "Usage: checkincludes.pl [-r]\n"; |
| 16 | print "By default we just warn of duplicates\n"; | 18 | print "By default we just warn of duplicates\n"; |
| @@ -35,23 +37,24 @@ if ($#ARGV >= 1) { | |||
| 35 | } | 37 | } |
| 36 | } | 38 | } |
| 37 | 39 | ||
| 38 | foreach $file (@ARGV) { | 40 | foreach my $file (@ARGV) { |
| 39 | open(FILE, $file) or die "Cannot open $file: $!.\n"; | 41 | open(my $f, '<', $file) |
| 42 | or die "Cannot open $file: $!.\n"; | ||
| 40 | 43 | ||
| 41 | my %includedfiles = (); | 44 | my %includedfiles = (); |
| 42 | my @file_lines = (); | 45 | my @file_lines = (); |
| 43 | 46 | ||
| 44 | while (<FILE>) { | 47 | while (<$f>) { |
| 45 | if (m/^\s*#\s*include\s*[<"](\S*)[>"]/o) { | 48 | if (m/^\s*#\s*include\s*[<"](\S*)[>"]/o) { |
| 46 | ++$includedfiles{$1}; | 49 | ++$includedfiles{$1}; |
| 47 | } | 50 | } |
| 48 | push(@file_lines, $_); | 51 | push(@file_lines, $_); |
| 49 | } | 52 | } |
| 50 | 53 | ||
| 51 | close(FILE); | 54 | close($f); |
| 52 | 55 | ||
| 53 | if (!$remove) { | 56 | if (!$remove) { |
| 54 | foreach $filename (keys %includedfiles) { | 57 | foreach my $filename (keys %includedfiles) { |
| 55 | if ($includedfiles{$filename} > 1) { | 58 | if ($includedfiles{$filename} > 1) { |
| 56 | print "$file: $filename is included more than once.\n"; | 59 | print "$file: $filename is included more than once.\n"; |
| 57 | } | 60 | } |
| @@ -59,27 +62,28 @@ foreach $file (@ARGV) { | |||
| 59 | next; | 62 | next; |
| 60 | } | 63 | } |
| 61 | 64 | ||
| 62 | open(FILE,">$file") || die("Cannot write to $file: $!"); | 65 | open($f, '>', $file) |
| 66 | or die("Cannot write to $file: $!"); | ||
| 63 | 67 | ||
| 64 | my $dups = 0; | 68 | my $dups = 0; |
| 65 | foreach (@file_lines) { | 69 | foreach (@file_lines) { |
| 66 | if (m/^\s*#\s*include\s*[<"](\S*)[>"]/o) { | 70 | if (m/^\s*#\s*include\s*[<"](\S*)[>"]/o) { |
| 67 | foreach $filename (keys %includedfiles) { | 71 | foreach my $filename (keys %includedfiles) { |
| 68 | if ($1 eq $filename) { | 72 | if ($1 eq $filename) { |
| 69 | if ($includedfiles{$filename} > 1) { | 73 | if ($includedfiles{$filename} > 1) { |
| 70 | $includedfiles{$filename}--; | 74 | $includedfiles{$filename}--; |
| 71 | $dups++; | 75 | $dups++; |
| 72 | } else { | 76 | } else { |
| 73 | print FILE $_; | 77 | print {$f} $_; |
| 74 | } | 78 | } |
| 75 | } | 79 | } |
| 76 | } | 80 | } |
| 77 | } else { | 81 | } else { |
| 78 | print FILE $_; | 82 | print {$f} $_ |
