Lines Matching refs:endpoint
47 …usb_device_khci_state_struct_t *khciState, uint8_t endpoint, uint8_t direction, uint8_t *buffer, u…
109 …usb_device_khci_state_struct_t *khciState, uint8_t endpoint, uint8_t direction, uint8_t *buffer, u…
111 uint32_t index = ((uint32_t)endpoint << 1U) | (uint32_t)direction;
121 USB_KHCI_BDT_SET_ADDRESS((uint32_t)khciState->bdt, endpoint, direction,
126 …(uint32_t)khciState->bdt, endpoint, direction, khciState->endpointState[index].stateUnion.stateBit…
280 uint8_t endpoint = (epInit->endpointAddress & USB_ENDPOINT_NUMBER_MASK); in USB_DeviceKhciEndpointInit() local
283 uint8_t index = ((uint8_t)((uint32_t)endpoint << 1U)) | (uint8_t)direction; in USB_DeviceKhciEndpointInit()
300 khciState->registerBase->ENDPOINT[endpoint].ENDPT |= USB_ENDPT_EPHSHK_MASK; in USB_DeviceKhciEndpointInit()
313 khciState->registerBase->ENDPOINT[endpoint].ENDPT |= in USB_DeviceKhciEndpointInit()
321 if (endpoint < 8U) in USB_DeviceKhciEndpointInit()
323 khciState->registerBase->STALL_IL_DIS |= (uint8_t)(1UL << endpoint); in USB_DeviceKhciEndpointInit()
326 else if ((endpoint >= 8U) && (endpoint < 16U)) in USB_DeviceKhciEndpointInit()
328 khciState->registerBase->STALL_IH_DIS |= (uint8_t)(1UL << (endpoint - 8U)); in USB_DeviceKhciEndpointInit()
338 if (endpoint < 8U) in USB_DeviceKhciEndpointInit()
340 khciState->registerBase->STALL_OL_DIS |= (uint8_t)(1UL << endpoint); in USB_DeviceKhciEndpointInit()
343 else if ((endpoint >= 8U) && (endpoint < 16U)) in USB_DeviceKhciEndpointInit()
345 khciState->registerBase->STALL_OH_DIS |= (uint8_t)(1UL << (endpoint - 8U)); in USB_DeviceKhciEndpointInit()
356 khciState->registerBase->STALL_IL_DIS &= (uint8_t)(~(1UL << endpoint)); in USB_DeviceKhciEndpointInit()
357 khciState->registerBase->STALL_OL_DIS &= (uint8_t)(~(1UL << endpoint)); in USB_DeviceKhciEndpointInit()
366 if ((USB_CONTROL_ENDPOINT == endpoint) && (USB_OUT == direction)) in USB_DeviceKhciEndpointInit()
387 uint8_t endpoint = (ep & USB_ENDPOINT_NUMBER_MASK); in USB_DeviceKhciEndpointDeinit() local
390 uint8_t index = ((uint8_t)((uint32_t)endpoint << 1U)) | (uint8_t)direction; in USB_DeviceKhciEndpointDeinit()
403 khciState->registerBase->ENDPOINT[endpoint].ENDPT = 0x00U; in USB_DeviceKhciEndpointDeinit()
423 uint8_t endpoint = ep & USB_ENDPOINT_NUMBER_MASK; in USB_DeviceKhciEndpointStall() local
426 uint8_t index = ((uint8_t)((uint32_t)endpoint << 1U)) | (uint8_t)direction; in USB_DeviceKhciEndpointStall()
429 if (USB_CONTROL_ENDPOINT == endpoint) in USB_DeviceKhciEndpointStall()
450 …(uint32_t)khciState->bdt, endpoint, 0, khciState->endpointState[0].stateUnion.stateBitField.bdtOdd, in USB_DeviceKhciEndpointStall()
457 …(uint32_t)khciState->bdt, endpoint, 1, khciState->endpointState[1].stateUnion.stateBitField.bdtOdd, in USB_DeviceKhciEndpointStall()
479 if (USB_CONTROL_ENDPOINT != endpoint) in USB_DeviceKhciEndpointStall()
484 if (endpoint < 8U) in USB_DeviceKhciEndpointStall()
486 khciState->registerBase->STALL_IL_DIS &= (uint8_t)(~(1UL << endpoint)); in USB_DeviceKhciEndpointStall()
489 else if (endpoint >= 8U) in USB_DeviceKhciEndpointStall()
491 khciState->registerBase->STALL_IH_DIS &= (uint8_t)(~(1UL << (endpoint - 8U))); in USB_DeviceKhciEndpointStall()
501 if (endpoint < 8U) in USB_DeviceKhciEndpointStall()
503 khciState->registerBase->STALL_OL_DIS &= (uint8_t)(~(1UL << endpoint)); in USB_DeviceKhciEndpointStall()
506 else if (endpoint >= 8U) in USB_DeviceKhciEndpointStall()
508 khciState->registerBase->STALL_OH_DIS &= (uint8_t)(~(1UL << (endpoint - 8U))); in USB_DeviceKhciEndpointStall()
522 (uint32_t)khciState->bdt, endpoint, direction, in USB_DeviceKhciEndpointStall()
547 uint8_t endpoint = ep & USB_ENDPOINT_NUMBER_MASK; in USB_DeviceKhciEndpointUnstall() local
550 uint8_t index = ((uint8_t)((uint32_t)endpoint << 1U)) | (uint8_t)direction; in USB_DeviceKhciEndpointUnstall()
562 (uint32_t)khciState->bdt, endpoint, direction, i, in USB_DeviceKhciEndpointUnstall()
569 khciState->registerBase->ENDPOINT[endpoint].ENDPT &= (uint8_t)(~USB_ENDPT_EPSTALL_MASK); in USB_DeviceKhciEndpointUnstall()
571 if (USB_CONTROL_ENDPOINT != endpoint) in USB_DeviceKhciEndpointUnstall()
575 if (endpoint < 8U) in USB_DeviceKhciEndpointUnstall()
577 khciState->registerBase->STALL_IL_DIS |= (uint8_t)(1UL << endpoint); in USB_DeviceKhciEndpointUnstall()
580 else if (endpoint >= 8U) in USB_DeviceKhciEndpointUnstall()
582 khciState->registerBase->STALL_IH_DIS |= (uint8_t)(1UL << (endpoint - 8U)); in USB_DeviceKhciEndpointUnstall()
592 if (endpoint < 8U) in USB_DeviceKhciEndpointUnstall()
594 khciState->registerBase->STALL_OL_DIS |= (uint8_t)(1UL << endpoint); in USB_DeviceKhciEndpointUnstall()
597 else if (endpoint >= 8U) in USB_DeviceKhciEndpointUnstall()
599 khciState->registerBase->STALL_OH_DIS |= (uint8_t)(1UL << (endpoint - 8U)); in USB_DeviceKhciEndpointUnstall()
609 if ((USB_CONTROL_ENDPOINT != endpoint)) in USB_DeviceKhciEndpointUnstall()
623 if ((USB_CONTROL_ENDPOINT == endpoint) && (USB_OUT == direction)) in USB_DeviceKhciEndpointUnstall()
649 uint8_t endpoint; in USB_DeviceKhciInterruptTokenDone() local
657 endpoint = (stateRegister & USB_STAT_ENDP_MASK) >> USB_STAT_ENDP_SHIFT; in USB_DeviceKhciInterruptTokenDone()
669 control = USB_KHCI_BDT_GET_CONTROL((uint32_t)khciState->bdt, endpoint, direction, bdtOdd); in USB_DeviceKhciInterruptTokenDone()
672 …bdtBuffer = (uint8_t *)USB_KHCI_BDT_GET_ADDRESS((uint32_t)khciState->bdt, endpoint, direction, bdt… in USB_DeviceKhciInterruptTokenDone()
682 index = ((uint8_t)((uint32_t)endpoint << 1U)) | (uint8_t)direction; in USB_DeviceKhciInterruptTokenDone()
728 if (USB_CONTROL_ENDPOINT == endpoint) in USB_DeviceKhciInterruptTokenDone()
743 … USB_DeviceKhciEndpointTransfer(khciState, endpoint, USB_IN, (uint8_t *)NULL, 0U)) in USB_DeviceKhciInterruptTokenDone()
750 … (void)USB_DeviceKhciEndpointTransfer(khciState, endpoint, USB_IN, (uint8_t *)NULL, 0U); in USB_DeviceKhciInterruptTokenDone()
759 … USB_DeviceKhciEndpointTransfer(khciState, endpoint, USB_IN, (uint8_t *)NULL, 0U)) in USB_DeviceKhciInterruptTokenDone()
766 … (void)USB_DeviceKhciEndpointTransfer(khciState, endpoint, USB_IN, (uint8_t *)NULL, 0U); in USB_DeviceKhciInterruptTokenDone()
779 if (kStatus_USB_Success != USB_DeviceKhciSend(khciState, endpoint | (USB_IN << 0x07U), in USB_DeviceKhciInterruptTokenDone()
788 (void)USB_DeviceKhciSend(khciState, endpoint | (USB_IN << 0x07U), in USB_DeviceKhciInterruptTokenDone()
796 if ((USB_CONTROL_ENDPOINT == endpoint) && (0U == length)) in USB_DeviceKhciInterruptTokenDone()
806 USB_KHCI_BDT_GET_ADDRESS((uint32_t)khciState->bdt, endpoint, USB_OUT, in USB_DeviceKhciInterruptTokenDone()
822 if ((USB_CONTROL_ENDPOINT == endpoint) && (0U != isSetup)) in USB_DeviceKhciInterruptTokenDone()
850 … if (kStatus_USB_Success != USB_DeviceKhciRecv(khciState, (endpoint) | (USB_OUT << 0x07U), in USB_DeviceKhciInterruptTokenDone()
859 (void)USB_DeviceKhciRecv(khciState, (endpoint) | (USB_OUT << 0x07U), in USB_DeviceKhciInterruptTokenDone()
868 message.code = (endpoint) | (uint8_t)(((uint32_t)direction << 0x07U)); in USB_DeviceKhciInterruptTokenDone()