diff options
| author | Michal Marek <mmarek@suse.cz> | 2010-08-20 07:53:08 -0400 |
|---|---|---|
| committer | Michal Marek <mmarek@suse.cz> | 2010-08-20 07:53:08 -0400 |
| commit | e981b060767b3c4ac9393ad8d2558d648e35dfcb (patch) | |
| tree | 9c05eaec3072be3645dda61d35085d152b9d5954 /scripts | |
| parent | 3c955b407a084810f57260d61548cc92c14bc627 (diff) | |
| parent | da5cabf80e2433131bf0ed8993abc0f7ea618c73 (diff) | |
Merge commit 'v2.6.36-rc1' into kbuild/rc-fixes
Diffstat (limited to 'scripts')
| -rw-r--r-- | scripts/Makefile.build | 37 | ||||
| -rw-r--r-- | scripts/Makefile.headersinst | 3 | ||||
| -rw-r--r-- | scripts/Makefile.help | 3 | ||||
| -rw-r--r-- | scripts/Makefile.modpost | 9 | ||||
| -rwxr-xr-x | scripts/checkkconfigsymbols.sh | 2 | ||||
| -rwxr-xr-x | scripts/checkpatch.pl | 42 | ||||
| -rwxr-xr-x | scripts/checksyscalls.sh | 1 | ||||
| -rwxr-xr-x | scripts/coccicheck | 80 | ||||
| -rw-r--r-- | scripts/coccinelle/alloc/drop_kmalloc_cast.cocci | 67 | ||||
| -rw-r--r-- | scripts/coccinelle/alloc/kzalloc-simple.cocci | 82 | ||||
| -rw-r--r-- | scripts/coccinelle/deref_null.cocci | 293 | ||||
| -rw-r--r-- | scripts/coccinelle/err_cast.cocci | 56 | ||||
| -rw-r--r-- | scripts/coccinelle/resource_size.cocci | 93 | ||||
| -rwxr-xr-x | scripts/decodecode | 10 | ||||
| -rw-r--r-- | scripts/dtc/fstree.c | 1 | ||||
| -rw-r--r-- | scripts/kconfig/.gitignore | 1 | ||||
| -rw-r--r-- | scripts/kconfig/conf.c | 2 | ||||
| -rwxr-xr-x | scripts/kernel-doc | 2 | ||||
| -rw-r--r-- | scripts/mod/file2alias.c | 6 | ||||
| -rw-r--r-- | scripts/mod/modpost.c | 175 | ||||
| -rw-r--r-- | scripts/mod/modpost.h | 43 | ||||
| -rw-r--r-- | scripts/package/Makefile | 37 | ||||
| -rw-r--r-- | scripts/package/builddeb | 5 | ||||
| -rwxr-xr-x | scripts/recordmcount.pl | 2 | ||||
| -rwxr-xr-x | scripts/setlocalversion | 2 |
25 files changed, 963 insertions, 91 deletions
diff --git a/scripts/Makefile.build b/scripts/Makefile.build index e4deb73e9a84..a1a5cf95a68d 100644 --- a/scripts/Makefile.build +++ b/scripts/Makefile.build | |||
| @@ -115,7 +115,10 @@ endif | |||
| 115 | # --------------------------------------------------------------------------- | 115 | # --------------------------------------------------------------------------- |
| 116 | 116 | ||
| 117 | # Default is built-in, unless we know otherwise | 117 | # Default is built-in, unless we know otherwise |
| 118 | modkern_cflags = $(if $(part-of-module), $(CFLAGS_MODULE), $(CFLAGS_KERNEL)) | 118 | modkern_cflags = \ |
| 119 | $(if $(part-of-module), \ | ||
| 120 | $(KBUILD_CFLAGS_MODULE) $(CFLAGS_MODULE), \ | ||
| 121 | $(KBUILD_CFLAGS_KERNEL) $(CFLAGS_KERNEL)) | ||
| 119 | quiet_modtag := $(empty) $(empty) | 122 | quiet_modtag := $(empty) $(empty) |
| 120 | 123 | ||
| 121 | $(real-objs-m) : part-of-module := y | 124 | $(real-objs-m) : part-of-module := y |
| @@ -156,14 +159,14 @@ $(obj)/%.i: $(src)/%.c FORCE | |||
| 156 | 159 | ||
| 157 | cmd_gensymtypes = \ | 160 | cmd_gensymtypes = \ |
| 158 | $(CPP) -D__GENKSYMS__ $(c_flags) $< | \ | 161 | $(CPP) -D__GENKSYMS__ $(c_flags) $< | \ |
| 159 | $(GENKSYMS) -T $@ -a $(ARCH) \ | 162 | $(GENKSYMS) $(if $(1), -T $(2)) -a $(ARCH) \ |
| 160 | $(if $(KBUILD_PRESERVE),-p) \ | 163 | $(if $(KBUILD_PRESERVE),-p) \ |
| 161 | $(if $(1),-r $(firstword $(wildcard $(@:.symtypes=.symref) /dev/null))) | 164 | -r $(firstword $(wildcard $(2:.symtypes=.symref) /dev/null)) |
| 162 | 165 | ||
| 163 | quiet_cmd_cc_symtypes_c = SYM $(quiet_modtag) $@ | 166 | quiet_cmd_cc_symtypes_c = SYM $(quiet_modtag) $@ |
| 164 | cmd_cc_symtypes_c = \ | 167 | cmd_cc_symtypes_c = \ |
| 165 | set -e; \ | 168 | set -e; \ |
| 166 | $(call cmd_gensymtypes, true) >/dev/null; \ | 169 | $(call cmd_gensymtypes,true,$@) >/dev/null; \ |
| 167 | test -s $@ || rm -f $@ | 170 | test -s $@ || rm -f $@ |
| 168 | 171 | ||
| 169 | $(obj)/%.symtypes : $(src)/%.c FORCE | 172 | $(obj)/%.symtypes : $(src)/%.c FORCE |
| @@ -192,16 +195,16 @@ else | |||
| 192 | # the actual value of the checksum generated by genksyms | 195 | # the actual value of the checksum generated by genksyms |
| 193 | 196 | ||
| 194 | cmd_cc_o_c = $(CC) $(c_flags) -c -o $(@D)/.tmp_$(@F) $< | 197 | cmd_cc_o_c = $(CC) $(c_flags) -c -o $(@D)/.tmp_$(@F) $< |
| 195 | cmd_modversions = \ | 198 | cmd_modversions = \ |
| 196 | if $(OBJDUMP) -h $(@D)/.tmp_$(@F) | grep -q __ksymtab; then \ | 199 | if $(OBJDUMP) -h $(@D)/.tmp_$(@F) | grep -q __ksymtab; then \ |
| 197 | $(call cmd_gensymtypes, $(KBUILD_SYMTYPES)) \ | 200 | $(call cmd_gensymtypes,$(KBUILD_SYMTYPES),$(@:.o=.symtypes)) \ |
| 198 | > $(@D)/.tmp_$(@F:.o=.ver); \ | 201 | > $(@D)/.tmp_$(@F:.o=.ver); \ |
| 199 | \ | 202 | \ |
| 200 | $(LD) $(LDFLAGS) -r -o $@ $(@D)/.tmp_$(@F) \ | 203 | $(LD) $(LDFLAGS) -r -o $@ $(@D)/.tmp_$(@F) \ |
| 201 | -T $(@D)/.tmp_$(@F:.o=.ver); \ | 204 | -T $(@D)/.tmp_$(@F:.o=.ver); \ |
| 202 | rm -f $(@D)/.tmp_$(@F) $(@D)/.tmp_$(@F:.o=.ver); \ | 205 | rm -f $(@D)/.tmp_$(@F) $(@D)/.tmp_$(@F:.o=.ver); \ |
| 203 | else \ | 206 | else \ |
| 204 | mv -f $(@D)/.tmp_$(@F) $@; \ | 207 | mv -f $(@D)/.tmp_$(@F) $@; \ |
| 205 | fi; | 208 | fi; |
| 206 | endif | 209 | endif |
| 207 | 210 | ||
| @@ -248,10 +251,10 @@ $(obj)/%.lst: $(src)/%.c FORCE | |||
| 248 | # Compile assembler sources (.S) | 251 | # Compile assembler sources (.S) |
| 249 | # --------------------------------------------------------------------------- | 252 | # --------------------------------------------------------------------------- |
| 250 | 253 | ||
| 251 | modkern_aflags := $(AFLAGS_KERNEL) | 254 | modkern_aflags := $(KBUILD_AFLAGS_KERNEL) $(AFLAGS_KERNEL) |
| 252 | 255 | ||
| 253 | $(real-objs-m) : modkern_aflags := $(AFLAGS_MODULE) | 256 | $(real-objs-m) : modkern_aflags := $(KBUILD_AFLAGS_MODULE) $(AFLAGS_MODULE) |
| 254 | $(real-objs-m:.o=.s): modkern_aflags := $(AFLAGS_MODULE) | 257 | $(real-objs-m:.o=.s): modkern_aflags := $(KBUILD_AFLAGS_MODULE) $(AFLAGS_MODULE) |
| 255 | 258 | ||
| 256 | quiet_cmd_as_s_S = CPP $(quiet_modtag) $@ | 259 | quiet_cmd_as_s_S = CPP $(quiet_modtag) $@ |
| 257 | cmd_as_s_S = $(CPP) $(a_flags) -o $@ $< | 260 | cmd_as_s_S = $(CPP) $(a_flags) -o $@ $< |
diff --git a/scripts/Makefile.headersinst b/scripts/Makefile.headersinst index 0fcd83838771..f89cb87f5c01 100644 --- a/scripts/Makefile.headersinst +++ b/scripts/Makefile.headersinst | |||
| @@ -3,7 +3,6 @@ | |||
| 3 | # | 3 | # |
| 4 | # header-y - list files to be installed. They are preprocessed | 4 | # header-y - list files to be installed. They are preprocessed |
| 5 | # to remove __KERNEL__ section of the file | 5 | # to remove __KERNEL__ section of the file |
| 6 | # unifdef-y - Same as header-y. Obsolete | ||
| 7 | # objhdr-y - Same as header-y but for generated files | 6 | # objhdr-y - Same as header-y but for generated files |
| 8 | # | 7 | # |
| 9 | # ========================================================================== | 8 | # ========================================================================== |
| @@ -20,7 +19,7 @@ include scripts/Kbuild.include | |||
| 20 | 19 | ||
| 21 | install := $(INSTALL_HDR_PATH)/$(_dst) | 20 | install := $(INSTALL_HDR_PATH)/$(_dst) |
| 22 | 21 | ||
| 23 | header-y := $(sort $(header-y) $(unifdef-y)) | 22 | header-y := $(sort $(header-y)) |
| 24 | subdirs := $(patsubst %/,%,$(filter %/, $(header-y))) | 23 | subdirs := $(patsubst %/,%,$(filter %/, $(header-y))) |
| 25 | header-y := $(filter-out %/, $(header-y)) | 24 | header-y := $(filter-out %/, $(header-y)) |
| 26 | 25 | ||
diff --git a/scripts/Makefile.help b/scripts/Makefile.help new file mode 100644 index 000000000000..d03608f5db04 --- /dev/null +++ b/scripts/Makefile.help | |||
| @@ -0,0 +1,3 @@ | |||
| 1 | |||
| 2 | checker-help: | ||
| 3 | @echo ' coccicheck - Check with Coccinelle.' | ||
diff --git a/scripts/Makefile.modpost b/scripts/Makefile.modpost index 8f14c81abbc7..7d22056582c1 100644 --- a/scripts/Makefile.modpost +++ b/scripts/Makefile.modpost | |||
| @@ -30,7 +30,7 @@ | |||
| 30 | # - See include/linux/module.h for more details | 30 | # - See include/linux/module.h for more details |
| 31 | 31 | ||
| 32 | # Step 4 is solely used to allow module versioning in external modules, | 32 | # Step 4 is solely used to allow module versioning in external modules, |
| 33 | # where the CRC of each module is retrieved from the Module.symers file. | 33 | # where the CRC of each module is retrieved from the Module.symvers file. |
| 34 | 34 | ||
| 35 | # KBUILD_MODPOST_WARN can be set to avoid error out in case of undefined | 35 | # KBUILD_MODPOST_WARN can be set to avoid error out in case of undefined |
| 36 | # symbols in the final module linking stage | 36 | # symbols in the final module linking stage |
| @@ -107,7 +107,7 @@ $(modules:.ko=.mod.c): __modpost ; | |||
| 107 | modname = $(notdir $(@:.mod.o=)) | 107 | modname = $(notdir $(@:.mod.o=)) |
| 108 | 108 | ||
| 109 | quiet_cmd_cc_o_c = CC $@ | 109 | quiet_cmd_cc_o_c = CC $@ |
| 110 | cmd_cc_o_c = $(CC) $(c_flags) $(CFLAGS_MODULE) \ | 110 | cmd_cc_o_c = $(CC) $(c_flags) $(KBUILD_CFLAGS_MODULE) $(CFLAGS_MODULE) \ |
| 111 | -c -o $@ $< | 111 | -c -o $@ $< |
| 112 | 112 | ||
| 113 | $(modules:.ko=.mod.o): %.mod.o: %.mod.c FORCE | 113 | $(modules:.ko=.mod.o): %.mod.o: %.mod.c FORCE |
| @@ -117,8 +117,9 @@ targets += $(modules:.ko=.mod.o) | |||
| 117 | 117 | ||
| 118 | # Step 6), final link of the modules | 118 | # Step 6), final link of the modules |
| 119 | quiet_cmd_ld_ko_o = LD [M] $@ | 119 | quiet_cmd_ld_ko_o = LD [M] $@ |
| 120 | cmd_ld_ko_o = $(LD) -r $(LDFLAGS) $(LDFLAGS_MODULE) -o $@ \ | 120 | cmd_ld_ko_o = $(LD) -r $(LDFLAGS) \ |
| 121 | $(filter-out FORCE,$^) | 121 | $(KBUILD_LDFLAGS_MODULE) $(LDFLAGS_MODULE) \ |
| 122 | -o $@ $(filter-out FORCE,$^) | ||
| 122 | 123 | ||
| 123 | $(modules): %.ko :%.o %.mod.o FORCE | 124 | $(modules): %.ko :%.o %.mod.o FORCE |
| 124 | $(call if_changed,ld_ko_o) | 125 | $(call if_changed,ld_ko_o) |
