From: Imre Deak Date: Mon, 5 Apr 2010 21:12:43 +0000 (+0300) Subject: gpu: pvr: remove sPowerStateChangeResource lock X-Git-Url: http://git.openpandora.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=f05224faaab1a7fe8a036ea97974dd77270b898e;p=sgx.git gpu: pvr: remove sPowerStateChangeResource lock This lock was only created / destroyed, but nowhere actually used. Remove it. Signed-off-by: Imre Deak CC: Mark Underwood CC: Mark Riding Reviewed-by: Topi Pohjolainen Reviewed-by: Ville Syrjälä --- diff --git a/pvr/power.c b/pvr/power.c index 1cfeb41..8a0821e 100644 --- a/pvr/power.c +++ b/pvr/power.c @@ -469,11 +469,6 @@ IMG_BOOL PVRSRVIsDevicePowered(u32 ui32DeviceIndex) if (eError != PVRSRV_OK) return IMG_FALSE; - if (OSIsResourceLocked(&psSysData->sPowerStateChangeResource, - KERNEL_ID) || - OSIsResourceLocked(&psSysData->sPowerStateChangeResource, ISR_ID)) - return IMG_FALSE; - psPowerDevice = psSysData->psPowerDeviceList; while (psPowerDevice) { if (psPowerDevice->ui32DeviceIndex == ui32DeviceIndex) diff --git a/pvr/pvrsrv.c b/pvr/pvrsrv.c index 411d9a0..2a11fe6 100644 --- a/pvr/pvrsrv.c +++ b/pvr/pvrsrv.c @@ -140,10 +140,6 @@ enum PVRSRV_ERROR PVRSRVInit(struct SYS_DATA *psSysData) if (eError != PVRSRV_OK) goto Error; - eError = OSCreateResource(&psSysData->sPowerStateChangeResource); - if (eError != PVRSRV_OK) - goto Error; - psSysData->eCurrentPowerState = PVRSRV_POWER_STATE_D0; psSysData->eFailedPowerState = PVRSRV_POWER_Unspecified; diff --git a/pvr/syscommon.h b/pvr/syscommon.h index e576fce..9d695bc 100644 --- a/pvr/syscommon.h +++ b/pvr/syscommon.h @@ -57,7 +57,6 @@ struct SYS_DATA { struct SYS_DEVICE_ID sDeviceID[SYS_DEVICE_COUNT]; struct PVRSRV_DEVICE_NODE *psDeviceNodeList; struct PVRSRV_POWER_DEV *psPowerDeviceList; - struct PVRSRV_RESOURCE sPowerStateChangeResource; enum PVR_POWER_STATE eCurrentPowerState; enum PVR_POWER_STATE eFailedPowerState; u32 ui32CurrentOSPowerState; @@ -153,7 +152,6 @@ static inline enum PVRSRV_ERROR SysInitialiseCommon(struct SYS_DATA *psSysData) static inline void SysDeinitialiseCommon(struct SYS_DATA *psSysData) { PVRSRVDeInit(psSysData); - OSDestroyResource(&psSysData->sPowerStateChangeResource); } #if !(defined(NO_HARDWARE) && defined(__KERNEL__))