Start splitting allocation into hal and core.

Change-Id: Ic506abb0469238cb0471eb1401cfcb7b2fbbe4bb
diff --git a/libs/rs/rsProgramFragment.cpp b/libs/rs/rsProgramFragment.cpp
index e40fc7b..0823d82 100644
--- a/libs/rs/rsProgramFragment.cpp
+++ b/libs/rs/rsProgramFragment.cpp
@@ -67,7 +67,6 @@
             rsc->setError(RS_ERROR_BAD_SHADER, "No texture bound");
             continue;
         }
-        mHal.state.textures[ct]->uploadCheck(rsc);
     }
 
     rsc->mHal.funcs.fragment.setActive(rsc, this);
@@ -109,7 +108,8 @@
     tmp[0] = RS_PROGRAM_PARAM_CONSTANT;
     tmp[1] = (uint32_t)inputType;
 
-    Allocation *constAlloc = new Allocation(rsc, inputType, RS_ALLOCATION_USAGE_SCRIPT | RS_ALLOCATION_USAGE_GRAPHICS_CONSTANTS);
+    Allocation *constAlloc = Allocation::createAllocation(rsc, inputType,
+                              RS_ALLOCATION_USAGE_SCRIPT | RS_ALLOCATION_USAGE_GRAPHICS_CONSTANTS);
     ProgramFragment *pf = new ProgramFragment(rsc, shaderString.string(),
                                               shaderString.length(), tmp, 2);
     pf->bindAllocation(rsc, constAlloc, 0);