1 #ifndef __NETWORKCONFIG_H__
2 #define __NETWORKCONFIG_H__
4 #include <rtems/rtems_bsdnet.h>
7 static char ethernet_address[6] = {0x00, 0x04, 0x9F, 0x00, 0x27, 0x50 };
9 #ifdef RTEMS_USE_LOOPBACK
12 rtems_bsdnet_loopattach(struct rtems_bsdnet_ifconfig *, int);
14 #ifdef RTEMS_USE_LOOPBACK_ONLY
15 static struct rtems_bsdnet_ifconfig netdriver_config = {
17 static struct rtems_bsdnet_ifconfig loopback_config = {
20 .attach = rtems_bsdnet_loopattach,
22 .ip_address = "127.0.0.1",
23 .ip_netmask = "255.0.0.0",
26 #endif /*RTEMS_USE_LOOPBACK*/
28 #ifndef RTEMS_USE_LOOPBACK_ONLY
29 static struct rtems_bsdnet_ifconfig netdriver_config = {
30 .name = RTEMS_BSP_NETWORK_DRIVER_NAME,
31 .attach = RTEMS_BSP_NETWORK_DRIVER_ATTACH,
32 #ifdef RTEMS_USE_LOOPBACK
33 .next = &loopback_config,
34 #else /*RTEMS_USE_LOOPBACK*/
36 #endif /*RTEMS_USE_LOOPBACK*/
37 .ip_address = "192.168.2.3",
38 .ip_netmask = "255.255.255.0",
39 .hardware_address = ethernet_address,
40 .ignore_broadcast = 0,
49 #endif /*RTEMS_USE_LOOPBACK_ONLY*/
51 struct rtems_bsdnet_config rtems_bsdnet_config = {
52 .ifconfig = &netdriver_config,
54 .network_task_priority = 0, /* 100 */
55 .mbuf_bytecount = 256 * 1024, /* 64 kbytes */
56 .mbuf_cluster_bytecount = 256 * 1024, /* 128 kbytes */
61 .name_server = { "NULL" },
62 .ntp_server = { "NULL" },
64 .udp_tx_buf_size = 0, /* UDP TX: 9216 bytes */
65 .udp_rx_buf_size = 0, /* UDP RX: 40 * (1024 + sizeof(struct sockaddr_in)) */
66 .tcp_tx_buf_size = 0, /* TCP TX: 16 * 1024 bytes */
67 .tcp_rx_buf_size = 0, /* TCP TX: 16 * 1024 bytes */
70 #endif /* ifndef __NETWORKCONFIG_H__ */