>
> [dave@computone.com (David Johnson) writes:]
>
> >For example, say two processes have the Ethernet driver open and are
> >registered to receive all packets (promiscuous mode). I need to take
> >each incoming packet and duplicate it to each of these receivers.
>
> Nick is right, but perhaps I can flesh out some details.
>
> First, your ethernet driver will not be receiving messages; he will be
> arming DMA down onto the Lance (or whatever ether chip), and filling in
> wired pages in his address space. He will be receiving interrupt messages
> as packets are completely received.
>
> Now he has some private memory, with interesting contents, and he wants
> to send it to two folks. Or does he? Is he a server (and thus must wait
> to RECEIVE requests) or a client (he gets to initiate requests)? I'd
> guess he's a server, since he must receive messages concerning interrupts,
> anyway.
>
> So, he has a packet, and has previously had msg_receive() return him two
> requests, neither to which he has msg_reply()'ed yet. All he does is find
> the pending messages, fill in the scatter/gather list with the packet,
> and do a msg_reply() to each client.
>
> You can see logic for handling multiple outstanding I/O requests. See
> the kbd driver, for instance. I think the fd driver queues multiple
> requests as well.
>
> Andy
>
No problem. I kinda figured it would be this simple. Now on to another
problem which now surfaces. A typical TCP stream will look something
like the following (maybe more servers):
User program
|
|
TCP server
|
|
Ethernet server
Normally packets are sent up in a STREAMS environment asynchronously to the
modules above. They process them and send them to the STREAM head which
holds them for the user. However, in the server model, how can the TCP
module keep a pending receive in the Ethernet server and still service other
write requests from above?
dave
Received on Wed Oct 13 05:42:25 1993
This archive was generated by hypermail 2.1.8 : Wed Sep 21 2005 - 19:37:12 PDT