Private
Public Access
2
0

uart: add pre uart hook

Signed-off-by: Thomas Ingleby <thomas.c.ingleby@intel.com>
This commit is contained in:
Thomas Ingleby
2014-10-20 18:43:58 +01:00
parent d49f20b7ba
commit 77be6da29c
2 changed files with 6 additions and 0 deletions

View File

@@ -33,6 +33,11 @@
mraa_uart_context
mraa_uart_init(int index)
{
if (advance_func->uart_init_pre != NULL) {
if (advance_func->uart_init_pre(index) != MRAA_SUCCESS)
return NULL;
}
if ( mraa_setup_uart(index) != MRAA_SUCCESS)
return NULL;