Renamed "slirp_new" to "slirp" (source file, symbols, classes, docs)
This commit is contained in:
parent
571f612bc7
commit
64385beaa4
@ -958,8 +958,8 @@ speaker: enabled=1, mode=sound
|
||||
# this script to configure this network interface, or enable masquerading.
|
||||
# This is mainly useful for the tun/tap devices that only exist during
|
||||
# Bochs execution. The network interface name is supplied to the script
|
||||
# as first parameter. The 'slirp_new' module uses this parameter
|
||||
# to specify a config file for setting up an alternative configuration.
|
||||
# as first parameter. The 'slirp' module uses this parameter to specify
|
||||
# a config file for setting up an alternative configuration.
|
||||
#
|
||||
# BOOTROM: The bootrom value is optional, and is the name of the ROM image
|
||||
# to load. Note that this feature is only implemented for the PCI version of
|
||||
@ -985,7 +985,7 @@ speaker: enabled=1, mode=sound
|
||||
# ne2k: ioaddr=0x300, irq=9, mac=b0:c4:20:00:00:01, ethmod=null, ethdev=eth0
|
||||
# ne2k: ioaddr=0x300, irq=9, mac=b0:c4:20:00:00:01, ethmod=vde, ethdev="/tmp/vde.ctl"
|
||||
# ne2k: ioaddr=0x300, irq=9, mac=b0:c4:20:00:00:01, ethmod=vnet, ethdev="c:/temp"
|
||||
# ne2k: mac=b0:c4:20:00:00:01, ethmod=slirp_new, script=slirp.conf, bootrom=ne2k_pci.rom
|
||||
# ne2k: mac=b0:c4:20:00:00:01, ethmod=slirp, script=slirp.conf, bootrom=ne2k_pci.rom
|
||||
|
||||
#=======================================================================
|
||||
# pcipnic: Bochs/Etherboot pseudo-NIC
|
||||
@ -1009,7 +1009,7 @@ speaker: enabled=1, mode=sound
|
||||
# The E1000 accepts the same syntax (for mac, ethmod, ethdev, script, bootrom)
|
||||
# and supports the same networking modules as the NE2000 adapter.
|
||||
#=======================================================================
|
||||
#e1000: enabled=1, mac=52:54:00:12:34:56, ethmod=slirp_new, script=slirp.conf
|
||||
#e1000: enabled=1, mac=52:54:00:12:34:56, ethmod=slirp, script=slirp.conf
|
||||
|
||||
#=======================================================================
|
||||
# USB_UHCI:
|
||||
|
Binary file not shown.
Binary file not shown.
@ -160,8 +160,8 @@ void bx_init_std_nic_options(const char *name, bx_list_c *menu)
|
||||
#if BX_NETMOD_VDE
|
||||
"vde",
|
||||
#endif
|
||||
#if BX_NETMOD_SLIRP_NEW
|
||||
"slirp_new",
|
||||
#if BX_NETMOD_SLIRP
|
||||
"slirp",
|
||||
#endif
|
||||
"vnet",
|
||||
NULL
|
||||
|
@ -846,7 +846,7 @@ typedef
|
||||
#define BX_NETMOD_TAP 0
|
||||
#define BX_NETMOD_TUNTAP 0
|
||||
#define BX_NETMOD_VDE 0
|
||||
#define BX_NETMOD_SLIRP_NEW 0
|
||||
#define BX_NETMOD_SLIRP 0
|
||||
|
||||
// Soundcard and gameport support
|
||||
#define BX_SUPPORT_SB16 0
|
||||
|
@ -1529,24 +1529,24 @@ NETLOW_OBJS=''
|
||||
if test "$networking" = yes; then
|
||||
NETLOW_OBJS='eth_null.o eth_vnet.o'
|
||||
ethernet_modules='null vnet'
|
||||
can_compile_slirp_new=0
|
||||
can_compile_slirp=0
|
||||
case "$target" in
|
||||
*-cygwin* | *-mingw32*)
|
||||
can_compile_slirp_new=1
|
||||
can_compile_slirp=1
|
||||
DEVICE_LINK_OPTS="$DEVICE_LINK_OPTS -liphlpapi"
|
||||
;;
|
||||
*-pc-windows* | *-pc-winnt*)
|
||||
can_compile_slirp_new=1
|
||||
can_compile_slirp=1
|
||||
DEVICE_LINK_OPTS="$DEVICE_LINK_OPTS iphlpapi.lib"
|
||||
;;
|
||||
*)
|
||||
AC_CHECK_HEADER([netinet/in.h], [ can_compile_slirp_new=1 ], [])
|
||||
AC_CHECK_HEADER([netinet/in.h], [ can_compile_slirp=1 ], [])
|
||||
;;
|
||||
esac
|
||||
if test $can_compile_slirp_new = 1; then
|
||||
NETLOW_OBJS="$NETLOW_OBJS eth_slirp_new.o \$(SLIRP_OBJS)"
|
||||
ethernet_modules="$ethernet_modules slirp_new"
|
||||
AC_DEFINE(BX_NETMOD_SLIRP_NEW, 1)
|
||||
if test $can_compile_slirp = 1; then
|
||||
NETLOW_OBJS="$NETLOW_OBJS eth_slirp.o \$(SLIRP_OBJS)"
|
||||
ethernet_modules="$ethernet_modules slirp"
|
||||
AC_DEFINE(BX_NETMOD_SLIRP, 1)
|
||||
fi
|
||||
if test "$MSVC_TARGET" != 1; then
|
||||
AC_CHECK_HEADER(net/bpf.h, [
|
||||
|
@ -4413,7 +4413,7 @@ ne2k: ioaddr=0x300, irq=9, mac=b0:c4:20:00:00:01, ethmod=vde, ethdev="/tmp/vde.c
|
||||
ne2k: ioaddr=0x300, irq=9, mac=b0:c4:20:00:00:01, ethmod=vnet, ethdev="c:/temp"
|
||||
ne2k: ioaddr=0x300, irq=9, mac=fe:fd:00:00:00:01, ethmod=tap, ethdev=tap0
|
||||
ne2k: ioaddr=0x300, irq=9, mac=fe:fd:00:00:00:01, ethmod=tuntap, ethdev=/dev/net/tun0, script=./tunconfig
|
||||
ne2k: mac=b0:c4:20:00:00:01, ethmod=slirp_new, script=slirp.conf, bootrom=ne2k_pci.rom
|
||||
ne2k: mac=b0:c4:20:00:00:01, ethmod=slirp, script=slirp.conf, bootrom=ne2k_pci.rom
|
||||
|
||||
IOADDR, IRQ: You probably won't need to change ioaddr and irq, unless there
|
||||
are IRQ conflicts. These parameters are ignored if the NE2000 is assigned to
|
||||
@ -4528,7 +4528,7 @@ version where this module was added.
|
||||
<entry>2.2</entry>
|
||||
</row>
|
||||
<row>
|
||||
<entry>slirp_new</entry>
|
||||
<entry>slirp</entry>
|
||||
<entry>Built-in Slirp support with DHCP / TFTP servers. Adds user mode
|
||||
networking to Bochs. The 'script' parameter can be used to set up an
|
||||
alternative configuration. The TFTP server uses the 'ethdev' value for
|
||||
@ -4568,7 +4568,7 @@ NE2000 adapter.
|
||||
<para>
|
||||
Example:
|
||||
<screen>
|
||||
e1000: enabled=1, mac=52:54:00:12:34:56, ethmod=slirp_new, script=slirp.conf
|
||||
e1000: enabled=1, mac=52:54:00:12:34:56, ethmod=slirp, script=slirp.conf
|
||||
</screen>
|
||||
To support the Intel(R) 82540EM Gigabit Ethernet adapter, Bochs must be compiled
|
||||
with the <option>--enable-e1000</option> configure option. It accepts the same syntax
|
||||
|
@ -1,5 +1,5 @@
|
||||
.\"Document Author: Timothy R. Butler - tbutler@uninetsolutions.com"
|
||||
.TH bochsrc 5 "01 Apr 2014" "bochsrc" "The Bochs Project"
|
||||
.TH bochsrc 5 "02 Apr 2014" "bochsrc" "The Bochs Project"
|
||||
.\"SKIP_SECTION"
|
||||
.SH NAME
|
||||
bochsrc \- Configuration file for Bochs.
|
||||
@ -1058,7 +1058,7 @@ to access physical ethernet interface. Current implemented values include
|
||||
- win32 : ethernet on win32
|
||||
- tap : ethernet through a linux tap interface
|
||||
- tuntap : ethernet through a linux tuntap interface
|
||||
- slirp_new : built-in Slirp support with DHCP / TFTP servers
|
||||
- slirp : built-in Slirp support with DHCP / TFTP servers
|
||||
|
||||
If you don't want to make connections to any physical networks,
|
||||
you can use the following 'ethmod's to simulate a virtual network.
|
||||
@ -1083,8 +1083,8 @@ is executed after bochs initialize the network interface. You can use
|
||||
this script to configure this network interface, or enable masquerading.
|
||||
This is mainly useful for the tun/tap devices that only exist during
|
||||
Bochs execution. The network interface name is supplied to the script
|
||||
as first parameter. The 'slirp_new' module uses this parameter
|
||||
to specify a config file for setting up an alternative configuration.
|
||||
as first parameter. The 'slirp' module uses this parameter to specify
|
||||
a config file for setting up an alternative configuration.
|
||||
|
||||
BOOTROM:
|
||||
The bootrom value is optional, and is the name of the ROM image
|
||||
@ -1099,7 +1099,7 @@ Examples:
|
||||
ne2k: ioaddr=0x300, irq=9, mac=fe:fd:00:00:00:01, ethmod=tuntap, ethdev=/dev/net/tun0, script=./tunconfig
|
||||
ne2k: ioaddr=0x300, irq=9, mac=b0:c4:20:00:00:01, ethmod=vde, ethdev="/tmp/vde.ctl"
|
||||
ne2k: ioaddr=0x300, irq=9, mac=b0:c4:20:00:00:01, ethmod=vnet, ethdev="c:/temp"
|
||||
ne2k: mac=b0:c4:20:00:00:01, ethmod=slirp_new, script=slirp.conf, bootrom=ne2k_pci.rom
|
||||
ne2k: mac=b0:c4:20:00:00:01, ethmod=slirp, script=slirp.conf, bootrom=ne2k_pci.rom
|
||||
|
||||
.TP
|
||||
.I "pcipnic:"
|
||||
@ -1119,7 +1119,7 @@ with the --eanble-e1000 configure option. The E1000 accepts the same syntax
|
||||
modules as the NE2000 adapter.
|
||||
|
||||
Example:
|
||||
e1000: enabled=1, mac=52:54:00:12:34:56, ethmod=slirp_new, script=slirp.conf
|
||||
e1000: enabled=1, mac=52:54:00:12:34:56, ethmod=slirp, script=slirp.conf
|
||||
|
||||
.TP
|
||||
.I "usb_uhci:"
|
||||
|
@ -90,7 +90,7 @@ Attached devices
|
||||
| +---- TUN/TAP Interface eth_tuntap.cc
|
||||
| +---- VDE Interface eth_vde.cc
|
||||
| +---- virtual Ethernet locator eth_vnet.cc
|
||||
| +---- builtin Slirp support eth_slirp_new.cc, slirp/*
|
||||
| +---- builtin Slirp support eth_slirp.cc, slirp/*
|
||||
|
|
||||
+---- Sound support sound/
|
||||
| |
|
||||
|
@ -164,7 +164,7 @@ eth_null.o: eth_null.@CPP_SUFFIX@ ../iodev.h ../../bochs.h ../../config.h \
|
||||
../../memory/memory.h ../../pc_system.h ../../gui/gui.h \
|
||||
../../instrument/stubs/instrument.h ../../plugin.h ../../extplugin.h \
|
||||
../../param_names.h netmod.h
|
||||
eth_slirp_new.o: eth_slirp_new.@CPP_SUFFIX@ ../iodev.h ../../bochs.h ../../config.h \
|
||||
eth_slirp.o: eth_slirp.@CPP_SUFFIX@ ../iodev.h ../../bochs.h ../../config.h \
|
||||
../../osdep.h ../../bx_debug/debug.h ../../config.h ../../osdep.h \
|
||||
../../gui/siminterface.h ../../cpudb.h ../../gui/paramtree.h \
|
||||
../../memory/memory.h ../../pc_system.h ../../gui/gui.h \
|
||||
@ -356,7 +356,7 @@ eth_null.lo: eth_null.@CPP_SUFFIX@ ../iodev.h ../../bochs.h ../../config.h \
|
||||
../../memory/memory.h ../../pc_system.h ../../gui/gui.h \
|
||||
../../instrument/stubs/instrument.h ../../plugin.h ../../extplugin.h \
|
||||
../../param_names.h netmod.h
|
||||
eth_slirp_new.lo: eth_slirp_new.@CPP_SUFFIX@ ../iodev.h ../../bochs.h ../../config.h \
|
||||
eth_slirp.lo: eth_slirp.@CPP_SUFFIX@ ../iodev.h ../../bochs.h ../../config.h \
|
||||
../../osdep.h ../../bx_debug/debug.h ../../config.h ../../osdep.h \
|
||||
../../gui/siminterface.h ../../cpudb.h ../../gui/paramtree.h \
|
||||
../../memory/memory.h ../../pc_system.h ../../gui/gui.h \
|
||||
|
@ -19,14 +19,14 @@
|
||||
// Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA
|
||||
//
|
||||
|
||||
// eth_slirp_new.cc - Bochs port of Qemu's slirp implementation
|
||||
// eth_slirp.cc - Bochs port of Qemu's slirp implementation
|
||||
|
||||
#define BX_PLUGGABLE
|
||||
|
||||
#include "iodev.h"
|
||||
#include "netmod.h"
|
||||
|
||||
#if BX_NETWORKING && BX_NETMOD_SLIRP_NEW
|
||||
#if BX_NETWORKING && BX_NETMOD_SLIRP
|
||||
|
||||
#include "slirp/slirp.h"
|
||||
#include "slirp/libslirp.h"
|
||||
@ -44,13 +44,13 @@ extern int slirp_smb(Slirp *s, char *smb_tmpdir, const char *exported_dir,
|
||||
void slirp_smb_cleanup(Slirp *s, char *smb_tmpdir);
|
||||
#endif
|
||||
|
||||
class bx_slirp_new_pktmover_c : public eth_pktmover_c {
|
||||
class bx_slirp_pktmover_c : public eth_pktmover_c {
|
||||
public:
|
||||
bx_slirp_new_pktmover_c();
|
||||
bx_slirp_new_pktmover_c(const char *netif, const char *macaddr,
|
||||
eth_rx_handler_t rxh, eth_rx_status_t rxstat,
|
||||
bx_devmodel_c *dev, const char *script);
|
||||
virtual ~bx_slirp_new_pktmover_c();
|
||||
bx_slirp_pktmover_c();
|
||||
bx_slirp_pktmover_c(const char *netif, const char *macaddr,
|
||||
eth_rx_handler_t rxh, eth_rx_status_t rxstat,
|
||||
bx_devmodel_c *dev, const char *script);
|
||||
virtual ~bx_slirp_pktmover_c();
|
||||
void sendpkt(void *buf, unsigned io_len);
|
||||
void receive(void *pkt, unsigned pkt_len);
|
||||
int can_receive(void);
|
||||
@ -70,19 +70,19 @@ private:
|
||||
static void rx_timer_handler(void *);
|
||||
};
|
||||
|
||||
class bx_slirp_new_locator_c : public eth_locator_c {
|
||||
class bx_slirp_locator_c : public eth_locator_c {
|
||||
public:
|
||||
bx_slirp_new_locator_c(void) : eth_locator_c("slirp_new") {}
|
||||
bx_slirp_locator_c(void) : eth_locator_c("slirp") {}
|
||||
protected:
|
||||
eth_pktmover_c *allocate(const char *netif, const char *macaddr,
|
||||
eth_rx_handler_t rxh, eth_rx_status_t rxstat,
|
||||
bx_devmodel_c *dev, const char *script) {
|
||||
return (new bx_slirp_new_pktmover_c(netif, macaddr, rxh, rxstat, dev, script));
|
||||
return (new bx_slirp_pktmover_c(netif, macaddr, rxh, rxstat, dev, script));
|
||||
}
|
||||
} bx_slirp_new_match;
|
||||
} bx_slirp_match;
|
||||
|
||||
|
||||
bx_slirp_new_pktmover_c::bx_slirp_new_pktmover_c()
|
||||
bx_slirp_pktmover_c::bx_slirp_pktmover_c()
|
||||
{
|
||||
slirp = NULL;
|
||||
bootfile = NULL;
|
||||
@ -94,7 +94,7 @@ bx_slirp_new_pktmover_c::bx_slirp_new_pktmover_c()
|
||||
#endif
|
||||
}
|
||||
|
||||
bx_slirp_new_pktmover_c::~bx_slirp_new_pktmover_c()
|
||||
bx_slirp_pktmover_c::~bx_slirp_pktmover_c()
|
||||
{
|
||||
if (slirp != NULL) {
|
||||
slirp_cleanup(slirp);
|
||||
@ -138,7 +138,7 @@ static size_t strip_whitespace(char *s)
|
||||
return ptr;
|
||||
}
|
||||
|
||||
bx_bool bx_slirp_new_pktmover_c::parse_slirp_conf(const char *conf)
|
||||
bx_bool bx_slirp_pktmover_c::parse_slirp_conf(const char *conf)
|
||||
{
|
||||
FILE *fd = NULL;
|
||||
char line[512];
|
||||
@ -254,12 +254,12 @@ bx_bool bx_slirp_new_pktmover_c::parse_slirp_conf(const char *conf)
|
||||
return 1;
|
||||
}
|
||||
|
||||
bx_slirp_new_pktmover_c::bx_slirp_new_pktmover_c(const char *netif,
|
||||
const char *macaddr,
|
||||
eth_rx_handler_t rxh,
|
||||
eth_rx_status_t rxstat,
|
||||
bx_devmodel_c *dev,
|
||||
const char *script)
|
||||
bx_slirp_pktmover_c::bx_slirp_pktmover_c(const char *netif,
|
||||
const char *macaddr,
|
||||
eth_rx_handler_t rxh,
|
||||
eth_rx_status_t rxstat,
|
||||
bx_devmodel_c *dev,
|
||||
const char *script)
|
||||
{
|
||||
logfunctions *slirplog;
|
||||
char prefix[10];
|
||||
@ -268,7 +268,7 @@ bx_slirp_new_pktmover_c::bx_slirp_new_pktmover_c(const char *netif,
|
||||
if (sizeof(struct arphdr) != 28) {
|
||||
BX_PANIC(("system error: invalid ARP header structure size"));
|
||||
}
|
||||
BX_INFO(("slirp_new network driver"));
|
||||
BX_INFO(("slirp network driver"));
|
||||
|
||||
this->rxh = rxh;
|
||||
this->rxstat = rxstat;
|
||||
@ -278,7 +278,7 @@ bx_slirp_new_pktmover_c::bx_slirp_new_pktmover_c(const char *netif,
|
||||
if (bx_slirp_instances == 0) {
|
||||
rx_timer_index =
|
||||
bx_pc_system.register_timer(this, this->rx_timer_handler, 1000,
|
||||
1, 1, "eth_slirp_new");
|
||||
1, 1, "eth_slirp");
|
||||
#ifndef WIN32
|
||||
signal(SIGPIPE, SIG_IGN);
|
||||
#endif
|
||||
@ -315,12 +315,12 @@ bx_slirp_new_pktmover_c::bx_slirp_new_pktmover_c(const char *netif,
|
||||
bx_slirp_instances++;
|
||||
}
|
||||
|
||||
void bx_slirp_new_pktmover_c::sendpkt(void *buf, unsigned io_len)
|
||||
void bx_slirp_pktmover_c::sendpkt(void *buf, unsigned io_len)
|
||||
{
|
||||
slirp_input(slirp, (Bit8u*)buf, io_len);
|
||||
}
|
||||
|
||||
void bx_slirp_new_pktmover_c::rx_timer_handler(void *this_ptr)
|
||||
void bx_slirp_pktmover_c::rx_timer_handler(void *this_ptr)
|
||||
{
|
||||
Bit32u timeout = 0;
|
||||
int ret;
|
||||
@ -339,22 +339,22 @@ void bx_slirp_new_pktmover_c::rx_timer_handler(void *this_ptr)
|
||||
|
||||
int slirp_can_output(void *this_ptr)
|
||||
{
|
||||
bx_slirp_new_pktmover_c *class_ptr = (bx_slirp_new_pktmover_c *)this_ptr;
|
||||
bx_slirp_pktmover_c *class_ptr = (bx_slirp_pktmover_c *)this_ptr;
|
||||
return class_ptr->can_receive();
|
||||
}
|
||||
|
||||
int bx_slirp_new_pktmover_c::can_receive()
|
||||
int bx_slirp_pktmover_c::can_receive()
|
||||
{
|
||||
return ((this->rxstat(this->netdev) & BX_NETDEV_RXREADY) != 0);
|
||||
}
|
||||
|
||||
void slirp_output(void *this_ptr, const Bit8u *pkt, int pkt_len)
|
||||
{
|
||||
bx_slirp_new_pktmover_c *class_ptr = (bx_slirp_new_pktmover_c *)this_ptr;
|
||||
bx_slirp_pktmover_c *class_ptr = (bx_slirp_pktmover_c *)this_ptr;
|
||||
class_ptr->receive((void*)pkt, pkt_len);
|
||||
}
|
||||
|
||||
void bx_slirp_new_pktmover_c::receive(void *pkt, unsigned pkt_len)
|
||||
void bx_slirp_pktmover_c::receive(void *pkt, unsigned pkt_len)
|
||||
{
|
||||
if (this->rxstat(this->netdev) & BX_NETDEV_RXREADY) {
|
||||
if (pkt_len < 60) pkt_len = 60;
|
||||
@ -364,4 +364,4 @@ void bx_slirp_new_pktmover_c::receive(void *pkt, unsigned pkt_len)
|
||||
}
|
||||
}
|
||||
|
||||
#endif /* if BX_NETWORKING && BX_NETMOD_SLIRP_NEW */
|
||||
#endif /* if BX_NETWORKING && BX_NETMOD_SLIRP */
|
@ -124,8 +124,8 @@ extern class bx_tuntap_locator_c bx_tuntap_match;
|
||||
#if BX_NETMOD_VDE
|
||||
extern class bx_vde_locator_c bx_vde_match;
|
||||
#endif
|
||||
#if BX_NETMOD_SLIRP_NEW
|
||||
extern class bx_slirp_new_locator_c bx_slirp_new_match;
|
||||
#if BX_NETMOD_SLIRP
|
||||
extern class bx_slirp_locator_c bx_slirp_match;
|
||||
#endif
|
||||
extern class bx_vnet_locator_c bx_vnet_match;
|
||||
|
||||
@ -174,10 +174,10 @@ eth_locator_c::create(const char *type, const char *netif,
|
||||
ptr = (eth_locator_c *) &bx_vde_match;
|
||||
}
|
||||
#endif
|
||||
#if BX_NETMOD_SLIRP_NEW
|
||||
#if BX_NETMOD_SLIRP
|
||||
{
|
||||
if (!strcmp(type, "slirp_new"))
|
||||
ptr = (eth_locator_c *) &bx_slirp_new_match;
|
||||
if (!strcmp(type, "slirp"))
|
||||
ptr = (eth_locator_c *) &bx_slirp_match;
|
||||
}
|
||||
#endif
|
||||
#if BX_NETMOD_TAP
|
||||
|
@ -27,7 +27,7 @@
|
||||
|
||||
#include "slirp.h"
|
||||
|
||||
#if BX_NETWORKING && BX_NETMOD_SLIRP_NEW
|
||||
#if BX_NETWORKING && BX_NETMOD_SLIRP
|
||||
|
||||
void arp_table_add(Slirp *slirp, uint32_t ip_addr, uint8_t ethaddr[ETH_ALEN])
|
||||
{
|
||||
|
@ -28,7 +28,7 @@
|
||||
|
||||
#include "slirp.h"
|
||||
|
||||
#if BX_NETWORKING && BX_NETMOD_SLIRP_NEW
|
||||
#if BX_NETWORKING && BX_NETMOD_SLIRP
|
||||
|
||||
/* XXX: only DHCP is supported */
|
||||
|
||||
|
@ -35,7 +35,7 @@
|
||||
|
||||
#include "slirp.h"
|
||||
|
||||
#if BX_NETWORKING && BX_NETMOD_SLIRP_NEW
|
||||
#if BX_NETWORKING && BX_NETMOD_SLIRP
|
||||
|
||||
/*
|
||||
* Checksum routine for Internet Protocol family headers (Portable Version).
|
||||
|
@ -27,7 +27,7 @@
|
||||
|
||||
#include "slirp.h"
|
||||
|
||||
#if BX_NETWORKING && BX_NETMOD_SLIRP_NEW
|
||||
#if BX_NETWORKING && BX_NETMOD_SLIRP
|
||||
|
||||
void pstrcpy(char *buf, int buf_size, const char *str)
|
||||
{
|
||||
|
@ -30,7 +30,7 @@
|
||||
#include <stdio.h>
|
||||
#include "slirp.h"
|
||||
|
||||
#if BX_NETWORKING && BX_NETMOD_SLIRP_NEW
|
||||
#if BX_NETWORKING && BX_NETMOD_SLIRP
|
||||
|
||||
static const uint8_t RFC3397_OPT_DOMAIN_SEARCH = 119;
|
||||
static const uint8_t MAX_OPT_LEN = 255;
|
||||
|
@ -13,7 +13,7 @@
|
||||
#include "iodev.h"
|
||||
#include "slirp.h"
|
||||
|
||||
#if BX_NETWORKING && BX_NETMOD_SLIRP_NEW
|
||||
#if BX_NETWORKING && BX_NETMOD_SLIRP
|
||||
|
||||
static void
|
||||
ifs_insque(struct mbuf *ifm, struct mbuf *ifmhead)
|
||||
|
@ -36,7 +36,7 @@
|
||||
#include "slirp.h"
|
||||
#include "ip_icmp.h"
|
||||
|
||||
#if BX_NETWORKING && BX_NETMOD_SLIRP_NEW
|
||||
#if BX_NETWORKING && BX_NETMOD_SLIRP
|
||||
|
||||
/* The message sent when emulating PING */
|
||||
/* Be nice and tell them it's just a pseudo-ping packet */
|
||||
|
@ -44,7 +44,7 @@
|
||||
#include "slirp.h"
|
||||
#include "ip_icmp.h"
|
||||
|
||||
#if BX_NETWORKING && BX_NETMOD_SLIRP_NEW
|
||||
#if BX_NETWORKING && BX_NETMOD_SLIRP
|
||||
|
||||
static struct ip *ip_reass(Slirp *slirp, struct ip *ip, struct ipq *fp);
|
||||
static void ip_freef(Slirp *slirp, struct ipq *fp);
|
||||
|
@ -43,7 +43,7 @@
|
||||
|
||||
#include "slirp.h"
|
||||
|
||||
#if BX_NETWORKING && BX_NETMOD_SLIRP_NEW
|
||||
#if BX_NETWORKING && BX_NETMOD_SLIRP
|
||||
|
||||
/* Number of packets queued before we start sending
|
||||
* (to prevent allocing too many mbufs) */
|
||||
|
@ -20,7 +20,7 @@
|
||||
|
||||
#include "slirp.h"
|
||||
|
||||
#if BX_NETWORKING && BX_NETMOD_SLIRP_NEW
|
||||
#if BX_NETWORKING && BX_NETMOD_SLIRP
|
||||
|
||||
#define MBUF_THRESH 30
|
||||
|
||||
|
@ -11,7 +11,7 @@
|
||||
#include "slirp.h"
|
||||
#include "libslirp.h"
|
||||
|
||||
#if BX_NETWORKING && BX_NETMOD_SLIRP_NEW
|
||||
#if BX_NETWORKING && BX_NETMOD_SLIRP
|
||||
|
||||
#ifdef DEBUG
|
||||
int slirp_debug = DBG_CALL|DBG_MISC|DBG_ERROR;
|
||||
|
@ -10,7 +10,7 @@
|
||||
|
||||
#include "slirp.h"
|
||||
|
||||
#if BX_NETWORKING && BX_NETMOD_SLIRP_NEW
|
||||
#if BX_NETWORKING && BX_NETMOD_SLIRP
|
||||
|
||||
static void sbappendsb(struct sbuf *sb, struct mbuf *m);
|
||||
|
||||
|
@ -29,7 +29,7 @@
|
||||
#include "iodev.h"
|
||||
#include "slirp.h"
|
||||
|
||||
#if BX_NETWORKING && BX_NETMOD_SLIRP_NEW
|
||||
#if BX_NETWORKING && BX_NETMOD_SLIRP
|
||||
|
||||
#define LOG_THIS ((logfunctions*)slirp->logfn)->
|
||||
|
||||
|
@ -11,7 +11,7 @@
|
||||
#include "slirp.h"
|
||||
#include "ip_icmp.h"
|
||||
|
||||
#if BX_NETWORKING && BX_NETMOD_SLIRP_NEW
|
||||
#if BX_NETWORKING && BX_NETMOD_SLIRP
|
||||
|
||||
#ifdef __sun__
|
||||
#include <sys/filio.h>
|
||||
|
@ -44,7 +44,7 @@
|
||||
#include "slirp.h"
|
||||
#include "ip_icmp.h"
|
||||
|
||||
#if BX_NETWORKING && BX_NETMOD_SLIRP_NEW
|
||||
#if BX_NETWORKING && BX_NETMOD_SLIRP
|
||||
|
||||
#define TCPREXMTTHRESH 3
|
||||
|
||||
|
@ -43,7 +43,7 @@
|
||||
|
||||
#include "slirp.h"
|
||||
|
||||
#if BX_NETWORKING && BX_NETMOD_SLIRP_NEW
|
||||
#if BX_NETWORKING && BX_NETMOD_SLIRP
|
||||
|
||||
static const u_char tcp_outflags[TCP_NSTATES] = {
|
||||
TH_RST|TH_ACK, 0, TH_SYN, TH_SYN|TH_ACK,
|
||||
|
@ -43,7 +43,7 @@
|
||||
|
||||
#include "slirp.h"
|
||||
|
||||
#if BX_NETWORKING && BX_NETMOD_SLIRP_NEW
|
||||
#if BX_NETWORKING && BX_NETMOD_SLIRP
|
||||
|
||||
/* patchable/settable parameters for tcp */
|
||||
/* Don't do rfc1323 performance enhancements */
|
||||
|
@ -35,7 +35,7 @@
|
||||
|
||||
#include "slirp.h"
|
||||
|
||||
#if BX_NETWORKING && BX_NETMOD_SLIRP_NEW
|
||||
#if BX_NETWORKING && BX_NETMOD_SLIRP
|
||||
|
||||
static struct tcpcb *tcp_timers(register struct tcpcb *tp, int timer);
|
||||
|
||||
|
@ -28,7 +28,7 @@
|
||||
|
||||
#include "slirp.h"
|
||||
|
||||
#if BX_NETWORKING && BX_NETMOD_SLIRP_NEW
|
||||
#if BX_NETWORKING && BX_NETMOD_SLIRP
|
||||
|
||||
// Missing defines for open (copied from osdep.h)
|
||||
#ifndef S_IRUSR
|
||||
|
@ -44,7 +44,7 @@
|
||||
#include "slirp.h"
|
||||
#include "ip_icmp.h"
|
||||
|
||||
#if BX_NETWORKING && BX_NETMOD_SLIRP_NEW
|
||||
#if BX_NETWORKING && BX_NETMOD_SLIRP
|
||||
|
||||
static uint8_t udp_tos(struct socket *so);
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user