display: gralloc: zero out the alloc'd ion buffer

Change-Id: Ib92863cf03f284eb24729bbad449795e7bd47d44
This commit is contained in:
Naseer Ahmed 2011-12-01 23:26:28 -08:00
parent e2de425bc4
commit e5a9508bad

View File

@ -139,10 +139,9 @@ int IonAlloc::alloc_buffer(alloc_data& data)
close(ionSyncFd);
ionSyncFd = FD_INIT;
// Not doing memset for ION, uncomment if needed
// memset(base, 0, ionAllocData.len);
memset(base, 0, ionAllocData.len);
// Clean cache after memset
// clean_buffer(base, data.size, data.offset, fd_data.fd);
clean_buffer(base, data.size, data.offset, fd_data.fd);
data.base = base;
data.fd = fd_data.fd;
ioctl(mIonFd, ION_IOC_FREE, &handle_data);