From 173ccc26ec04298fd476ef25f8ffea7d691fcc47 Mon Sep 17 00:00:00 2001 From: Sundar Raman Date: Sun, 28 Aug 2011 19:25:55 -0700 Subject: CameraHAL: Adds ION support to MemoryManager MemoryManager has been updated to allocate from ION carveout instead of 1D TILER via MemMgr. Note: 2D TILER allocation is not supported as it is not needed currently. We may have to add support for it in the future. Change-Id: I3507da9a26ef4cadfda26ee21c8e12bbce515656 Signed-off-by: Sundar Raman --- camera/CameraHal.cpp | 2 ++ 1 file changed, 2 insertions(+) (limited to 'camera/CameraHal.cpp') diff --git a/camera/CameraHal.cpp b/camera/CameraHal.cpp index 8f67058..5af0825 100644 --- a/camera/CameraHal.cpp +++ b/camera/CameraHal.cpp @@ -1019,6 +1019,7 @@ status_t CameraHal::allocPreviewDataBufs(size_t size, size_t bufferCount) if ( NO_ERROR == ret ) { + bytes = ((bytes+4095)/4096)*4096; mPreviewDataBufs = (int32_t *)mMemoryManager->allocateBuffer(0, 0, NULL, bytes, bufferCount); CAMHAL_LOGDB("Size of Preview data buffer = %d", bytes); @@ -1101,6 +1102,7 @@ status_t CameraHal::allocImageBufs(unsigned int width, unsigned int height, size if ( NO_ERROR == ret ) { + bytes = ((bytes+4095)/4096)*4096; mImageBufs = (int32_t *)mMemoryManager->allocateBuffer(0, 0, previewFormat, bytes, bufferCount); CAMHAL_LOGDB("Size of Image cap buffer = %d", bytes); -- cgit v1.1