From: Andy Shevchenko <ext-andriy.shevchenko@xxxxxxxxx> Signed-off-by: Andy Shevchenko <ext-andriy.shevchenko@xxxxxxxxx> --- drivers/dsp/bridge/rmgr/drv.c | 14 ++++++++++++-- 1 files changed, 12 insertions(+), 2 deletions(-) diff --git a/drivers/dsp/bridge/rmgr/drv.c b/drivers/dsp/bridge/rmgr/drv.c index bedc34c..44d7f2d 100644 --- a/drivers/dsp/bridge/rmgr/drv.c +++ b/drivers/dsp/bridge/rmgr/drv.c @@ -825,7 +825,13 @@ DSP_STATUS DRV_ProcDisplayResInfo(u8 *pBuf1, u32 *pSize) u32 tempStrLen = 0, tempStrLen2 = 0; DSP_STATUS status = DSP_SOK; - CFG_GetObject((u32 *)&hDrvObject, REG_DRV_OBJECT); + if (DSP_FAILED(CFG_GetObject((u32 *)&hDrvObject, REG_DRV_OBJECT))) { + /* Should we print something? */ + *pBuf1 = 0; + *pSize = 0; + return DSP_EHANDLE; + } + DRV_GetProcCtxtList(&pCtxt, (struct DRV_OBJECT *)hDrvObject); GT_0trace(curTrace, GT_ENTER, "*********************" "DRV_ProcDisplayResourceInfo:*\n"); @@ -954,8 +960,12 @@ static DSP_STATUS PrintProcessInformation(void) u32 tempCount; u32 procID; + if (DSP_FAILED(CFG_GetObject((u32 *)&hDrvObject, REG_DRV_OBJECT))) { + /* Should we print something? */ + return DSP_EHANDLE; + } + /* Get the Process context list */ - CFG_GetObject((u32 *)&hDrvObject, REG_DRV_OBJECT); DRV_GetProcCtxtList(&pCtxtList, hDrvObject); GT_0trace(curTrace, GT_4CLASS, "\n### Debug information" " for DSP bridge ##\n"); -- 1.5.6.5 -- To unsubscribe from this list: send the line "unsubscribe linux-omap" in the body of a message to majordomo@xxxxxxxxxxxxxxx More majordomo info at http://vger.kernel.org/majordomo-info.html