From patchwork Tue Dec 29 16:34:16 2009 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: "Hebbar, Shivananda" X-Patchwork-Id: 70121 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 nBTGYPZj009905 for ; Tue, 29 Dec 2009 16:34:25 GMT Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1752774AbZL2QeY (ORCPT ); Tue, 29 Dec 2009 11:34:24 -0500 Received: (majordomo@vger.kernel.org) by vger.kernel.org id S1752315AbZL2QeY (ORCPT ); Tue, 29 Dec 2009 11:34:24 -0500 Received: from arroyo.ext.ti.com ([192.94.94.40]:47169 "EHLO arroyo.ext.ti.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1752574AbZL2QeX convert rfc822-to-8bit (ORCPT ); Tue, 29 Dec 2009 11:34:23 -0500 Received: from dbdp20.itg.ti.com ([172.24.170.38]) by arroyo.ext.ti.com (8.13.7/8.13.7) with ESMTP id nBTGYKoM019772 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-SHA bits=256 verify=NO) for ; Tue, 29 Dec 2009 10:34:22 -0600 Received: from dbde70.ent.ti.com (localhost [127.0.0.1]) by dbdp20.itg.ti.com (8.13.8/8.13.8) with ESMTP id nBTGYIoW026119 for ; Tue, 29 Dec 2009 22:04:19 +0530 (IST) Received: from dbde02.ent.ti.com ([172.24.170.145]) by dbde70.ent.ti.com ([172.24.170.148]) with mapi; Tue, 29 Dec 2009 22:04:18 +0530 From: "Hebbar, Shivananda" To: "linux-omap@vger.kernel.org" Date: Tue, 29 Dec 2009 22:04:16 +0530 Subject: [PATCH ] DSPBRIDGE:Remove conditional check from the InputMsg function Thread-Topic: [PATCH ] DSPBRIDGE:Remove conditional check from the InputMsg function Thread-Index: AcqIpMN5XKAJC4qKSWuk7bAQUvhXXQ== Message-ID: <19F8576C6E063C45BE387C64729E7394044A277A9C@dbde02.ent.ti.com> Accept-Language: en-US Content-Language: en-US X-MS-Has-Attach: X-MS-TNEF-Correlator: acceptlanguage: en-US MIME-Version: 1.0 Sender: linux-omap-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-omap@vger.kernel.org diff --git a/drivers/dsp/bridge/wmd/io_sm.c b/drivers/dsp/bridge/wmd/io_sm.c index a6c8e31..5b7b004 100644 --- a/drivers/dsp/bridge/wmd/io_sm.c +++ b/drivers/dsp/bridge/wmd/io_sm.c @@ -1308,7 +1308,7 @@ static void InputMsg(struct IO_MGR *pIOMgr, struct MSG_MGR *hMsgMgr) fInputEmpty = IO_GetValue(pIOMgr->hWmdContext, struct MSG, pCtrl, bufEmpty); uMsgs = IO_GetValue(pIOMgr->hWmdContext, struct MSG, pCtrl, size); - if (fInputEmpty || uMsgs >= hMsgMgr->uMaxMsgs) + if (fInputEmpty) goto func_end; pMsgInput = pIOMgr->pMsgInput; @@ -1331,12 +1331,11 @@ static void InputMsg(struct IO_MGR *pIOMgr, struct MSG_MGR *hMsgMgr) DBG_Trace(DBG_LEVEL7, "InputMsg RECVD: dwCmd=0x%x dwArg1=0x%x " "dwArg2=0x%x dwId=0x%x \n", msg.msg.dwCmd, msg.msg.dwArg1, msg.msg.dwArg2, msg.dwId); - /* Interrupt may occur before shared memory and message - * input locations have been set up. If all nodes were - * cleaned up, hMsgMgr->uMaxMsgs should be 0. */ - if (hMsgQueue && uMsgs > hMsgMgr->uMaxMsgs) - goto func_end; - + /* + * Interrupt may occur before shared memory and message + * input locations have been set up. If all nodes were + * cleaned up, hMsgMgr->uMaxMsgs should be 0. + */ while (hMsgQueue != NULL) { if (msg.dwId == hMsgQueue->dwId) { /* Found it */