diff mbox

[04/13] DSPBRIDGE: Moving macros from mem.h to drv.h

Message ID 818EF96F5A7CC84789DD014773DB09548F6481D6@dlee01.ent.ti.com (mailing list archive)
State Accepted
Delegated to:
Headers show

Commit Message

Gomez Castellanos, Ivan April 8, 2010, 11:54 p.m. UTC
None
diff mbox

Patch

diff --git a/arch/arm/plat-omap/include/dspbridge/drv.h b/arch/arm/plat-omap/include/dspbridge/drv.h
index eeb5e23..b4bea17 100644
--- a/arch/arm/plat-omap/include/dspbridge/drv.h
+++ b/arch/arm/plat-omap/include/dspbridge/drv.h
@@ -468,4 +468,37 @@  extern void mem_flush_cache(void *pMemBuf, u32 byte_size, s32 FlushType);
 extern void mem_free_phys_mem(void *pVirtualAddress,
 			      u32 pPhysicalAddress, u32 byte_size);
 
+/*
+ *  ======== MEM_LINEAR_ADDRESS ========
+ *  Purpose:
+ *      Get the linear address corresponding to the given physical address.
+ *  Parameters:
+ *      pPhysAddr:  Physical address to be mapped.
+ *      byte_size:     Number of bytes in physical range to map.
+ *  Returns:
+ *      The corresponding linear address, or NULL if unsuccessful.
+ *  Requires:
+ *      MEM initialized.
+ *  Ensures:
+ *  Notes:
+ *      If valid linear address is returned, be sure to call
+ *      MEM_UNMAP_LINEAR_ADDRESS().
+ */
+#define MEM_LINEAR_ADDRESS(pPhyAddr, byte_size) pPhyAddr
+
+/*
+ *  ======== MEM_UNMAP_LINEAR_ADDRESS ========
+ *  Purpose:
+ *      Unmap the linear address mapped in MEM_LINEAR_ADDRESS.
+ *  Parameters:
+ *      pBaseAddr: Ptr to mapped memory (as returned by MEM_LINEAR_ADDRESS()).
+ *  Returns:
+ *  Requires:
+ *      - MEM initialized.
+ *      - pBaseAddr is a valid linear address mapped in MEM_LINEAR_ADDRESS.
+ *  Ensures:
+ *      - pBaseAddr no longer points to a valid linear address.
+ */
+#define MEM_UNMAP_LINEAR_ADDRESS(pBaseAddr) {}
+
 #endif /* DRV_ */
diff --git a/arch/arm/plat-omap/include/dspbridge/mem.h b/arch/arm/plat-omap/include/dspbridge/mem.h
index 374b971..9f713b9 100644
--- a/arch/arm/plat-omap/include/dspbridge/mem.h
+++ b/arch/arm/plat-omap/include/dspbridge/mem.h
@@ -166,37 +166,4 @@  extern bool services_mem_init(void);
 #define MEM_IS_VALID_HANDLE(hObj, Sig)                \
      ((hObj != NULL) && (hObj->dw_signature == Sig))
 
-/*
- *  ======== MEM_LINEAR_ADDRESS ========
- *  Purpose:
- *      Get the linear address corresponding to the given physical address.
- *  Parameters:
- *      pPhysAddr:  Physical address to be mapped.
- *      byte_size:     Number of bytes in physical range to map.
- *  Returns:
- *      The corresponding linear address, or NULL if unsuccessful.
- *  Requires:
- *      MEM initialized.
- *  Ensures:
- *  Notes:
- *      If valid linear address is returned, be sure to call
- *      MEM_UNMAP_LINEAR_ADDRESS().
- */
-#define MEM_LINEAR_ADDRESS(pPhyAddr, byte_size) pPhyAddr
-
-/*
- *  ======== MEM_UNMAP_LINEAR_ADDRESS ========
- *  Purpose:
- *      Unmap the linear address mapped in MEM_LINEAR_ADDRESS.
- *  Parameters:
- *      pBaseAddr: Ptr to mapped memory (as returned by MEM_LINEAR_ADDRESS()).
- *  Returns:
- *  Requires:
- *      - MEM initialized.
- *      - pBaseAddr is a valid linear address mapped in MEM_LINEAR_ADDRESS.
- *  Ensures:
- *      - pBaseAddr no longer points to a valid linear address.
- */
-#define MEM_UNMAP_LINEAR_ADDRESS(pBaseAddr) {}
-
 #endif /* MEM_ */