user6510364:
if(SRIO_NO_LOOPBACK==loopback_mode)
/*DSP0 is the master for test, DSP0 DirectIO or send message to DSP1.DSP1 is the slave for test, it monitor the doorbell and message interrupt to detect the received data*/if(0==uiDspNum){SRIO_2DSP_Test();}else{srio_cfg.device_ID_routing_config= dsp1_device_ID_routing_config;srio_cfg.uiNumDeviceId= sizeof(dsp1_device_ID_routing_config)/sizeof(SRIO_Device_ID_Routing_Config);
msg_cfg.message_map = DSP1_message_map;msg_cfg.uiNumMessageMap= sizeof(DSP1_message_map)/sizeof(SRIO_RX_Message_Map);srio_cfg.msg_cfg= &msg_cfg;serdesLinkSetup.linkSpeed_GHz= SRIO_DEFAULT_TEST_SPEED;srio_cfg.srio_1x2x4x_path_control= SRIO_PATH_CTL_1xLaneA_1xLaneB_1xLaneC_1xLaneD;srio_identify_used_ports_lanes(srio_cfg.srio_1x2x4x_path_control);
/*On dual Nyquist EVM only lane 2 and 3 are connected between 2 DSPs*/srio_cfg.blockEn.bLogic_Port_EN[0]= FALSE;srio_cfg.blockEn.bLogic_Port_EN[1]= FALSE;KeyStone_SRIO_Init(&srio_cfg);SRIO_PktDM_init();
/*accumulation is only used for the 2nd DSP for two DSPs test*/QMSS_Accumulation_config();
puts("DSP1 ready as slave for test");while(1);}}
,
user6510364:
if(SRIO_NO_LOOPBACK==loopback_mode)
/*DSP0 is the master for test, DSP0 DirectIO or send message to DSP1.DSP1 is the slave for test, it monitor the doorbell and message interrupt to detect the received data*/if(0==uiDspNum){SRIO_2DSP_Test();}else{srio_cfg.device_ID_routing_config= dsp1_device_ID_routing_config;srio_cfg.uiNumDeviceId= sizeof(dsp1_device_ID_routing_config)/sizeof(SRIO_Device_ID_Routing_Config);
msg_cfg.message_map = DSP1_message_map;msg_cfg.uiNumMessageMap= sizeof(DSP1_message_map)/sizeof(SRIO_RX_Message_Map);srio_cfg.msg_cfg= &msg_cfg;serdesLinkSetup.linkSpeed_GHz= SRIO_DEFAULT_TEST_SPEED;srio_cfg.srio_1x2x4x_path_control= SRIO_PATH_CTL_1xLaneA_1xLaneB_1xLaneC_1xLaneD;srio_identify_used_ports_lanes(srio_cfg.srio_1x2x4x_path_control);
/*On dual Nyquist EVM only lane 2 and 3 are connected between 2 DSPs*/srio_cfg.blockEn.bLogic_Port_EN[0]= FALSE;srio_cfg.blockEn.bLogic_Port_EN[1]= FALSE;KeyStone_SRIO_Init(&srio_cfg);SRIO_PktDM_init();
/*accumulation is only used for the 2nd DSP for two DSPs test*/QMSS_Accumulation_config();
puts("DSP1 ready as slave for test");while(1);}}
,
user6510364:
else if(SRIO_NO_LOOPBACK==loopback_mode)//test between 2 DSPs{/*DSP0 is the master for test, DSP0 DirectIO or send message to DSP1.DSP1 is the slave for test, it monitor the doorbell and message interrupt to detect the received data*/if(0==uiDspNum){SRIO_2DSP_Test();}else{srio_cfg.device_ID_routing_config= dsp1_device_ID_routing_config;srio_cfg.uiNumDeviceId= sizeof(dsp1_device_ID_routing_config)/sizeof(SRIO_Device_ID_Routing_Config);
msg_cfg.message_map = DSP1_message_map;msg_cfg.uiNumMessageMap= sizeof(DSP1_message_map)/sizeof(SRIO_RX_Message_Map);srio_cfg.msg_cfg= &msg_cfg;serdesLinkSetup.linkSpeed_GHz= SRIO_DEFAULT_TEST_SPEED;srio_cfg.srio_1x2x4x_path_control= SRIO_PATH_CTL_1xLaneA_1xLaneB_1xLaneC_1xLaneD;srio_identify_used_ports_lanes(srio_cfg.srio_1x2x4x_path_control);
/*On dual Nyquist EVM only lane 2 and 3 are connected between 2 DSPs*/srio_cfg.blockEn.bLogic_Port_EN[0]= FALSE;srio_cfg.blockEn.bLogic_Port_EN[1]= FALSE;KeyStone_SRIO_Init(&srio_cfg);SRIO_PktDM_init();
/*accumulation is only used for the 2nd DSP for two DSPs test*/QMSS_Accumulation_config();
puts("DSP1 ready as slave for test");while(1);}
,
user6510364:
是只要修改上面的程序吗
,
Shine:
可以结合KeyStone_1_SRIO_STK_User's_Guide.doc文档,里面有Data passing between 2 DSPs例程。