summaryrefslogtreecommitdiff
path: root/sys
diff options
context:
space:
mode:
Diffstat (limited to 'sys')
-rw-r--r--sys/dev/pci/ips.c24
1 files changed, 23 insertions, 1 deletions
diff --git a/sys/dev/pci/ips.c b/sys/dev/pci/ips.c
index 02a1e6de844..e7e64d3d154 100644
--- a/sys/dev/pci/ips.c
+++ b/sys/dev/pci/ips.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: ips.c,v 1.53 2009/03/10 08:27:08 grange Exp $ */
+/* $OpenBSD: ips.c,v 1.54 2009/03/10 09:16:40 grange Exp $ */
/*
* Copyright (c) 2006, 2007, 2009 Alexander Yurchenko <grange@openbsd.org>
@@ -374,6 +374,7 @@ int ips_flush(struct ips_softc *);
void ips_copperhead_exec(struct ips_softc *, struct ips_ccb *);
void ips_copperhead_init(struct ips_softc *);
void ips_copperhead_intren(struct ips_softc *);
+void ips_copperhead_intrds(struct ips_softc *);
int ips_copperhead_isintr(struct ips_softc *);
int ips_copperhead_reset(struct ips_softc *);
u_int32_t ips_copperhead_status(struct ips_softc *);
@@ -381,6 +382,7 @@ u_int32_t ips_copperhead_status(struct ips_softc *);
void ips_morpheus_exec(struct ips_softc *, struct ips_ccb *);
void ips_morpheus_init(struct ips_softc *);
void ips_morpheus_intren(struct ips_softc *);
+void ips_morpheus_intrds(struct ips_softc *);
int ips_morpheus_isintr(struct ips_softc *);
int ips_morpheus_reset(struct ips_softc *);
u_int32_t ips_morpheus_status(struct ips_softc *);
@@ -435,6 +437,7 @@ static const struct ips_chipset {
void (*ic_exec)(struct ips_softc *, struct ips_ccb *);
void (*ic_init)(struct ips_softc *);
void (*ic_intren)(struct ips_softc *);
+ void (*ic_intrds)(struct ips_softc *);
int (*ic_isintr)(struct ips_softc *);
int (*ic_reset)(struct ips_softc *);
u_int32_t (*ic_status)(struct ips_softc *);
@@ -445,6 +448,7 @@ static const struct ips_chipset {
ips_copperhead_exec,
ips_copperhead_init,
ips_copperhead_intren,
+ ips_copperhead_intrds,
ips_copperhead_isintr,
ips_copperhead_reset,
ips_copperhead_status
@@ -455,6 +459,7 @@ static const struct ips_chipset {
ips_morpheus_exec,
ips_morpheus_init,
ips_morpheus_intren,
+ ips_morpheus_intrds,
ips_morpheus_isintr,
ips_morpheus_reset,
ips_morpheus_status
@@ -464,6 +469,7 @@ static const struct ips_chipset {
#define ips_exec(s, c) (s)->sc_chip->ic_exec((s), (c))
#define ips_init(s) (s)->sc_chip->ic_init((s))
#define ips_intren(s) (s)->sc_chip->ic_intren((s))
+#define ips_intrds(s) (s)->sc_chip->ic_intrds((s))
#define ips_isintr(s) (s)->sc_chip->ic_isintr((s))
#define ips_reset(s) (s)->sc_chip->ic_reset((s))
#define ips_status(s) (s)->sc_chip->ic_status((s))
@@ -1413,6 +1419,12 @@ ips_copperhead_intren(struct ips_softc *sc)
bus_space_write_1(sc->sc_iot, sc->sc_ioh, IPS_REG_HIS, IPS_REG_HIS_EN);
}
+void
+ips_copperhead_intrds(struct ips_softc *sc)
+{
+ bus_space_write_1(sc->sc_iot, sc->sc_ioh, IPS_REG_HIS, 0);
+}
+
int
ips_copperhead_isintr(struct ips_softc *sc)
{
@@ -1479,6 +1491,16 @@ ips_morpheus_intren(struct ips_softc *sc)
bus_space_write_4(sc->sc_iot, sc->sc_ioh, IPS_REG_OIM, reg);
}
+void
+ips_morpheus_intrds(struct ips_softc *sc)
+{
+ u_int32_t reg;
+
+ reg = bus_space_read_4(sc->sc_iot, sc->sc_ioh, IPS_REG_OIM);
+ reg |= IPS_REG_OIM_DS;
+ bus_space_write_4(sc->sc_iot, sc->sc_ioh, IPS_REG_OIM, reg);
+}
+
int
ips_morpheus_isintr(struct ips_softc *sc)
{