From patchwork Thu Jan 21 13:40:41 2010 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Ameya Palande X-Patchwork-Id: 74339 Received: from vger.kernel.org (vger.kernel.org [209.132.180.67]) by demeter.kernel.org (8.14.3/8.14.2) with ESMTP id o0LDfYUH015737 for ; Thu, 21 Jan 2010 13:41:34 GMT Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1751636Ab0AUNle (ORCPT ); Thu, 21 Jan 2010 08:41:34 -0500 Received: (majordomo@vger.kernel.org) by vger.kernel.org id S1751800Ab0AUNle (ORCPT ); Thu, 21 Jan 2010 08:41:34 -0500 Received: from smtp.nokia.com ([192.100.122.233]:20880 "EHLO mgw-mx06.nokia.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1750866Ab0AUNld (ORCPT ); Thu, 21 Jan 2010 08:41:33 -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 o0LDfEoh020061; Thu, 21 Jan 2010 15:41:26 +0200 Received: from esebh102.NOE.Nokia.com ([172.21.138.183]) by esebh106.NOE.Nokia.com with Microsoft SMTPSVC(6.0.3790.3959); Thu, 21 Jan 2010 15:41:12 +0200 Received: from mgw-da02.ext.nokia.com ([147.243.128.26]) by esebh102.NOE.Nokia.com over TLS secured channel with Microsoft SMTPSVC(6.0.3790.3959); Thu, 21 Jan 2010 15:41:12 +0200 Received: from localhost.localdomain (esdhcp041187.research.nokia.com [172.21.41.187]) by mgw-da02.ext.nokia.com (Switch-3.3.3/Switch-3.3.3) with ESMTP id o0LDf7sF011911; Thu, 21 Jan 2010 15:41:07 +0200 From: Ameya Palande To: linux-omap@vger.kernel.org Cc: omar.ramirez@ti.com, nm@ti.com, deepak.chitriki@ti.com, mika.kukkonen@nokia.com Subject: [PATCH] DSPBRIDGE: Various compile warning fixes Date: Thu, 21 Jan 2010 15:40:41 +0200 Message-Id: X-Mailer: git-send-email 1.6.3.3 X-OriginalArrivalTime: 21 Jan 2010 13:41:13.0064 (UTC) FILETIME=[65B9E680:01CA9A9F] X-Nokia-AV: Clean Sender: linux-omap-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-omap@vger.kernel.org diff --git a/arch/arm/plat-omap/include/dspbridge/dbc.h b/arch/arm/plat-omap/include/dspbridge/dbc.h index ac5d178..1b3ac44 100644 --- a/arch/arm/plat-omap/include/dspbridge/dbc.h +++ b/arch/arm/plat-omap/include/dspbridge/dbc.h @@ -43,9 +43,9 @@ #else -#define DBC_Assert(exp) -#define DBC_Require(exp) -#define DBC_Ensure(exp) +#define DBC_Assert(exp) {} +#define DBC_Require(exp) {} +#define DBC_Ensure(exp) {} #endif /* DEBUG */ diff --git a/arch/arm/plat-omap/include/dspbridge/dbg.h b/arch/arm/plat-omap/include/dspbridge/dbg.h index 2f61dab..4d01eca 100644 --- a/arch/arm/plat-omap/include/dspbridge/dbg.h +++ b/arch/arm/plat-omap/include/dspbridge/dbg.h @@ -80,9 +80,9 @@ extern DSP_STATUS DBG_Trace(IN u8 bLevel, IN char *pstrFormat, ...); #else -#define DBG_Exit(void) +#define DBG_Exit(void) do {} while (0) #define DBG_Init(void) true -#define DBG_Trace(bLevel, pstrFormat, args...) +#define DBG_Trace(bLevel, pstrFormat, args...) do {} while (0) #endif /* (CONFIG_BRIDGE_DEBUG || DDSP_DEBUG_PRODUCT) && GT_TRACE */ diff --git a/arch/arm/plat-omap/include/dspbridge/gt.h b/arch/arm/plat-omap/include/dspbridge/gt.h index 6082d15..9097910 100644 --- a/arch/arm/plat-omap/include/dspbridge/gt.h +++ b/arch/arm/plat-omap/include/dspbridge/gt.h @@ -252,13 +252,15 @@ extern struct GT_Config _GT_params; #define GT_query(mask, class) false -#define GT_0trace(mask, class, format) -#define GT_1trace(mask, class, format, arg1) -#define GT_2trace(mask, class, format, arg1, arg2) -#define GT_3trace(mask, class, format, arg1, arg2, arg3) -#define GT_4trace(mask, class, format, arg1, arg2, arg3, arg4) -#define GT_5trace(mask, class, format, arg1, arg2, arg3, arg4, arg5) -#define GT_6trace(mask, class, format, arg1, arg2, arg3, arg4, arg5, arg6) +#define GT_0trace(mask, class, format) do {} while (0) +#define GT_1trace(mask, class, format, arg1) do {} while (0) +#define GT_2trace(mask, class, format, arg1, arg2) do {} while (0) +#define GT_3trace(mask, class, format, arg1, arg2, arg3) do {} while (0) +#define GT_4trace(mask, class, format, arg1, arg2, arg3, arg4) do {} while (0) +#define GT_5trace(mask, class, format, arg1, arg2, arg3, arg4, arg5) \ + do {} while (0) +#define GT_6trace(mask, class, format, arg1, arg2, arg3, arg4, arg5, arg6) \ + do {} while (0) #else /* GT_TRACE == 1 */ diff --git a/arch/arm/plat-omap/include/dspbridge/mem.h b/arch/arm/plat-omap/include/dspbridge/mem.h index 03b419a..353ffb0 100644 --- a/arch/arm/plat-omap/include/dspbridge/mem.h +++ b/arch/arm/plat-omap/include/dspbridge/mem.h @@ -286,7 +286,7 @@ * Ensures: * - pBaseAddr no longer points to a valid linear address. */ -#define MEM_UnmapLinearAddress(pBaseAddr) +#define MEM_UnmapLinearAddress(pBaseAddr) {} /* * ======== MEM_ExtPhysPoolInit ======== diff --git a/drivers/dsp/bridge/wmd/io_sm.c b/drivers/dsp/bridge/wmd/io_sm.c index e35ce57..64eba5a 100644 --- a/drivers/dsp/bridge/wmd/io_sm.c +++ b/drivers/dsp/bridge/wmd/io_sm.c @@ -1210,7 +1210,7 @@ static void InputChnl(struct IO_MGR *pIOMgr, struct CHNL_OBJECT *pChnl, pChnlMgr->uWordSize; chnlId = IO_GetValue(pIOMgr->hWmdContext, struct SHM, sm, inputId); dwArg = IO_GetLong(pIOMgr->hWmdContext, struct SHM, sm, arg); - if (!(chnlId >= 0) || !(chnlId < CHNL_MAXCHANNELS)) { + if (chnlId >= CHNL_MAXCHANNELS) { /* Shouldn't be here: would indicate corrupted SHM. */ DBC_Assert(chnlId); goto func_end; diff --git a/drivers/dsp/bridge/wmd/ue_deh.c b/drivers/dsp/bridge/wmd/ue_deh.c index 6166d97..2c3a2cd 100644 --- a/drivers/dsp/bridge/wmd/ue_deh.c +++ b/drivers/dsp/bridge/wmd/ue_deh.c @@ -189,7 +189,7 @@ void WMD_DEH_Notify(struct DEH_MGR *hDehMgr, u32 ulEventMask, DSP_STATUS status = DSP_SOK; u32 memPhysical = 0; u32 HW_MMU_MAX_TLB_COUNT = 31; - u32 extern faultAddr; + extern u32 faultAddr; struct CFG_HOSTRES resources; HW_STATUS hwStatus;