Add DEFAULT_NETWORK_PAGE_MBUFS_SIZE to allow per BSP allocation domain sizes.

This commit is contained in:
Chris Johns 2016-06-27 13:15:11 +10:00
parent 9edacb625c
commit c6713d1b51
3 changed files with 15 additions and 0 deletions

View File

@ -53,6 +53,11 @@ rtems_task Init(
early_initialization();
#endif
#ifdef DEFAULT_NETWORK_PAGE_MBUFS_SIZE
rtems_bsd_allocator_domain_page_mbuf_size =
DEFAULT_NETWORK_PAGE_MBUFS_SIZE;
#endif
/* Let other tasks run to complete background work */
default_set_self_prio( RTEMS_MAXIMUM_PRIORITY - 1 );

View File

@ -263,6 +263,11 @@ Init(rtems_task_argument arg)
assert(sc == RTEMS_SUCCESSFUL);
#endif
#ifdef DEFAULT_NETWORK_PAGE_MBUFS_SIZE
rtems_bsd_allocator_domain_page_mbuf_size =
DEFAULT_NETWORK_PAGE_MBUFS_SIZE;
#endif
rtems_bsd_initialize();
#ifndef DEFAULT_NETWORK_NO_INTERFACE_0
@ -367,6 +372,7 @@ SYSINIT_NEED_NET_IF_VLAN;
#define CONFIGURE_SHELL_COMMAND_MV
#define CONFIGURE_SHELL_COMMAND_RM
#define CONFIGURE_SHELL_COMMAND_MALLOC_INFO
#define CONFIGURE_SHELL_COMMAND_SHUTDOWN
#include <rtems/shellconfig.h>

View File

@ -46,6 +46,10 @@
#define NET_CFG_INTERFACE_0 "lo0"
#endif
#if defined(LIBBSP_I386_PC386_BSP_H)
#define DEFAULT_NETWORK_PAGE_MBUFS_SIZE (64 * 1024 * 1024)
#endif
#define NET_CFG_SELF_IP "@NET_CFG_SELF_IP@"
#define NET_CFG_NETMASK "@NET_CFG_NETMASK@"