Main Page | Alphabetical List | Data Structures | Directories | File List | Data Fields | Globals | Related Pages

omap3530_hal.h

Go to the documentation of this file.
00001 /** ============================================================================
00002  *  @file   omap3530_hal.h
00003  *
00004  *  @path   $(DSPLINK)/gpp/inc/sys/arch/OMAP3530/
00005  *
00006  *  @brief  Hardware Abstraction Layer.
00007  *
00008  *  @ver    1.65.00.03
00009  *  ============================================================================
00010  *  @copyright Copyright (C) 2002-2009, Texas Instruments Incorporated -
00011  *  http://www.ti.com/
00012  *
00013  *  Redistribution and use in source and binary forms, with or without
00014  *  modification, are permitted provided that the following conditions
00015  *  are met:
00016  *  
00017  *  *  Redistributions of source code must retain the above copyright
00018  *     notice, this list of conditions and the following disclaimer.
00019  *  
00020  *  *  Redistributions in binary form must reproduce the above copyright
00021  *     notice, this list of conditions and the following disclaimer in the
00022  *     documentation and/or other materials provided with the distribution.
00023  *  
00024  *  *  Neither the name of Texas Instruments Incorporated nor the names of
00025  *     its contributors may be used to endorse or promote products derived
00026  *     from this software without specific prior written permission.
00027  *  
00028  *  THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS"
00029  *  AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO,
00030  *  THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR
00031  *  PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR
00032  *  CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL,
00033  *  EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO,
00034  *  PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS;
00035  *  OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY,
00036  *  WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR
00037  *  OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE,
00038  *  EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
00039  *  ============================================================================
00040  */
00041 
00042 
00043 #if !defined (OMAP3530_HAL_H)
00044 #define OMAP3530_HAL_H
00045 
00046 
00047 /*  ----------------------------------- DSP/BIOS Link               */
00048 #include <dsplink.h>
00049 #include <_dsplink.h>
00050 
00051 /*  ----------------------------------- Trace & Debug               */
00052 #include <_trace.h>
00053 
00054 /*  ----------------------------------- Hardware Abstraction Layer  */
00055 #include <hal.h>
00056 
00057 /*  ----------------------------------- OSAL Headers                */
00058 #include <osal.h>
00059 
00060 #if defined (__cplusplus)
00061 extern "C" {
00062 #endif
00063 
00064 
00065 /*  ============================================================================
00066  *  @macro  REG
00067  *
00068  *  @brief  Regsiter access method.
00069  *  ============================================================================
00070  */
00071 #define REG(x)              *((volatile Uint32 *) (x))
00072 
00073 
00074 /** ============================================================================
00075  *  @name   OMAP3530_HalObj
00076  *
00077  *  @brief  Hardware Abstraction object.
00078  *
00079  *  @param  interface
00080  *              Pointer to HAL interface table.
00081  *  @param  isrObject
00082  *              Pointer to IsrObject.
00083  *  @param  generalCtrlBase
00084  *              Virtual base address of the General Control module.
00085  *  @param  iva2CmBase
00086  *              Virtual base address of the IVA2 CM module.
00087  *  @param  coreCmBase
00088  *              Virtual base address of the CORE CM module.
00089  *  @param  perCmBase
00090  *              Virtual base address of the PER CM module.
00091  *  @param  iva2PrmBase
00092  *              Virtual base address of the IVA2 PRM module.
00093  *  @param  mailboxBase
00094  *              base address of the mailbox module.
00095  *  @param  mmuBase
00096  *              base address of the MMU module.
00097  *  @param  prcmBase
00098  *              base address of the PRCM module.
00099  *  @param  tlbIndex
00100  *              TLB entry of the MMU module.
00101  *  @param  procId 
00102  *              Processor ID.
00103  *  @param  type
00104  *              Flag to verify the static or dynamic entry.
00105  *  ============================================================================
00106  */
00107 typedef struct OMAP3530_HalObj_tag {
00108     HAL_Interface * interface       ;
00109     IsrObject     * isrObject       ;
00110     Uint32          generalCtrlBase ;
00111     Uint32          iva2CmBase      ;
00112     Uint32          coreCmBase      ;
00113     Uint32          perCmBase       ;
00114     Uint32          iva2PrmBase     ;
00115     Uint32          mailboxBase     ;
00116     Uint32          mmuBase         ;
00117     Uint32          tlbIndex        ;
00118     Uint32          procId          ;
00119     Bool            type            ;
00120 
00121 } OMAP3530_HalObj ;
00122 
00123 
00124 /** ============================================================================
00125  *  @func   OMAP3530_halInitialize
00126  *
00127  *  @brief  Initializes the HAL object.
00128  *
00129  *  @param halObj.
00130  *              Pointer to HAL object.
00131  *  @param initParams.
00132  *              Parameters for initialize (optional).
00133  *
00134  *  @return DSP_SOK
00135  *              Operation successfully completed.
00136  *          DSP_EFAIL
00137  *              All other error conditions.
00138  *
00139  *  @pre    None.
00140  *
00141  *  @post   None.
00142  *
00143  *  @see    None
00144  *  ============================================================================
00145  */
00146 NORMAL_API
00147 DSP_STATUS
00148 OMAP3530_halInit (IN     Pvoid * halObj,
00149                    IN     Pvoid   initParams) ;
00150 
00151 
00152 /** ============================================================================
00153  *  @func   OMAP3530_halExit
00154  *
00155  *  @brief  Finalizes the HAL object.
00156  *
00157  *  @param halObj.
00158  *              Pointer to HAL object.
00159  *
00160  *  @return DSP_SOK
00161  *              Operation successfully completed.
00162  *          DSP_EFAIL
00163  *              All other error conditions.
00164  *
00165  *  @pre    None.
00166  *
00167  *  @post   None.
00168  *
00169  *  @see    None
00170  *  ============================================================================
00171  */
00172 NORMAL_API
00173 DSP_STATUS
00174 OMAP3530_halExit (IN Pvoid * halObj) ;
00175 
00176 
00177 #if defined (__cplusplus)
00178 }
00179 #endif
00180 
00181 
00182 #endif  /* !defined (OMAP3530_HAL_H) */

Generated on Fri Jul 16 14:34:03 2010 for DSP/BIOSLink by  doxygen 1.4.4