221 lines
5.6 KiB
C
221 lines
5.6 KiB
C
/*
|
|
*******************************************************************************
|
|
* INTERPEAK SOURCE FILE
|
|
*
|
|
* Document no: @(#) $Name: VXWORKS_ITER40_2019102207 $ $RCSfile: ipmippm.c,v $ $Revision: 1.10 $
|
|
* $Source: /home/interpeak/CVSRoot/ipmippm/src/ipmippm.c,v $
|
|
* $Author: jhorteli $
|
|
* $State: Exp $ $Locker: $
|
|
*
|
|
* INTERPEAK_COPYRIGHT_STRING
|
|
* Design and implementation by Niklas Lundberg <n@interpeak.se>
|
|
******************************************************************************
|
|
*/
|
|
|
|
|
|
/*
|
|
*******************************************************************************
|
|
* 1 DESCRIPTION
|
|
*******************************************************************************
|
|
*
|
|
*/
|
|
|
|
/*
|
|
****************************************************************************
|
|
* 2 CONFIGURATION
|
|
****************************************************************************
|
|
*/
|
|
|
|
|
|
#include "ipmippm_config.h"
|
|
|
|
|
|
/*
|
|
****************************************************************************
|
|
* 3 INCLUDE FILES
|
|
****************************************************************************
|
|
*/
|
|
|
|
#define IPCOM_USE_CLIB_PROTO
|
|
#include <ipcom_clib.h>
|
|
#include <ipcom_drv_eth_filter.h>
|
|
#include <ipcom_err.h>
|
|
#include <ipcom_hash.h>
|
|
#include <ipcom_inet.h>
|
|
#include <ipcom_ipd.h>
|
|
#include <ipcom_list.h>
|
|
#include <ipcom_os.h>
|
|
#include <ipcom_sock.h>
|
|
#include <ipcom_sock2.h>
|
|
#include <ipcom_sysctl.h>
|
|
#include <ipcom_syslog.h>
|
|
#include <ipcom_netif.h>
|
|
#include <ipcom_sysvar.h>
|
|
|
|
#include <ipmip.h>
|
|
#include <private/ipmip_sysvar.h>
|
|
|
|
#include <ipmip4.h>
|
|
#include <private/ipmip4_pkt.h>
|
|
#include <private/ipmip4_sysext.h>
|
|
#include <private/ipmip4_util.h>
|
|
#include <private/ipmip4_radius.h>
|
|
|
|
#include <private/ipmipmn_api.h>
|
|
|
|
#include "ipmippm.h"
|
|
#include "ipmippm_h.h"
|
|
#include "ipmippm_reg.h"
|
|
#include "ipmippm_client.h"
|
|
#include "ipmippm_attr_h.h"
|
|
|
|
/*
|
|
****************************************************************************
|
|
* 4 DEFINES
|
|
****************************************************************************
|
|
*/
|
|
|
|
/*
|
|
****************************************************************************
|
|
* 5 TYPES
|
|
****************************************************************************
|
|
*/
|
|
|
|
|
|
/*
|
|
*===========================================================================
|
|
* Application datatypes
|
|
*===========================================================================
|
|
*/
|
|
|
|
/*
|
|
****************************************************************************
|
|
* 6 EXTERN PROTOTYPES
|
|
****************************************************************************
|
|
*/
|
|
|
|
IP_PUBLIC Ip_err ipmippm_configure(void);
|
|
IP_PUBLIC Ip_err ipmippm_init(void);
|
|
IP_PUBLIC Ip_err ipmippm_exit(void);
|
|
|
|
/*
|
|
****************************************************************************
|
|
* 7 LOCAL PROTOTYPES
|
|
****************************************************************************
|
|
*/
|
|
|
|
IP_PUBLIC Ip_err ipmippm_start(void);
|
|
IP_PUBLIC const char *ipmippm_version(void);
|
|
|
|
|
|
/*
|
|
****************************************************************************
|
|
* 8 DATA
|
|
****************************************************************************
|
|
*/
|
|
|
|
/*
|
|
****************************************************************************
|
|
* 9 STATIC FUNCTIONS
|
|
****************************************************************************
|
|
*/
|
|
IP_PUBLIC IPCOM_PROCESS(ipmippm_proc);
|
|
|
|
/*
|
|
*===========================================================================
|
|
* ipmippmd
|
|
*===========================================================================
|
|
* Description: The main process.
|
|
* Parameters:
|
|
* Returns:
|
|
*
|
|
*/
|
|
IP_PUBLIC
|
|
IPCOM_PROCESS(ipmippm_proc)
|
|
{
|
|
ipmippm_main();
|
|
}
|
|
|
|
|
|
/*
|
|
****************************************************************************
|
|
* 10 GLOBAL FUNCTIONS
|
|
****************************************************************************
|
|
*/
|
|
|
|
|
|
/*
|
|
****************************************************************************
|
|
* 11 PUBLIC FUNCTIONS
|
|
****************************************************************************
|
|
*/
|
|
|
|
|
|
/*
|
|
*===========================================================================
|
|
* ipmippm_start
|
|
*===========================================================================
|
|
* Description:
|
|
* Parameters:
|
|
* Returns:
|
|
*
|
|
*/
|
|
IP_PUBLIC Ip_err
|
|
ipmippm_start(void)
|
|
{
|
|
Ipcom_proc_attr attr;
|
|
Ip_err ret;
|
|
|
|
ipcom_proc_attr_init(&attr);
|
|
attr.stacksize = IPCOM_PROC_STACK_LARGE;
|
|
|
|
ret = ipcom_proc_acreate("ipmippmd", ipmippm_proc, &attr, IP_NULL);
|
|
ip_assert(ret == IPCOM_SUCCESS);
|
|
|
|
return ret;
|
|
}
|
|
|
|
|
|
/*
|
|
*===========================================================================
|
|
* ipmippm_version
|
|
*===========================================================================
|
|
* Description:
|
|
* Parameters:
|
|
* Returns:
|
|
*
|
|
*/
|
|
IP_PUBLIC const char *
|
|
ipmippm_version(void)
|
|
{
|
|
return "@(#) IPMIPPM $Name: VXWORKS_ITER40_2019102207 $ - INTERPEAK_COPYRIGHT_STRING";
|
|
}
|
|
|
|
|
|
#if defined (IP_PORT_LAS)
|
|
|
|
/* Prototypes */
|
|
IP_PUBLIC Ip_err ipcom_daemon_configure(void);
|
|
IP_PUBLIC Ip_err ipcom_daemon_create(void);
|
|
|
|
IP_PUBLIC Ip_err
|
|
ipcom_daemon_configure(void)
|
|
{
|
|
return IPCOM_SUCCESS;
|
|
}
|
|
|
|
IP_PUBLIC Ip_err
|
|
ipcom_daemon_create(void)
|
|
{
|
|
return IPCOM_SUCCESS;
|
|
}
|
|
|
|
#endif
|
|
|
|
|
|
/*
|
|
****************************************************************************
|
|
* END OF FILE
|
|
****************************************************************************
|
|
*/
|