Kernel 0.9.2

This commit is contained in:
Rémy GIBERT 2018-09-27 17:34:38 +02:00
parent 620f57c3d9
commit 42fc2a01e1
6 changed files with 30 additions and 12 deletions

Binary file not shown.

Binary file not shown.

View File

@ -44,6 +44,23 @@ AUTO 4,1
* CC: A = hSOCKET * CC: A = hSOCKET
* CS: A = EC * CS: A = EC
*\-------------------------------------- *\--------------------------------------
SKT.connect >SYSCALL GetMemPtr
>STYA ZPPtrSKT
>PULLW ZPTmpPtr1 sockaddr
ldy #S.SOCKET.SOCK
lda (ZPTmpPtr1),y
tax
jmp (J.SKT.connect,x)
SKT.connect.RAW
SKT.connect.DGRAM
SKT.connect.STREAM
SKT.connect.SEQPACKET
*/-------------------------------------- */--------------------------------------
* # SKT.listen * # SKT.listen
* Create a new socket * Create a new socket
@ -162,7 +179,7 @@ SKT.New >PULLW ZPTmpPtr1
ldy #S.SOCKET.TCP.OPTIONS ldy #S.SOCKET.TCP.OPTIONS
lda (ZPPtrSKT),y lda (ZPPtrSKT),y
ora #S.TCP.OPTIONS.SYN ora #S.TCP.OPTIONS.SYN
jsr TCP.OUT.SendOptA Send SYN,Only for CLIENT conn,or SYN/ACK if comminf from LISTEN jsr TCP.OUT.SendOptA Send SYN,Only for CLIENT conn,or SYN/ACK if coming from LISTEN
bcs .99 bcs .99
ldy #S.SOCKET.TCP.STATUS ldy #S.SOCKET.TCP.STATUS

View File

@ -58,7 +58,7 @@ TCP.IN jsr IP.FillSKT.TemplateSrcDstIPP
asl asl
tax tax
jmp (L.TCP.IN.JMP,x) jmp (J.TCP.IN,x)
.7 lda ZPPtrSKT .7 lda ZPPtrSKT
clc clc
@ -81,9 +81,11 @@ TCP.IN.JMP.LISTEN
sta SKT.Template+S.SOCKET.SOCK sta SKT.Template+S.SOCKET.SOCK
stz SKT.Template+S.SOCKET.SO stz SKT.Template+S.SOCKET.SO
stz SKT.Template+S.SOCKET.TCP.STATUS stz SKT.Template+S.SOCKET.TCP.STATUS
lda #S.TCP.OPTIONS.ACK lda #S.TCP.OPTIONS.SYN+S.TCP.OPTIONS.ACK
sta SKT.Template+S.SOCKET.TCP.OPTIONS sta SKT.Template+S.SOCKET.TCP.OPTIONS
jsr ARP.AddFromFrameInPtr
>PUSHW L.SKT.Template >PUSHW L.SKT.Template
jsr SKT.New Assign OUTNEXTSEQ jsr SKT.New Assign OUTNEXTSEQ
@ -106,8 +108,6 @@ TCP.IN.JMP.LISTEN
jsr SKT.StoreTCB jsr SKT.StoreTCB
jsr ARP.AddFromFrameInPtr
lda #S.TCP.OPTIONS.SYN+S.TCP.OPTIONS.ACK lda #S.TCP.OPTIONS.SYN+S.TCP.OPTIONS.ACK
jsr TCP.OUT.SendOptA SYN received, Send SYN.ACK jsr TCP.OUT.SendOptA SYN received, Send SYN.ACK
bcs .9 bcs .9

View File

@ -113,7 +113,7 @@ L.SKT.Template .DA SKT.Template
L.HST.SScanF .DA HST.SScanF L.HST.SScanF .DA HST.SScanF
L.IOCTL .DA IOCTL L.IOCTL .DA IOCTL
L.DCB.NIC .DA DCB.NIC L.DCB.NIC .DA DCB.NIC
L.TCP.IN.JMP .DA TCP.IN.JMP.CLOSED J.TCP.IN .DA TCP.IN.JMP.CLOSED
.DA TCP.IN.JMP.LISTEN .DA TCP.IN.JMP.LISTEN
.DA TCP.IN.JMP.SYNSENT .DA TCP.IN.JMP.SYNSENT
.DA TCP.IN.JMP.SYNRCVD .DA TCP.IN.JMP.SYNRCVD
@ -124,6 +124,10 @@ L.TCP.IN.JMP .DA TCP.IN.JMP.CLOSED
.DA TCP.IN.JMP.FINWT2 .DA TCP.IN.JMP.FINWT2
.DA TCP.IN.JMP.CLOSING .DA TCP.IN.JMP.CLOSING
.DA TCP.IN.JMP.TIMEWT .DA TCP.IN.JMP.TIMEWT
J.SKT.connect .DA SKT.connect.RAW
.DA SKT.connect.DGRAM
.DA SKT.connect.STREAM
.DA SKT.connect.SEQPACKET
.DA 0 .DA 0
*-------------------------------------- *--------------------------------------
LIB.LOAD ldx RefCount LIB.LOAD ldx RefCount

View File

@ -17,7 +17,8 @@ CS.START cld
jmp (.1,x) jmp (.1,x)
.DA #$61 6502,Level 1 (65c02) .DA #$61 6502,Level 1 (65c02)
.DA #1 BIN Layout Version 1 .DA #1 BIN Layout Version 1
.DA 0 .DA #S.PS.F.EVENT
.DA #0
.DA CS.END-CS.START CS .DA CS.END-CS.START CS
.DA DS.END-DS.START DS .DA DS.END-DS.START DS
.DA #64 SS .DA #64 SS
@ -38,11 +39,7 @@ CS.INIT >LDYA L.LIBTCPIP
bcs .99 bcs .99
sta hLIBTCPIP sta hLIBTCPIP
lda (pPs) * clc
ora #S.PS.F.EVENT Now accept events
sta (pPs)
clc
.99 rts .99 rts
*-------------------------------------- *--------------------------------------
CS.RUN >LIBCALL hLIBTCPIP,LIBTCPIP.POLL CS.RUN >LIBCALL hLIBTCPIP,LIBTCPIP.POLL