From patchwork Thu Mar 12 12:03:10 2009 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: "Gupta, Ramesh" X-Patchwork-Id: 11334 Received: from vger.kernel.org (vger.kernel.org [209.132.176.167]) by demeter.kernel.org (8.14.2/8.14.2) with ESMTP id n2CC3r4G019446 for ; Thu, 12 Mar 2009 12:05:08 GMT Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1752031AbZCLMFI (ORCPT ); Thu, 12 Mar 2009 08:05:08 -0400 Received: (majordomo@vger.kernel.org) by vger.kernel.org id S1752508AbZCLMFI (ORCPT ); Thu, 12 Mar 2009 08:05:08 -0400 Received: from devils.ext.ti.com ([198.47.26.153]:35097 "EHLO devils.ext.ti.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1752031AbZCLMFH convert rfc822-to-8bit (ORCPT ); Thu, 12 Mar 2009 08:05:07 -0400 Received: from dbdp20.itg.ti.com ([172.24.170.38]) by devils.ext.ti.com (8.13.7/8.13.7) with ESMTP id n2CC3pDI029384 for ; Thu, 12 Mar 2009 07:03:58 -0500 Received: from dbde71.ent.ti.com (localhost [127.0.0.1]) by dbdp20.itg.ti.com (8.13.8/8.13.8) with ESMTP id n2CC3nTG016613 for ; Thu, 12 Mar 2009 17:33:49 +0530 (IST) Received: from dbde02.ent.ti.com ([172.24.170.145]) by dbde71.ent.ti.com ([172.24.170.149]) with mapi; Thu, 12 Mar 2009 17:33:50 +0530 From: "Gupta, Ramesh" To: "linux-omap@vger.kernel.org" CC: "Kanigeri, Hari" , "Menon, Nishanth" , "Guzman Lugo, Fernando" Date: Thu, 12 Mar 2009 17:33:10 +0530 Subject: [PATCH 1/1] DSPBRIDGE Fix for auto image load updated Thread-Topic: [PATCH 1/1] DSPBRIDGE Fix for auto image load updated Thread-Index: AcmjCoMDb02YH30bTiy5dGA9NrK0hw== Message-ID: 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 From cab4630ad3b5922179424215f91de4b0a4b5ec8a Mon Sep 17 00:00:00 2001 From: Ramesh Gupta Date: Thu, 12 Mar 2009 17:18:21 +0530 Subject: [PATCH] DSPBRIDGE Fix for auto image load updated This is updated patch to fix the auto image loading while bridgedriver initialization. Signed-off-by: Ramesh Gupta G --- drivers/dsp/bridge/rmgr/drv_interface.c | 30 +++++++++++++++--------------- 1 files changed, 15 insertions(+), 15 deletions(-) diff --git a/drivers/dsp/bridge/rmgr/drv_interface.c b/drivers/dsp/bridge/rmgr/drv_interface.c index 9c82ef4..ee9d63b 100755 --- a/drivers/dsp/bridge/rmgr/drv_interface.c +++ b/drivers/dsp/bridge/rmgr/drv_interface.c @@ -405,7 +405,7 @@ static int __init bridge_init(void) REG_SetValue(NULL, NULL, AUTOSTART, REG_DWORD, (u8 *)&temp, sizeof(temp)); REG_SetValue(NULL, NULL, DEFEXEC, REG_SZ, (u8 *)base_img, - strlen(base_img) + 1); + strlen(base_img) + 1); } else { temp = false; REG_SetValue(NULL, NULL, AUTOSTART, REG_DWORD, (u8 *)&temp, @@ -413,7 +413,7 @@ static int __init bridge_init(void) REG_SetValue(NULL, NULL, DEFEXEC, REG_SZ, (u8 *) "\0", (u32)2); } REG_SetValue(NULL, NULL, NUMPROCS, REG_SZ, (u8 *) num_procs, - strlen(num_procs) + 1); + strlen(num_procs) + 1); if (shm_size >= 0x10000) { /* 64 KB */ initStatus = REG_SetValue(NULL, NULL, SHMSIZE, REG_DWORD, @@ -455,17 +455,8 @@ static int __init bridge_init(void) sizeof(tc_wordswapon)); } if (DSP_SUCCEEDED(initStatus)) { - driverContext = DSP_Init(&initStatus); - if (DSP_FAILED(initStatus)) { - status = -1; - GT_0trace(driverTrace, GT_7CLASS, - "DSP/BIOS Bridge initialization Failed\n"); - } else { - GT_0trace(driverTrace, GT_5CLASS, - "DSP/BIOS Bridge driver loaded\n"); - } #ifdef CONFIG_BRIDGE_DVFS - for (i = 0; i < 5; i++) + for (i = 0; i < 6; i++) pdata->mpu_speed[i] = vdd1_rate_table_bridge[i].rate; clk_handle = clk_get(NULL, "iva2_ck"); @@ -484,6 +475,15 @@ static int __init bridge_init(void) "clk_notifier_register FAIL for iva2_ck \n"); } #endif + driverContext = DSP_Init(&initStatus); + if (DSP_FAILED(initStatus)) { + status = -1; + GT_0trace(driverTrace, GT_7CLASS, + "DSP/BIOS Bridge initialization Failed\n"); + } else { + GT_0trace(driverTrace, GT_5CLASS, + "DSP/BIOS Bridge driver loaded\n"); + } } DBC_Assert(status == 0); @@ -660,11 +660,11 @@ func_cont: (struct DRV_OBJECT *)hDrvObject, &pPctxt); if (pPctxt != NULL) { - /* Return PID instead of process handle */ - hProcess = current->pid; + /* Return PID instead of process handle */ + hProcess = current->pid; DRV_ProcUpdatestate(pPctxt, PROC_RES_ALLOCATED); - DRV_ProcSetPID(pPctxt, hProcess); + DRV_ProcSetPID(pPctxt, hProcess); } #endif