Source-Changes-HG archive
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]
[src/trunk]: src/sys/arch/cesfic - use cpu_{g,s}etmodel
details: https://anonhg.NetBSD.org/src/rev/8af87e06580a
branches: trunk
changeset: 328037:8af87e06580a
user: christos <christos%NetBSD.org@localhost>
date: Mon Mar 24 18:56:43 2014 +0000
description:
- use cpu_{g,s}etmodel
- remove unused
diffstat:
sys/arch/cesfic/cesfic/machdep.c | 11 +++++++----
sys/arch/cesfic/dev/zs.c | 10 +++++-----
2 files changed, 12 insertions(+), 9 deletions(-)
diffs (102 lines):
diff -r 56f0117737a1 -r 8af87e06580a sys/arch/cesfic/cesfic/machdep.c
--- a/sys/arch/cesfic/cesfic/machdep.c Mon Mar 24 18:50:31 2014 +0000
+++ b/sys/arch/cesfic/cesfic/machdep.c Mon Mar 24 18:56:43 2014 +0000
@@ -1,4 +1,4 @@
-/* $NetBSD: machdep.c,v 1.64 2012/08/08 16:29:50 drochner Exp $ */
+/* $NetBSD: machdep.c,v 1.65 2014/03/24 18:56:43 christos Exp $ */
/*
* Copyright (c) 1988 University of Utah.
@@ -39,7 +39,7 @@
*/
#include <sys/cdefs.h>
-__KERNEL_RCSID(0, "$NetBSD: machdep.c,v 1.64 2012/08/08 16:29:50 drochner Exp $");
+__KERNEL_RCSID(0, "$NetBSD: machdep.c,v 1.65 2014/03/24 18:56:43 christos Exp $");
#include "opt_bufcache.h"
#include "opt_ddb.h"
@@ -71,6 +71,7 @@
#include <sys/vnode.h>
#include <sys/ksyms.h>
#include <sys/module.h>
+#include <sys/cpu.h>
#ifdef SYSVMSG
#include <sys/msg.h>
#endif
@@ -247,6 +248,7 @@
pmapdebug = 0;
#endif
+ cpu_setmodel("FIC8234");
if (fputype != FPU_NONE)
m68k_make_fpu_idle_frame();
@@ -274,12 +276,11 @@
/*
* Info for CTL_HW
*/
-char cpu_model[] = "FIC8234";
void
identifycpu(void)
{
- printf("%s\n", cpu_model);
+ printf("%s\n", cpu_getmodel());
printf("delay constant: %d\n", delay_divisor);
}
@@ -510,6 +511,7 @@
return (1);
}
i = *(volatile short *)addr;
+ __USE(i);
nofault = (int *) 0;
return (0);
}
@@ -526,6 +528,7 @@
return (1);
}
i = *(volatile char *)addr;
+ __USE(i);
nofault = (int *) 0;
return (0);
}
diff -r 56f0117737a1 -r 8af87e06580a sys/arch/cesfic/dev/zs.c
--- a/sys/arch/cesfic/dev/zs.c Mon Mar 24 18:50:31 2014 +0000
+++ b/sys/arch/cesfic/dev/zs.c Mon Mar 24 18:56:43 2014 +0000
@@ -1,4 +1,4 @@
-/* $NetBSD: zs.c,v 1.18 2009/10/26 19:16:55 cegger Exp $ */
+/* $NetBSD: zs.c,v 1.19 2014/03/24 18:56:43 christos Exp $ */
/*-
* Copyright (c) 1996 The NetBSD Foundation, Inc.
@@ -37,7 +37,7 @@
*/
#include <sys/cdefs.h>
-__KERNEL_RCSID(0, "$NetBSD: zs.c,v 1.18 2009/10/26 19:16:55 cegger Exp $");
+__KERNEL_RCSID(0, "$NetBSD: zs.c,v 1.19 2014/03/24 18:56:43 christos Exp $");
#include "opt_ddb.h"
@@ -271,16 +271,16 @@
int
zs_set_speed(struct zs_chanstate *cs, int bps)
{
- int tconst, real_bps;
+ int tconst;
tconst = BPS_TO_TCONST(cs->cs_brg_clk, bps);
if (tconst < 0)
return (EINVAL);
+#if 0
/* Convert back to make sure we can do it. */
- real_bps = TCONST_TO_BPS(cs->cs_brg_clk, tconst);
-#if 0
+ int real_bps = TCONST_TO_BPS(cs->cs_brg_clk, tconst);
/* XXX - Allow some tolerance here? */
if (real_bps != bps)
return (EINVAL);
Home |
Main Index |
Thread Index |
Old Index