CP working in Z3 and driver update

A fix for int6 is needed for the first proto: Connect SJ1 right with INT6-Pad. But CP and lan are not working with AmiTCP
This commit is contained in:
MHeinrichs
2019-02-20 23:45:57 +01:00
parent 94425362cc
commit 11c25fe78d
49 changed files with 17604 additions and 14235 deletions
+4 -2
View File
@@ -162,11 +162,11 @@ ASM SAVEDS LONG DevOpen( ASMR(a1) struct IOSana2Req *ioreq ASMREG(a1),
if( (db->db_Units[unit].du_OpenCount > 0) &&
(flags & SANA2OPF_MINE) )
ok = 0;
#if 0
if( (db->db_Units[unit].du_OpenCount > 0) &&
(flags & SANA2OPF_PROM) )
ok = 0;
#endif
if( db->db_Units[unit].du_Flags & DUF_EXCLUSIVE )
ok = 0;
@@ -215,6 +215,8 @@ ASM SAVEDS LONG DevOpen( ASMR(a1) struct IOSana2Req *ioreq ASMREG(a1),
dbm->dbm_CopyFromBuffer32 = (BMCALL)((void (*)())(GetTagData(S2_CopyFromBuff32, 0,
(struct TagItem *)ioreq->ios2_BufferManagement)));
}
D(("BufferMgmt CBuf32 %lx PF %lx CBuf %lx\n",(ULONG)dbm->dbm_CopyFromBuffer32,(ULONG)dbm->dbm_PacketFilter,(ULONG)dbm->dbm_CopyFromBuffer));
if( !dbm->dbm_CopyToBuffer32 )
dbm->dbm_CopyToBuffer32 = dbm->dbm_CopyToBuffer;
+54 -5
View File
@@ -6,7 +6,9 @@
; - device in Mode 3, i.e. 16 Bit access
; - register addresses shifted by 1 left, i.e. register base * 2 compared
; to 16 Bit mode of ENC624J600 documentation (8 Bit mode alike)
; - some byte shuffling required - which currently is in a state of flux
; - in initial hardware/software combinations there was some byte
; shuffling required - whose consequence is encapsulation of hardware
; accesses in macros
;
; Note: This code is in some places intentionally saving more registers than
; required by the AmigaOS ABI.
@@ -376,8 +378,9 @@ _enc624j6l_CheckBoard: ;check whether board is operating correctly
; ----------------- quick check for operational mode ------------------
move.w #$1234,d1
WRITEREG EUDAST,a0,d1 ;write data
tst.l 4.w ;clear BUS
READREG EUDAST,a0,d0
moveq #0,d0
SETREG EUDAST,a0,d0 ;clear ENC's bus (does not change anything in its regs)
READREG EUDAST,a0,d0 ;
cmp.w d0,d1 ;do we get the register back ?
bne.s .err ;no -> complain
@@ -1296,6 +1299,52 @@ _enc624j6l_RecvFrame: ;
bra.s .end_read
.nooptrecv:
ifeq _OPT_BUFFER_SWAP ;1
;
;wraparound aware loop for big endian buffer
;
move.w #RXSTOP_INIT+1,d1 ;end address $6000
lea (a0,d7.w),a2 ;read pointer
sub.w d7,d1 ;minus start pointer = number of bytes until wrap
cmp.w d0,d1 ;
bhi.s .emergency_slow ;don`t trust anyone: if d1<0 or >total_length, then branch to slow routine
move d1,d2
lsr #2,d2 ;we copy long words
subq #1,d2 ;dbf
blt.s .nowords_beforewrap ;
.loop_beforewrap:
move.l (a2)+,(a1)+
dbf d2,.loop_beforewrap
.nowords_beforewrap: ;
btst #1,d7 ;uneven longword address before wraparound ?
beq.s .copy_afterwrap
move.w (a2)+,(a1)+ ;copy word from uneven address
.copy_afterwrap:
move #RXSTART_INIT,d7 ;wrap
lea (a0,d7.w),a2 ;read pointer
move d0,d2 ;total bytes to read
sub.w d1,d2 ;remaining=total-copied (D1=RXSTOP_INIT+1-D7)
ble.s .end_read ;done, if zero
move d2,d1 ;
lsr #2,d2 ;we copy long words
bra.s .enter_afterwrap
.loop_afterwrap:
move.l (a2)+,(a1)+
.enter_afterwrap:
dbf d2,.loop_afterwrap
and.b #3,d1 ;btst #1,d1 ;1 byte or short remaining ?
beq.s .end_read
move.w (a2)+,(a1)+
bra.s .end_read
.emergency_slow:
endc ;_OPT_BUFFER_SWAP
endc ;_OPT_RECV
;generic loop: check for position overflows with each word
@@ -1427,7 +1476,7 @@ _enc624j6l_TransmitFrame:
move.l (a1)+,(a2)+ ;save to SRAM
endr
move.l (a1)+,d1
dbf d5,.largecopy
dbf d5,.largecopy
move.l d1,(a2)+
@@ -1479,7 +1528,7 @@ _enc624j6l_TransmitFrame:
;100 MBit/s frame time is max. 0.12 ms (without inter-frame spacing)
;wait 20 us via CIA
moveq #120,d0
moveq #20,d0
bsr _enc624j6l_UMinDelay
dbf d3,.txwait ;approx. 4ms max. wait
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
+16 -1
View File
@@ -1,3 +1,4 @@
;APS00000000000000000000000000000000000000000000000000000000000000000000000000000000
; ------------------------------------------------------------------------------
; | Flash ROM Read Serial Number |
; | Copyright (c) 2016 APOLLO TEAM |
@@ -21,6 +22,10 @@ FLASH_MISOn EQU $0
;VAMPIRE_MAGIC EQU ascii "Vamp"
VAMPIRE_MAGIC EQU $56616D70
VAMPIDREG EQU $DFF3FC
V4_ID1 EQU $DFF3F4
V4_ID2 EQU $DFF3F0
xdef _vampire_UUID
;-------- Get 64 Bit unique ID --------------------
@@ -31,13 +36,23 @@ VAMPIRE_MAGIC EQU $56616D70
; >0 - success
_vampire_UUID:
movem.l d1-a6,-(sp) ;lazy register store
lea VAMPIDREG,a0
move.w (a0),d0 ;ID reg empty?
blt.s v2$ ;yes, try flash method
cmp.w #$2FF,d0 ;Core type << 8 | Clock_Multiplier
ble.s v2$
move.l V4_ID1-VAMPIDREG(a0),d0
move.l V4_ID2-VAMPIDREG(a0),d1
bra.s common$
v2$
bsr flashreadid
cmpi.b #FLASH_ID,d0
bne.s error$
bsr flashuniqueid
common$
move.l d0,(a1)
move.l d1,4(a1)
+7 -1
View File
@@ -35,6 +35,10 @@ static LONG server_queryext( DEVBASEP, ULONG unit, struct IOSana2Req *ioreq );
*/
#define S2QUERYEXT_NOLENGTHCHECK
/* this limits the number of write requests per run, also improves
Roadshow performance when active */
#define ONE_WRITE_REQ
/* (avoid external link libraries) this call is not time critical */
static void MemSet( void *a, ULONG val, ULONG size )
@@ -684,7 +688,7 @@ static LONG server_writequeue( DEVBASEP, ULONG unit )
ObtainSemaphore( &db->db_Units[unit].du_Sem );
#if 1
#if 1 /* #ifdef ONE_WRITE_REQ */
/* whole queue per call */
for( ioreq = (struct IOSana2Req *)db->db_Units[unit].du_WriteQueue.lh_Head;
(nextio= (struct IOSana2Req *)ioreq->ios2_Req.io_Message.mn_Node.ln_Succ);
@@ -726,8 +730,10 @@ static LONG server_writequeue( DEVBASEP, ULONG unit )
/* error handling */
server_writeerror( db, unit, ioreq, code );
}
#ifdef ONE_WRITE_REQ
if( hw_recv_pending(db,unit) )
break;
#endif
}
ReleaseSemaphore( &db->db_Units[unit].du_Sem );
+1 -1
View File
@@ -154,7 +154,7 @@ v2expeth.device: $(OBJECTS)
-$(LD) $(OBJECTS) LIB sc:lib/sc.lib $(LDFLAGS) TO $(DEVICEID)
clean:
-$(RM) sdnet.device v2expeth.device \#?.oex *.osd $(SUBDIR)/\#?.oex $(SUBDIR)/\#?.osd
-$(RM) sdnet.device v2expeth.device \#?.oex \#?.osd $(SUBDIR)/\#?.oex $(SUBDIR)/\#?.osd
install:
copy sdnet.device v2expeth.device DEVS:Networks
+1 -1
View File
@@ -154,7 +154,7 @@ enc624j6net.device_68000: $(OBJECTS)
-$(LD) $(OBJECTS) LIB sc:lib/sc.lib $(LDFLAGS) TO $(DEVICEID)_68000
clean:
-$(RM) enc624j6net.device enc624j6net.device_68000 \#?.o00 *.o20 $(SUBDIR)/\#?.o00 $(SUBDIR)/\#?.o20
-$(RM) enc624j6net.device enc624j6net.device_68000 \#?.o00 \#?.o20 $(SUBDIR)/\#?.o00 $(SUBDIR)/\#?.o20
install:
copy enc624j6net.device DEVS:Networks
+5 -4
View File
@@ -8,9 +8,10 @@
#ifndef _INC_VERSION_H
#define _INC_VERSION_H
#define DEVICEVERSION 1
#define DEVICEREVISION 99
#define DEVICEEXTRA Beta
#define DEVICEDATE 08.01.2019
#define DEVICEVERSION 2
#define DEVICEREVISION 0
#define DEVICEEXTRA
/* #define DEVICEEXTRA Beta */
#define DEVICEDATE 13.01.2019
#endif