Source-Changes-HG archive
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]
[src/trunk]: src/sys/arch Use C89 function prototypes.
details: https://anonhg.NetBSD.org/src/rev/69885489b90e
branches: trunk
changeset: 773367:69885489b90e
user: matt <matt%NetBSD.org@localhost>
date: Wed Feb 01 02:02:07 2012 +0000
description:
Use C89 function prototypes.
diffstat:
sys/arch/macppc/dev/adb.c | 6 +++---
sys/arch/macppc/dev/adb_direct.c | 6 +++---
sys/arch/macppc/dev/viareg.h | 27 +++++++++++----------------
sys/arch/powerpc/include/openpic.h | 25 ++++++++++---------------
sys/arch/powerpc/pic/pic_mpcsoc.c | 6 +++---
5 files changed, 30 insertions(+), 40 deletions(-)
diffs (206 lines):
diff -r 18327f8f3055 -r 69885489b90e sys/arch/macppc/dev/adb.c
--- a/sys/arch/macppc/dev/adb.c Wed Feb 01 02:01:28 2012 +0000
+++ b/sys/arch/macppc/dev/adb.c Wed Feb 01 02:02:07 2012 +0000
@@ -1,4 +1,4 @@
-/* $NetBSD: adb.c,v 1.32 2011/07/01 18:41:51 dyoung Exp $ */
+/* $NetBSD: adb.c,v 1.33 2012/02/01 02:02:07 matt Exp $ */
/*-
* Copyright (C) 1994 Bradley A. Grantham
@@ -26,7 +26,7 @@
*/
#include <sys/cdefs.h>
-__KERNEL_RCSID(0, "$NetBSD: adb.c,v 1.32 2011/07/01 18:41:51 dyoung Exp $");
+__KERNEL_RCSID(0, "$NetBSD: adb.c,v 1.33 2012/02/01 02:02:07 matt Exp $");
#include <sys/param.h>
#include <sys/device.h>
@@ -107,7 +107,7 @@
int totaladbs;
int adbindex, adbaddr, adb_node;
- extern volatile u_char *Via1Base;
+ extern volatile uint8_t *Via1Base;
ca->ca_reg[0] += ca->ca_baseaddr;
diff -r 18327f8f3055 -r 69885489b90e sys/arch/macppc/dev/adb_direct.c
--- a/sys/arch/macppc/dev/adb_direct.c Wed Feb 01 02:01:28 2012 +0000
+++ b/sys/arch/macppc/dev/adb_direct.c Wed Feb 01 02:02:07 2012 +0000
@@ -1,4 +1,4 @@
-/* $NetBSD: adb_direct.c,v 1.42 2009/03/18 10:22:31 cegger Exp $ */
+/* $NetBSD: adb_direct.c,v 1.43 2012/02/01 02:02:07 matt Exp $ */
/* From: adb_direct.c 2.02 4/18/97 jpw */
@@ -60,7 +60,7 @@
*/
#include <sys/cdefs.h>
-__KERNEL_RCSID(0, "$NetBSD: adb_direct.c,v 1.42 2009/03/18 10:22:31 cegger Exp $");
+__KERNEL_RCSID(0, "$NetBSD: adb_direct.c,v 1.43 2012/02/01 02:02:07 matt Exp $");
#include <sys/param.h>
#include <sys/systm.h>
@@ -224,7 +224,7 @@
struct callout adb_cuda_tickle_ch;
struct callout adb_soft_intr_ch;
-volatile u_char *Via1Base;
+volatile uint8_t *Via1Base;
extern int adb_polling; /* Are we polling? */
void pm_setup_adb(void);
diff -r 18327f8f3055 -r 69885489b90e sys/arch/macppc/dev/viareg.h
--- a/sys/arch/macppc/dev/viareg.h Wed Feb 01 02:01:28 2012 +0000
+++ b/sys/arch/macppc/dev/viareg.h Wed Feb 01 02:02:07 2012 +0000
@@ -1,4 +1,4 @@
-/* $NetBSD: viareg.h,v 1.8 2009/03/14 14:46:01 dsl Exp $ */
+/* $NetBSD: viareg.h,v 1.9 2012/02/01 02:02:07 matt Exp $ */
/*-
* Copyright (C) 1993 Allen K. Briggs, Chris P. Caputo,
@@ -201,46 +201,41 @@
static inline int read_via_reg(int, int);
static inline void
-via_reg_and(ign, reg, val)
- int ign, reg, val;
+via_reg_and(int ign, int reg, int val)
{
- volatile unsigned char *addr = Via1Base + reg;
+ volatile uint8_t *addr = Via1Base + reg;
out8(addr, in8(addr) & val);
}
static inline void
-via_reg_or(ign, reg, val)
- int ign, reg, val;
+via_reg_or(int ign, int reg, int val)
{
- volatile unsigned char *addr = Via1Base + reg;
+ volatile uint8_t *addr = Via1Base + reg;
out8(addr, in8(addr) | val);
}
static inline void
-via_reg_xor(ign, reg, val)
- int ign, reg, val;
+via_reg_xor(int ign, int reg, int val)
{
- volatile unsigned char *addr = Via1Base + reg;
+ volatile uint8_t *addr = Via1Base + reg;
out8(addr, in8(addr) ^ val);
}
static inline int
-read_via_reg(ign, reg)
- int ign, reg;
+read_via_reg(int ign, int reg)
{
- volatile unsigned char *addr = Via1Base + reg;
+ volatile uint8_t *addr = Via1Base + reg;
return in8(addr);
}
static inline void
-write_via_reg(ign, reg, val)
- int ign, reg, val;
+write_via_reg(int ign, int reg, int val)
{
- volatile unsigned char *addr = Via1Base + reg;
+ volatile uint8_t *addr = Via1Base + reg;
out8(addr, val);
}
diff -r 18327f8f3055 -r 69885489b90e sys/arch/powerpc/include/openpic.h
--- a/sys/arch/powerpc/include/openpic.h Wed Feb 01 02:01:28 2012 +0000
+++ b/sys/arch/powerpc/include/openpic.h Wed Feb 01 02:02:07 2012 +0000
@@ -1,4 +1,4 @@
-/* $NetBSD: openpic.h,v 1.7 2009/03/14 14:46:05 dsl Exp $ */
+/* $NetBSD: openpic.h,v 1.8 2012/02/01 02:03:51 matt Exp $ */
/*-
* Copyright (c) 2000 Tsubai Masanari. All rights reserved.
@@ -32,40 +32,35 @@
extern volatile unsigned char *openpic_base;
-static __inline u_int openpic_read(int);
-static __inline void openpic_write(int, u_int);
+static __inline uint32_t openpic_read(u_int);
+static __inline void openpic_write(u_int, uint32_t);
static __inline int openpic_read_irq(int);
static __inline void openpic_eoi(int);
-static __inline u_int
-openpic_read(reg)
- int reg;
+static __inline uint32_t
+openpic_read(u_int reg)
{
- volatile unsigned char *addr = openpic_base + reg;
+ volatile uint8_t *addr = openpic_base + reg;
return in32rb(addr);
}
static __inline void
-openpic_write(reg, val)
- int reg;
- u_int val;
+openpic_write(u_int reg, uint32_t val)
{
- volatile unsigned char *addr = openpic_base + reg;
+ volatile uint8_t *addr = openpic_base + reg;
out32rb(addr, val);
}
static __inline int
-openpic_read_irq(cpu)
- int cpu;
+openpic_read_irq(int cpu)
{
return openpic_read(OPENPIC_IACK(cpu)) & OPENPIC_VECTOR_MASK;
}
static __inline void
-openpic_eoi(cpu)
- int cpu;
+openpic_eoi(int cpu)
{
openpic_write(OPENPIC_EOI(cpu), 0);
openpic_read(OPENPIC_EOI(cpu));
diff -r 18327f8f3055 -r 69885489b90e sys/arch/powerpc/pic/pic_mpcsoc.c
--- a/sys/arch/powerpc/pic/pic_mpcsoc.c Wed Feb 01 02:01:28 2012 +0000
+++ b/sys/arch/powerpc/pic/pic_mpcsoc.c Wed Feb 01 02:02:07 2012 +0000
@@ -1,4 +1,4 @@
-/* $NetBSD: pic_mpcsoc.c,v 1.3 2012/01/14 19:35:59 phx Exp $ */
+/* $NetBSD: pic_mpcsoc.c,v 1.4 2012/02/01 02:03:52 matt Exp $ */
/*-
* Copyright (c) 2007 Michael Lorenz
@@ -27,7 +27,7 @@
*/
#include <sys/cdefs.h>
-__KERNEL_RCSID(0, "$NetBSD: pic_mpcsoc.c,v 1.3 2012/01/14 19:35:59 phx Exp $");
+__KERNEL_RCSID(0, "$NetBSD: pic_mpcsoc.c,v 1.4 2012/02/01 02:03:52 matt Exp $");
#include <sys/param.h>
#include <sys/malloc.h>
@@ -143,7 +143,7 @@
}
void
-mpcpic_reserv16()
+mpcpic_reserv16(void)
{
extern int max_base; /* intr.c */
Home |
Main Index |
Thread Index |
Old Index