History

Merge tag 'v6.11-rc6' into docs-mw

This is done primarily to get a docs build fix merged via another tree so that "make htmldocs" stops failing.

Jonathan Corbet committed 2 years ago

Commit d2243382 parents eb5ed2f 431c1641361 files · +16839 −8618Browse files

Showing the changes to scripts (13 of 1361 files). Show all

Unified · Split

13 files
  1. scripts/Makefile.build +1 −1
  2. scripts/Makefile.lib +10 −18
  3. scripts/Makefile.modfinal +1 −1
  4. scripts/Makefile.vmlinux +1 −1
  5. scripts/Makefile.vmlinux_o +1 −1
  6. scripts/checkpatch.pl +0 −10
  7. scripts/gcc-plugins/randomize_layout_plugin.c +0 −4
  8. scripts/generate_rust_analyzer.py +5 −1
  9. scripts/generate_rust_target.rs +2 −2
  10. scripts/kallsyms.c +2 −29
  11. scripts/kconfig/merge_config.sh +2 −0
  12. scripts/link-vmlinux.sh +2 −5
  13. scripts/syscall.tbl +3 −3
scripts/Makefile.build+1−1
@@ -487,7 +487,7 @@ $(subdir-ym): · 486 unmodified lines
487487 need-modorder=$(if $(filter $@/modules.order, $(subdir-modorder)),1) \
488488 $(filter $@/%, $(single-subdir-goals))
489489
490−# Add FORCE to the prequisites of a target to force it to be always rebuilt.
490+# Add FORCE to the prerequisites of a target to force it to be always rebuilt.
491491 # ---------------------------------------------------------------------------
492492
493493 PHONY += FORCE
scripts/Makefile.lib+10−18
@@ -400,26 +400,23 @@ $(obj)/%.dtb.S: $(obj)/%.dtb FORCE · 399 unmodified lines
400400 $(obj)/%.dtbo.S: $(obj)/%.dtbo FORCE
401401 $(call if_changed,wrap_S_dtb)
402402
403−quiet_cmd_dtc = DTC $@
403+quiet_dtb_check_tag = $(if $(dtb-check-enabled),[C], )
404+cmd_dtb_check = $(if $(dtb-check-enabled),; $(DT_CHECKER) $(DT_CHECKER_FLAGS) -u $(srctree)/$(DT_BINDING_DIR) -p $(DT_TMP_SCHEMA) $@ || true)
405+
406+quiet_cmd_dtc = DTC $(quiet_dtb_check_tag) $@
404407 cmd_dtc = $(HOSTCC) -E $(dtc_cpp_flags) -x assembler-with-cpp -o $(dtc-tmp) $< ; \
405408 $(DTC) -o $@ -b 0 \
406409 $(addprefix -i,$(dir $<) $(DTC_INCLUDE)) $(DTC_FLAGS) \
407410 -d $(depfile).dtc.tmp $(dtc-tmp) ; \
408− cat $(depfile).pre.tmp $(depfile).dtc.tmp > $(depfile)
409−
410−DT_CHECK_CMD = $(DT_CHECKER) $(DT_CHECKER_FLAGS) -u $(srctree)/$(DT_BINDING_DIR) -p $(DT_TMP_SCHEMA)
411+ cat $(depfile).pre.tmp $(depfile).dtc.tmp > $(depfile) \
412+ $(cmd_dtb_check)
411413
412414 # NOTE:
413415 # Do not replace $(filter %.dtb %.dtbo, $^) with $(real-prereqs). When a single
414416 # DTB is turned into a multi-blob DTB, $^ will contain header file dependencies
415417 # recorded in the .*.cmd file.
416−ifneq ($(CHECK_DTBS),)
417−quiet_cmd_fdtoverlay = DTOVLCH $@
418− cmd_fdtoverlay = $(objtree)/scripts/dtc/fdtoverlay -o $@ -i $(filter %.dtb %.dtbo, $^) ; $(DT_CHECK_CMD) $@ || true
419−else
420−quiet_cmd_fdtoverlay = DTOVL $@
421− cmd_fdtoverlay = $(objtree)/scripts/dtc/fdtoverlay -o $@ -i $(filter %.dtb %.dtbo, $^)
422−endif
418+quiet_cmd_fdtoverlay = OVL $(quiet_dtb_check_tag) $@
419+ cmd_fdtoverlay = $(objtree)/scripts/dtc/fdtoverlay -o $@ -i $(filter %.dtb %.dtbo, $^) $(cmd_dtb_check)
423420
424421 $(multi-dtb-y): FORCE
425422 $(call if_changed,fdtoverlay)
@@ -430,16 +427,11 @@ DT_CHECKER ?= dt-validate · 4 unmodified lines
430427 DT_CHECKER_FLAGS ?= $(if $(DT_SCHEMA_FILES),-l $(DT_SCHEMA_FILES),-m)
431428 DT_BINDING_DIR := Documentation/devicetree/bindings
432429 DT_TMP_SCHEMA := $(objtree)/$(DT_BINDING_DIR)/processed-schema.json
433−
434−quiet_cmd_dtb = DTC_CHK $@
435− cmd_dtb = $(cmd_dtc) ; $(DT_CHECK_CMD) $@ || true
436−else
437−quiet_cmd_dtb = $(quiet_cmd_dtc)
438− cmd_dtb = $(cmd_dtc)
430+dtb-check-enabled = $(if $(filter %.dtb, $@),y)
439431 endif
440432
441433 $(obj)/%.dtb: $(obj)/%.dts $(DTC) $(DT_TMP_SCHEMA) FORCE
442− $(call if_changed_dep,dtb)
434+ $(call if_changed_dep,dtc)
443435
444436 $(obj)/%.dtbo: $(src)/%.dtso $(DTC) FORCE
445437 $(call if_changed_dep,dtc)
scripts/Makefile.modfinal+1−1
@@ -62,7 +62,7 @@ endif · 61 unmodified lines
6262
6363 targets += $(modules:%.o=%.ko) $(modules:%.o=%.mod.o)
6464
65−# Add FORCE to the prequisites of a target to force it to be always rebuilt.
65+# Add FORCE to the prerequisites of a target to force it to be always rebuilt.
6666 # ---------------------------------------------------------------------------
6767
6868 PHONY += FORCE
scripts/Makefile.vmlinux+1−1
@@ -33,7 +33,7 @@ targets += vmlinux · 32 unmodified lines
3333 vmlinux: scripts/link-vmlinux.sh vmlinux.o $(KBUILD_LDS) FORCE
3434 +$(call if_changed_dep,link_vmlinux)
3535
36−# Add FORCE to the prequisites of a target to force it to be always rebuilt.
36+# Add FORCE to the prerequisites of a target to force it to be always rebuilt.
3737 # ---------------------------------------------------------------------------
3838
3939 PHONY += FORCE
scripts/Makefile.vmlinux_o+1−1
@@ -87,7 +87,7 @@ targets += modules.builtin · 86 unmodified lines
8787 modules.builtin: modules.builtin.modinfo FORCE
8888 $(call if_changed,modules_builtin)
8989
90−# Add FORCE to the prequisites of a target to force it to be always rebuilt.
90+# Add FORCE to the prerequisites of a target to force it to be always rebuilt.
9191 # ---------------------------------------------------------------------------
9292
9393 PHONY += FORCE
scripts/checkpatch.pl+0−10
@@ -4015,16 +4015,6 @@ sub process { · 4014 unmodified lines
40154015 }
40164016 }
40174017
4018−# Block comment styles
4019−# Networking with an initial /*
4020− if ($realfile =~ m@^(drivers/net/|net/)@ &&
4021− $prevrawline =~ /^\+[ \t]*\/\*[ \t]*$/ &&
4022− $rawline =~ /^\+[ \t]*\*/ &&
4023− $realline > 3) { # Do not warn about the initial copyright comment block after SPDX-License-Identifier
4024− WARN("NETWORKING_BLOCK_COMMENT_STYLE",
4025− "networking block comments don't use an empty /* line, use /* Comment...\n" . $hereprev);
4026− }
4027−
40284018 # Block comments use * on subsequent lines
40294019 if ($prevline =~ /$;[ \t]*$/ && #ends in comment
40304020 $prevrawline =~ /^\+.*?\/\*/ && #starting /*
scripts/gcc-plugins/randomize_layout_plugin.c+0−4
@@ -19,10 +19,6 @@ · 18 unmodified lines
1919 #include "gcc-common.h"
2020 #include "randomize_layout_seed.h"
2121
22−#if BUILDING_GCC_MAJOR < 4 || (BUILDING_GCC_MAJOR == 4 && BUILDING_GCC_MINOR < 7)
23−#error "The RANDSTRUCT plugin requires GCC 4.7 or newer."
24−#endif
25−
2622 #define ORIG_TYPE_NAME(node) \
2723 (TYPE_NAME(TYPE_MAIN_VARIANT(node)) != NULL_TREE ? ((const unsigned char *)IDENTIFIER_POINTER(TYPE_NAME(TYPE_MAIN_VARIANT(node)))) : (const unsigned char *)"anonymous")
2824
scripts/generate_rust_analyzer.py+5−1
@@ -145,6 +145,7 @@ def main(): · 144 unmodified lines
145145 parser.add_argument('--cfgs', action='append', default=[])
146146 parser.add_argument("srctree", type=pathlib.Path)
147147 parser.add_argument("objtree", type=pathlib.Path)
148+ parser.add_argument("sysroot", type=pathlib.Path)
148149 parser.add_argument("sysroot_src", type=pathlib.Path)
149150 parser.add_argument("exttree", type=pathlib.Path, nargs="?")
150151 args = parser.parse_args()
@@ -154,9 +155,12 @@ def main(): · 3 unmodified lines
154155 level=logging.INFO if args.verbose else logging.WARNING
155156 )
156157
158+ # Making sure that the `sysroot` and `sysroot_src` belong to the same toolchain.
159+ assert args.sysroot in args.sysroot_src.parents
160+
157161 rust_project = {
158162 "crates": generate_crates(args.srctree, args.objtree, args.sysroot_src, args.exttree, args.cfgs),
159− "sysroot_src": str(args.sysroot_src),
163+ "sysroot": str(args.sysroot),
160164 }
161165
162166 json.dump(rust_project, sys.stdout, sort_keys=True, indent=4)
scripts/generate_rust_target.rs+2−2
@@ -162,7 +162,7 @@ fn main() { · 161 unmodified lines
162162 "data-layout",
163163 "e-m:e-p270:32:32-p271:32:32-p272:64:64-i64:64-i128:128-f80:128-n8:16:32:64-S128",
164164 );
165− let mut features = "-3dnow,-3dnowa,-mmx,+soft-float".to_string();
165+ let mut features = "-mmx,+soft-float".to_string();
166166 if cfg.has("MITIGATION_RETPOLINE") {
167167 features += ",+retpoline-external-thunk";
168168 }
@@ -179,7 +179,7 @@ fn main() { · 10 unmodified lines
179179 "data-layout",
180180 "e-m:e-p:32:32-p270:32:32-p271:32:32-p272:64:64-i128:128-f64:32:64-f80:32-n8:16:32-S128",
181181 );
182− let mut features = "-3dnow,-3dnowa,-mmx,+soft-float".to_string();
182+ let mut features = "-mmx,+soft-float".to_string();
183183 if cfg.has("MITIGATION_RETPOLINE") {
184184 features += ",+retpoline-external-thunk";
185185 }
scripts/kallsyms.c+2−29
@@ -5,8 +5,7 @@ · 4 unmodified lines
55 * This software may be used and distributed according to the terms
66 * of the GNU General Public License, incorporated herein by reference.
77 *
8− * Usage: kallsyms [--all-symbols] [--absolute-percpu]
9− * [--lto-clang] in.map > out.S
8+ * Usage: kallsyms [--all-symbols] [--absolute-percpu] in.map > out.S
109 *
1110 * Table compression uses all the unused char codes on the symbols and
1211 * maps these to the most used substrings (tokens). For instance, it might
@@ -62,7 +61,6 @@ static struct sym_entry **table; · 49 unmodified lines
6261 static unsigned int table_size, table_cnt;
6362 static int all_symbols;
6463 static int absolute_percpu;
65−static int lto_clang;
6664
6765 static int token_profit[0x10000];
6866
@@ -73,8 +71,7 @@ static unsigned char best_table_len[256]; · 4 unmodified lines
7371
7472 static void usage(void)
7573 {
76− fprintf(stderr, "Usage: kallsyms [--all-symbols] [--absolute-percpu] "
77− "[--lto-clang] in.map > out.S\n");
74+ fprintf(stderr, "Usage: kallsyms [--all-symbols] [--absolute-percpu] in.map > out.S\n");
7875 exit(1);
7976 }
8077
@@ -344,25 +341,6 @@ static bool symbol_absolute(const struct sym_entry *s) · 263 unmodified lines
344341 return s->percpu_absolute;
345342 }
346343
347−static void cleanup_symbol_name(char *s)
348−{
349− char *p;
350−
351− /*
352− * ASCII[.] = 2e
353− * ASCII[0-9] = 30,39
354− * ASCII[A-Z] = 41,5a
355− * ASCII[_] = 5f
356− * ASCII[a-z] = 61,7a
357− *
358− * As above, replacing the first '.' in ".llvm." with '\0' does not
359− * affect the main sorting, but it helps us with subsorting.
360− */
361− p = strstr(s, ".llvm.");
362− if (p)
363− *p = '\0';
364−}
365−
366344 static int compare_names(const void *a, const void *b)
367345 {
368346 int ret;
@@ -526,10 +504,6 @@ static void write_src(void) · 157 unmodified lines
526504 output_address(relative_base);
527505 printf("\n");
528506
529− if (lto_clang)
530− for (i = 0; i < table_cnt; i++)
531− cleanup_symbol_name((char *)table[i]->sym);
532−
533507 sort_symbols_by_name();
534508 output_label("kallsyms_seqs_of_names");
535509 for (i = 0; i < table_cnt; i++)
@@ -807,7 +781,6 @@ int main(int argc, char **argv) · 271 unmodified lines
807781 static const struct option long_options[] = {
808782 {"all-symbols", no_argument, &all_symbols, 1},
809783 {"absolute-percpu", no_argument, &absolute_percpu, 1},
810− {"lto-clang", no_argument, &lto_clang, 1},
811784 {},
812785 };
813786
scripts/kconfig/merge_config.sh+2−0
@@ -167,6 +167,8 @@ for ORIG_MERGE_FILE in $MERGE_LIST ; do · 166 unmodified lines
167167 sed -i "/$CFG[ =]/d" $MERGE_FILE
168168 fi
169169 done
170+ # In case the previous file lacks a new line at the end
171+ echo >> $TMP_FILE
170172 cat $MERGE_FILE >> $TMP_FILE
171173 done
172174
scripts/link-vmlinux.sh+2−5
@@ -156,10 +156,6 @@ kallsyms() · 155 unmodified lines
156156 kallsymopt="${kallsymopt} --absolute-percpu"
157157 fi
158158
159− if is_enabled CONFIG_LTO_CLANG; then
160− kallsymopt="${kallsymopt} --lto-clang"
161− fi
162−
163159 info KSYMS "${2}.S"
164160 scripts/kallsyms ${kallsymopt} "${1}" > "${2}.S"
165161
@@ -219,7 +215,8 @@ kallsymso= · 53 unmodified lines
219215 strip_debug=
220216
221217 if is_enabled CONFIG_KALLSYMS; then
222− kallsyms /dev/null .tmp_vmlinux0.kallsyms
218+ truncate -s0 .tmp_vmlinux.kallsyms0.syms
219+ kallsyms .tmp_vmlinux.kallsyms0.syms .tmp_vmlinux0.kallsyms
223220 fi
224221
225222 if is_enabled CONFIG_KALLSYMS || is_enabled CONFIG_DEBUG_INFO_BTF; then
scripts/syscall.tbl+3−3
@@ -53,6 +53,7 @@ · 52 unmodified lines
5353 39 common umount2 sys_umount
5454 40 common mount sys_mount
5555 41 common pivot_root sys_pivot_root
56+42 common nfsservctl sys_ni_syscall
5657 43 32 statfs64 sys_statfs64 compat_sys_statfs64
5758 43 64 statfs sys_statfs
5859 44 32 fstatfs64 sys_fstatfs64 compat_sys_fstatfs64
@@ -98,9 +99,9 @@ · 39 unmodified lines
9899 77 common tee sys_tee
99100 78 common readlinkat sys_readlinkat
100101 79 stat64 fstatat64 sys_fstatat64
101−79 newstat fstatat sys_newfstatat
102+79 64 newfstatat sys_newfstatat
102103 80 stat64 fstat64 sys_fstat64
103−80 newstat fstat sys_newfstat
104+80 64 fstat sys_newfstat
104105 81 common sync sys_sync
105106 82 common fsync sys_fsync
106107 83 common fdatasync sys_fdatasync
@@ -402,4 +403,3 @@ · 295 unmodified lines
402403 460 common lsm_set_self_attr sys_lsm_set_self_attr
403404 461 common lsm_list_modules sys_lsm_list_modules
404405 462 common mseal sys_mseal
405−467 common uretprobe sys_uretprobe