diff options
author | Richard Lowe <richlowe@richlowe.net> | 2011-06-22 10:37:21 -0700 |
---|---|---|
committer | Richard Lowe <richlowe@richlowe.net> | 2011-06-22 10:37:21 -0700 |
commit | 8682d1ef2a0960ed5a9f05b9448eaa3e68ac931f (patch) | |
tree | 97a8eff38c31609d814ca5b2ed5806e5e0553d26 /usr/src | |
parent | e65fcc69bb33b3f4525b0c2c9732ece17c90b196 (diff) | |
download | illumos-gate-8682d1ef2a0960ed5a9f05b9448eaa3e68ac931f.tar.gz |
1200 various modules declare static functions within function bodies
Reviewed by: Jason King <jason.brian.king@gmail.com>
Reviewed by: Gordon Ross <gwr@nexenta.com>
Approved by: Eric Schrock <eric.schrock@delphix.com>
Diffstat (limited to 'usr/src')
-rw-r--r-- | usr/src/cmd/picl/plugins/sun4u/snowbird/frutree/piclkstat.c | 36 | ||||
-rw-r--r-- | usr/src/lib/libbc/libc/gen/common/usleep.c | 17 | ||||
-rw-r--r-- | usr/src/uts/i86pc/io/acpi/drmach_acpi/drmach_acpi.c | 32 | ||||
-rw-r--r-- | usr/src/uts/i86pc/io/dr/dr.c | 4 | ||||
-rw-r--r-- | usr/src/uts/sun4u/cpu/opl_kdi.c | 8 | ||||
-rw-r--r-- | usr/src/uts/sun4u/ngdr/io/dr.c | 4 | ||||
-rw-r--r-- | usr/src/uts/sun4u/opl/io/drmach.c | 19 | ||||
-rw-r--r-- | usr/src/uts/sun4u/os/fillsysinfo.c | 4 | ||||
-rw-r--r-- | usr/src/uts/sun4u/serengeti/io/sbdp_cpu.c | 3 | ||||
-rw-r--r-- | usr/src/uts/sun4u/starcat/io/drmach.c | 25 | ||||
-rw-r--r-- | usr/src/uts/sun4u/starfire/io/drmach.c | 24 | ||||
-rw-r--r-- | usr/src/uts/sun4u/sunfire/io/fhc.c | 4 |
12 files changed, 84 insertions, 96 deletions
diff --git a/usr/src/cmd/picl/plugins/sun4u/snowbird/frutree/piclkstat.c b/usr/src/cmd/picl/plugins/sun4u/snowbird/frutree/piclkstat.c index 6ac96ce407..60b6b99efa 100644 --- a/usr/src/cmd/picl/plugins/sun4u/snowbird/frutree/piclkstat.c +++ b/usr/src/cmd/picl/plugins/sun4u/snowbird/frutree/piclkstat.c @@ -24,8 +24,6 @@ * Use is subject to license terms. */ -#pragma ident "%Z%%M% %I% %E% SMI" - /* * Implementation to get PORT nodes state and condition information */ @@ -70,6 +68,7 @@ static int serial_port_state(kstat_ctl_t *, char *, int); static int serial_port_cond(kstat_ctl_t *kc, char *, int); static int parallel_port_state(kstat_ctl_t *, char *, int); static int parallel_port_cond(kstat_ctl_t *kc, char *, int); +static void sig_alarm_handler(int); static funcp port_state[] = { kstat_network_port_state, @@ -144,13 +143,13 @@ kstat_name_lookup(kstat_ctl_t *kc, char *ks_module, int ks_instance, char *name) for (ksp = kc->kc_chain; ksp; ksp = ksp->ks_next) { if (strcmp(ksp->ks_module, ks_module) == 0 && - ksp->ks_instance == ks_instance && - ksp->ks_type == KSTAT_TYPE_NAMED && - kstat_read(kc, ksp, NULL) != -1 && - kstat_data_lookup(ksp, name)) { + ksp->ks_instance == ks_instance && + ksp->ks_type == KSTAT_TYPE_NAMED && + kstat_read(kc, ksp, NULL) != -1 && + kstat_data_lookup(ksp, name)) { ksp = kstat_lookup(kc, ks_module, ks_instance, - ksp->ks_name); + ksp->ks_name); if (!ksp) return (NULL); if (kstat_read(kc, ksp, NULL) == -1) @@ -171,7 +170,7 @@ kstat_network_port_state(kstat_ctl_t *kc, char *ks_module, int ks_instance) kstat_named_t *port_datap = NULL; if ((port_datap = kstat_name_lookup(kc, ks_module, ks_instance, - LINK_UP)) == NULL) { + LINK_UP)) == NULL) { return (-1); } if (port_datap == NULL) { @@ -208,7 +207,7 @@ kstat_network_port_cond(kstat_ctl_t *kc, char *ks_module, int ks_instance) uint64_t ifspeed, ierrors, ipackets, oerrors, opackets; if ((port_datap = kstat_name_lookup(kc, ks_module, ks_instance, - LINK_UP)) == NULL) { + LINK_UP)) == NULL) { return (-1); } @@ -222,7 +221,7 @@ kstat_network_port_cond(kstat_ctl_t *kc, char *ks_module, int ks_instance) } if ((port_datap = kstat_name_lookup(kc, ks_module, ks_instance, - DUPLEX)) == NULL) { + DUPLEX)) == NULL) { return (-1); } @@ -236,7 +235,7 @@ kstat_network_port_cond(kstat_ctl_t *kc, char *ks_module, int ks_instance) } if ((port_datap = kstat_name_lookup(kc, ks_module, ks_instance, - IF_SPEED)) == NULL) { + IF_SPEED)) == NULL) { return (-1); } if (port_datap->data_type == KSTAT_DATA_UINT32) { @@ -250,7 +249,7 @@ kstat_network_port_cond(kstat_ctl_t *kc, char *ks_module, int ks_instance) /* check for FAILING conditions */ if ((port_datap = kstat_name_lookup(kc, ks_module, ks_instance, - IERRORS)) == NULL) { + IERRORS)) == NULL) { return (-1); } if (port_datap->data_type == KSTAT_DATA_UINT32) { @@ -260,7 +259,7 @@ kstat_network_port_cond(kstat_ctl_t *kc, char *ks_module, int ks_instance) } if ((port_datap = kstat_name_lookup(kc, ks_module, ks_instance, - IPACKETS)) == NULL) { + IPACKETS)) == NULL) { return (-1); } @@ -274,7 +273,7 @@ kstat_network_port_cond(kstat_ctl_t *kc, char *ks_module, int ks_instance) } if ((port_datap = kstat_name_lookup(kc, ks_module, ks_instance, - OERRORS)) == NULL) { + OERRORS)) == NULL) { return (-1); } if (port_datap->data_type == KSTAT_DATA_UINT32) { @@ -284,7 +283,7 @@ kstat_network_port_cond(kstat_ctl_t *kc, char *ks_module, int ks_instance) } if ((port_datap = kstat_name_lookup(kc, ks_module, ks_instance, - OPACKETS)) == NULL) { + OPACKETS)) == NULL) { return (-1); } if (port_datap->data_type == KSTAT_DATA_UINT32) { @@ -297,7 +296,7 @@ kstat_network_port_cond(kstat_ctl_t *kc, char *ks_module, int ks_instance) } if ((port_datap = kstat_name_lookup(kc, ks_module, ks_instance, - RUNT_ERRORS)) == NULL) { + RUNT_ERRORS)) == NULL) { return (-1); } if (port_datap->data_type == KSTAT_DATA_UINT32) { @@ -310,7 +309,7 @@ kstat_network_port_cond(kstat_ctl_t *kc, char *ks_module, int ks_instance) } if ((port_datap = kstat_name_lookup(kc, ks_module, ks_instance, - COLLISIONS)) == NULL) { + COLLISIONS)) == NULL) { return (-1); } if (port_datap->data_type == KSTAT_DATA_UINT32) { @@ -337,7 +336,6 @@ serial_port_state(kstat_ctl_t *kc, char *driver, int instance) char device[20]; struct termios flags; struct sigaction old_sa, new_sa; - static void sig_alarm_handler(int); (void) memset(&old_sa, 0, sizeof (old_sa)); (void) memset(&new_sa, 0, sizeof (new_sa)); @@ -404,7 +402,7 @@ parallel_port_state(kstat_ctl_t *kc, char *ks_module, int ks_instance) char ks_name[20]; (void) snprintf(ks_name, sizeof (ks_name), "%s%d", ks_module, - ks_instance); + ks_instance); if ((ksp = kstat_lookup(kc, ks_module, ks_instance, ks_name)) == NULL) { return (-1); } diff --git a/usr/src/lib/libbc/libc/gen/common/usleep.c b/usr/src/lib/libbc/libc/gen/common/usleep.c index 41df69ae78..65b5071b36 100644 --- a/usr/src/lib/libbc/libc/gen/common/usleep.c +++ b/usr/src/lib/libbc/libc/gen/common/usleep.c @@ -9,8 +9,6 @@ * specifies the terms and conditions for redistribution. */ -#pragma ident "%Z%%M% %I% %E% SMI" - #include <unistd.h> #include <sys/time.h> #include <signal.h> @@ -23,10 +21,16 @@ static int ringring; +static void +sleepx(void) +{ + + ringring = 1; +} + void usleep(unsigned n) { - static void sleepx(); int omask; struct itimerval itv, oitv; struct itimerval *itp = &itv; @@ -65,10 +69,3 @@ usleep(unsigned n) (void) sigsetmask(omask); (void) setitimer(ITIMER_REAL, &oitv, (struct itimerval *)0); } - -static void -sleepx(void) -{ - - ringring = 1; -} diff --git a/usr/src/uts/i86pc/io/acpi/drmach_acpi/drmach_acpi.c b/usr/src/uts/i86pc/io/acpi/drmach_acpi/drmach_acpi.c index 35ad4353aa..29d44de2d2 100644 --- a/usr/src/uts/i86pc/io/acpi/drmach_acpi/drmach_acpi.c +++ b/usr/src/uts/i86pc/io/acpi/drmach_acpi/drmach_acpi.c @@ -82,6 +82,22 @@ static void drmach_fini(void); static int drmach_name2type_idx(char *); static sbd_error_t *drmach_mem_update_lgrp(drmachid_t); +static void drmach_board_dispose(drmachid_t id); +static sbd_error_t *drmach_board_release(drmachid_t); +static sbd_error_t *drmach_board_status(drmachid_t, drmach_status_t *); + +static void drmach_io_dispose(drmachid_t); +static sbd_error_t *drmach_io_release(drmachid_t); +static sbd_error_t *drmach_io_status(drmachid_t, drmach_status_t *); + +static void drmach_cpu_dispose(drmachid_t); +static sbd_error_t *drmach_cpu_release(drmachid_t); +static sbd_error_t *drmach_cpu_status(drmachid_t, drmach_status_t *); + +static void drmach_mem_dispose(drmachid_t); +static sbd_error_t *drmach_mem_release(drmachid_t); +static sbd_error_t *drmach_mem_status(drmachid_t, drmach_status_t *); + #ifdef DEBUG int drmach_debug = 1; /* set to non-zero to enable debug messages */ #endif /* DEBUG */ @@ -523,10 +539,6 @@ drmach_device_status(drmachid_t id, drmach_status_t *stat) drmach_board_t * drmach_board_new(uint_t bnum, int boot_board) { - static void drmach_board_dispose(drmachid_t id); - static sbd_error_t *drmach_board_release(drmachid_t); - static sbd_error_t *drmach_board_status(drmachid_t, drmach_status_t *); - sbd_error_t *err; drmach_board_t *bp; dev_info_t *dip = NULL; @@ -961,10 +973,6 @@ drmach_fini(void) sbd_error_t * drmach_io_new(drmach_device_t *proto, drmachid_t *idp) { - static void drmach_io_dispose(drmachid_t); - static sbd_error_t *drmach_io_release(drmachid_t); - static sbd_error_t *drmach_io_status(drmachid_t, drmach_status_t *); - drmach_io_t *ip; int portid; @@ -1037,10 +1045,6 @@ drmach_io_status(drmachid_t id, drmach_status_t *stat) sbd_error_t * drmach_cpu_new(drmach_device_t *proto, drmachid_t *idp) { - static void drmach_cpu_dispose(drmachid_t); - static sbd_error_t *drmach_cpu_release(drmachid_t); - static sbd_error_t *drmach_cpu_status(drmachid_t, drmach_status_t *); - int portid; processorid_t cpuid; drmach_cpu_t *cp = NULL; @@ -1250,10 +1254,6 @@ drmach_setup_mc_info(DRMACH_HANDLE hdl, drmach_mem_t *mp) sbd_error_t * drmach_mem_new(drmach_device_t *proto, drmachid_t *idp) { - static void drmach_mem_dispose(drmachid_t); - static sbd_error_t *drmach_mem_release(drmachid_t); - static sbd_error_t *drmach_mem_status(drmachid_t, drmach_status_t *); - DRMACH_HANDLE hdl; drmach_mem_t *mp; int portid; diff --git a/usr/src/uts/i86pc/io/dr/dr.c b/usr/src/uts/i86pc/io/dr/dr.c index 90f3a80adf..302d07f5bd 100644 --- a/usr/src/uts/i86pc/io/dr/dr.c +++ b/usr/src/uts/i86pc/io/dr/dr.c @@ -71,6 +71,8 @@ extern struct memlist *phys_install; uint_t dr_debug = 0; /* dr.h for bit values */ #endif /* DEBUG */ +static int dr_dev_type_to_nt(char *); + /* * NOTE: state_str, nt_str and SBD_CMD_STR are only used in a debug * kernel. They are, however, referenced during both debug and non-debug @@ -554,8 +556,6 @@ static int dr_ioctl(dev_t dev, int cmd, intptr_t arg, int mode, cred_t *cred_p, int *rval_p) { - static int dr_dev_type_to_nt(char *); - int rv = 0; int instance; int bd; diff --git a/usr/src/uts/sun4u/cpu/opl_kdi.c b/usr/src/uts/sun4u/cpu/opl_kdi.c index c6795bb4e8..d5c34bf0b5 100644 --- a/usr/src/uts/sun4u/cpu/opl_kdi.c +++ b/usr/src/uts/sun4u/cpu/opl_kdi.c @@ -23,8 +23,6 @@ * Use is subject to license terms. */ -#pragma ident "%Z%%M% %I% %E% SMI" - /* * CPU-specific functions needed by the Kernel-Debugger Interface (KDI). These * functions are invoked directly by the kernel debugger (kmdb) while the system @@ -65,6 +63,8 @@ extern void shipit(int, int); extern void kdi_flush_idcache(int, int, int, int); extern int kdi_get_stick(uint64_t *); +static void kdi_tickwait(clock_t); + static int kdi_cpu_ready_iter(int (*cb)(int, void *), void *arg) { @@ -88,7 +88,6 @@ kdi_xc_one(int cpuid, void (*func)(uintptr_t, uintptr_t), uintptr_t arg1, uintptr_t arg2) { uint64_t idsr; - static void kdi_tickwait(clock_t); uint64_t endtick, tick; init_mondo_nocheck((xcfunc_t *)func, arg1, arg2); @@ -123,7 +122,8 @@ kdi_tickwait(clock_t nticks) { clock_t endtick = gettick() + nticks; - while (gettick() < endtick); + while (gettick() < endtick) + ; } static void diff --git a/usr/src/uts/sun4u/ngdr/io/dr.c b/usr/src/uts/sun4u/ngdr/io/dr.c index 56547d5a05..e89ea0b05e 100644 --- a/usr/src/uts/sun4u/ngdr/io/dr.c +++ b/usr/src/uts/sun4u/ngdr/io/dr.c @@ -156,6 +156,8 @@ struct { int dr_modunload_okay = 0; /* set to non-zero to allow unload */ +static int dr_dev_type_to_nt(char *); + /* * State transition table. States valid transitions for "board" state. * Recall that non-zero return value terminates operation, however @@ -556,8 +558,6 @@ static int dr_ioctl(dev_t dev, int cmd, intptr_t arg, int mode, cred_t *cred_p, int *rval_p) { - static int dr_dev_type_to_nt(char *); - int rv = 0; int instance; int bd; diff --git a/usr/src/uts/sun4u/opl/io/drmach.c b/usr/src/uts/sun4u/opl/io/drmach.c index 3f40c0b732..0999f18e15 100644 --- a/usr/src/uts/sun4u/opl/io/drmach.c +++ b/usr/src/uts/sun4u/opl/io/drmach.c @@ -229,6 +229,15 @@ static void drmach_fini(void); static void drmach_swap_pa(drmach_mem_t *, drmach_mem_t *); static drmach_board_t *drmach_get_board_by_bnum(int); +static sbd_error_t *drmach_board_release(drmachid_t); +static sbd_error_t *drmach_board_status(drmachid_t, drmach_status_t *); +static void drmach_cpu_dispose(drmachid_t); +static sbd_error_t *drmach_cpu_release(drmachid_t); +static sbd_error_t *drmach_cpu_status(drmachid_t, drmach_status_t *); +static void drmach_mem_dispose(drmachid_t); +static sbd_error_t *drmach_mem_release(drmachid_t); +static sbd_error_t *drmach_mem_status(drmachid_t, drmach_status_t *); + /* options for the second argument in drmach_add_remove_cpu() */ #define HOTADD_CPU 1 #define HOTREMOVE_CPU 2 @@ -1021,9 +1030,6 @@ drmach_device_dispose(drmachid_t id) static drmach_board_t * drmach_board_new(int bnum, int boot_board) { - static sbd_error_t *drmach_board_release(drmachid_t); - static sbd_error_t *drmach_board_status(drmachid_t, drmach_status_t *); - drmach_board_t *bp; bp = kmem_zalloc(sizeof (drmach_board_t), KM_SLEEP); @@ -1811,10 +1817,6 @@ drmach_board_unassign(drmachid_t id) static sbd_error_t * drmach_cpu_new(drmach_device_t *proto, drmachid_t *idp) { - static void drmach_cpu_dispose(drmachid_t); - static sbd_error_t *drmach_cpu_release(drmachid_t); - static sbd_error_t *drmach_cpu_status(drmachid_t, drmach_status_t *); - int portid; drmach_cpu_t *cp = NULL; @@ -2208,9 +2210,6 @@ drmach_io_status(drmachid_t id, drmach_status_t *stat) static sbd_error_t * drmach_mem_new(drmach_device_t *proto, drmachid_t *idp) { - static void drmach_mem_dispose(drmachid_t); - static sbd_error_t *drmach_mem_release(drmachid_t); - static sbd_error_t *drmach_mem_status(drmachid_t, drmach_status_t *); dev_info_t *dip; int rv; diff --git a/usr/src/uts/sun4u/os/fillsysinfo.c b/usr/src/uts/sun4u/os/fillsysinfo.c index e5395d5443..ab7abd783b 100644 --- a/usr/src/uts/sun4u/os/fillsysinfo.c +++ b/usr/src/uts/sun4u/os/fillsysinfo.c @@ -23,8 +23,6 @@ * Use is subject to license terms. */ -#pragma ident "%Z%%M% %I% %E% SMI" - #include <sys/errno.h> #include <sys/types.h> #include <sys/param.h> @@ -103,6 +101,7 @@ struct cpu_node cpunodes[NCPU]; static void check_cpus_ver(void); static void check_cpus_set(void); +static void fill_address(pnode_t, char *); void fill_cpu(pnode_t); void fill_cpu_ddi(dev_info_t *); void empty_cpu(int); @@ -243,7 +242,6 @@ map_wellknown(pnode_t curnode) { extern int status_okay(int, char *, int); char tmp_name[MAXSYSNAME]; - static void fill_address(pnode_t, char *); int sok; #ifdef VPRINTF diff --git a/usr/src/uts/sun4u/serengeti/io/sbdp_cpu.c b/usr/src/uts/sun4u/serengeti/io/sbdp_cpu.c index 5b8b016d60..0d237486e5 100644 --- a/usr/src/uts/sun4u/serengeti/io/sbdp_cpu.c +++ b/usr/src/uts/sun4u/serengeti/io/sbdp_cpu.c @@ -96,7 +96,7 @@ extern int prom_serengeti_cpu_off(pnode_t); extern sbdp_wnode_t *sbdp_get_wnodep(int); extern caddr_t sbdp_shutdown_va; static int sbdp_prom_get_cpu(void *arg, int changed); - +static void sbdp_cpu_shutdown_self(void); int sbdp_disconnect_cpu(sbdp_handle_t *hp, dev_info_t *dip, processorid_t cpuid) @@ -360,7 +360,6 @@ int sbdp_cpu_poweroff(struct cpu *cp) { processorid_t cpuid; - static void sbdp_cpu_shutdown_self(void); pnode_t nodeid; sbdp_cpu_sram_map_t map; static fn_t f = "sbdp_cpu_poweroff"; diff --git a/usr/src/uts/sun4u/starcat/io/drmach.c b/usr/src/uts/sun4u/starcat/io/drmach.c index 7928fbbf31..d176b650f1 100644 --- a/usr/src/uts/sun4u/starcat/io/drmach.c +++ b/usr/src/uts/sun4u/starcat/io/drmach.c @@ -378,6 +378,8 @@ static int drmach_xt_mb_size; uint64_t drmach_bus_sync_list[18 * 4 * 4 + 1]; static kmutex_t drmach_bus_sync_lock; +static void drmach_fini(void); + static sbd_error_t *drmach_device_new(drmach_node_t *, drmach_board_t *, int, drmachid_t *); static sbd_error_t *drmach_cpu_new(drmach_device_t *, drmachid_t *); @@ -385,6 +387,17 @@ static sbd_error_t *drmach_mem_new(drmach_device_t *, drmachid_t *); static sbd_error_t *drmach_pci_new(drmach_device_t *, drmachid_t *); static sbd_error_t *drmach_io_new(drmach_device_t *, drmachid_t *); +static sbd_error_t *drmach_board_release(drmachid_t); +static sbd_error_t *drmach_board_status(drmachid_t, drmach_status_t *); + +static void drmach_cpu_dispose(drmachid_t); +static sbd_error_t *drmach_cpu_release(drmachid_t); +static sbd_error_t *drmach_cpu_status(drmachid_t, drmach_status_t *); + +static void drmach_mem_dispose(drmachid_t); +static sbd_error_t *drmach_mem_release(drmachid_t); +static sbd_error_t *drmach_mem_status(drmachid_t, drmach_status_t *); + static dev_info_t *drmach_node_ddi_get_dip(drmach_node_t *np); static int drmach_node_ddi_get_prop(drmach_node_t *np, char *name, void *buf, int len); @@ -546,7 +559,6 @@ _init(void) int _fini(void) { - static void drmach_fini(void); int err; if ((err = mod_remove(&modlinkage)) == 0) @@ -1181,9 +1193,6 @@ drmach_device_dispose(drmachid_t id) static drmach_board_t * drmach_board_new(int bnum) { - static sbd_error_t *drmach_board_release(drmachid_t); - static sbd_error_t *drmach_board_status(drmachid_t, drmach_status_t *); - drmach_board_t *bp; bp = kmem_zalloc(sizeof (drmach_board_t), KM_SLEEP); @@ -5226,10 +5235,6 @@ drmach_cpu_read_cpuid(drmach_cpu_t *cp, processorid_t *cpuid) static sbd_error_t * drmach_cpu_new(drmach_device_t *proto, drmachid_t *idp) { - static void drmach_cpu_dispose(drmachid_t); - static sbd_error_t *drmach_cpu_release(drmachid_t); - static sbd_error_t *drmach_cpu_status(drmachid_t, drmach_status_t *); - sbd_error_t *err; uint64_t scr_pa; drmach_cpu_t *cp = NULL; @@ -6257,10 +6262,6 @@ drmach_mem_init_size(drmachid_t id) static sbd_error_t * drmach_mem_new(drmach_device_t *proto, drmachid_t *idp) { - static void drmach_mem_dispose(drmachid_t); - static sbd_error_t *drmach_mem_release(drmachid_t); - static sbd_error_t *drmach_mem_status(drmachid_t, drmach_status_t *); - sbd_error_t *err; uint64_t madr_pa; drmach_mem_t *mp; diff --git a/usr/src/uts/sun4u/starfire/io/drmach.c b/usr/src/uts/sun4u/starfire/io/drmach.c index c7bdd5ae99..d0dca88eb8 100644 --- a/usr/src/uts/sun4u/starfire/io/drmach.c +++ b/usr/src/uts/sun4u/starfire/io/drmach.c @@ -211,11 +211,21 @@ struct drmach_shutdown_mbox { uint64_t physaddr; }; struct drmach_shutdown_mbox *drmach_shutdown_asm_mbox; + +static int drmach_fini(void); static sbd_error_t *drmach_device_new(drmach_node_t *, drmach_board_t *, drmach_device_t **); static sbd_error_t *drmach_cpu_new(drmach_device_t *); static sbd_error_t *drmach_mem_new(drmach_device_t *); static sbd_error_t *drmach_io_new(drmach_device_t *); +static sbd_error_t *drmach_board_release(drmachid_t); +static sbd_error_t *drmach_board_status(drmachid_t, drmach_status_t *); +static sbd_error_t *drmach_cpu_release(drmachid_t); +static sbd_error_t *drmach_cpu_status(drmachid_t, drmach_status_t *); +static sbd_error_t *drmach_io_release(drmachid_t); +static sbd_error_t *drmach_io_status(drmachid_t, drmach_status_t *); +static sbd_error_t *drmach_mem_release(drmachid_t); +static sbd_error_t *drmach_mem_status(drmachid_t, drmach_status_t *); extern struct cpu *SIGBCPU; @@ -347,8 +357,6 @@ _init(void) int _fini(void) { - static int drmach_fini(void); - if (drmach_fini()) return (DDI_FAILURE); else @@ -787,9 +795,6 @@ drmach_device_get_proplen(drmach_device_t *dp, char *name, int *len) static drmach_board_t * drmach_board_new(int bnum) { - static sbd_error_t *drmach_board_release(drmachid_t); - static sbd_error_t *drmach_board_status(drmachid_t, drmach_status_t *); - drmach_board_t *bp; bp = kmem_zalloc(sizeof (drmach_board_t), KM_SLEEP); @@ -1730,9 +1735,6 @@ drmach_copy_rename_fini(drmachid_t id) static sbd_error_t * drmach_io_new(drmach_device_t *dp) { - static sbd_error_t *drmach_io_release(drmachid_t); - static sbd_error_t *drmach_io_status(drmachid_t, drmach_status_t *); - sbd_error_t *err; int portid; @@ -2350,9 +2352,6 @@ drmach_board_unassign(drmachid_t id) static sbd_error_t * drmach_cpu_new(drmach_device_t *dp) { - static sbd_error_t *drmach_cpu_release(drmachid_t); - static sbd_error_t *drmach_cpu_status(drmachid_t, drmach_status_t *); - sbd_error_t *err; int portid; @@ -2930,9 +2929,6 @@ drmach_io_status(drmachid_t id, drmach_status_t *stat) static sbd_error_t * drmach_mem_new(drmach_device_t *dp) { - static sbd_error_t *drmach_mem_release(drmachid_t); - static sbd_error_t *drmach_mem_status(drmachid_t, drmach_status_t *); - dp->unum = 0; dp->cm.isa = (void *)drmach_mem_new; dp->cm.release = drmach_mem_release; diff --git a/usr/src/uts/sun4u/sunfire/io/fhc.c b/usr/src/uts/sun4u/sunfire/io/fhc.c index e06a2889e9..d47130bddc 100644 --- a/usr/src/uts/sun4u/sunfire/io/fhc.c +++ b/usr/src/uts/sun4u/sunfire/io/fhc.c @@ -94,6 +94,8 @@ static int fhc_int_priorities[] = { }; static void fhc_tod_fault(enum tod_fault_type tod_bad); +static void fhc_cpu_shutdown_self(void); +static void os_completes_shutdown(void); /* * The dont_calibrate variable is meant to be set to one in /etc/system @@ -3194,7 +3196,6 @@ fhc_cpu_poweroff(struct cpu *cp) fhc_bd_t *bd_list; int delays; extern void idle_stop_xcall(void); - static void fhc_cpu_shutdown_self(void); ASSERT(MUTEX_HELD(&cpu_lock)); ASSERT((cp->cpu_flags & (CPU_EXISTS | CPU_OFFLINE | CPU_QUIESCED)) == @@ -3271,7 +3272,6 @@ static void fhc_cpu_shutdown_self(void) { extern void flush_windows(void); - static void os_completes_shutdown(void); flush_windows(); |