aboutsummaryrefslogtreecommitdiff
path: root/sys/i386/isa/cy.c
diff options
context:
space:
mode:
authorBruce Evans <bde@FreeBSD.org>1998-11-23 13:58:55 +0000
committerBruce Evans <bde@FreeBSD.org>1998-11-23 13:58:55 +0000
commit976d09b9f24624cbba422fa49cfdba565dac4577 (patch)
treebd08c04136263f59ae2475a7b3052437b0c1c3c5 /sys/i386/isa/cy.c
parentaa045fa499198eb2eb8470a800289fd6c40cff0d (diff)
downloadsrc-976d09b9f24624cbba422fa49cfdba565dac4577.tar.gz
src-976d09b9f24624cbba422fa49cfdba565dac4577.zip
Untangled the Cyclades offsets a little. CY16_RESET and CY_CLEAR_INTR
were half of their physical offsets for ISA and 1/4 of their physical offsets for PCI, while all other Cyclades offsets were physical/1 for ISA and physical/2 for PCI. Logically wrong macros were used to scale CY16_RESET and CY_CLEAR_INTR to the correct physical offsets. Fixed some style bugs (mostly long lines).
Notes
Notes: svn path=/head/; revision=41309
Diffstat (limited to 'sys/i386/isa/cy.c')
-rw-r--r--sys/i386/isa/cy.c16
1 files changed, 8 insertions, 8 deletions
diff --git a/sys/i386/isa/cy.c b/sys/i386/isa/cy.c
index 187a3e9e19c9..1d41b5bf3455 100644
--- a/sys/i386/isa/cy.c
+++ b/sys/i386/isa/cy.c
@@ -27,7 +27,7 @@
* NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS
* SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
*
- * $Id: cy.c,v 1.72 1998/10/22 05:58:38 bde Exp $
+ * $Id: cy.c,v 1.73 1998/11/22 17:40:32 bde Exp $
*/
#include "opt_compat.h"
@@ -432,11 +432,11 @@ sioprobe(dev)
iobase = (cy_addr)dev->id_maddr;
/* Cyclom-16Y hardware reset (Cyclom-8Ys don't care) */
- cd_inb(iobase, CY16_RESET, 0); /* XXX? */
+ cy_inb(iobase, CY16_RESET, 0); /* XXX? */
DELAY(500); /* wait for the board to get its act together */
/* this is needed to get the board out of reset */
- cd_outb(iobase, CY_CLEAR_INTR, 0, 0);
+ cy_outb(iobase, CY_CLEAR_INTR, 0, 0);
DELAY(500);
return (cy_units(iobase, 0) == 0 ? 0 : -1);
@@ -646,7 +646,7 @@ cyattach_common(cy_iobase, cy_align)
}
/* ensure an edge for the next interrupt */
- cd_outb(cy_iobase, CY_CLEAR_INTR, cy_align, 0);
+ cy_outb(cy_iobase, CY_CLEAR_INTR, cy_align, 0);
return (adapter);
}
@@ -1068,7 +1068,7 @@ siointr(unit)
& CD1400_xIVR_CHAN));
#else
/* ack receive service */
- serv_type = cy_inb(iobase, CY8_SVCACKR);
+ serv_type = cy_inb(iobase, CY8_SVCACKR, cy_align);
com = com_addr(baseu +
+ ((serv_type >> CD1400_xIVR_CHAN_SHIFT)
@@ -1241,7 +1241,7 @@ cont:
+ (save_mir & CD1400_MIR_CHAN));
#else
/* ack modem service */
- vector = cy_inb(iobase, CY8_SVCACKM);
+ vector = cy_inb(iobase, CY8_SVCACKM, cy_align);
com = com_addr(baseu
+ ((vector >> CD1400_xIVR_CHAN_SHIFT)
@@ -1324,7 +1324,7 @@ cont:
+ (save_tir & CD1400_TIR_CHAN));
#else
/* ack transmit service */
- vector = cy_inb(iobase, CY8_SVCACKT);
+ vector = cy_inb(iobase, CY8_SVCACKT, cy_align);
com = com_addr(baseu
+ ((vector >> CD1400_xIVR_CHAN_SHIFT)
@@ -1384,7 +1384,7 @@ cont:
}
/* ensure an edge for the next interrupt */
- cd_outb(cy_iobase, CY_CLEAR_INTR, cy_align, 0);
+ cy_outb(cy_iobase, CY_CLEAR_INTR, cy_align, 0);
schedsofttty();