下面介绍在"TI C66x DSP 系统events及其应用 - 2"中提到的PrivID。Each C66x DSP(corepac)is assigned a unique privilege ID (PrivID) value. Data I/O masters are assigned one PrivID, with the exception of the EDMA, which inherits the PrivID value of the master that configures it for each transfer.There are 16 total PrivID values supported in KeyStone devices. The memory protection attributes include read/write/execute access permissions for supervisor- and user-accesses individually.
摘自TI C66x data manual 5.2:
即当PrivID映射到了FID(AID)后,可以根据Memory Protection Register (MPPAxx)(L1,L2中的每个页均有对应的寄存器)来设置AID对该页的访问属性。
下图是TI C66x DSP data manual中定义的master的Privlege ID,以SRIO为例,SRIO在该文档中的Privilege ID值是9,在"TI C66x DSP 系统events及其应用 - 2"中设置cgemRegsPtr->PAMAP9 = EAidValues_AID5 = 5(Map SRIO to AID5,重新映射SRIO的ID,根据下图中SRIO的Privilege ID=9,只能通过设置PAMAP9寄存器来实现,映射的ID可由用户定义),表示当SRIO访问corePac的资源时,在corePac内部,SRIO的代号就是5了(取代原来的9),即Privilege ID 9已转化为FID 5。同理,AIF在下图中的Privilege ID值是4,设置cgemRegsPtr->PAMAP4 = (u32)(EAidValues_AIDX),即实现映射FFTC的Privilege ID =4 为EAidValues_AIDX = 7(FID)。