// +FHDR------------------------------------------------------------
//                 Copyright (c) 2022 SmartLogic.
//                       ALL RIGHTS RESERVED
// -----------------------------------------------------------------
// Filename      : ecs_rfm_dm_mgt.h
// Author        : xianfeng.du
// Created On    : 2022-06-25
// Last Modified :
// -----------------------------------------------------------------
// Description:
//
//
// -FHDR------------------------------------------------------------

#ifndef __ECS_RFM_DM_MGT_H__
#define __ECS_RFM_DM_MGT_H__

#include "typedef.h"
#include "hw_cpri.h"
#include "cpri_delay.h"
#include "mtimer_com.h"
#include "phy_para.h"
#include "gpio_drv.h"
#include "jesd_drv_para.h"

typedef struct tEcsRfmDmLocalMgt {
	stCpriPara*				pCpriPara;
	stCpriDelayMeasure*		pCpriDelay;
	stGpioOnBoard* 			      pGpioInfo;
	stFhAlarmStat*			      pAlarmStatus;
	stMtimerPara*			      pMtimerPara[MTIMER_INTEGRATED_MAX_NUM];
    stOamMsgTransferHeader*       pOamMsgPtr;
    stCpriSetLinkDelay*           pOamBaseDelaySetRspPtr   ;
    stCpriGetLinkDelay*           pOamBaseDelayQryRspPtr   ;
    stCpriGetRndDelay*            pOamFiberDelayQryRspPtr  ;
    stCpriFrameHeadOffsetRsp*     pOamFrameHeadOffsetRspPtr  ;
    stCpriGetFrameHeadOffset*     pOamFrameHeadOffsetQryRspPtr;
	stCpriCsuCmdFifoInfo*	   tx_cmd_fifo_ptr;
	stCpriCsuCmdFifoInfo*	   rx_cmd_fifo_ptr;
	JesdOrxPara_t*			   jesd_orx_para_ptr;
	JesdDelay_t*               jesd_delay_ptr;
} EcsRfmDmLocalMgt_t;

EcsRfmDmLocalMgt_t* get_ecs_rfm_dm_local_mgt(void);

int32_t ecs_rfm_dm_alloc(void);

int32_t ecs_rfm1_dm_init(void);

#endif

