]> git.karo-electronics.de Git - karo-tx-linux.git/commitdiff
ENGR00277333 gpu: Enable OT limitation for gc880
authorLoren HUANG <b02279@freescale.com>
Wed, 4 Sep 2013 07:58:04 +0000 (15:58 +0800)
committerLothar Waßmann <LW@KARO-electronics.de>
Mon, 16 Jun 2014 15:45:53 +0000 (17:45 +0200)
Enable OT limitation for gc880, without this limitation
3D core may stall system bus when it is running at a very low clock.

Signed-off-by: Loren HUANG <b02279@freescale.com>
Acked-by: Shawn Guo
drivers/mxc/gpu-viv/arch/XAQ2/hal/kernel/gc_hal_kernel_hardware.c

index 00f383993ffe5c067a02c0485125861f02eb58ec..64929350f567c97d7faefa7321e11b61a132922d 100644 (file)
@@ -728,6 +728,13 @@ gckHARDWARE_Construct(
 
     default:
         hardware->type = gcvHARDWARE_3D;
+        if(hardware->identity.chipModel == gcv880)
+        {
+            /*set outstanding limit*/
+            gcmkONERROR(gckOS_ReadRegisterEx(Os, Core, 0x00414, &axi_ot));
+            axi_ot = (axi_ot & (~0xFF)) | 0x10;
+            gcmkONERROR(gckOS_WriteRegisterEx(Os, Core, 0x00414, axi_ot));
+        }
 
         if ((((((gctUINT32) (hardware->identity.chipFeatures)) >> (0 ? 9:9)) & ((gctUINT32) ((((1 ? 9:9) - (0 ? 9:9) + 1) == 32) ? ~0 : (~(~0 << ((1 ? 9:9) - (0 ? 9:9) + 1)))))) ))
         {
@@ -1198,6 +1205,14 @@ gckHARDWARE_InitializeHardware(
 #endif
 
     /* Limit 2D outstanding request. */
+    if(Hardware->identity.chipModel == gcv880)
+    {
+        gctUINT32 axi_ot;
+        gcmkONERROR(gckOS_ReadRegisterEx(Hardware->os, Hardware->core, 0x00414, &axi_ot));
+        axi_ot = (axi_ot & (~0xFF)) | 0x10;
+        gcmkONERROR(gckOS_WriteRegisterEx(Hardware->os, Hardware->core, 0x00414, axi_ot));
+    }
+
     if ((Hardware->identity.chipModel == gcv320)
         && ((Hardware->identity.chipRevision == 0x5007)
         || (Hardware->identity.chipRevision == 0x5220)))