History

kbuild: trivial - use tabs for code indent where possible

Masahiro Yamada committed 12 years ago

Commit bb66fc61 parent 7eb6e3419 files · +89 −91Browse files

Showing the changes to scripts/mod (3 of 19 files). Show all

Unified · Split

3 files
  1. scripts/mod/file2alias.c +20 −22
  2. scripts/mod/modpost.c +15 −15
  3. scripts/mod/sumversion.c +2 −2
scripts/mod/file2alias.c+20−22
@@ -644,28 +644,26 @@ ADD_TO_DEVTABLE("pcmcia", pcmcia_device_id, do_pcmcia_entry); · 643 unmodified lines
644644
645645 static int do_of_entry (const char *filename, void *symval, char *alias)
646646 {
647− int len;
648− char *tmp;
649− DEF_FIELD_ADDR(symval, of_device_id, name);
650− DEF_FIELD_ADDR(symval, of_device_id, type);
651− DEF_FIELD_ADDR(symval, of_device_id, compatible);
652−
653− len = sprintf (alias, "of:N%sT%s",
654− (*name)[0] ? *name : "*",
655− (*type)[0] ? *type : "*");
656−
657− if (compatible[0])
658− sprintf (&alias[len], "%sC%s",
659− (*type)[0] ? "*" : "",
660− *compatible);
661−
662− /* Replace all whitespace with underscores */
663− for (tmp = alias; tmp && *tmp; tmp++)
664− if (isspace (*tmp))
665− *tmp = '_';
666−
667− add_wildcard(alias);
668− return 1;
647+ int len;
648+ char *tmp;
649+ DEF_FIELD_ADDR(symval, of_device_id, name);
650+ DEF_FIELD_ADDR(symval, of_device_id, type);
651+ DEF_FIELD_ADDR(symval, of_device_id, compatible);
652+
653+ len = sprintf(alias, "of:N%sT%s", (*name)[0] ? *name : "*",
654+ (*type)[0] ? *type : "*");
655+
656+ if (compatible[0])
657+ sprintf(&alias[len], "%sC%s", (*type)[0] ? "*" : "",
658+ *compatible);
659+
660+ /* Replace all whitespace with underscores */
661+ for (tmp = alias; tmp && *tmp; tmp++)
662+ if (isspace (*tmp))
663+ *tmp = '_';
664+
665+ add_wildcard(alias);
666+ return 1;
669667 }
670668 ADD_TO_DEVTABLE("of", of_device_id, do_of_entry);
671669
scripts/mod/modpost.c+15−15
@@ -862,7 +862,7 @@ static const char *section_white_list[] = · 861 unmodified lines
862862 * without "ax" / "aw".
863863 */
864864 static void check_section(const char *modname, struct elf_info *elf,
865− Elf_Shdr *sechdr)
865+ Elf_Shdr *sechdr)
866866 {
867867 const char *sec = sech_name(elf, sechdr);
868868
@@ -1296,12 +1296,12 @@ static void print_section_list(const char * const list[20]) · 427 unmodified lines
12961296 */
12971297 static void report_sec_mismatch(const char *modname,
12981298 const struct sectioncheck *mismatch,
1299− const char *fromsec,
1300− unsigned long long fromaddr,
1301− const char *fromsym,
1302− int from_is_func,
1303− const char *tosec, const char *tosym,
1304− int to_is_func)
1299+ const char *fromsec,
1300+ unsigned long long fromaddr,
1301+ const char *fromsym,
1302+ int from_is_func,
1303+ const char *tosec, const char *tosym,
1304+ int to_is_func)
13051305 {
13061306 const char *from, *from_p;
13071307 const char *to, *to_p;
@@ -1441,7 +1441,7 @@ static void report_sec_mismatch(const char *modname, · 133 unmodified lines
14411441 }
14421442
14431443 static void check_section_mismatch(const char *modname, struct elf_info *elf,
1444− Elf_Rela *r, Elf_Sym *sym, const char *fromsec)
1444+ Elf_Rela *r, Elf_Sym *sym, const char *fromsec)
14451445 {
14461446 const char *tosec;
14471447 const struct sectioncheck *mismatch;
@@ -1528,7 +1528,7 @@ static int addend_arm_rel(struct elf_info *elf, Elf_Shdr *sechdr, Elf_Rela *r) · 80 unmodified lines
15281528 case R_ARM_ABS32:
15291529 /* From ARM ABI: (S + A) | T */
15301530 r->r_addend = (int)(long)
1531− (elf->symtab_start + ELF_R_SYM(r->r_info));
1531+ (elf->symtab_start + ELF_R_SYM(r->r_info));
15321532 break;
15331533 case R_ARM_PC24:
15341534 case R_ARM_CALL:
@@ -1538,8 +1538,8 @@ static int addend_arm_rel(struct elf_info *elf, Elf_Shdr *sechdr, Elf_Rela *r) · 3 unmodified lines
15381538 case R_ARM_THM_JUMP19:
15391539 /* From ARM ABI: ((S + A) | T) - P */
15401540 r->r_addend = (int)(long)(elf->hdr +
1541− sechdr->sh_offset +
1542− (r->r_offset - sechdr->sh_addr));
1541+ sechdr->sh_offset +
1542+ (r->r_offset - sechdr->sh_addr));
15431543 break;
15441544 default:
15451545 return 1;
@@ -1571,7 +1571,7 @@ static int addend_mips_rel(struct elf_info *elf, Elf_Shdr *sechdr, Elf_Rela *r) · 25 unmodified lines
15711571 }
15721572
15731573 static void section_rela(const char *modname, struct elf_info *elf,
1574− Elf_Shdr *sechdr)
1574+ Elf_Shdr *sechdr)
15751575 {
15761576 Elf_Sym *sym;
15771577 Elf_Rela *rela;
@@ -1615,7 +1615,7 @@ static void section_rela(const char *modname, struct elf_info *elf, · 37 unmodified lines
16151615 }
16161616
16171617 static void section_rel(const char *modname, struct elf_info *elf,
1618− Elf_Shdr *sechdr)
1618+ Elf_Shdr *sechdr)
16191619 {
16201620 Elf_Sym *sym;
16211621 Elf_Rel *rel;
@@ -1685,7 +1685,7 @@ static void section_rel(const char *modname, struct elf_info *elf, · 63 unmodified lines
16851685 * be discarded and warns about it.
16861686 **/
16871687 static void check_sec_ref(struct module *mod, const char *modname,
1688− struct elf_info *elf)
1688+ struct elf_info *elf)
16891689 {
16901690 int i;
16911691 Elf_Shdr *sechdrs = elf->sechdrs;
@@ -1945,7 +1945,7 @@ static int add_versions(struct buffer *b, struct module *mod) · 253 unmodified lines
19451945 s->name, mod->name);
19461946 } else {
19471947 merror("\"%s\" [%s.ko] undefined!\n",
1948− s->name, mod->name);
1948+ s->name, mod->name);
19491949 err = 1;
19501950 }
19511951 }
scripts/mod/sumversion.c+2−2
@@ -214,7 +214,7 @@ static void md4_final_ascii(struct md4_ctx *mctx, char *out, unsigned int len) · 213 unmodified lines
214214 mctx->block[14] = mctx->byte_count << 3;
215215 mctx->block[15] = mctx->byte_count >> 29;
216216 le32_to_cpu_array(mctx->block, (sizeof(mctx->block) -
217− sizeof(uint64_t)) / sizeof(uint32_t));
217+ sizeof(uint64_t)) / sizeof(uint32_t));
218218 md4_transform(mctx->hash, mctx->block);
219219 cpu_to_le32_array(mctx->hash, sizeof(mctx->hash) / sizeof(uint32_t));
220220
@@ -367,7 +367,7 @@ static int parse_source_files(const char *objfile, struct md4_ctx *md) · 146 unmodified lines
367367 break;
368368 /* Terminate line at first space, to get rid of final ' \' */
369369 while (*p) {
370− if (isspace(*p)) {
370+ if (isspace(*p)) {
371371 *p = '\0';
372372 break;
373373 }

Keyboard shortcuts

General

Show keyboard shortcuts
?
Focus the current search
/

Issues and pull requests

Open filters
f

Issues, pull requests and Inbox

Select next item
j↓
Select previous item
k↑
Open selected item
Enter
Dismiss filters or clear selection
Esc

Repository code

Go to file
t