Lines Matching refs:usage

57 static bool canFallback(int usage, bool triedSystem)  in canFallback()  argument
71 if(usage & (GRALLOC_HEAP_MASK | GRALLOC_USAGE_PROTECTED)) in canFallback()
73 if(usage & (GRALLOC_HEAP_MASK | GRALLOC_USAGE_PRIVATE_EXTERNAL_ONLY)) in canFallback()
79 static bool useUncached(int usage) in useUncached() argument
81 if (usage & GRALLOC_USAGE_PRIVATE_UNCACHED) in useUncached()
83 if(((usage & GRALLOC_USAGE_SW_WRITE_MASK) == GRALLOC_USAGE_SW_WRITE_RARELY) in useUncached()
84 ||((usage & GRALLOC_USAGE_SW_READ_MASK) == GRALLOC_USAGE_SW_READ_RARELY)) in useUncached()
282 int IonController::allocate(alloc_data& data, int usage) in allocate() argument
287 data.uncached = useUncached(usage); in allocate()
290 if(usage & GRALLOC_USAGE_PRIVATE_UI_CONTIG_HEAP) in allocate()
293 if(usage & GRALLOC_USAGE_PRIVATE_SYSTEM_HEAP) in allocate()
296 if(usage & GRALLOC_USAGE_PRIVATE_IOMMU_HEAP) in allocate()
299 if(usage & GRALLOC_USAGE_PROTECTED) { in allocate()
300 if (usage & GRALLOC_USAGE_PRIVATE_MM_HEAP) { in allocate()
308 } else if(usage & GRALLOC_USAGE_PRIVATE_MM_HEAP) { in allocate()
317 if(usage & GRALLOC_USAGE_PRIVATE_CAMERA_HEAP) in allocate()
320 if(usage & GRALLOC_USAGE_PRIVATE_ADSP_HEAP) in allocate()
337 if(ret < 0 && canFallback(usage, in allocate()
364 bool isMacroTileEnabled(int format, int usage) in isMacroTileEnabled() argument
382 if (usage & (GRALLOC_USAGE_SW_READ_MASK | in isMacroTileEnabled()
521 int usage, int& alignedw, int &alignedh) in getBufferSizeAndDimensions() argument
524 int tileEnabled = isMacroTileEnabled(format, usage); in getBufferSizeAndDimensions()
539 void getBufferAttributes(int width, int height, int format, int usage, in getBufferAttributes() argument
542 tileEnabled = isMacroTileEnabled(format, usage); in getBufferAttributes()
621 int alloc_buffer(private_handle_t **pHnd, int w, int h, int format, int usage) in alloc_buffer() argument
630 data.size = getBufferSizeAndDimensions(w, h, format, usage, alignedw, in alloc_buffer()
634 data.uncached = useUncached(usage); in alloc_buffer()
635 int allocFlags = usage; in alloc_buffer()