linux/drivers/gpu/drm/amd/amdgpu/amdgpu_amdkfd_gfx_v9.c
/* TODO - RING0 form of field is obsolete, seems to date back to SI
 * but still works
 */
RING0 form of field is obsolete, seems to date back to SI
but still works
RING0 form of field is obsolete seems to date back to SI but still works
static int kgd_init_interrupts(struct kgd_dev *kgd, uint32_t pipe_id)
{
	struct amdgpu_device *adev = get_amdgpu_device(kgd);
	uint32_t mec;
	uint32_t pipe;
	mec = (pipe_id / adev->gfx.mec.num_pipe_per_mec) + 1;
	pipe = (pipe_id % adev->gfx.mec.num_pipe_per_mec);
	lock_srbm(kgd, mec, pipe, 0, 0);
	WREG32(SOC15_REG_OFFSET(GC, 0, mmCPC_INT_CNTL),
		CP_INT_CNTL_RING0__TIME_STAMP_INT_ENABLE_MASK |
		CP_INT_CNTL_RING0__OPCODE_ERROR_INT_ENABLE_MASK);
	unlock_srbm(kgd);
	return 0;
}
static int kgd_init_interrupts ( struct kgd_dev * kgd , uint32_t pipe_id ) { struct amdgpu_device * adev = get_amdgpu_device ( kgd ) ; uint32_t mec ; uint32_t pipe ; mec = ( pipe_id / adev -> gfx . mec . num_pipe_per_mec ) + 1 ; pipe = ( pipe_id % adev -> gfx . mec . num_pipe_per_mec ) ; lock_srbm ( kgd , mec , pipe , 0 , 0 ) ; WREG32 ( SOC15_REG_OFFSET ( GC , 0 , mmCPC_INT_CNTL ) , CP_INT_CNTL_RING0__TIME_STAMP_INT_ENABLE_MASK | CP_INT_CNTL_RING0__OPCODE_ERROR_INT_ENABLE_MASK ) ; unlock_srbm ( kgd ) ; return 0 ; }
TODO - RING0 form of field is obsolete, seems to date back to SI
 but still works
TODO - RING0 form of field is obsolete seems to date back to SI but still works