📄 ocp.h
字号:
/*
===============================================================================
TEXAS INSTRUMENTS INCORPORATED PROPRIETARY INFORMATION
Property of Texas Instruments
For Unrestricted Internal Use Only
Unauthorized reproduction and/or distribution is strictly prohibited.
This product is protected under copyright law and trade secret law
as an unpublished work.
Created 2001, (C) Copyright 2001 Texas Instruments. All rights reserved.
Filename : ocp.h
Description : Header file for the OCP module.
Project : OMAP3.2
Author : Radhika Apshankar
===============================================================================
*/
#ifndef _OCP__HH
#define _OCP__HH
#include "top.h"
//-------------------------------------------------------------
//-- OCPT1 REGISTERS ADDRESS MAPPING
//-------------------------------------------------------------
#define OCPT1_PRIOR 0xFFFECC00
#define OCPT1_PTOR1 (OCPT1_PRIOR + 0x00a0)
#define OCPT1_PTOR2 (OCPT1_PRIOR + 0x00a4)
#define OCPT1_PTOR3 (OCPT1_PRIOR + 0x00a8)
#define OCPT1_ATOR (OCPT1_PRIOR + 0x00ac)
#define OCPT1_AADDR (OCPT1_PRIOR + 0x00b0)
#define OCPT1_ATYPER (OCPT1_PRIOR + 0x00b4)
#define OCPT1_CONFIG (OCPT1_PRIOR + 0x00b8)
//-------------------------------------------------------------
//-- OCPT1 REGISTERS RESET VALUES
//-------------------------------------------------------------
#define OCPT1_PRIOR_RESET_VALUE 0x00000000
#define OCPT1_PTOR1_RESET_VALUE 0x00000000
#define OCPT1_PTOR2_RESET_VALUE 0x00000000
#define OCPT1_PTOR3_RESET_VALUE 0x00000000
#define OCPT1_ATOR_RESET_VALUE 0x000001ff
#define OCPT1_AADDR_RESET_VALUE 0x00000000
#define OCPT1_ATYPER_RESET_VALUE 0x00000000
#define OCPT1_CONFIG_RESET_VALUE 0x00000002
//--------------------------------------------------------------
//-- OCPT1 REGISTERS READ only Bits & RESERVED bits MASK VALUES
//--------------------------------------------------------------
#define OCPT1_PRIOR_MASK_VALUE 0x0000ffff
#define OCPT1_PTOR1_MASK_VALUE 0x000000ff
#define OCPT1_PTOR2_MASK_VALUE 0x00ff00ff
#define OCPT1_PTOR3_MASK_VALUE 0x000000ff
#define OCPT1_ATOR_MASK_VALUE 0x000001ff
#define OCPT1_ATYPER_MASK_VALUE 0x0000001f
#define OCPT1_CONFIG_MASK_VALUE 0x00000003
//-------------------------------------------------------------
//-- OCPT2 REGISTERS ADDRESS MAPPING
//-------------------------------------------------------------
#define OCPT2_PRIOR (OCPT1_PRIOR + 0x00d0)
#define OCPT2_PTOR1 (OCPT1_PRIOR + 0x00d4)
#define OCPT2_PTOR2 (OCPT1_PRIOR + 0x00d8)
#define OCPT2_PTOR3 (OCPT1_PRIOR + 0x00dc)
#define OCPT2_ATOR (OCPT1_PRIOR + 0x00e0)
#define OCPT2_AADDR (OCPT1_PRIOR + 0x00e4)
#define OCPT2_ATYPER (OCPT1_PRIOR + 0x00e8)
//-------------------------------------------------------------
//-- OCPT2 REGISTERS RESET VALUES
//-------------------------------------------------------------
#define OCPT2_PRIOR_RESET_VALUE 0x00000000
#define OCPT2_PTOR1_RESET_VALUE 0x00000000
#define OCPT2_PTOR2_RESET_VALUE 0x00000000
#define OCPT2_PTOR3_RESET_VALUE 0x00000000
#define OCPT2_ATOR_RESET_VALUE 0x000001ff
#define OCPT2_AADDR_RESET_VALUE 0x00000000
#define OCPT2_ATYPER_RESET_VALUE 0x00000000
//--------------------------------------------------------------
//-- OCPT2 REGISTERS READ only Bits & RESERVED bits MASK VALUES
//--------------------------------------------------------------
#define OCPT2_PRIOR_MASK_VALUE 0x0000ffff
#define OCPT2_PTOR1_MASK_VALUE 0x000000ff
#define OCPT2_PTOR2_MASK_VALUE 0x00ff00ff
#define OCPT2_PTOR3_MASK_VALUE 0x000000ff
#define OCPT2_ATOR_MASK_VALUE 0x000001ff
#define OCPT2_ATYPER_MASK_VALUE 0x0000001f
//-------------------------------------------------------------
// OCPT1 ERROR CODES
//-------------------------------------------------------------
#define OCPT1_REG_RESET_ERROR 0x2000
#define OCPT1_REG_RW_ERROR 0x2001
#define OCPT1_REG_RONLY_ERROR 0x2002
#define OCPT1_REG_RONLY_ABORT 0x2003
#define OCPT1_MULTIPLE_RW_ERROR 0x2004
#define OCPT1_DMA_Transfer_ERROR 0x2005
//-------------------------------------------------------------
//-------------------------------------------------------------
// OCPT2 ERROR CODES
//-------------------------------------------------------------
#define OCPT2_REG_RESET_ERROR 0x2100
#define OCPT2_REG_RW_ERROR 0x2101
#define OCPT2_REG_RONLY_ERROR 0x2102
#define OCPT2_REG_RONLY_ABORT 0x2103
#define OCPT2_MULTIPLE_RW_ERROR 0x2104
#define OCPT2_DMA_Transfer_ERROR 0x2105
//-------------------------------------------------------------
// OCP master registers
//-------------------------------------------------------------
#define OCPI_ADDR_FAULT_REG 0xfffec320
#define OCPI_MCMD_FAULT_REG 0xfffec324
#define OCPI_SINT0_REG 0xfffec328
#define OCPI_ABORT_TYPE_REG 0xfffec32c
#define OCPI_SINT1_REG 0xfffec330
#define OCPI_PROTECT_REG 0xfffec334
#define OCPI_SECURE_MODE_REG 0xfffec338
//-------------------------------------------------------------
// OCP master registers MASK values
//-------------------------------------------------------------
#define OCPI_MCMD_MASK_VALUE 0x00000007
#define OCPI_SINT0_MASK_VALUE 0x00000003
#define OCPI_ABORT_TYPE_MASK_VALUE 0x0000000f
#define OCPI_SINT1_MASK_VALUE 0x00000003
#define OCPI_PROTECT_MASK_VALUE 0x000000ff
#define OCPI_SECURE_MODE_MASK_VALUE 0x0000007f
//-------------------------------------------------------------
//-- OCPI REGISTERS RESET VALUES
//-------------------------------------------------------------
#define OCPI_ADDR_FAULT_RESET_VALUE 0x00000000
#define OCPI_MCMD_FAULT_RESET_VALUE 0x00000000
#define OCPI_SINT0_RESET_VALUE 0x00000003
#define OCPI_ABORT_TYPE_RESET_VALUE 0x00000000
#define OCPI_SINT1_RESET_VALUE 0x00000003
#define OCPI_PROTECT_RESET_VALUE 0x00000000
#define OCPI_SECURE_MODE_RESET_VALUE 0x00000000
#define OCPI_SECURE_MODE_RESET 0x0000007f
//-------------------------------------------------------------
// OCPI ERROR CODES
//-------------------------------------------------------------
#define OCPI_OCPT1_ERROR 0x2200
#define OCPI_OCPT2_ERROR 0x2201
#define OCPI_OCPT12_ERROR 0x2202
#define OCPI_EMIFF_ERROR 0x2203
#define OCPI_EMIFS_ERROR 0x2204
#define OCPI_REG_RESET_ERROR 0x2205
#define OCPI_REG_RW_ERROR 0x2206
#define OCPI_REG_RONLY_ERROR 0x2207
/*End OCPT -------------------------------------------------------------*/
BOOL Write_WORD_Read_BYTE (UWORD32 Addr);
BOOL Write_BYTE_Read_WORD (UWORD32 Addr);
#endif
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -