x86: rename all fields of mpc_bus mpc_X to X

Impact: cleanup, solve 80 columns wrap problems

It would be cleaner to rename all the mpc->mpc_X fields to
mpc->X - that alone would give 4 characters per usage site.
(we already know that it's an 'mpc' entity -
no need to duplicate that in the field too)

Signed-off-by: Jaswinder Singh Rajput <jaswinderrajput@gmail.com>
Signed-off-by: Ingo Molnar <mingo@elte.hu>

authored by

Jaswinder Singh Rajput and committed by
Ingo Molnar
d4c715fa c4563826

+27 -27
+3 -3
arch/x86/include/asm/mpspec_def.h
··· 81 }; 82 83 struct mpc_bus { 84 - unsigned char mpc_type; 85 - unsigned char mpc_busid; 86 - unsigned char mpc_bustype[6]; 87 }; 88 89 /* List of Bus Type string values, Intel MP Spec. */
··· 81 }; 82 83 struct mpc_bus { 84 + unsigned char type; 85 + unsigned char busid; 86 + unsigned char bustype[6]; 87 }; 88 89 /* List of Bus Type string values, Intel MP Spec. */
+20 -20
arch/x86/kernel/mpparse.c
··· 77 static void __init MP_bus_info(struct mpc_bus *m) 78 { 79 char str[7]; 80 - memcpy(str, m->mpc_bustype, 6); 81 str[6] = 0; 82 83 if (x86_quirks->mpc_oem_bus_info) 84 x86_quirks->mpc_oem_bus_info(m, str); 85 else 86 - apic_printk(APIC_VERBOSE, "Bus #%d is %s\n", m->mpc_busid, str); 87 88 #if MAX_MP_BUSSES < 256 89 - if (m->mpc_busid >= MAX_MP_BUSSES) { 90 printk(KERN_WARNING "MP table busid value (%d) for bustype %s " 91 " is too large, max. supported is %d\n", 92 - m->mpc_busid, str, MAX_MP_BUSSES - 1); 93 return; 94 } 95 #endif 96 97 if (strncmp(str, BUSTYPE_ISA, sizeof(BUSTYPE_ISA) - 1) == 0) { 98 - set_bit(m->mpc_busid, mp_bus_not_pci); 99 #if defined(CONFIG_EISA) || defined(CONFIG_MCA) 100 - mp_bus_id_to_type[m->mpc_busid] = MP_BUS_ISA; 101 #endif 102 } else if (strncmp(str, BUSTYPE_PCI, sizeof(BUSTYPE_PCI) - 1) == 0) { 103 if (x86_quirks->mpc_oem_pci_bus) 104 x86_quirks->mpc_oem_pci_bus(m); 105 106 - clear_bit(m->mpc_busid, mp_bus_not_pci); 107 #if defined(CONFIG_EISA) || defined(CONFIG_MCA) 108 - mp_bus_id_to_type[m->mpc_busid] = MP_BUS_PCI; 109 } else if (strncmp(str, BUSTYPE_EISA, sizeof(BUSTYPE_EISA) - 1) == 0) { 110 - mp_bus_id_to_type[m->mpc_busid] = MP_BUS_EISA; 111 } else if (strncmp(str, BUSTYPE_MCA, sizeof(BUSTYPE_MCA) - 1) == 0) { 112 - mp_bus_id_to_type[m->mpc_busid] = MP_BUS_MCA; 113 #endif 114 } else 115 printk(KERN_WARNING "Unknown bustype %s - ignoring\n", str); ··· 484 struct mpc_ioapic ioapic; 485 struct mpc_bus bus; 486 487 - bus.mpc_type = MP_BUS; 488 - bus.mpc_busid = 0; 489 switch (mpc_default_type) { 490 default: 491 printk(KERN_ERR "???\nUnknown standard configuration %d\n", ··· 493 /* fall through */ 494 case 1: 495 case 5: 496 - memcpy(bus.mpc_bustype, "ISA ", 6); 497 break; 498 case 2: 499 case 6: 500 case 3: 501 - memcpy(bus.mpc_bustype, "EISA ", 6); 502 break; 503 case 4: 504 case 7: 505 - memcpy(bus.mpc_bustype, "MCA ", 6); 506 } 507 MP_bus_info(&bus); 508 if (mpc_default_type > 4) { 509 - bus.mpc_busid = 1; 510 - memcpy(bus.mpc_bustype, "PCI ", 6); 511 MP_bus_info(&bus); 512 } 513 ··· 656 "using default mptable. " 657 "(tell your hw vendor)\n"); 658 659 - bus.mpc_type = MP_BUS; 660 - bus.mpc_busid = 0; 661 - memcpy(bus.mpc_bustype, "ISA ", 6); 662 MP_bus_info(&bus); 663 664 construct_default_ioirq_mptable(0);
··· 77 static void __init MP_bus_info(struct mpc_bus *m) 78 { 79 char str[7]; 80 + memcpy(str, m->bustype, 6); 81 str[6] = 0; 82 83 if (x86_quirks->mpc_oem_bus_info) 84 x86_quirks->mpc_oem_bus_info(m, str); 85 else 86 + apic_printk(APIC_VERBOSE, "Bus #%d is %s\n", m->busid, str); 87 88 #if MAX_MP_BUSSES < 256 89 + if (m->busid >= MAX_MP_BUSSES) { 90 printk(KERN_WARNING "MP table busid value (%d) for bustype %s " 91 " is too large, max. supported is %d\n", 92 + m->busid, str, MAX_MP_BUSSES - 1); 93 return; 94 } 95 #endif 96 97 if (strncmp(str, BUSTYPE_ISA, sizeof(BUSTYPE_ISA) - 1) == 0) { 98 + set_bit(m->busid, mp_bus_not_pci); 99 #if defined(CONFIG_EISA) || defined(CONFIG_MCA) 100 + mp_bus_id_to_type[m->busid] = MP_BUS_ISA; 101 #endif 102 } else if (strncmp(str, BUSTYPE_PCI, sizeof(BUSTYPE_PCI) - 1) == 0) { 103 if (x86_quirks->mpc_oem_pci_bus) 104 x86_quirks->mpc_oem_pci_bus(m); 105 106 + clear_bit(m->busid, mp_bus_not_pci); 107 #if defined(CONFIG_EISA) || defined(CONFIG_MCA) 108 + mp_bus_id_to_type[m->busid] = MP_BUS_PCI; 109 } else if (strncmp(str, BUSTYPE_EISA, sizeof(BUSTYPE_EISA) - 1) == 0) { 110 + mp_bus_id_to_type[m->busid] = MP_BUS_EISA; 111 } else if (strncmp(str, BUSTYPE_MCA, sizeof(BUSTYPE_MCA) - 1) == 0) { 112 + mp_bus_id_to_type[m->busid] = MP_BUS_MCA; 113 #endif 114 } else 115 printk(KERN_WARNING "Unknown bustype %s - ignoring\n", str); ··· 484 struct mpc_ioapic ioapic; 485 struct mpc_bus bus; 486 487 + bus.type = MP_BUS; 488 + bus.busid = 0; 489 switch (mpc_default_type) { 490 default: 491 printk(KERN_ERR "???\nUnknown standard configuration %d\n", ··· 493 /* fall through */ 494 case 1: 495 case 5: 496 + memcpy(bus.bustype, "ISA ", 6); 497 break; 498 case 2: 499 case 6: 500 case 3: 501 + memcpy(bus.bustype, "EISA ", 6); 502 break; 503 case 4: 504 case 7: 505 + memcpy(bus.bustype, "MCA ", 6); 506 } 507 MP_bus_info(&bus); 508 if (mpc_default_type > 4) { 509 + bus.busid = 1; 510 + memcpy(bus.bustype, "PCI ", 6); 511 MP_bus_info(&bus); 512 } 513 ··· 656 "using default mptable. " 657 "(tell your hw vendor)\n"); 658 659 + bus.type = MP_BUS; 660 + bus.busid = 0; 661 + memcpy(bus.bustype, "ISA ", 6); 662 MP_bus_info(&bus); 663 664 construct_default_ioirq_mptable(0);
+4 -4
arch/x86/kernel/numaq_32.c
··· 139 int quad = translation_table[mpc_record]->trans_quad; 140 int local = translation_table[mpc_record]->trans_local; 141 142 - mp_bus_id_to_node[m->mpc_busid] = quad; 143 - mp_bus_id_to_local[m->mpc_busid] = local; 144 printk(KERN_INFO "Bus #%d is %s (node %d)\n", 145 - m->mpc_busid, name, quad); 146 } 147 148 int quad_local_to_mp_bus_id [NR_CPUS/4][4]; ··· 153 int quad = translation_table[mpc_record]->trans_quad; 154 int local = translation_table[mpc_record]->trans_local; 155 156 - quad_local_to_mp_bus_id[quad][local] = m->mpc_busid; 157 } 158 159 static void __init MP_translation_info(struct mpc_config_translation *m)
··· 139 int quad = translation_table[mpc_record]->trans_quad; 140 int local = translation_table[mpc_record]->trans_local; 141 142 + mp_bus_id_to_node[m->busid] = quad; 143 + mp_bus_id_to_local[m->busid] = local; 144 printk(KERN_INFO "Bus #%d is %s (node %d)\n", 145 + m->busid, name, quad); 146 } 147 148 int quad_local_to_mp_bus_id [NR_CPUS/4][4]; ··· 153 int quad = translation_table[mpc_record]->trans_quad; 154 int local = translation_table[mpc_record]->trans_local; 155 156 + quad_local_to_mp_bus_id[quad][local] = m->busid; 157 } 158 159 static void __init MP_translation_info(struct mpc_config_translation *m)