* [PATCH] DSPBRIDGE: Avoid inserting wrong elements to STRM list
@ 2010-02-10 8:34 Guzman Lugo, Fernando
2010-02-16 23:56 ` Omar Ramirez Luna
0 siblings, 1 reply; 2+ messages in thread
From: Guzman Lugo, Fernando @ 2010-02-10 8:34 UTC (permalink / raw)
To: linux-omap@vger.kernel.org
Cc: Ameya Palande, Hiroshi Doyu, felipe.contreras@nokia.com
>From 09260a0211d088d840d09c04380c8c9448c01ec4 Mon Sep 17 00:00:00 2001
From: Fernando Guzman Lugo <x0095840@ti.com>
Date: Wed, 10 Feb 2010 02:33:54 -0600
Subject: [PATCH] DSPBRIDGE: Avoid inserting wrong elements to STRM list
This fixes a bug where in error case and after deleting a
strm element (if allocated), the strm is still inserted as
part of the process context allocated resources, this pointer
is not valid and shouldn't be considered as part of valid
resources.
Signed-off-by: Fernando Guzman Lugo <x0095840@ti.com>
---
drivers/dsp/bridge/rmgr/strm.c | 8 ++++----
1 files changed, 4 insertions(+), 4 deletions(-)
diff --git a/drivers/dsp/bridge/rmgr/strm.c b/drivers/dsp/bridge/rmgr/strm.c
index 1bb4670..e004205 100644
--- a/drivers/dsp/bridge/rmgr/strm.c
+++ b/drivers/dsp/bridge/rmgr/strm.c
@@ -634,12 +634,12 @@ func_cont:
status);
}
}
- if (DSP_SUCCEEDED(status))
+ if (DSP_SUCCEEDED(status)) {
*phStrm = pStrm;
- else
+ DRV_ProcInsertSTRMResElement(*phStrm, &hSTRMRes, pr_ctxt);
+ } else {
(void)DeleteStrm(pStrm);
-
- DRV_ProcInsertSTRMResElement(*phStrm, &hSTRMRes, pr_ctxt);
+ }
/* ensure we return a documented error code */
DBC_Ensure((DSP_SUCCEEDED(status) &&
--
1.6.0.4
^ permalink raw reply related [flat|nested] 2+ messages in thread
* Re: [PATCH] DSPBRIDGE: Avoid inserting wrong elements to STRM list
2010-02-10 8:34 [PATCH] DSPBRIDGE: Avoid inserting wrong elements to STRM list Guzman Lugo, Fernando
@ 2010-02-16 23:56 ` Omar Ramirez Luna
0 siblings, 0 replies; 2+ messages in thread
From: Omar Ramirez Luna @ 2010-02-16 23:56 UTC (permalink / raw)
To: Guzman Lugo, Fernando
Cc: linux-omap@vger.kernel.org, Ameya Palande, Hiroshi Doyu,
felipe.contreras@nokia.com
On 2/10/2010 2:34 AM, Guzman Lugo, Fernando wrote:
> From 09260a0211d088d840d09c04380c8c9448c01ec4 Mon Sep 17 00:00:00 2001
> From: Fernando Guzman Lugo<x0095840@ti.com>
> Date: Wed, 10 Feb 2010 02:33:54 -0600
> Subject: [PATCH] DSPBRIDGE: Avoid inserting wrong elements to STRM list
>
> This fixes a bug where in error case and after deleting a
> strm element (if allocated), the strm is still inserted as
> part of the process context allocated resources, this pointer
> is not valid and shouldn't be considered as part of valid
> resources.
>
> Signed-off-by: Fernando Guzman Lugo<x0095840@ti.com>
Acked-by: Omar Ramirez Luna <omar.ramirez@ti.com>
Pushed to dspbridge
- omar
^ permalink raw reply [flat|nested] 2+ messages in thread
end of thread, other threads:[~2010-02-16 23:56 UTC | newest]
Thread overview: 2+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2010-02-10 8:34 [PATCH] DSPBRIDGE: Avoid inserting wrong elements to STRM list Guzman Lugo, Fernando
2010-02-16 23:56 ` Omar Ramirez Luna
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox