Path: utzoo!mnetor!uunet!lll-winken!lll-lcc!ames!pasteur!ucbvax!VAX.FTP.COM!jbvb From: jbvb@VAX.FTP.COM (James Van Bokkelen) Newsgroups: comp.protocols.tcp-ip.ibmpc Subject: Re: An attempt to rekindle interface discuissions... Message-ID: <8803041656.AA03791@vax.ftp.com> Date: 4 Mar 88 16:56:09 GMT References: <8803040730.AA11717@trwind.ind.TRW.COM> Sender: daemon@ucbvax.BERKELEY.EDU Organization: The Internet Lines: 33 FTP Software's 2.0 asynch interface allows the following: You can make any non-blocking kernel call (including writes and closes/aborts), provided that you don't interrupt a blocked syscall of the same type from the mainline program on the same network descriptor. In other words, you can net_write from an asynch handler while the mainline is blocked in net_read on the same descriptor, and you can net_abort from the asynch handler, but don't try another net_read. We support two kinds of handlers. 1. User upcall written in assembly, that doesn't need to save registers, but does have to switch stacks. 2. C-language upcall, where the stack switch is already done, but the stack isn't awfully large (2400 bytes). Interrupts are enabled at entry to either kind. You aren't guaranteed to be synchronized with either DOS or the mainline, so you have to do your own check before you can use O/S services. In general, our asynch handlers aren't supposed to take *too* long, because you're locking out other asynch upcalls, and the kernel won't preempt your handler to do packet processing. Since our normal network descriptors are allocated from a particular program's file descriptor space, and we can't associate a PID with a system call made from an asynch handler, we require that all network descriptors used from within asynch handlers be global (unique in the system). I don't know what goals others have. We have the sockets at source-code level, and our native interrupt-based interface at binary level (you can substitute any of our various TCP/IP kernels without changing your .EXE file, if you need to change interfaces). jbvb