-
Notifications
You must be signed in to change notification settings - Fork 34
USB Host remote wakeup #298
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
base: feat/usb_host_suspend
Are you sure you want to change the base?
Conversation
port->flags.conn_dev_ena = 0; | ||
break; | ||
} | ||
case USB_DWC_HAL_PORT_EVENT_REMOTE_WAKEUP: { |
Check failure
Code scanning / clang-tidy
duplicate case value: 'USB_DWC_HAL_PORT_EVENT_DISABLED' and 'HCD_PORT_EVENT_REMOTE_WAKEUP' both equal '5' [clang-diagnostic-error] Error
port->flags.conn_dev_ena = 0; | ||
break; | ||
} | ||
case USB_DWC_HAL_PORT_EVENT_REMOTE_WAKEUP: { |
Check failure
Code scanning / clang-tidy
use of undeclared identifier 'USB_DWC_HAL_PORT_EVENT_REMOTE_WAKEUP'; did you mean 'HCD_PORT_EVENT_REMOTE_WAKEUP'? [clang-diagnostic-error] Error
ret = ESP_ERR_INVALID_STATE; | ||
goto exit; | ||
} | ||
hprt = usb_dwc_hal_port_get_hprt_val(port->hal); |
Check failure
Code scanning / clang-tidy
use of undeclared identifier 'usb_dwc_hal_port_get_hprt_val' [clang-diagnostic-error] Error
goto exit; | ||
} | ||
hprt = usb_dwc_hal_port_get_hprt_val(port->hal); | ||
gintsts = usb_dwc_hal_port_get_gintsts_val(port->hal); |
Check failure
Code scanning / clang-tidy
use of undeclared identifier 'usb_dwc_hal_port_get_gintsts_val'; did you mean 'usb_dwc_hal_port_get_conn_speed'? [clang-diagnostic-error] Error
} | ||
hprt = usb_dwc_hal_port_get_hprt_val(port->hal); | ||
gintsts = usb_dwc_hal_port_get_gintsts_val(port->hal); | ||
state = usb_dwc_hal_hprt_get_pwr_line_status(port->hal); |
Check failure
Code scanning / clang-tidy
use of undeclared identifier 'usb_dwc_hal_hprt_get_pwr_line_status'; did you mean 'usb_dwc_ll_hprt_get_pwr_line_status'? [clang-diagnostic-error] Error
vTaskDelay(pdMS_TO_TICKS(100)); | ||
|
||
// Res3 (Wkp3) | ||
hprt = usb_dwc_hal_port_get_hprt_val(port->hal); |
Check failure
Code scanning / clang-tidy
use of undeclared identifier 'usb_dwc_hal_port_get_hprt_val' [clang-diagnostic-error] Error
|
||
// Res3 (Wkp3) | ||
hprt = usb_dwc_hal_port_get_hprt_val(port->hal); | ||
gintsts = usb_dwc_hal_port_get_gintsts_val(port->hal); |
Check failure
Code scanning / clang-tidy
use of undeclared identifier 'usb_dwc_hal_port_get_gintsts_val'; did you mean 'usb_dwc_hal_port_get_conn_speed'? [clang-diagnostic-error] Error
// Res3 (Wkp3) | ||
hprt = usb_dwc_hal_port_get_hprt_val(port->hal); | ||
gintsts = usb_dwc_hal_port_get_gintsts_val(port->hal); | ||
state = usb_dwc_hal_hprt_get_pwr_line_status(port->hal); |
Check failure
Code scanning / clang-tidy
use of undeclared identifier 'usb_dwc_hal_hprt_get_pwr_line_status'; did you mean 'usb_dwc_ll_hprt_get_pwr_line_status'? [clang-diagnostic-error] Error
ctrl_transfer->context = (void *)transfer_done; | ||
|
||
// Copy setup packet | ||
memcpy(ctrl_transfer->data_buffer, setup_packet, sizeof(usb_setup_packet_t)); |
Check warning
Code scanning / clang-tidy
Call to function 'memcpy' is insecure as it does not provide security checks introduced in the C11 standard. Replace with analogous functions that support length arguments or provides boundary checks such as 'memcpy_s' in case of C11 [clang-analyzer-security.insecureAPI.DeprecatedOrUnsafeBufferHandling] Warning
|
||
// For IN transfers, copy data back to caller buffer | ||
if (data_buf && (data_len > 0)) { | ||
memcpy(data_buf, ctrl_transfer->data_buffer + sizeof(usb_setup_packet_t), data_len); |
Check warning
Code scanning / clang-tidy
Call to function 'memcpy' is insecure as it does not provide security checks introduced in the C11 standard. Replace with analogous functions that support length arguments or provides boundary checks such as 'memcpy_s' in case of C11 [clang-analyzer-security.insecureAPI.DeprecatedOrUnsafeBufferHandling] Warning
3cd4cc8
to
d6209d7
Compare
8b08fa0
to
3aa7eba
Compare
Description
Adding remote wakeup feature for usb host lib
Related
Testing
Checklist
Before submitting a Pull Request, please ensure the following: