Forgot to upload a file, wich caused net kernel not to compile.
PS: There seems to be a bug in UDP checksum wich causes it to currently only work on DHCP git-svn-id: svn://kolibrios.org@1250 a494cfbc-eb01-0410-851d-a64ba20cac60
This commit is contained in:
parent
7f9d0c6697
commit
441819a385
72
kernel/branches/net/applications/network.inc
Normal file
72
kernel/branches/net/applications/network.inc
Normal file
@ -0,0 +1,72 @@
|
||||
; Socket types
|
||||
SOCK_STREAM = 1
|
||||
SOCK_DGRAM = 2
|
||||
SOCK_RAW = 3 ; not supported by the kernel
|
||||
|
||||
; IP protocols
|
||||
IPPROTO_IP = 0
|
||||
IPPROTO_ICMP = 1 ; not supported by the kernel
|
||||
IPPROTO_TCP = 6
|
||||
IPPROTO_UDP = 17
|
||||
|
||||
; Address families
|
||||
AF_UNSPEC = 0
|
||||
AF_UNIX = 1
|
||||
AF_INET4 = 2 ; IPv4
|
||||
;AF_INET6 = 28 ; IPv6 (not supported)
|
||||
|
||||
PF_UNSPEC = AF_UNSPEC
|
||||
PF_UNIX = AF_UNIX
|
||||
PF_INET4 = AF_INET4
|
||||
;PF_INET6 = AF_INET6
|
||||
|
||||
; Flags for addrinfo
|
||||
AI_PASSIVE = 1
|
||||
AI_CANONNAME = 2
|
||||
AI_NUMERICHOST = 4
|
||||
AI_NUMERICSERV = 8
|
||||
AI_ADDRCONFIG = 0x400
|
||||
|
||||
; internal definition
|
||||
AI_SUPPORTED = 0x40F
|
||||
|
||||
struct sockaddr_in
|
||||
sin_family dw ? ; sa_family_t
|
||||
sin_port dw ? ; in_port_t
|
||||
sin_addr dd ? ; struct in_addr
|
||||
sin_zero rb 8 ; zero
|
||||
ends
|
||||
|
||||
struct addrinfo
|
||||
ai_flags dd ? ; bitmask of AI_*
|
||||
ai_family dd ? ; PF_*
|
||||
ai_socktype dd ? ; SOCK_*
|
||||
ai_protocol dd ? ; 0 or IPPROTO_*
|
||||
ai_addrlen dd ? ; length of ai_addr
|
||||
ai_canonname dd ? ; char*
|
||||
ai_addr dd ? ; struct sockaddr*
|
||||
ai_next dd ? ; struct addrinfo*
|
||||
ends
|
||||
|
||||
EAI_ADDRFAMILY = 1
|
||||
EAI_AGAIN = 2
|
||||
EAI_BADFLAGS = 3
|
||||
EAI_FAIL = 4
|
||||
EAI_FAMILY = 5
|
||||
EAI_MEMORY = 6
|
||||
EAI_NONAME = 8
|
||||
EAI_SERVICE = 9
|
||||
EAI_SOCKTYPE = 10
|
||||
EAI_BADHINTS = 12
|
||||
EAI_PROTOCOL = 13
|
||||
EAI_OVERFLOW = 14
|
||||
|
||||
socket fix 74, 0
|
||||
close fix 74, 1
|
||||
bind fix 74, 2
|
||||
listen fix 74, 3
|
||||
connect fix 74, 4
|
||||
accept fix 74, 5
|
||||
send fix 74, 6
|
||||
recv fix 74, 7
|
||||
|
@ -160,9 +160,9 @@ kernel_export:
|
||||
dd szStrchr , strchr
|
||||
dd szStrrchr , strrchr
|
||||
|
||||
dd szEthReceiver , ETH_Receiver
|
||||
dd szEthRegDev , ETH_Add_Device
|
||||
dd szEthUnRegDev , ETH_Remove_Device
|
||||
dd szEthReceiver , ETH_receiver
|
||||
dd szEthRegDev , ETH_add_device
|
||||
dd szEthUnRegDev , ETH_remove_device
|
||||
dd szEthStruc2Dev , ETH_struc2dev
|
||||
|
||||
exp_lfb:
|
||||
|
Loading…
Reference in New Issue
Block a user