Lines Matching full:api
134 * @defgroup uart_interrupt Interrupt-driven UART API
158 * @defgroup uart_async Async UART API
339 /** @brief Driver API structure. */
473 const struct uart_driver_api *api = in z_impl_uart_err_check() local
474 (const struct uart_driver_api *)dev->api; in z_impl_uart_err_check()
476 if (api->err_check == NULL) { in z_impl_uart_err_check()
480 return api->err_check(dev); in z_impl_uart_err_check()
484 * @defgroup uart_polling Polling UART API
511 const struct uart_driver_api *api = in z_impl_uart_poll_in() local
512 (const struct uart_driver_api *)dev->api; in z_impl_uart_poll_in()
514 if (api->poll_in == NULL) { in z_impl_uart_poll_in()
518 return api->poll_in(dev, p_char); in z_impl_uart_poll_in()
536 * @retval -ENOTSUP If API is not enabled.
546 const struct uart_driver_api *api = in z_impl_uart_poll_in_u16() local
547 (const struct uart_driver_api *)dev->api; in z_impl_uart_poll_in_u16()
549 if (api->poll_in_u16 == NULL) { in z_impl_uart_poll_in_u16()
553 return api->poll_in_u16(dev, p_u16); in z_impl_uart_poll_in_u16()
581 const struct uart_driver_api *api = in z_impl_uart_poll_out() local
582 (const struct uart_driver_api *)dev->api; in z_impl_uart_poll_out()
584 api->poll_out(dev, out_char); in z_impl_uart_poll_out()
607 const struct uart_driver_api *api = in z_impl_uart_poll_out_u16() local
608 (const struct uart_driver_api *)dev->api; in z_impl_uart_poll_out_u16()
610 api->poll_out_u16(dev, out_u16); in z_impl_uart_poll_out_u16()
640 const struct uart_driver_api *api = in z_impl_uart_configure() local
641 (const struct uart_driver_api *)dev->api; in z_impl_uart_configure()
643 if (api->configure == NULL) { in z_impl_uart_configure()
646 return api->configure(dev, cfg); in z_impl_uart_configure()
668 const struct uart_driver_api *api = in z_impl_uart_config_get() local
669 (const struct uart_driver_api *)dev->api; in z_impl_uart_config_get()
671 if (api->config_get == NULL) { in z_impl_uart_config_get()
675 return api->config_get(dev, cfg); in z_impl_uart_config_get()
701 * @retval -ENOTSUP If API is not enabled.
708 const struct uart_driver_api *api = in uart_fifo_fill() local
709 (const struct uart_driver_api *)dev->api; in uart_fifo_fill()
711 if (api->fifo_fill == NULL) { in uart_fifo_fill()
715 return api->fifo_fill(dev, tx_data, size); in uart_fifo_fill()
742 * @retval -ENOTSUP If API is not enabled.
749 const struct uart_driver_api *api = in uart_fifo_fill_u16() local
750 (const struct uart_driver_api *)dev->api; in uart_fifo_fill_u16()
752 if (api->fifo_fill_u16 == NULL) { in uart_fifo_fill_u16()
756 return api->fifo_fill_u16(dev, tx_data, size); in uart_fifo_fill_u16()
787 * @retval -ENOTSUP If API is not enabled.
793 const struct uart_driver_api *api = in uart_fifo_read() local
794 (const struct uart_driver_api *)dev->api; in uart_fifo_read()
796 if (api->fifo_read == NULL) { in uart_fifo_read()
800 return api->fifo_read(dev, rx_data, size); in uart_fifo_read()
831 * @retval -ENOTSUP If API is not enabled.
838 const struct uart_driver_api *api = in uart_fifo_read_u16() local
839 (const struct uart_driver_api *)dev->api; in uart_fifo_read_u16()
841 if (api->fifo_read_u16 == NULL) { in uart_fifo_read_u16()
845 return api->fifo_read_u16(dev, rx_data, size); in uart_fifo_read_u16()
864 const struct uart_driver_api *api = in z_impl_uart_irq_tx_enable() local
865 (const struct uart_driver_api *)dev->api; in z_impl_uart_irq_tx_enable()
867 if (api->irq_tx_enable != NULL) { in z_impl_uart_irq_tx_enable()
868 api->irq_tx_enable(dev); in z_impl_uart_irq_tx_enable()
885 const struct uart_driver_api *api = in z_impl_uart_irq_tx_disable() local
886 (const struct uart_driver_api *)dev->api; in z_impl_uart_irq_tx_disable()
888 if (api->irq_tx_disable != NULL) { in z_impl_uart_irq_tx_disable()
889 api->irq_tx_disable(dev); in z_impl_uart_irq_tx_disable()
912 * @retval -ENOTSUP If API is not enabled.
917 const struct uart_driver_api *api = in uart_irq_tx_ready() local
918 (const struct uart_driver_api *)dev->api; in uart_irq_tx_ready()
920 if (api->irq_tx_ready == NULL) { in uart_irq_tx_ready()
924 return api->irq_tx_ready(dev); in uart_irq_tx_ready()
941 const struct uart_driver_api *api = in z_impl_uart_irq_rx_enable() local
942 (const struct uart_driver_api *)dev->api; in z_impl_uart_irq_rx_enable()
944 if (api->irq_rx_enable != NULL) { in z_impl_uart_irq_rx_enable()
945 api->irq_rx_enable(dev); in z_impl_uart_irq_rx_enable()
962 const struct uart_driver_api *api = in z_impl_uart_irq_rx_disable() local
963 (const struct uart_driver_api *)dev->api; in z_impl_uart_irq_rx_disable()
965 if (api->irq_rx_disable != NULL) { in z_impl_uart_irq_rx_disable()
966 api->irq_rx_disable(dev); in z_impl_uart_irq_rx_disable()
990 * @retval -ENOTSUP If API is not enabled.
995 const struct uart_driver_api *api = in uart_irq_tx_complete() local
996 (const struct uart_driver_api *)dev->api; in uart_irq_tx_complete()
998 if (api->irq_tx_complete == NULL) { in uart_irq_tx_complete()
1001 return api->irq_tx_complete(dev); in uart_irq_tx_complete()
1026 * @retval -ENOTSUP If API is not enabled.
1031 const struct uart_driver_api *api = in uart_irq_rx_ready() local
1032 (const struct uart_driver_api *)dev->api; in uart_irq_rx_ready()
1034 if (api->irq_rx_ready == NULL) { in uart_irq_rx_ready()
1037 return api->irq_rx_ready(dev); in uart_irq_rx_ready()
1053 const struct uart_driver_api *api = in z_impl_uart_irq_err_enable() local
1054 (const struct uart_driver_api *)dev->api; in z_impl_uart_irq_err_enable()
1056 if (api->irq_err_enable) { in z_impl_uart_irq_err_enable()
1057 api->irq_err_enable(dev); in z_impl_uart_irq_err_enable()
1074 const struct uart_driver_api *api = in z_impl_uart_irq_err_disable() local
1075 (const struct uart_driver_api *)dev->api; in z_impl_uart_irq_err_disable()
1077 if (api->irq_err_disable) { in z_impl_uart_irq_err_disable()
1078 api->irq_err_disable(dev); in z_impl_uart_irq_err_disable()
1093 * @retval -ENOTSUP If API is not enabled.
1100 const struct uart_driver_api *api = in z_impl_uart_irq_is_pending() local
1101 (const struct uart_driver_api *)dev->api; in z_impl_uart_irq_is_pending()
1103 if (api->irq_is_pending == NULL) { in z_impl_uart_irq_is_pending()
1106 return api->irq_is_pending(dev); in z_impl_uart_irq_is_pending()
1136 * @retval -ENOTSUP If API is not enabled.
1143 const struct uart_driver_api *api = in z_impl_uart_irq_update() local
1144 (const struct uart_driver_api *)dev->api; in z_impl_uart_irq_update()
1146 if (api->irq_update == NULL) { in z_impl_uart_irq_update()
1149 return api->irq_update(dev); in z_impl_uart_irq_update()
1169 * @retval -ENOTSUP If API is not enabled.
1176 const struct uart_driver_api *api = in uart_irq_callback_user_data_set() local
1177 (const struct uart_driver_api *)dev->api; in uart_irq_callback_user_data_set()
1179 if ((api != NULL) && (api->irq_callback_set != NULL)) { in uart_irq_callback_user_data_set()
1180 api->irq_callback_set(dev, cb, user_data); in uart_irq_callback_user_data_set()
1204 * @retval -ENOTSUP If API is not enabled.
1225 * it can be used to detect if the device supports asynchronous API. Remaining
1226 * API does not have that detection.
1234 * @retval -ENOTSUP If API not enabled.
1241 const struct uart_driver_api *api = in uart_callback_set() local
1242 (const struct uart_driver_api *)dev->api; in uart_callback_set()
1244 if (api->callback_set == NULL) { in uart_callback_set()
1248 return api->callback_set(dev, callback, user_data); in uart_callback_set()
1270 * @retval -ENOTSUP If API is not enabled.
1283 const struct uart_driver_api *api = in z_impl_uart_tx() local
1284 (const struct uart_driver_api *)dev->api; in z_impl_uart_tx()
1286 return api->tx(dev, buf, len, timeout); in z_impl_uart_tx()
1309 * @retval -ENOTSUP If API is not enabled.
1322 const struct uart_driver_api *api = in z_impl_uart_tx_u16() local
1323 (const struct uart_driver_api *)dev->api; in z_impl_uart_tx_u16()
1325 return api->tx_u16(dev, buf, len, timeout); in z_impl_uart_tx_u16()
1343 * @retval -ENOTSUP If API is not enabled.
1352 const struct uart_driver_api *api = in z_impl_uart_tx_abort() local
1353 (const struct uart_driver_api *)dev->api; in z_impl_uart_tx_abort()
1355 return api->tx_abort(dev); in z_impl_uart_tx_abort()
1378 * @retval -ENOTSUP If API is not enabled.
1392 const struct uart_driver_api *api = in z_impl_uart_rx_enable() local
1393 (const struct uart_driver_api *)dev->api; in z_impl_uart_rx_enable()
1395 return api->rx_enable(dev, buf, len, timeout); in z_impl_uart_rx_enable()
1421 * @retval -ENOTSUP If API is not enabled.
1434 const struct uart_driver_api *api = in z_impl_uart_rx_enable_u16() local
1435 (const struct uart_driver_api *)dev->api; in z_impl_uart_rx_enable_u16()
1437 return api->rx_enable_u16(dev, buf, len, timeout); in z_impl_uart_rx_enable_u16()
1462 * @retval -ENOTSUP If API is not enabled.
1471 const struct uart_driver_api *api = in uart_rx_buf_rsp() local
1472 (const struct uart_driver_api *)dev->api; in uart_rx_buf_rsp()
1474 return api->rx_buf_rsp(dev, buf, len); in uart_rx_buf_rsp()
1499 * @retval -ENOTSUP If API is not enabled
1508 const struct uart_driver_api *api = in uart_rx_buf_rsp_u16() local
1509 (const struct uart_driver_api *)dev->api; in uart_rx_buf_rsp_u16()
1511 return api->rx_buf_rsp_u16(dev, buf, len); in uart_rx_buf_rsp_u16()
1531 * @retval -ENOTSUP If API is not enabled.
1540 const struct uart_driver_api *api = in z_impl_uart_rx_disable() local
1541 (const struct uart_driver_api *)dev->api; in z_impl_uart_rx_disable()
1543 return api->rx_disable(dev); in z_impl_uart_rx_disable()
1563 * @retval -ENOTSUP If API is not enabled.
1573 const struct uart_driver_api *api = in z_impl_uart_line_ctrl_set() local
1574 (const struct uart_driver_api *)dev->api; in z_impl_uart_line_ctrl_set()
1576 if (api->line_ctrl_set == NULL) { in z_impl_uart_line_ctrl_set()
1579 return api->line_ctrl_set(dev, ctrl, val); in z_impl_uart_line_ctrl_set()
1597 * @retval -ENOTSUP If API is not enabled.
1607 const struct uart_driver_api *api = in z_impl_uart_line_ctrl_get() local
1608 (const struct uart_driver_api *)dev->api; in z_impl_uart_line_ctrl_get()
1610 if (api->line_ctrl_get == NULL) { in z_impl_uart_line_ctrl_get()
1613 return api->line_ctrl_get(dev, ctrl, val); in z_impl_uart_line_ctrl_get()
1634 * @retval -ENOTSUP If API is not enabled.
1643 const struct uart_driver_api *api = in z_impl_uart_drv_cmd() local
1644 (const struct uart_driver_api *)dev->api; in z_impl_uart_drv_cmd()
1646 if (api->drv_cmd == NULL) { in z_impl_uart_drv_cmd()
1649 return api->drv_cmd(dev, cmd, p); in z_impl_uart_drv_cmd()