This thread has been locked.
If you have a related question, please click the "Ask a related question" button in the top right corner. The newly created question will be automatically linked to this question.
Hi,
pdk_C6678_1_1_2_6\packages\ti\drv\srio\device\device_srio_loopback.c
/* TODO: Configure the processing element features * The SRIO RL file is missing the Re-transmit Suppression Support (Bit6) field definition */ peFeatures.isBridge = 0; peFeatures.isEndpoint = 0; peFeatures.isProcessor = 1; peFeatures.isSwitch = 0; peFeatures.isMultiport = 0; peFeatures.isFlowArbiterationSupported = 0; peFeatures.isMulticastSupported = 0; peFeatures.isExtendedRouteConfigSupported = 0; peFeatures.isStandardRouteConfigSupported = 1; peFeatures.isFlowControlSupported = 1; peFeatures.isCRFSupported = 0; peFeatures.isCTLSSupported = 1; peFeatures.isExtendedFeaturePtrValid = 1; peFeatures.numAddressBitSupported = 1; CSL_SRIO_SetProcessingElementFeatures (hSrio, &peFeatures); CSL_IDEF_INLINE void CSL_SRIO_SetProcessingElementFeatures ( CSL_SrioHandle hSrio, SRIO_PE_FEATURES* ptrPEFeatures ) { Uint32 value = 0; /* Initialize the various fields in the register */ CSL_FINS (value, SRIO_RIO_PE_FEAT_BRDG, ptrPEFeatures->isBridge); CSL_FINS (value, SRIO_RIO_PE_FEAT_MEM, ptrPEFeatures->isEndpoint); CSL_FINS (value, SRIO_RIO_PE_FEAT_PROC, ptrPEFeatures->isProcessor); CSL_FINS (value, SRIO_RIO_PE_FEAT_SW, ptrPEFeatures->isSwitch); CSL_FINS (value, SRIO_RIO_PE_FEAT_MULT_P, ptrPEFeatures->isMultiport); CSL_FINS (value, SRIO_RIO_PE_FEAT_FLOW_ARB, ptrPEFeatures->isFlowArbiterationSupported); CSL_FINS (value, SRIO_RIO_PE_FEAT_MC, ptrPEFeatures->isMulticastSupported); CSL_FINS (value, SRIO_RIO_PE_FEAT_ERTC, ptrPEFeatures->isExtendedRouteConfigSupported); CSL_FINS (value, SRIO_RIO_PE_FEAT_SRTC, ptrPEFeatures->isStandardRouteConfigSupported); CSL_FINS (value, SRIO_RIO_PE_FEAT_FLOW_CTRL,ptrPEFeatures->isFlowControlSupported); CSL_FINS (value, SRIO_RIO_PE_FEAT_CRF, ptrPEFeatures->isCRFSupported); CSL_FINS (value, SRIO_RIO_PE_FEAT_CTLS, ptrPEFeatures->isCTLSSupported); CSL_FINS (value, SRIO_RIO_PE_FEAT_EXT_FEA, ptrPEFeatures->isExtendedFeaturePtrValid); CSL_FINS (value, SRIO_RIO_PE_FEAT_EXT_AS, ptrPEFeatures->numAddressBitSupported); hSrio->RIO_PE_FEAT = value;
The PE_FEAT register in the manual is a read-only attribute. Why can it be written? There are only 11 options in the register in the manual, but why there are 14 options in the code, please help explain.
Nancy,
Those registers are read only. Those values in the code are reset-values.
For example:
#define CSL_SRIO_RIO_PE_FEAT_BRDG_RESETVAL (0x00000000u)
CSL_FINS (value, SRIO_RIO_PE_FEAT_BRDG, ptrPEFeatures->isBridge);
Please read section , page no: 53 :- https://www.ti.com/lit/ug/sprugw1c/sprugw1c.pdf
2.3.2.7 Reset and Powerdown
Upon reset, the load/store module puts all the register fields in their default values and waits for a write by the CPU.
Regards
Shankari G
Hi,
There are only 11 options in the register in the manual, but why there are 14 options in the code, please help explain.
How about this question?
Nancy,
I looked into it.
That's true. There are 14 options in the code and 11 options in the manual.
---
The reason is ... the code is common for series of devices like C667x, K2e, k2h,k2g,AMX etc...
Few attributes might differ, enhanced and improved, iterated when proceeding towards newer devices...and the datamanuals are updated accordingly.
For better maintenance, the same common code is used and built specific to the particular devices and released...
---
The customer can modify according to their requirements. It is recommended to stick to the data manual than the source code.
Because the data manual is specific to the keystone-devices-C6678. But the source code is common for the series of many devices .
--
As per the data manual, the bits 9-27 are reserved for keystone devices. In the source code, one might see additional variables like "Multiport", "flow arbitration" etc...
Sometimes, in the software they may club all the features in one structure for ease of use....
Or otherwise, when the software was initially designed, these reserved bits might be belonging to the actual features like "multiport"," flow-arbitration" etc and then it might have got separated to be the part of "Port Control Register CSR" etc....
Regards
Shankari G