rosbootplib.h

来自「vxworks MPC8541 BSP」· C头文件 代码 · 共 91 行

H
91
字号
/*****************************************************************
* Copyright (c) 2002,ZTE 网络事业部 数据软件开发二部             *
* All rights reserved.                                           *
*ModuleName: Ros                 FileName:RosBootpServLib.h      *
*CreateDAte: 2002-3-20 9:01        Author:Deng Pan               *
*Version:    1.0                                                 *
*History:                                                        *
* Date       Version       Modifier           Activies           *
*================================================================*
*2002-3-20    1.0          Pan Deng            create            *
******************************************************************/
#ifndef _ROS_BOOTP_LIB_H
#define _ROS_BOOTP_LIB_H


/* includes */

#include "vxWorks.h"
#include "bootpLib.h"
#include "netinet/in.h"
#include "netinet/udp.h"
#include "netinet/in_var.h"
#include "netinet/if_ether.h"

#include "etherLib.h"
#include "taskLib.h"
#include "string.h"
#include "stdio.h"
#include "errno.h"
#include "sysLib.h"
#include "tickLib.h"
#include "icmpLib.h"
#include "inetLib.h"

#include "end.h"
#include "muxLib.h"
#include "ipProto.h"


typedef struct tagBOARDINFO
{
    char          boardType;   /*区分MPU RPU SFC NPC NPCI NPCF NAT*/
    char          physSlotNo;  /*面板所在物理槽位号*/
} BOARDINFO;

/*
malloc(sizeof(BOARDALLINFO) + filenum * length)
(BOARDALLINFO*)bInfo->routertype;
bInfo++;
*/  

typedef struct tagBOOTPIPPACKET
{
    struct ip       ih;		/* IP header		*/
    struct udphdr   uh;		/* UDP header		*/
    BOOTP_MSG       bp;     /* Bootp message	*/
    BOARDINFO       bdInfo; /*基本板信息作为获取bootp的key*/
} BootpIpPacket;

typedef struct tagBOOTPUDPPACKET
{
    BOOTP_MSG       bp;     /* Bootp message	*/
    BOARDINFO       bdInfo; /*基本板信息作为获取bootp的key*/
} BootpUdpPacket;

typedef struct tagSlotMapTab
{
	char      phySlot;
	char      switchNo;
	char      cpuUnit;
	char      panelNo;
}SLOTMAPTAB;

typedef struct tagBOOTPINFOPACKET
{
    
    BOOTP_MSG     response;
    char        frametype;
    char        module;
    struct in_addr     sip;
    SLOTMAPTAB    mpu[2];
    SLOTMAPTAB    npu[16];
    SLOTMAPTAB    npz[16];
    SLOTMAPTAB    npc[16];
} BootpInfo;


extern STATUS r10BootpParamsGet(char *ifName,int port,u_int	timeOut,struct bootpParams *pBootpParams);

#endif

⌨️ 快捷键说明

复制代码Ctrl + C
搜索代码Ctrl + F
全屏模式F11
增大字号Ctrl + =
减小字号Ctrl + -
显示快捷键?