1
0
mirror of https://github.com/simh/simh.git synced 2026-01-25 19:56:25 +00:00

ETHER,VAX,PDP11: Added UDP as a link type for Ethernet packet connectivity.

This will allow a single simulator to directly connect to HECnet systems without needing an external bridge program.
This commit is contained in:
Mark Pizzolato
2013-12-05 11:58:58 -08:00
parent c1aa85d944
commit 834e986eaf
5 changed files with 210 additions and 44 deletions

View File

@@ -67,6 +67,7 @@
#define SIM_ETHER_H
#include "sim_defs.h"
#include "sim_sock.h"
/* make common BSD code a bit easier to read in this file */
/* OS/X seems to define and compile using one of these BSD types */
@@ -212,11 +213,13 @@ typedef struct eth_item ETH_ITEM;
struct eth_device {
char* name; /* name of ethernet device */
void* handle; /* handle of implementation-specific device */
int fd_handle; /* fd to kernel device (where needed) */
SOCKET fd_handle; /* fd to kernel device (where needed) */
int eth_api; /* Designator for which API is being used to move packets */
#define ETH_API_PCAP 0 /* Pcap API in use */
#define ETH_API_TAP 1 /* tun/tap API in use */
#define ETH_API_VDE 2 /* VDE API in use */
#define ETH_API_UDP 3 /* UDP API in use */
#define ETH_API_NAT 4 /* NAT (SLiRP) API in use */
ETH_PCALLBACK read_callback; /* read callback function */
ETH_PCALLBACK write_callback; /* write callback function */
ETH_PACK* read_packet; /* read packet */