Wed Apr 5 21:46:09 2023 UTC ()
s/esssentially/essentially/ in comment.


(andvar)
diff -r1.105 -r1.106 src/sys/dev/ic/aic6360.c

cvs diff -r1.105 -r1.106 src/sys/dev/ic/aic6360.c (expand / switch to unified diff)

--- src/sys/dev/ic/aic6360.c 2022/01/01 21:07:14 1.105
+++ src/sys/dev/ic/aic6360.c 2023/04/05 21:46:09 1.106
@@ -1,14 +1,14 @@ @@ -1,14 +1,14 @@
1/* $NetBSD: aic6360.c,v 1.105 2022/01/01 21:07:14 andvar Exp $ */ 1/* $NetBSD: aic6360.c,v 1.106 2023/04/05 21:46:09 andvar Exp $ */
2 2
3/* 3/*
4 * Copyright (c) 1994, 1995, 1996 Charles M. Hannum. All rights reserved. 4 * Copyright (c) 1994, 1995, 1996 Charles M. Hannum. All rights reserved.
5 * 5 *
6 * Redistribution and use in source and binary forms, with or without 6 * Redistribution and use in source and binary forms, with or without
7 * modification, are permitted provided that the following conditions 7 * modification, are permitted provided that the following conditions
8 * are met: 8 * are met:
9 * 1. Redistributions of source code must retain the above copyright 9 * 1. Redistributions of source code must retain the above copyright
10 * notice, this list of conditions and the following disclaimer. 10 * notice, this list of conditions and the following disclaimer.
11 * 2. Redistributions in binary form must reproduce the above copyright 11 * 2. Redistributions in binary form must reproduce the above copyright
12 * notice, this list of conditions and the following disclaimer in the 12 * notice, this list of conditions and the following disclaimer in the
13 * documentation and/or other materials provided with the distribution. 13 * documentation and/or other materials provided with the distribution.
14 * 3. All advertising materials mentioning features or use of this software 14 * 3. All advertising materials mentioning features or use of this software
@@ -48,27 +48,27 @@ @@ -48,27 +48,27 @@
48 * Acknowledgements: Many of the algorithms used in this driver are 48 * Acknowledgements: Many of the algorithms used in this driver are
49 * inspired by the work of Julian Elischer (julian@tfs.com) and 49 * inspired by the work of Julian Elischer (julian@tfs.com) and
50 * Charles Hannum (mycroft@duality.gnu.ai.mit.edu). Thanks a million! 50 * Charles Hannum (mycroft@duality.gnu.ai.mit.edu). Thanks a million!
51 */ 51 */
52 52
53/* TODO list: 53/* TODO list:
54 * 1) Get the DMA stuff working. 54 * 1) Get the DMA stuff working.
55 * 2) Get the iov/uio stuff working. Is this a good thing ??? 55 * 2) Get the iov/uio stuff working. Is this a good thing ???
56 * 3) Get the synch stuff working. 56 * 3) Get the synch stuff working.
57 * 4) Rewrite it to use malloc for the acb structs instead of static alloc.? 57 * 4) Rewrite it to use malloc for the acb structs instead of static alloc.?
58 */ 58 */
59 59
60#include <sys/cdefs.h> 60#include <sys/cdefs.h>
61__KERNEL_RCSID(0, "$NetBSD: aic6360.c,v 1.105 2022/01/01 21:07:14 andvar Exp $"); 61__KERNEL_RCSID(0, "$NetBSD: aic6360.c,v 1.106 2023/04/05 21:46:09 andvar Exp $");
62 62
63#include "opt_ddb.h" 63#include "opt_ddb.h"
64 64
65/* 65/*
66 * A few customizable items: 66 * A few customizable items:
67 */ 67 */
68 68
69/* Use doubleword transfers to/from SCSI chip. Note: This requires 69/* Use doubleword transfers to/from SCSI chip. Note: This requires
70 * motherboard support. Basically, some motherboard chipsets are able to 70 * motherboard support. Basically, some motherboard chipsets are able to
71 * split a 32 bit I/O operation into two 16 bit I/O operations, 71 * split a 32 bit I/O operation into two 16 bit I/O operations,
72 * transparently to the processor. This speeds up some things, notably long 72 * transparently to the processor. This speeds up some things, notably long
73 * data transfers. 73 * data transfers.
74 */ 74 */
@@ -1700,27 +1700,27 @@ aicintr(void *arg) @@ -1700,27 +1700,27 @@ aicintr(void *arg)
1700 bus_space_tag_t iot = sc->sc_iot; 1700 bus_space_tag_t iot = sc->sc_iot;
1701 bus_space_handle_t ioh = sc->sc_ioh; 1701 bus_space_handle_t ioh = sc->sc_ioh;
1702 u_char sstat0, sstat1; 1702 u_char sstat0, sstat1;
1703 struct aic_acb *acb; 1703 struct aic_acb *acb;
1704 struct scsipi_periph *periph; 1704 struct scsipi_periph *periph;
1705 struct aic_tinfo *ti; 1705 struct aic_tinfo *ti;
1706 int n; 1706 int n;
1707 1707
1708 if (!device_is_active(sc->sc_dev)) 1708 if (!device_is_active(sc->sc_dev))
1709 return (0); 1709 return (0);
1710 1710
1711 /* 1711 /*
1712 * Clear INTEN. We enable it again before returning. This makes the 1712 * Clear INTEN. We enable it again before returning. This makes the
1713 * interrupt esssentially level-triggered. 1713 * interrupt essentially level-triggered.
1714 */ 1714 */
1715 bus_space_write_1(iot, ioh, DMACNTRL0, 0); 1715 bus_space_write_1(iot, ioh, DMACNTRL0, 0);
1716 1716
1717 AIC_TRACE(("aicintr ")); 1717 AIC_TRACE(("aicintr "));
1718 1718
1719loop: 1719loop:
1720 /* 1720 /*
1721 * First check for abnormal conditions, such as reset. 1721 * First check for abnormal conditions, such as reset.
1722 */ 1722 */
1723 sstat1 = bus_space_read_1(iot, ioh, SSTAT1); 1723 sstat1 = bus_space_read_1(iot, ioh, SSTAT1);
1724 AIC_MISC(("sstat1:0x%02x ", sstat1)); 1724 AIC_MISC(("sstat1:0x%02x ", sstat1));
1725 1725
1726 if ((sstat1 & SCSIRSTI) != 0) { 1726 if ((sstat1 & SCSIRSTI) != 0) {