Start splitting allocation into hal and core.

Change-Id: Ic506abb0469238cb0471eb1401cfcb7b2fbbe4bb
diff --git a/libs/rs/rsFBOCache.cpp b/libs/rs/rsFBOCache.cpp
index 31a51b7..6960ef2 100644
--- a/libs/rs/rsFBOCache.cpp
+++ b/libs/rs/rsFBOCache.cpp
@@ -51,13 +51,6 @@
             LOGE("Invalid Color Target");
             return;
         }
-        if (a->getIsTexture()) {
-            if (a->getTextureID() == 0) {
-                a->deferredUploadToTexture(rsc);
-            }
-        } else if (a->getRenderTargetID() == 0) {
-            a->deferredAllocateRenderTarget(rsc);
-        }
     }
     mHal.state.colorTargets[slot].set(a);
     mDirty = true;
@@ -69,13 +62,6 @@
             LOGE("Invalid Depth Target");
             return;
         }
-        if (a->getIsTexture()) {
-            if (a->getTextureID() == 0) {
-                a->deferredUploadToTexture(rsc);
-            }
-        } else if (a->getRenderTargetID() == 0) {
-            a->deferredAllocateRenderTarget(rsc);
-        }
     }
     mHal.state.depthTarget.set(a);
     mDirty = true;
@@ -95,12 +81,12 @@
     }
 
     if (mHal.state.depthTarget.get() != NULL) {
-        mHal.state.depthTarget->uploadCheck(rsc);
+        mHal.state.depthTarget->syncAll(rsc, RS_ALLOCATION_USAGE_SCRIPT);
     }
 
     for (uint32_t i = 0; i < mHal.state.colorTargetsCount; i ++) {
         if (mHal.state.colorTargets[i].get() != NULL) {
-            mHal.state.colorTargets[i]->uploadCheck(rsc);
+            mHal.state.colorTargets[i]->syncAll(rsc, RS_ALLOCATION_USAGE_SCRIPT);
         }
     }