Add getPointer for USAGE_SHARED allocations.

Change-Id: I13a2af09bbbeec6cc6131b935979ac21c02820be
diff --git a/driver/rsdAllocation.cpp b/driver/rsdAllocation.cpp
index 817c9d8..0d85ebe 100644
--- a/driver/rsdAllocation.cpp
+++ b/driver/rsdAllocation.cpp
@@ -599,7 +599,7 @@
         return;
     }
 
-    rsAssert(src == RS_ALLOCATION_USAGE_SCRIPT);
+    rsAssert(src == RS_ALLOCATION_USAGE_SCRIPT || src == RS_ALLOCATION_USAGE_SHARED);
 
     if (alloc->mHal.state.usageFlags & RS_ALLOCATION_USAGE_GRAPHICS_TEXTURE) {
         UploadToTexture(rsc, alloc);
@@ -614,7 +614,13 @@
     }
 
     if (alloc->mHal.state.usageFlags & RS_ALLOCATION_USAGE_SHARED) {
-        // NOP in CPU driver for now
+
+        if (src == RS_ALLOCATION_USAGE_SHARED) {
+            // just a memory fence for the CPU driver
+            // vendor drivers probably want to flush any dirty cachelines for
+            // this particular Allocation
+            __sync_synchronize();
+        }
     }
 
     drv->uploadDeferred = false;