diff options
| author | Jerry Gilliam <Jerry.Gilliam@Sun.COM> | 2009-11-19 11:51:27 -0800 |
|---|---|---|
| committer | Jerry Gilliam <Jerry.Gilliam@Sun.COM> | 2009-11-19 11:51:27 -0800 |
| commit | db9ce1c953f094d292df951aada6b8a85e1ff103 (patch) | |
| tree | 571cd996fde1de2bfd3703a54f7a924a20e0ed9d /usr/src | |
| parent | 6dea24b719d51f1b407611c551f7e9c4845f5e7b (diff) | |
| download | illumos-joyent-db9ce1c953f094d292df951aada6b8a85e1ff103.tar.gz | |
6899987 sparc simulator cleanup
Diffstat (limited to 'usr/src')
| -rw-r--r-- | usr/src/psm/stand/boot/common/readfile.c | 16 | ||||
| -rw-r--r-- | usr/src/psm/stand/boot/sparc/common/boot_plat.c | 7 | ||||
| -rw-r--r-- | usr/src/psm/stand/boot/sparc/common/boot_plat.h | 9 | ||||
| -rw-r--r-- | usr/src/psm/stand/boot/sparc/common/sun4dep.c | 45 | ||||
| -rw-r--r-- | usr/src/psm/stand/boot/sparcv9/sun4u/Makefile | 5 | ||||
| -rw-r--r-- | usr/src/psm/stand/boot/sparcv9/sun4v/Makefile | 7 | ||||
| -rw-r--r-- | usr/src/uts/Makefile.uts | 5 | ||||
| -rw-r--r-- | usr/src/uts/i86pc/os/ddi_impl.c | 4 | ||||
| -rw-r--r-- | usr/src/uts/sun4/os/mp_startup.c | 5 | ||||
| -rw-r--r-- | usr/src/uts/sun4u/Makefile.sun4u.shared | 2 | ||||
| -rw-r--r-- | usr/src/uts/sun4u/io/todmostek.c | 30 | ||||
| -rw-r--r-- | usr/src/uts/sun4v/Makefile.sun4v.shared | 2 |
12 files changed, 13 insertions, 124 deletions
diff --git a/usr/src/psm/stand/boot/common/readfile.c b/usr/src/psm/stand/boot/common/readfile.c index daacc98d7a..b06173fe3d 100644 --- a/usr/src/psm/stand/boot/common/readfile.c +++ b/usr/src/psm/stand/boot/common/readfile.c @@ -19,12 +19,10 @@ * CDDL HEADER END */ /* - * Copyright 2007 Sun Microsystems, Inc. All rights reserved. + * Copyright 2009 Sun Microsystems, Inc. All rights reserved. * Use is subject to license terms. */ -#pragma ident "%Z%%M% %I% %E% SMI" - #include <sys/sysmacros.h> #include <sys/types.h> #include <sys/exechdr.h> @@ -178,10 +176,6 @@ extern int boothowto; extern int pagesize; extern char filename[]; -#ifdef MPSAS -extern void sas_symtab(int start, int end); -#endif - /* * repeat reads (forever) until size of request is satisfied * (Thus, you don't want to use this cases where short reads are ok) @@ -587,10 +581,6 @@ read_elf32(int fd, int print, Elf32_Ehdr *elfhdrp) (caddr_t)(uintptr_t)phdr->p_vaddr, phdr->p_memsz); } -#ifdef MPSAS - sas_symtab(phdr->p_vaddr, - phdr->p_vaddr + phdr->p_memsz); -#endif } else if (phdr->p_type == PT_INTERP) { /* * Dynamically-linked executable. @@ -981,10 +971,6 @@ read_elf64(int fd, int print, Elf64_Ehdr *elfhdrp) sync_instruction_memory((caddr_t)(uintptr_t) phdr->p_vaddr, phdr->p_memsz); -#ifdef MPSAS - sas_symtab(phdr->p_vaddr, - phdr->p_vaddr + phdr->p_memsz); -#endif } else if (phdr->p_type == PT_INTERP) { /* * Dynamically-linked executable. diff --git a/usr/src/psm/stand/boot/sparc/common/boot_plat.c b/usr/src/psm/stand/boot/sparc/common/boot_plat.c index 9a9423cf1b..2abc69b687 100644 --- a/usr/src/psm/stand/boot/sparc/common/boot_plat.c +++ b/usr/src/psm/stand/boot/sparc/common/boot_plat.c @@ -19,12 +19,10 @@ * CDDL HEADER END */ /* - * Copyright 2007 Sun Microsystems, Inc. All rights reserved. + * Copyright 2009 Sun Microsystems, Inc. All rights reserved. * Use is subject to license terms. */ -#pragma ident "%Z%%M% %I% %E% SMI" - #include <sys/param.h> #include <sys/fcntl.h> #include <sys/obpdefs.h> @@ -202,9 +200,6 @@ post_mountroot(char *bootfile, char *redirect) if ((go2 = readfile(fd, boothowto & RB_VERBOSE)) != (int(*)()) -1) { -#ifdef MPSAS - sas_bpts(); -#endif (void) close(fd); } else { printf("boot failed\n"); diff --git a/usr/src/psm/stand/boot/sparc/common/boot_plat.h b/usr/src/psm/stand/boot/sparc/common/boot_plat.h index e6dffbedc4..393b3188b5 100644 --- a/usr/src/psm/stand/boot/sparc/common/boot_plat.h +++ b/usr/src/psm/stand/boot/sparc/common/boot_plat.h @@ -19,15 +19,13 @@ * CDDL HEADER END */ /* - * Copyright 2007 Sun Microsystems, Inc. All rights reserved. + * Copyright 2009 Sun Microsystems, Inc. All rights reserved. * Use is subject to license terms. */ #ifndef _BOOT_PLAT_H #define _BOOT_PLAT_H -#pragma ident "%Z%%M% %I% %E% SMI" - #ifdef __cplusplus extern "C" { #endif @@ -85,11 +83,6 @@ extern int vac; extern void fiximp(void); extern void retain_nvram_page(); - -#ifdef MPSAS -extern void sas_bpts(void); -#endif - extern int cpu_is_ultrasparc_1(void); diff --git a/usr/src/psm/stand/boot/sparc/common/sun4dep.c b/usr/src/psm/stand/boot/sparc/common/sun4dep.c index e4dbcc2d7b..a80cc3d60d 100644 --- a/usr/src/psm/stand/boot/sparc/common/sun4dep.c +++ b/usr/src/psm/stand/boot/sparc/common/sun4dep.c @@ -19,12 +19,10 @@ * CDDL HEADER END */ /* - * Copyright 2006 Sun Microsystems, Inc. All rights reserved. + * Copyright 2009 Sun Microsystems, Inc. All rights reserved. * Use is subject to license terms. */ -#pragma ident "%Z%%M% %I% %E% SMI" - #include <sys/types.h> #include <sys/param.h> #include <sys/fcntl.h> @@ -92,47 +90,6 @@ setup_aux(void) prom_panic("no cpu node"); } - -#ifdef MPSAS - -void sas_symtab(int start, int end); -extern int sas_command(char *cmdstr); - -/* - * SAS support - inform SAS of new symbols being dynamically added - * during simulation via the first standalone. - */ - -#ifndef BUFSIZ -#define BUFSIZ 1024 /* for cmd string buffer allocation */ -#endif - -int sas_symdebug = 0; /* SAS support */ - -void -sas_symtab(int start, int end) -{ - char *addstr = "symtab add $LD_KERNEL_PATH/%s%s 0x%x 0x%x\n"; - char *file, *prefix, cmdstr[BUFSIZ]; - extern char filename[]; - - file = filename; - prefix = *file == '/' ? "../../.." : ""; - - (void) sprintf(cmdstr, addstr, prefix, file, start, end); - - /* add the symbol table */ - if (sas_symdebug) (void) printf("sas_symtab: %s", cmdstr); - sas_command(cmdstr); -} - -void -sas_bpts() -{ - sas_command("file $KERN_SCRIPT_FILE\n"); -} -#endif /* MPSAS */ - /* * Allocate a region of virtual address space, unmapped. */ diff --git a/usr/src/psm/stand/boot/sparcv9/sun4u/Makefile b/usr/src/psm/stand/boot/sparcv9/sun4u/Makefile index 455cf316cd..6f68499e0a 100644 --- a/usr/src/psm/stand/boot/sparcv9/sun4u/Makefile +++ b/usr/src/psm/stand/boot/sparcv9/sun4u/Makefile @@ -100,11 +100,6 @@ LIBPLAT_DEP_L = $(LIBPLAT_DIR)/$(LIBPLAT_L_LIBS) PSMLIBS += $(LIBPLAT_LIBS:lib%.a=-l%) PSMLIB_DIRS += $(LIBPLAT_DIR) - -# MPSAS support -MPSAS_BUILD:sh= echo \\043 -$(MPSAS_BUILD)ARCHOPTS += -DMPSAS - include ../Makefile.com # re-define ELFCONV for 4u--- sun4u can boot ELF directly diff --git a/usr/src/psm/stand/boot/sparcv9/sun4v/Makefile b/usr/src/psm/stand/boot/sparcv9/sun4v/Makefile index 56efb6bbad..fc204fbeab 100644 --- a/usr/src/psm/stand/boot/sparcv9/sun4v/Makefile +++ b/usr/src/psm/stand/boot/sparcv9/sun4v/Makefile @@ -19,7 +19,7 @@ # CDDL HEADER END # # -# Copyright 2008 Sun Microsystems, Inc. All rights reserved. +# Copyright 2009 Sun Microsystems, Inc. All rights reserved. # Use is subject to license terms. # @@ -79,11 +79,6 @@ LIBPLAT_DEP_L = $(LIBPLAT_DIR)/$(LIBPLAT_L_LIBS) PSMLIBS += $(LIBPLAT_LIBS:lib%.a=-l%) PSMLIB_DIRS += $(LIBPLAT_DIR) - -# MPSAS support -MPSAS_BUILD:sh= echo \\043 -$(MPSAS_BUILD)ARCHOPTS += -DMPSAS - include ../Makefile.com CPPINCS += -I$(SRC)/uts/sun4u diff --git a/usr/src/uts/Makefile.uts b/usr/src/uts/Makefile.uts index 0f144dced5..a3e59dfc92 100644 --- a/usr/src/uts/Makefile.uts +++ b/usr/src/uts/Makefile.uts @@ -656,11 +656,6 @@ $(CODE_COVERAGE)$(OBJS_DIR)/unix_bb.ln := CPPFLAGS += -DKCOV $(OBJS_DIR)/unix_bb.o := XAOPT = # -# MPSAS support -# -MPSAS_BUILD:sh= echo \\043 - -# # Privilege files # PRIVS_AWK = $(SRC)/uts/common/os/privs.awk diff --git a/usr/src/uts/i86pc/os/ddi_impl.c b/usr/src/uts/i86pc/os/ddi_impl.c index fafd476529..ccfe1d2cb0 100644 --- a/usr/src/uts/i86pc/os/ddi_impl.c +++ b/usr/src/uts/i86pc/os/ddi_impl.c @@ -193,7 +193,7 @@ FP hardware exhibits Pentium floating point divide problem\n"); * is present, and builds a tree of prototype dev_info nodes * corresponding to the hardware which identified itself. */ -#if !defined(SAS) && !defined(MPSAS) + /* * Initialize root node. */ @@ -219,8 +219,6 @@ FP hardware exhibits Pentium floating point divide problem\n"); else (void) i_ddi_attach_hw_nodes("isa"); #endif - -#endif /* !SAS && !MPSAS */ } /* diff --git a/usr/src/uts/sun4/os/mp_startup.c b/usr/src/uts/sun4/os/mp_startup.c index af867f6eed..49ec390172 100644 --- a/usr/src/uts/sun4/os/mp_startup.c +++ b/usr/src/uts/sun4/os/mp_startup.c @@ -673,12 +673,7 @@ start_other_cpus(int flag) * initializing it. */ if (CPUSET_ISNULL(cpu_bringup_set)) { -#ifdef MPSAS - /* just CPU 0 */ - CPUSET_ADD(cpu_bringup_set, 0); -#else CPUSET_ALL(cpu_bringup_set); -#endif } if (&cpu_feature_init) diff --git a/usr/src/uts/sun4u/Makefile.sun4u.shared b/usr/src/uts/sun4u/Makefile.sun4u.shared index 539305cd75..9da3888d2f 100644 --- a/usr/src/uts/sun4u/Makefile.sun4u.shared +++ b/usr/src/uts/sun4u/Makefile.sun4u.shared @@ -245,8 +245,6 @@ FDOFFSETS = $(UTSBASE)/sun/io/fd_offsets.in MACHINE_DEFS = -D$(PLATFORM) -D_MACHDEP -DSFMMU -$(MPSAS_BUILD)MACHINE_DEFS += -DMPSAS - # # Software workarounds for hardware "features" # diff --git a/usr/src/uts/sun4u/io/todmostek.c b/usr/src/uts/sun4u/io/todmostek.c index db1c68da51..d9bbca3a9f 100644 --- a/usr/src/uts/sun4u/io/todmostek.c +++ b/usr/src/uts/sun4u/io/todmostek.c @@ -19,7 +19,7 @@ * CDDL HEADER END */ /* - * Copyright 2008 Sun Microsystems, Inc. All rights reserved. + * Copyright 2009 Sun Microsystems, Inc. All rights reserved. * Use is subject to license terms. */ @@ -83,10 +83,11 @@ _init(void) */ if (watchdog_enable) { if (!watchdog_available) { - cmn_err(CE_WARN, "Hardware watchdog unavailable"); + cmn_err(CE_WARN, + "Hardware watchdog unavailable"); } else if (boothowto & RB_DEBUG) { - cmn_err(CE_WARN, "Hardware watchdog disabled" - " [debugger]"); + cmn_err(CE_WARN, "Hardware watchdog disabled" + " [debugger]"); } } } @@ -118,7 +119,6 @@ static timestruc_t todm_get(void) { timestruc_t ts; -#ifndef MPSAS todinfo_t tod; int s; @@ -147,10 +147,6 @@ todm_get(void) ts.tv_sec = tod_to_utc(tod); ts.tv_nsec = 0; -#else - ts.tv_sec = 0; - ts.tv_nsec = 0; -#endif return (ts); } @@ -162,7 +158,6 @@ todm_get(void) static void todm_set(timestruc_t ts) { -#ifndef MPSAS todinfo_t tod = utc_to_tod(ts.tv_sec); ASSERT(MUTEX_HELD(&tod_lock)); @@ -176,7 +171,6 @@ todm_set(timestruc_t ts) CLOCK->clk_min = BYTE_TO_BCD(tod.tod_min); CLOCK->clk_sec = BYTE_TO_BCD(tod.tod_sec); CLOCK->clk_ctrl &= ~CLK_CTRL_WRITE; /* load values */ -#endif } @@ -190,8 +184,8 @@ todm_set_watchdog_timer(uint_t timeoutval) ASSERT(MUTEX_HELD(&tod_lock)); if (watchdog_enable == 0 || watchdog_available == 0 || - (boothowto & RB_DEBUG)) - return (0); + (boothowto & RB_DEBUG)) + return (0); watchdog_timeout = timeoutval; watchdog_bits = CLK_WATCHDOG_BITS(timeoutval); @@ -212,9 +206,7 @@ todm_clear_watchdog_timer(void) if (watchdog_activated == 0) return (0); -#ifndef MPSAS CLOCK->clk_watchdog = 0; -#endif /* MPSAS */ watchdog_bits = 0; watchdog_activated = 0; @@ -227,7 +219,6 @@ todm_clear_watchdog_timer(void) static void todm_set_power_alarm(timestruc_t ts) { -#ifndef MPSAS todinfo_t tod; uchar_t c; @@ -248,7 +239,6 @@ todm_set_power_alarm(timestruc_t ts) CLOCK->clk_alm_secs = BYTE_TO_BCD(tod.tod_sec); CLOCK->clk_interrupts |= CLK_ALARM_ENABLE; /* enable alarm intr */ -#endif /* MPSAS */ } /* @@ -257,7 +247,6 @@ todm_set_power_alarm(timestruc_t ts) static void todm_clear_power_alarm() { -#ifndef MPSAS uchar_t c; ASSERT(MUTEX_HELD(&tod_lock)); @@ -269,7 +258,6 @@ todm_clear_power_alarm() #endif CLOCK->clk_interrupts &= ~CLK_ALARM_ENABLE; /* disable alarm intr */ -#endif /* MPSAS */ } /* @@ -280,11 +268,7 @@ todm_clear_power_alarm() uint64_t todm_get_cpufrequency(void) { -#ifndef MPSAS ASSERT(MUTEX_HELD(&tod_lock)); return (find_cpufrequency(&(TIMECHECK_CLOCK->clk_sec))); -#else - return (cpunodes[CPU->cpu_id].clock_freq); -#endif /* MPSAS */ } diff --git a/usr/src/uts/sun4v/Makefile.sun4v.shared b/usr/src/uts/sun4v/Makefile.sun4v.shared index aa8e4481ab..0b27ee8299 100644 --- a/usr/src/uts/sun4v/Makefile.sun4v.shared +++ b/usr/src/uts/sun4v/Makefile.sun4v.shared @@ -221,8 +221,6 @@ FDOFFSETS = $(UTSBASE)/sun/io/fd_offsets.in MACHINE_DEFS = -D$(PLATFORM) -D_MACHDEP -DSFMMU MACHINE_DEFS += -DMAX_MEM_NODES=8 -$(MPSAS_BUILD)MACHINE_DEFS += -DMPSAS - # # Software workarounds for hardware "features" # |
