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()
283 int IonController::allocate(alloc_data& data, int usage) in allocate() argument
288 data.uncached = useUncached(usage); in allocate()
291 if(usage & GRALLOC_USAGE_PRIVATE_UI_CONTIG_HEAP) in allocate()
294 if(usage & GRALLOC_USAGE_PRIVATE_SYSTEM_HEAP) in allocate()
297 if(usage & GRALLOC_USAGE_PRIVATE_IOMMU_HEAP) in allocate()
300 if(usage & GRALLOC_USAGE_PROTECTED) { in allocate()
301 if (usage & GRALLOC_USAGE_PRIVATE_MM_HEAP) { in allocate()
309 } else if(usage & GRALLOC_USAGE_PRIVATE_MM_HEAP) { in allocate()
318 if(usage & GRALLOC_USAGE_PRIVATE_CAMERA_HEAP) in allocate()
321 if(usage & GRALLOC_USAGE_PRIVATE_ADSP_HEAP) in allocate()
338 if(ret < 0 && canFallback(usage, in allocate()
365 bool isMacroTileEnabled(int format, int usage) in isMacroTileEnabled() argument
383 if (usage & (GRALLOC_USAGE_SW_READ_MASK | in isMacroTileEnabled()
525 size_t getBufferSizeAndDimensions(int width, int height, int format, int usage, in getBufferSizeAndDimensions() argument
529 int tileEnabled = isMacroTileEnabled(format, usage); in getBufferSizeAndDimensions()
544 void getBufferAttributes(int width, int height, int format, int usage, in getBufferAttributes() argument
547 tileEnabled = isMacroTileEnabled(format, usage); in getBufferAttributes()
627 int alloc_buffer(private_handle_t **pHnd, int w, int h, int format, int usage) in alloc_buffer() argument
636 data.size = getBufferSizeAndDimensions(w, h, format, usage, alignedw, in alloc_buffer()
640 data.uncached = useUncached(usage); in alloc_buffer()
641 int allocFlags = usage; in alloc_buffer()