Searched refs:uhs_ctx (Results 1 – 6 of 6) sorted by relevance
14 int usbh_init(struct usbh_contex *uhs_ctx) in usbh_init() argument18 k_mutex_lock(&uhs_ctx->mutex, K_FOREVER); in usbh_init()20 if (!device_is_ready(uhs_ctx->dev)) { in usbh_init()26 if (uhc_is_initialized(uhs_ctx->dev)) { in usbh_init()32 ret = usbh_init_device_intl(uhs_ctx); in usbh_init()35 k_mutex_unlock(&uhs_ctx->mutex); in usbh_init()39 int usbh_enable(struct usbh_contex *uhs_ctx) in usbh_enable() argument43 k_mutex_lock(&uhs_ctx->mutex, K_FOREVER); in usbh_enable()45 if (!uhc_is_initialized(uhs_ctx->dev)) { in usbh_enable()51 if (uhc_is_enabled(uhs_ctx->dev)) { in usbh_enable()[all …]
104 STRUCT_SECTION_FOREACH(usbh_contex, uhs_ctx) { in usbh_thread()105 if (uhs_ctx->dev == event.dev) { in usbh_thread()106 usbh_event_handler(uhs_ctx, &event); in usbh_thread()112 int usbh_init_device_intl(struct usbh_contex *const uhs_ctx) in usbh_init_device_intl() argument116 ret = uhc_init(uhs_ctx->dev, usbh_event_carrier); in usbh_init_device_intl()
24 USBH_CONTROLLER_DEFINE(uhs_ctx, DEVICE_DT_GET(DT_NODELABEL(zephyr_uhc0)));85 return uhc_ep_enqueue(uhs_ctx.dev, xfer); in cmd_bulk()373 err = uhc_bus_suspend(uhs_ctx.dev); in cmd_bus_suspend()388 err = uhc_bus_resume(uhs_ctx.dev); in cmd_bus_resume()395 err = uhc_sof_enable(uhs_ctx.dev); in cmd_bus_resume()408 err = uhc_bus_reset(uhs_ctx.dev); in cmd_bus_reset()415 err = uhc_sof_enable(uhs_ctx.dev); in cmd_bus_reset()428 udev = usbh_device_get_any(&uhs_ctx); in cmd_usbh_init()430 err = usbh_init(&uhs_ctx); in cmd_usbh_init()447 err = usbh_enable(&uhs_ctx); in cmd_usbh_enable()[all …]
13 int usbh_init_device_intl(struct usbh_contex *const uhs_ctx);
78 int (*request)(struct usbh_contex *const uhs_ctx,81 int (*connected)(struct usbh_contex *const uhs_ctx);83 int (*removed)(struct usbh_contex *const uhs_ctx);85 int (*rwup)(struct usbh_contex *const uhs_ctx);87 int (*suspended)(struct usbh_contex *const uhs_ctx);89 int (*resumed)(struct usbh_contex *const uhs_ctx);105 int usbh_init(struct usbh_contex *uhs_ctx);116 int usbh_enable(struct usbh_contex *uhs_ctx);127 int usbh_disable(struct usbh_contex *uhs_ctx);138 int usbh_shutdown(struct usbh_contex *const uhs_ctx);
38 USBH_CONTROLLER_DEFINE(uhs_ctx, DEVICE_DT_GET(DT_NODELABEL(zephyr_uhc0)));47 udev = usbh_device_get_any(&uhs_ctx); in ZTEST()76 udev = usbh_device_get_any(&uhs_ctx); in ZTEST()99 err = usbh_init(&uhs_ctx); in usb_test_enable()102 err = usbh_enable(&uhs_ctx); in usb_test_enable()105 err = uhc_bus_reset(uhs_ctx.dev); in usb_test_enable()108 err = uhc_bus_resume(uhs_ctx.dev); in usb_test_enable()111 err = uhc_sof_enable(uhs_ctx.dev); in usb_test_enable()163 udev = usbh_device_get_any(&uhs_ctx); in usb_test_enable()181 err = usbh_disable(&uhs_ctx); in usb_test_shutdown()