summaryrefslogtreecommitdiff
path: root/sys
diff options
context:
space:
mode:
Diffstat (limited to 'sys')
-rw-r--r--sys/arch/sparc64/include/cpu.h5
-rw-r--r--sys/arch/sparc64/sparc64/machdep.c31
2 files changed, 3 insertions, 33 deletions
diff --git a/sys/arch/sparc64/include/cpu.h b/sys/arch/sparc64/include/cpu.h
index e109dd4e92b..33f2d15239b 100644
--- a/sys/arch/sparc64/include/cpu.h
+++ b/sys/arch/sparc64/include/cpu.h
@@ -1,4 +1,4 @@
-/* $OpenBSD: cpu.h,v 1.32 2005/09/21 21:08:35 miod Exp $ */
+/* $OpenBSD: cpu.h,v 1.33 2005/11/11 16:50:19 miod Exp $ */
/* $NetBSD: cpu.h,v 1.28 2001/06/14 22:56:58 thorpej Exp $ */
/*
@@ -47,7 +47,6 @@
/*
* CTL_MACHDEP definitions.
*/
-#define CPU_BOOTED_KERNEL 1 /* string: booted kernel name */
#define CPU_LED_BLINK 2 /* int: blink leds? */
#define CPU_ALLOWAPERTURE 3 /* allow xf86 operations */
#define CPU_CPUTYPE 4 /* cpu type */
@@ -57,7 +56,7 @@
#define CTL_MACHDEP_NAMES { \
{ 0, 0 }, \
- { "booted_kernel", CTLTYPE_STRING }, \
+ { 0, 0 }, \
{ "led_blink", CTLTYPE_INT }, \
{ "allowaperture", CTLTYPE_INT }, \
{ "cputype", CTLTYPE_INT }, \
diff --git a/sys/arch/sparc64/sparc64/machdep.c b/sys/arch/sparc64/sparc64/machdep.c
index 096204a7852..ef2c29b4f51 100644
--- a/sys/arch/sparc64/sparc64/machdep.c
+++ b/sys/arch/sparc64/sparc64/machdep.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: machdep.c,v 1.77 2005/10/24 19:07:40 martin Exp $ */
+/* $OpenBSD: machdep.c,v 1.78 2005/11/11 16:50:21 miod Exp $ */
/* $NetBSD: machdep.c,v 1.108 2001/07/24 19:30:14 eeh Exp $ */
/*-
@@ -511,41 +511,12 @@ cpu_sysctl(name, namelen, oldp, oldlenp, newp, newlen, p)
struct proc *p;
{
int oldval, ret;
- u_int chosen;
- char bootargs[256];
- char *cp = NULL;
/* all sysctl names are this level are terminal */
if (namelen != 1)
return (ENOTDIR); /* overloaded */
switch (name[0]) {
- case CPU_BOOTED_KERNEL:
- if (((chosen = OF_finddevice("/chosen")) != -1) &&
- ((OF_getprop(chosen, "bootargs", bootargs, sizeof bootargs))
- >= 0)) {
- /*
- * bootargs is of the form: [kernelname] [args...]
- * It can be the empty string if we booted from the
- * default kernel name.
- */
- for (cp = bootargs;
- *cp && *cp != ' ' && *cp != '\t' && *cp != '\n';
- cp++);
- *cp = 0;
- /* Now we've separated the kernel name from the args */
- cp = bootargs;
- if (*cp == 0 || *cp == '-')
- /*
- * We can leave it NULL && let userland handle
- * the failure or set it to the default name,
- * `bsd'
- */
- cp = "bsd";
- }
- if (cp == NULL || cp[0] == '\0')
- return (ENOENT);
- return (sysctl_rdstring(oldp, oldlenp, newp, cp));
case CPU_LED_BLINK:
oldval = sparc_led_blink;
ret = sysctl_int(oldp, oldlenp, newp, newlen,