Changeset ed0dd65 in mainline for arch/ia32/src/smp/mps.c
- Timestamp:
- 2005-04-30T16:47:17Z (20 years ago)
- Branches:
- lfn, master, serial, ticket/834-toolchain-update, topic/msim-upgrade, topic/simplify-dev-export
- Children:
- 30ef8ce
- Parents:
- 10a2e22
- File:
-
- 1 moved
Legend:
- Unmodified
- Added
- Removed
-
arch/ia32/src/smp/mps.c
r10a2e22 red0dd65 1 1 /* 2 * Copyright (C) 2001-200 4Jakub Jermar2 * Copyright (C) 2001-2005 Jakub Jermar 3 3 * All rights reserved. 4 4 * … … 33 33 #include <print.h> 34 34 #include <panic.h> 35 #include <arch/smp/mp .h>35 #include <arch/smp/mps.h> 36 36 #include <arch/smp/ap.h> 37 37 #include <arch/smp/apic.h> … … 51 51 52 52 /* 53 * Multi -Processor Specification detection code.53 * MultiProcessor Specification detection code. 54 54 */ 55 55 … … 57 57 #define CT_SIGNATURE 0x504d4350 58 58 59 int mp _fs_check(__u8 *base);60 int mp _ct_check(void);59 int mps_fs_check(__u8 *base); 60 int mps_ct_check(void); 61 61 62 62 int configure_via_ct(void); … … 71 71 void ct_extended_entries(void); 72 72 73 static struct __mpfs *fs;74 static struct __mpct *ct;73 static struct mps_fs *fs; 74 static struct mps_ct *ct; 75 75 76 76 struct __processor_entry *processor_entries = NULL; … … 92 92 * Used to check the integrity of the MP Floating Structure. 93 93 */ 94 int mp _fs_check(__u8 *base)94 int mps_fs_check(__u8 *base) 95 95 { 96 96 int i; … … 106 106 * Used to check the integrity of the MP Configuration Table. 107 107 */ 108 int mp _ct_check(void)108 int mps_ct_check(void) 109 109 { 110 110 __u8 *base = (__u8 *) ct; … … 127 127 } 128 128 129 void mp _init(void)129 void mps_init(void) 130 130 { 131 131 __u8 *addr[2] = { NULL, (__u8 *) 0xf0000 }; … … 143 143 for (i = 0; i < 2; i++) { 144 144 for (j = 0; j < length[i]; j += 16) { 145 if (*((__u32 *) &addr[i][j]) == FS_SIGNATURE && mp _fs_check(&addr[i][j])) {146 fs = (struct __mpfs *) &addr[i][j];145 if (*((__u32 *) &addr[i][j]) == FS_SIGNATURE && mps_fs_check(&addr[i][j])) { 146 fs = (struct mps_fs *) &addr[i][j]; 147 147 goto fs_found; 148 148 } … … 153 153 154 154 fs_found: 155 printf("%L: MP Floating Pointer Structure\n", fs);155 printf("%L: MPS Floating Pointer Structure\n", fs); 156 156 157 157 frame_not_free((__address) fs); … … 159 159 if (fs->config_type == 0 && fs->configuration_table) { 160 160 if (fs->mpfib2 >> 7) { 161 printf("mp _init: PIC mode not supported\n");161 printf("mps_init: PIC mode not supported\n"); 162 162 return; 163 163 } … … 192 192 return 1; 193 193 } 194 if (!mp _ct_check()) {194 if (!mps_ct_check()) { 195 195 printf("configure_via_ct: bad ct checksum\n"); 196 196 return 1; … … 288 288 void ct_bus_entry(struct __bus_entry *bus) 289 289 { 290 #ifdef MP CT_VERBOSE290 #ifdef MPSCT_VERBOSE 291 291 char buf[7]; 292 292 memcopy((__address) bus->bus_type, (__address) buf,6); … … 316 316 } 317 317 318 //#define MP CT_VERBOSE318 //#define MPSCT_VERBOSE 319 319 void ct_io_intr_entry(struct __io_intr_entry *iointr) 320 320 { 321 #ifdef MP CT_VERBOSE321 #ifdef MPSCT_VERBOSE 322 322 switch (iointr->intr_type) { 323 323 case 0: printf("INT"); break; … … 350 350 void ct_l_intr_entry(struct __l_intr_entry *lintr) 351 351 { 352 #ifdef MP CT_VERBOSE352 #ifdef MPSCT_VERBOSE 353 353 switch (lintr->intr_type) { 354 354 case 0: printf("INT"); break; … … 496 496 } 497 497 498 int mp _irq_to_pin(int irq)498 int mps_irq_to_pin(int irq) 499 499 { 500 500 int i;
Note:
See TracChangeset
for help on using the changeset viewer.