Lines Matching refs:result
219 cy_rslt_t result = CYHAL_USB_DEV_RSLT_ERR_CLK_CFG; in _cyhal_usb_dev_reserve_pll() local
228 result = cyhal_hwmgr_reserve(rsc); in _cyhal_usb_dev_reserve_pll()
229 if (CY_RSLT_SUCCESS == result) in _cyhal_usb_dev_reserve_pll()
234 if (CY_RSLT_SUCCESS != result) in _cyhal_usb_dev_reserve_pll()
237 return result; in _cyhal_usb_dev_reserve_pll()
253 cy_rslt_t result = Cy_SysClk_PllConfigure(pll, &cfg); in _cyhal_usb_dev_init_pll() local
256 if (result == CY_RSLT_SUCCESS) in _cyhal_usb_dev_init_pll()
257 result = Cy_SysClk_PllEnable(pll, 1000000); in _cyhal_usb_dev_init_pll()
259 if (result == CY_RSLT_SUCCESS) in _cyhal_usb_dev_init_pll()
262 return result; in _cyhal_usb_dev_init_pll()
284 cy_rslt_t result = CYHAL_USB_DEV_RSLT_ERR_CLK_CFG; in _cyhal_usb_dev_hf_clock_setup() local
310 result = CY_RSLT_SUCCESS; in _cyhal_usb_dev_hf_clock_setup()
317 if (CY_RSLT_SUCCESS != result) in _cyhal_usb_dev_hf_clock_setup()
319 result = _cyhal_usb_dev_reserve_pll(&(obj->pll_resource)); in _cyhal_usb_dev_hf_clock_setup()
321 if (CY_RSLT_SUCCESS == result) in _cyhal_usb_dev_hf_clock_setup()
324 …result = _cyhal_usb_dev_init_pll(clock, obj->pll_resource.block_num, _CYHAL_USB_DEV_USB_CLK_HF_FRE… in _cyhal_usb_dev_hf_clock_setup()
331 if (result == CY_RSLT_SUCCESS) in _cyhal_usb_dev_hf_clock_setup()
336 return result; in _cyhal_usb_dev_hf_clock_setup()
341 cy_rslt_t result; in _cyhal_usb_dev_peri_clock_setup() local
349 …result = _cyhal_utils_allocate_clock(&(obj->clock), &(obj->resource), CYHAL_CLOCK_BLOCK_PERIPHERAL… in _cyhal_usb_dev_peri_clock_setup()
351 if (CY_RSLT_SUCCESS == result) in _cyhal_usb_dev_peri_clock_setup()
373 result = (CY_RSLT_SUCCESS == status) ? CY_RSLT_SUCCESS : CYHAL_USB_DEV_RSLT_ERR_CLK_CFG; in _cyhal_usb_dev_peri_clock_setup()
375 return result; in _cyhal_usb_dev_peri_clock_setup()
380 cy_rslt_t result = CYHAL_USB_DEV_RSLT_ERR; in _cyhal_usb_dev_pin_setup() local
390 result = _cyhal_utils_reserve_and_connect(dp_map, CYHAL_PIN_MAP_DRIVE_MODE_USB_USB_DP_PAD); in _cyhal_usb_dev_pin_setup()
391 if (CY_RSLT_SUCCESS == result) in _cyhal_usb_dev_pin_setup()
395 … result = _cyhal_utils_reserve_and_connect(dm_map, CYHAL_PIN_MAP_DRIVE_MODE_USB_USB_DM_PAD); in _cyhal_usb_dev_pin_setup()
396 if (CY_RSLT_SUCCESS == result) in _cyhal_usb_dev_pin_setup()
403 return result; in _cyhal_usb_dev_pin_setup()
435 cy_rslt_t result; in cyhal_usb_dev_init() local
448 result = _cyhal_usb_dev_pin_setup(obj, dp, dm); in cyhal_usb_dev_init()
450 if (CY_RSLT_SUCCESS == result) in cyhal_usb_dev_init()
453 result = _cyhal_usb_dev_hf_clock_setup(obj); in cyhal_usb_dev_init()
454 if (CY_RSLT_SUCCESS == result) in cyhal_usb_dev_init()
457 result = _cyhal_usb_dev_peri_clock_setup(obj, clk); in cyhal_usb_dev_init()
461 if (CY_RSLT_SUCCESS == result) in cyhal_usb_dev_init()
463 result = cyhal_hwmgr_reserve(&(obj->resource)); in cyhal_usb_dev_init()
467 if (CY_RSLT_SUCCESS == result) in cyhal_usb_dev_init()
483 result = CYHAL_USB_DEV_RSLT_ERR; in cyhal_usb_dev_init()
487 if (CY_RSLT_SUCCESS == result) in cyhal_usb_dev_init()
527 if (CY_RSLT_SUCCESS != result) in cyhal_usb_dev_init()
532 return result; in cyhal_usb_dev_init()
672 cy_rslt_t result = CYHAL_USB_DEV_RSLT_ERR; in cyhal_usb_dev_endpoint_read() local
686 result = CY_RSLT_SUCCESS; in cyhal_usb_dev_endpoint_read()
689 return result; in cyhal_usb_dev_endpoint_read()
694 cy_rslt_t result = CYHAL_USB_DEV_RSLT_ERR; in cyhal_usb_dev_endpoint_read_result() local
700 result = (CY_USBFS_DEV_DRV_SUCCESS == Cy_USBFS_Dev_Drv_ReadOutEndpoint(obj->base, in cyhal_usb_dev_endpoint_read_result()
708 return result; in cyhal_usb_dev_endpoint_read_result()
713 cy_rslt_t result = CYHAL_USB_DEV_RSLT_ERR; in cyhal_usb_dev_endpoint_write() local
720 result = (CY_USBFS_DEV_DRV_SUCCESS == Cy_USBFS_Dev_Drv_LoadInEndpoint(obj->base, in cyhal_usb_dev_endpoint_write()
727 return result; in cyhal_usb_dev_endpoint_write()