Changeset ed0dd65 in mainline for arch/ia32/src/smp/mps.c


Ignore:
Timestamp:
2005-04-30T16:47:17Z (20 years ago)
Author:
Jakub Jermar <jakub@…>
Branches:
lfn, master, serial, ticket/834-toolchain-update, topic/msim-upgrade, topic/simplify-dev-export
Children:
30ef8ce
Parents:
10a2e22
Message:

More ACPI work.
Initial MADT table parsing.

SMP renaming and reorganization to reflect there are more ways to bring SMP up.

File:
1 moved

Legend:

Unmodified
Added
Removed
  • arch/ia32/src/smp/mps.c

    r10a2e22 red0dd65  
    11/*
    2  * Copyright (C) 2001-2004 Jakub Jermar
     2 * Copyright (C) 2001-2005 Jakub Jermar
    33 * All rights reserved.
    44 *
     
    3333#include <print.h>
    3434#include <panic.h>
    35 #include <arch/smp/mp.h>
     35#include <arch/smp/mps.h>
    3636#include <arch/smp/ap.h>
    3737#include <arch/smp/apic.h>
     
    5151
    5252/*
    53  * Multi-Processor Specification detection code.
     53 * MultiProcessor Specification detection code.
    5454 */
    5555
     
    5757#define CT_SIGNATURE    0x504d4350
    5858
    59 int mp_fs_check(__u8 *base);
    60 int mp_ct_check(void);
     59int mps_fs_check(__u8 *base);
     60int mps_ct_check(void);
    6161
    6262int configure_via_ct(void);
     
    7171void ct_extended_entries(void);
    7272
    73 static struct __mpfs *fs;
    74 static struct __mpct *ct;
     73static struct mps_fs *fs;
     74static struct mps_ct *ct;
    7575
    7676struct __processor_entry *processor_entries = NULL;
     
    9292 * Used to check the integrity of the MP Floating Structure.
    9393 */
    94 int mp_fs_check(__u8 *base)
     94int mps_fs_check(__u8 *base)
    9595{
    9696        int i;
     
    106106 * Used to check the integrity of the MP Configuration Table.
    107107 */
    108 int mp_ct_check(void)
     108int mps_ct_check(void)
    109109{
    110110        __u8 *base = (__u8 *) ct;
     
    127127}
    128128
    129 void mp_init(void)
     129void mps_init(void)
    130130{
    131131        __u8 *addr[2] = { NULL, (__u8 *) 0xf0000 };
     
    143143        for (i = 0; i < 2; i++) {
    144144                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];
    147147                                goto fs_found;
    148148                        }
     
    153153       
    154154fs_found:
    155         printf("%L: MP Floating Pointer Structure\n", fs);
     155        printf("%L: MPS Floating Pointer Structure\n", fs);
    156156
    157157        frame_not_free((__address) fs);
     
    159159        if (fs->config_type == 0 && fs->configuration_table) {
    160160                if (fs->mpfib2 >> 7) {
    161                         printf("mp_init: PIC mode not supported\n");
     161                        printf("mps_init: PIC mode not supported\n");
    162162                        return;
    163163                }
     
    192192                return 1;
    193193        }
    194         if (!mp_ct_check()) {
     194        if (!mps_ct_check()) {
    195195                printf("configure_via_ct: bad ct checksum\n");
    196196                return 1;
     
    288288void ct_bus_entry(struct __bus_entry *bus)
    289289{
    290 #ifdef MPCT_VERBOSE
     290#ifdef MPSCT_VERBOSE
    291291        char buf[7];
    292292        memcopy((__address) bus->bus_type, (__address) buf,6);
     
    316316}
    317317
    318 //#define MPCT_VERBOSE
     318//#define MPSCT_VERBOSE
    319319void ct_io_intr_entry(struct __io_intr_entry *iointr)
    320320{
    321 #ifdef MPCT_VERBOSE
     321#ifdef MPSCT_VERBOSE
    322322        switch (iointr->intr_type) {
    323323            case 0: printf("INT"); break;
     
    350350void ct_l_intr_entry(struct __l_intr_entry *lintr)
    351351{
    352 #ifdef MPCT_VERBOSE
     352#ifdef MPSCT_VERBOSE
    353353        switch (lintr->intr_type) {
    354354            case 0: printf("INT"); break;
     
    496496}
    497497
    498 int mp_irq_to_pin(int irq)
     498int mps_irq_to_pin(int irq)
    499499{
    500500        int i;
Note: See TracChangeset for help on using the changeset viewer.