1
0
mirror of https://github.com/PDP-10/klh10.git synced 2026-02-10 10:11:08 +00:00

Add libpcap for receiving and sending ethernet frames.

The goal is to retire KLH10_NET_BPF, _PFLT, _DLPI and _LNX as much as possible.
However where ethernet addresses are manipulated, such operating system dependent methods still need to be used, since libpcap does not handle that.

Code for the other packet filters is still included but most likely does not work.
To use the new code, add -DKLH10_NET_PCAP to the Makefile(s).
This commit is contained in:
Olaf Seibert
2015-12-20 17:56:51 +01:00
parent 6bc3ecd739
commit 89be604190
7 changed files with 500 additions and 134 deletions

View File

@@ -1346,8 +1346,8 @@ tim_init(void)
os_rtmget(&cpu.tim.osbase);
return FALSE;
}
fread((char *)&cpu.tim.wrbase, sizeof(cpu.tim.wrbase), 1, f);
fread((char *)&cpu.tim.osbase, sizeof(cpu.tim.osbase), 1, f);
(void)fread((char *)&cpu.tim.wrbase, sizeof(cpu.tim.wrbase), 1, f);
(void)fread((char *)&cpu.tim.osbase, sizeof(cpu.tim.osbase), 1, f);
os_rtm_adjust_base(&cpu.tim.osbase, &cpu.tim.osbase, 0);
if (ferror(f)) {
fclose(f);