From patchwork Wed Feb 3 23:32:26 2010 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Ameya Palande X-Patchwork-Id: 76834 X-Patchwork-Delegate: omar.ramirez@ti.com Received: from vger.kernel.org (vger.kernel.org [209.132.180.67]) by demeter.kernel.org (8.14.3/8.14.3) with ESMTP id o13NWdmw015499 for ; Wed, 3 Feb 2010 23:32:42 GMT Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1757890Ab0BCXcl (ORCPT ); Wed, 3 Feb 2010 18:32:41 -0500 Received: from smtp.nokia.com ([192.100.122.233]:23029 "EHLO mgw-mx06.nokia.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1757886Ab0BCXck (ORCPT ); Wed, 3 Feb 2010 18:32:40 -0500 Received: from esebh106.NOE.Nokia.com (esebh106.ntc.nokia.com [172.21.138.213]) by mgw-mx06.nokia.com (Switch-3.3.3/Switch-3.3.3) with ESMTP id o13NWW6u016620; Thu, 4 Feb 2010 01:32:34 +0200 Received: from esebh102.NOE.Nokia.com ([172.21.138.183]) by esebh106.NOE.Nokia.com with Microsoft SMTPSVC(6.0.3790.3959); Thu, 4 Feb 2010 01:32:32 +0200 Received: from mgw-sa01.ext.nokia.com ([147.243.1.47]) by esebh102.NOE.Nokia.com over TLS secured channel with Microsoft SMTPSVC(6.0.3790.3959); Thu, 4 Feb 2010 01:32:33 +0200 Received: from localhost.localdomain (essapo-nirac253153.europe.nokia.com [10.162.253.153]) by mgw-sa01.ext.nokia.com (Switch-3.3.3/Switch-3.3.3) with ESMTP id o13NWQT7013007; Thu, 4 Feb 2010 01:32:31 +0200 From: Ameya Palande To: linux-omap@vger.kernel.org Cc: omar.ramirez@ti.com, nm@ti.com, deepak.chitriki@ti.com Subject: [PATCH 3/3] DSPBRIDGE: Get rid of MEM_VFree() Date: Thu, 4 Feb 2010 01:32:26 +0200 Message-Id: <3240b3d882542163a213b63e345f71a9d2308806.1265239075.git.ameya.palande@nokia.com> X-Mailer: git-send-email 1.6.3.3 In-Reply-To: References: In-Reply-To: References: X-OriginalArrivalTime: 03 Feb 2010 23:32:33.0356 (UTC) FILETIME=[28FF90C0:01CAA529] X-Nokia-AV: Clean Sender: linux-omap-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-omap@vger.kernel.org X-Greylist: IP, sender and recipient auto-whitelisted, not delayed by milter-greylist-4.2.3 (demeter.kernel.org [140.211.167.41]); Wed, 03 Feb 2010 23:32:42 +0000 (UTC) diff --git a/arch/arm/plat-omap/include/dspbridge/mem.h b/arch/arm/plat-omap/include/dspbridge/mem.h index 3b94c02..afc15a9 100644 --- a/arch/arm/plat-omap/include/dspbridge/mem.h +++ b/arch/arm/plat-omap/include/dspbridge/mem.h @@ -140,23 +140,6 @@ extern void MEM_FlushCache(void *pMemBuf, u32 cBytes, s32 FlushType); /* - * ======== MEM_VFree ======== - * Purpose: - * Free the given block of system memory in virtual space. - * Parameters: - * pMemBuf: Pointer to memory allocated by MEM_Calloc/Alloc() - * using vmalloc. - * Returns: - * Requires: - * MEM initialized. - * pMemBuf is a valid memory address returned by MEM_Calloc/Alloc() - * using vmalloc. - * Ensures: - * pMemBuf is no longer a valid pointer to memory. - */ - extern void MEM_VFree(IN void *pMemBuf); - -/* * ======== MEM_FreePhysMem ======== * Purpose: * Free the given block of physically contiguous memory. diff --git a/drivers/dsp/bridge/pmgr/dmm.c b/drivers/dsp/bridge/pmgr/dmm.c index d5a7275..2425f0f 100644 --- a/drivers/dsp/bridge/pmgr/dmm.c +++ b/drivers/dsp/bridge/pmgr/dmm.c @@ -220,8 +220,7 @@ DSP_STATUS DMM_DeleteTables(struct DMM_OBJECT *hDmmMgr) /* Delete all DMM tables */ SYNC_EnterCS(pDmmObj->hDmmLock); - if (pVirtualMappingTable != NULL) - MEM_VFree(pVirtualMappingTable); + vfree(pVirtualMappingTable); SYNC_LeaveCS(pDmmObj->hDmmLock); } else diff --git a/drivers/dsp/bridge/services/mem.c b/drivers/dsp/bridge/services/mem.c index 614396e..57f1794 100644 --- a/drivers/dsp/bridge/services/mem.c +++ b/drivers/dsp/bridge/services/mem.c @@ -292,23 +292,6 @@ void MEM_FlushCache(void *pMemBuf, u32 cBytes, s32 FlushType) } /* - * ======== MEM_VFree ======== - * Purpose: - * Free the given block of system memory in virtual space. - */ -void MEM_VFree(IN void *pMemBuf) -{ - DBC_Require(pMemBuf != NULL); - - GT_1trace(MEM_debugMask, GT_ENTER, "MEM_VFree: pMemBufs 0x%x\n", - pMemBuf); - - if (pMemBuf) { - vfree(pMemBuf); - } -} - -/* * ======== MEM_FreePhysMem ======== * Purpose: * Free the given block of physically contiguous memory.