handle = dlopen(path, RTLD_NOW);
if (handle == NULL) {
char const *err_str = dlerror();
- LOGE("load: module=%s\n%s", path, err_str?err_str:"unknown");
+ ALOGE("load: module=%s\n%s", path, err_str?err_str:"unknown");
status = -EINVAL;
goto done;
}
const char *sym = HAL_MODULE_INFO_SYM_AS_STR;
hmi = (struct hw_module_t *)dlsym(handle, sym);
if (hmi == NULL) {
- LOGE("load: couldn't find symbol %s", sym);
+ ALOGE("load: couldn't find symbol %s", sym);
status = -EINVAL;
goto done;
}
/* Check that the id matches */
if (strcmp(id, hmi->id) != 0) {
- LOGE("load: id=%s != hmi->id=%s", id, hmi->id);
+ ALOGE("load: id=%s != hmi->id=%s", id, hmi->id);
status = -EINVAL;
goto done;
}
m->info.activate = FB_ACTIVATE_VBL;
m->info.yoffset = offset / m->finfo.line_length;
if (ioctl(m->framebuffer->fd, FBIOPUT_VSCREENINFO, &m->info) == -1) {
- LOGE("FBIOPUT_VSCREENINFO failed");
+ ALOGE("FBIOPUT_VSCREENINFO failed");
m->base.unlock(&m->base, buffer);
return -errno;
}
void* vaddr = mmap(0, fbSize, PROT_READ|PROT_WRITE, MAP_SHARED, fd, 0);
if (vaddr == MAP_FAILED) {
- LOGE("Error mapping the framebuffer (%s)", strerror(errno));
+ ALOGE("Error mapping the framebuffer (%s)", strerror(errno));
return -errno;
}
module->framebuffer->base = intptr_t(vaddr);
fd = ashmem_create_region("gralloc-buffer", size);
if (fd < 0) {
- LOGE("couldn't create ashmem (%s)", strerror(-errno));
+ ALOGE("couldn't create ashmem (%s)", strerror(-errno));
err = -errno;
}
}
}
- LOGE_IF(err, "gralloc failed err=%s", strerror(-err));
+ ALOGE_IF(err, "gralloc failed err=%s", strerror(-err));
return err;
}
h->numInts != sNumInts || h->numFds != sNumFds ||
hnd->magic != sMagic)
{
- LOGE("invalid gralloc handle (at %p)", h);
+ ALOGE("invalid gralloc handle (at %p)", h);
return -EINVAL;
}
return 0;
void* mappedAddress = mmap(0, size,
PROT_READ|PROT_WRITE, MAP_SHARED, hnd->fd, 0);
if (mappedAddress == MAP_FAILED) {
- LOGE("Could not mmap %s", strerror(errno));
+ ALOGE("Could not mmap %s", strerror(errno));
return -errno;
}
hnd->base = intptr_t(mappedAddress) + hnd->offset;
size_t size = hnd->size;
//ALOGD("unmapping from %p, size=%d", base, size);
if (munmap(base, size) < 0) {
- LOGE("Could not unmap %s", strerror(errno));
+ ALOGE("Could not unmap %s", strerror(errno));
}
}
hnd->base = 0;