sdm: Add support for single buffer layers

Add support for single buffer layers. Graphics writes to the same
buffer being read by display. For dumb panels, there should be no
idle mode, smart panels should be put in an auto-refresh mode. Also
such layers cannot be sent to framebuffer.
Change-Id: Id4f15239d8edc258524dfddd4e9d72c67cd2406f
CRs-fixed: 1114808
This commit is contained in:
Ramakant Singh
2017-08-31 12:34:54 +05:30
parent d90a6a43cc
commit ae0570951d
4 changed files with 41 additions and 1 deletions

View File

@@ -809,6 +809,17 @@ gralloc1_error_t BufferManager::Perform(int operation, va_list args) {
}
} break;
case GRALLOC_MODULE_PERFORM_SET_SINGLE_BUFFER_MODE: {
private_handle_t* hnd = va_arg(args, private_handle_t*);
uint32_t *enable = va_arg(args, uint32_t*);
if (private_handle_t::validate(hnd) != 0) {
return GRALLOC1_ERROR_BAD_HANDLE;
}
if (setMetaData(hnd, SET_SINGLE_BUFFER_MODE, enable) != 0) {
return GRALLOC1_ERROR_UNSUPPORTED;
}
} break;
default:
break;
}