# calibrate.h

    00001 #define CALSRQ        0xcacca
    00002
    00003 #define CAL_8254      1
    00004 #define KLATENCY      2
    00005 #define END_KLATENCY  3
    00006 #define FREQ_CAL      4
    00007 #define END_FREQ_CAL  5
    00008 #define BUS_CHECK     6
    00009 #define END_BUS_CHECK 7
    00010 #define GET_PARAMS    8
    00011
    00012 #define PARPORT       0x370
    00013
    00014 #define MAXARGS       4
    00015 #define STACKSIZE     2000
    00016 #define FIFOBUFSIZE   1000
    00017 #define INILOOPS      100
    00018
    00019 struct params_t { unsigned long
    00020         mp,
    00021         setup_time_8254,
    00022         latency_8254,
    00023         freq_apic,
    00024         latency_apic,
    00025         setup_time_apic,
    00026         calibrated_apic_freq,
    00027         cpu_freq,
    00028         calibrated_cpu_freq,
    00029         clock_tick_rate,
    00030         latch;
    00031 };
    00032
    00033 struct times_t {
    00034         unsigned long long cpu_time;
    00035         unsigned long apic_time;
    00036         int intrs;
    00037 };