Deleted Added
full compact
aic7xxx.seq (21947) aic7xxx.seq (21982)
1/*+M***********************************************************************
2 *Adaptec 274x/284x/294x device driver for Linux and FreeBSD.
3 *
4 *Copyright (c) 1994 John Aycock
5 * The University of Calgary Department of Computer Science.
6 * All rights reserved.
7 *
8 *FreeBSD, Twin, Wide, 2 command per target support, tagged queuing,

--- 25 unchanged lines hidden (view full) ---

34 *OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
35 *HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT
36 *LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY
37 *OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
38 *SUCH DAMAGE.
39 *
40 *-M************************************************************************/
41
1/*+M***********************************************************************
2 *Adaptec 274x/284x/294x device driver for Linux and FreeBSD.
3 *
4 *Copyright (c) 1994 John Aycock
5 * The University of Calgary Department of Computer Science.
6 * All rights reserved.
7 *
8 *FreeBSD, Twin, Wide, 2 command per target support, tagged queuing,

--- 25 unchanged lines hidden (view full) ---

34 *OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
35 *HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT
36 *LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY
37 *OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
38 *SUCH DAMAGE.
39 *
40 *-M************************************************************************/
41
42VERSION AIC7XXX_SEQ_VER "$FreeBSD: head/sys/dev/aic7xxx/aic7xxx.seq 21947 1997-01-22 18:01:07Z gibbs $"
42VERSION AIC7XXX_SEQ_VER "$FreeBSD: head/sys/dev/aic7xxx/aic7xxx.seq 21982 1997-01-24 21:57:47Z gibbs $"
43
44#if defined(__NetBSD__)
45#include "../../../../dev/ic/aic7xxxreg.h"
46#include "../../../../scsi/scsi_message.h"
47#elif defined(__FreeBSD__)
48#include "../../dev/aic7xxx/aic7xxx_reg.h"
49#include "../../scsi/scsi_message.h"
50#endif

--- 449 unchanged lines hidden (view full) ---

500 */
501 mvi DINDEX, HADDR0
502 mvi SCB_CMDPTR call bcopy_5
503 clr HCNT1
504 clr HCNT2
505
506 call set_stcnt_from_hcnt
507
43
44#if defined(__NetBSD__)
45#include "../../../../dev/ic/aic7xxxreg.h"
46#include "../../../../scsi/scsi_message.h"
47#elif defined(__FreeBSD__)
48#include "../../dev/aic7xxx/aic7xxx_reg.h"
49#include "../../scsi/scsi_message.h"
50#endif

--- 449 unchanged lines hidden (view full) ---

500 */
501 mvi DINDEX, HADDR0
502 mvi SCB_CMDPTR call bcopy_5
503 clr HCNT1
504 clr HCNT2
505
506 call set_stcnt_from_hcnt
507
508 mvi 0x3d call dma # SCSIEN|SDMAEN|HDMAEN|
509 # DIRECTION|FIFORESET
508 mvi DFCNTRL, 0x3d /* SCSIEN|SDMAEN|HDMAEN
509 * |DIRECTION|FIFORESET
510 */
511p_command_dma:
512 test SSTAT0, SDONE jnz p_command_dma_done
513 test SSTAT1, PHASEMIS jz p_command_dma
514 test SSTAT0, SDONE jnz p_command_dma_done
515 clr DFCNTRL
510 jmp ITloop
516 jmp ITloop
517p_command_dma_done:
518 and DFCNTRL, 0xc7 /* ~(SCSIEN|SDMAEN|HDMAEN) */
519p_command_dma_clear:
520 test DFCNTRL, 0x38 jnz p_command_dma_clear
521 jmp ITloop
511
512/*
513 * Status phase. Wait for the data byte to appear, then read it
514 * and store it into the SCB.
515 */
516p_status:
517 call assert
518

--- 405 unchanged lines hidden (view full) ---

924dma4:
925 test DFSTATUS,FIFOEMP jz dma4
926
927/*
928 * Now shut the DMA enables off and make sure that the DMA enables are
929 * actually off first lest we get an ILLSADDR.
930 */
931dma5:
522
523/*
524 * Status phase. Wait for the data byte to appear, then read it
525 * and store it into the SCB.
526 */
527p_status:
528 call assert
529

--- 405 unchanged lines hidden (view full) ---

935dma4:
936 test DFSTATUS,FIFOEMP jz dma4
937
938/*
939 * Now shut the DMA enables off and make sure that the DMA enables are
940 * actually off first lest we get an ILLSADDR.
941 */
942dma5:
932 /* disable DMA, but maintain WIDEODD */
933 and DFCNTRL,WIDEODD
943 /* Don't clobber an inprogress host data transfer */
944 test DFSTATUS, MREQPEND jnz dma5
945 /* disable DMA */
946 and DFCNTRL, 0xc7 /* ~(SCSIEN|SDMAEN|HDMAEN|DIRECTION) */
934dma6:
947dma6:
935 test DFCNTRL,0x38 jnz dma6 /* SCSIENACK|SDMAENACK|HDMAENACK */
948 test DFCNTRL, HDMAENACK jnz dma6
936return:
937 ret
938
939/*
940 * Common SCSI initialization for selection and reselection. Expects
941 * the target SCSI ID to be in the upper four bits of SINDEX, and A's
942 * contents are stomped on return.
943 */

--- 210 unchanged lines hidden ---
949return:
950 ret
951
952/*
953 * Common SCSI initialization for selection and reselection. Expects
954 * the target SCSI ID to be in the upper four bits of SINDEX, and A's
955 * contents are stomped on return.
956 */

--- 210 unchanged lines hidden ---