6678 SRIO: 关于QMSS,CPPI和SRIO Socket
[复制链接]
socket是SRIO LLD里的概念,跟网络的套接字类似。
The SRIO driver was designed such that the library could handle all communication protocols. The design was based on the well known BSD socket API which achieves the same by supporting the networking socket API over different protocol families i.e. IPv4, IPv6, IPX etc. From an application perspective; a SRIO socket is basically an endpoint which can be used to send and receive data. The SRIO socket abstracts the inner details of the SRIO peripheral from
the end user.
下面是例程中device_srio_loopback.c的代码
/* Enable TLM Base Routing Information for Maintainance Requests & ensure that
* the BRR's can be used by all the ports. */
CSL_SRIO_SetTLMPortBaseRoutingInfo(hSrio, 0, 1, 1, 1, 0);
CSL_SRIO_SetTLMPortBaseRoutingInfo(hSrio, 0, 2, 1, 1, 0);
CSL_SRIO_SetTLMPortBaseRoutingInfo(hSrio, 0, 3, 1, 1, 0);
CSL_SRIO_SetTLMPortBaseRoutingInfo(hSrio, 1, 0, 1, 1, 0);
/* Configure the Base Routing Register to ensure that all packets matching the
* Device Identifier & the Secondary Device Id are admitted. */
CSL_SRIO_SetTLMPortBaseRoutingPatternMatch(hSrio, 0, 1, DEVICE_ID2_16BIT, 0xFFFF);
CSL_SRIO_SetTLMPortBaseRoutingPatternMatch(hSrio, 0, 2, DEVICE_ID3_16BIT, 0xFFFF);
CSL_SRIO_SetTLMPortBaseRoutingPatternMatch(hSrio, 0, 3, DEVICE_ID4_16BIT, 0xFFFF);
CSL_SRIO_SetTLMPortBaseRoutingPatternMatch(hSrio, 1, 0, DEVICE_ID2_8BIT, 0xFF);
以上代码和port的配置是什么关系呢?
2. 手册的KeyStone Architecture Serial Rapid IO (SRIO)对于RapidIO Feature Support in SRIO中的描述中有Defined as Big Endian这一条,是否在DSP在接收的时候,比如自环,或者从fpga等设备接收还需要进行大小端的转换?
解答:
1. 主要是用来配置片内的inbound 的route路由的。可以参考一下附件SRIO编程手册。3323.SRIO_Programming_Performance.pdf
2. SRIO数据是big endian的。如果DSP工作在little endian模式的话,SRIO接口会把数据自动转换成big endian。FPGA那边如果是小端模式的话,需要转换成大端。
|