version 1.64.16.5, 2005/03/04 16:41:26 |
version 1.65, 2003/08/07 16:30:58 |
Line 79 __KERNEL_RCSID(0, "$NetBSD$"); |
|
Line 79 __KERNEL_RCSID(0, "$NetBSD$"); |
|
|
|
#include <sys/param.h> |
#include <sys/param.h> |
#include <sys/systm.h> |
#include <sys/systm.h> |
#include <sys/mbuf.h> |
#include <sys/mbuf.h> |
#include <sys/syslog.h> |
#include <sys/syslog.h> |
#include <sys/socket.h> |
#include <sys/socket.h> |
#include <sys/device.h> |
#include <sys/device.h> |
Line 105 __KERNEL_RCSID(0, "$NetBSD$"); |
|
Line 105 __KERNEL_RCSID(0, "$NetBSD$"); |
|
#include <dev/ic/am7990reg.h> |
#include <dev/ic/am7990reg.h> |
#include <dev/ic/am7990var.h> |
#include <dev/ic/am7990var.h> |
|
|
static void am7990_meminit(struct lance_softc *); |
void am7990_meminit __P((struct lance_softc *)); |
static void am7990_start(struct ifnet *); |
void am7990_start __P((struct ifnet *)); |
|
|
#if defined(_KERNEL_OPT) |
#if defined(_KERNEL_OPT) |
#include "opt_ddb.h" |
#include "opt_ddb.h" |
#endif |
#endif |
|
|
|
#ifdef DDB |
|
#define integrate |
|
#define hide |
|
#else |
|
#define integrate static __inline |
|
#define hide static |
|
#endif |
|
|
|
integrate void am7990_rint __P((struct lance_softc *)); |
|
integrate void am7990_tint __P((struct lance_softc *)); |
|
|
#ifdef LEDEBUG |
#ifdef LEDEBUG |
static void am7990_recv_print(struct lance_softc *, int); |
void am7990_recv_print __P((struct lance_softc *, int)); |
static void am7990_xmit_print(struct lance_softc *, int); |
void am7990_xmit_print __P((struct lance_softc *, int)); |
#endif |
#endif |
|
|
#define ifp (&sc->sc_ethercom.ec_if) |
#define ifp (&sc->sc_ethercom.ec_if) |
|
|
void |
void |
am7990_config(struct am7990_softc *sc) |
am7990_config(sc) |
|
struct am7990_softc *sc; |
{ |
{ |
int mem, i; |
int mem, i; |
|
|
Line 149 am7990_config(struct am7990_softc *sc) |
|
Line 161 am7990_config(struct am7990_softc *sc) |
|
/* |
/* |
* Set up the initialization block and the descriptor rings. |
* Set up the initialization block and the descriptor rings. |
*/ |
*/ |
static void |
void |
am7990_meminit(struct lance_softc *sc) |
am7990_meminit(sc) |
|
struct lance_softc *sc; |
{ |
{ |
u_long a; |
u_long a; |
int bix; |
int bix; |
Line 222 am7990_meminit(struct lance_softc *sc) |
|
Line 235 am7990_meminit(struct lance_softc *sc) |
|
} |
} |
} |
} |
|
|
static void |
integrate void |
am7990_rint(struct lance_softc *sc) |
am7990_rint(sc) |
|
struct lance_softc *sc; |
{ |
{ |
int bix; |
int bix; |
int rp; |
int rp; |
Line 296 am7990_rint(struct lance_softc *sc) |
|
Line 310 am7990_rint(struct lance_softc *sc) |
|
sc->sc_last_rd = bix; |
sc->sc_last_rd = bix; |
} |
} |
|
|
static void |
integrate void |
am7990_tint(struct lance_softc *sc) |
am7990_tint(sc) |
|
struct lance_softc *sc; |
{ |
{ |
int bix; |
int bix; |
struct letmd tmd; |
struct letmd tmd; |
Line 381 am7990_tint(struct lance_softc *sc) |
|
Line 396 am7990_tint(struct lance_softc *sc) |
|
* Controller interrupt. |
* Controller interrupt. |
*/ |
*/ |
int |
int |
am7990_intr(void *arg) |
am7990_intr(arg) |
|
void *arg; |
{ |
{ |
struct lance_softc *sc = arg; |
struct lance_softc *sc = arg; |
u_int16_t isr; |
u_int16_t isr; |
Line 474 am7990_intr(void *arg) |
|
Line 490 am7990_intr(void *arg) |
|
* interface before starting the output. |
* interface before starting the output. |
* Called only at splnet or interrupt level. |
* Called only at splnet or interrupt level. |
*/ |
*/ |
static void |
void |
am7990_start(struct ifnet *ifp) |
am7990_start(ifp) |
|
struct ifnet *ifp; |
{ |
{ |
struct lance_softc *sc = ifp->if_softc; |
struct lance_softc *sc = ifp->if_softc; |
int bix; |
int bix; |
Line 554 am7990_start(struct ifnet *ifp) |
|
Line 571 am7990_start(struct ifnet *ifp) |
|
} |
} |
|
|
#ifdef LEDEBUG |
#ifdef LEDEBUG |
static void |
void |
am7990_recv_print(struct lance_softc *sc, int no) |
am7990_recv_print(sc, no) |
|
struct lance_softc *sc; |
|
int no; |
{ |
{ |
struct lermd rmd; |
struct lermd rmd; |
u_int16_t len; |
u_int16_t len; |
Line 579 am7990_recv_print(struct lance_softc *sc |
|
Line 598 am7990_recv_print(struct lance_softc *sc |
|
} |
} |
} |
} |
|
|
static void |
void |
am7990_xmit_print(struct lance_softc *sc, int no) |
am7990_xmit_print(sc, no) |
|
struct lance_softc *sc; |
|
int no; |
{ |
{ |
struct letmd tmd; |
struct letmd tmd; |
u_int16_t len; |
u_int16_t len; |