Eliminate one set of XBOX #ifdefs. The Xbox code just needs to set a

different TIMER_FREQ value than default.  Accomplish this via the
config file rather than via an #ifdef.
This commit is contained in:
Warner Losh 2006-08-09 23:47:38 +00:00
parent f5190c1277
commit ddebcb409b
3 changed files with 2 additions and 18 deletions

View File

@ -42,6 +42,8 @@ options CD9660 # ISO 9660 Filesystem
#options _KPOSIX_PRIORITY_SCHEDULING # POSIX P1003_1B real-time extensions
#options KBD_INSTALL_CDEV # install a CDEV entry in /dev
options ADAPTIVE_GIANT # Giant mutex is adaptive.
# Xbox has a non-standard default timer frequency
options TIMER_FREQ=1125000 # Gives ~733.34MHz CPU
#device apic # I/O APIC

View File

@ -93,10 +93,6 @@ __FBSDID("$FreeBSD$");
#include <i386/bios/mca_machdep.h>
#endif
#ifdef XBOX
#include <machine/xbox.h>
#endif
/*
* 32-bit time_t's can't reach leap years before 1904 or after 2036, so we
* can use a simple formula for leap years.
@ -543,11 +539,6 @@ calibrate_clocks(void)
return (tot_count);
fail:
#ifdef XBOX
if (arch_i386_is_xbox)
timer_freq = 1125000; /* gives ~733.34MHz CPU clock */
#endif
if (bootverbose)
printf("failed, using default i8254 clock of %u Hz\n",
timer_freq);

View File

@ -93,10 +93,6 @@ __FBSDID("$FreeBSD$");
#include <i386/bios/mca_machdep.h>
#endif
#ifdef XBOX
#include <machine/xbox.h>
#endif
/*
* 32-bit time_t's can't reach leap years before 1904 or after 2036, so we
* can use a simple formula for leap years.
@ -543,11 +539,6 @@ calibrate_clocks(void)
return (tot_count);
fail:
#ifdef XBOX
if (arch_i386_is_xbox)
timer_freq = 1125000; /* gives ~733.34MHz CPU clock */
#endif
if (bootverbose)
printf("failed, using default i8254 clock of %u Hz\n",
timer_freq);