usb: device_next: uvc: move files to common directory#103369
usb: device_next: uvc: move files to common directory#103369aescolar merged 2 commits intozephyrproject-rtos:mainfrom
Conversation
f4062b7 to
56dbc8f
Compare
| #ifndef ZEPHYR_INCLUDE_USBD_CLASS_UVC_H_ | ||
| #define ZEPHYR_INCLUDE_USBD_CLASS_UVC_H_ | ||
| #ifndef ZEPHYR_INCLUDE_USB_COMMON_UVC_H | ||
| #define ZEPHYR_INCLUDE_USB_COMMON_UVC_H |
There was a problem hiding this comment.
subsys/usb/common/include/
@josuah Do we need include directory? We do not have it, for example, in drivers/usb.
There was a problem hiding this comment.
I think I mistook an arch WG discussion for a review.
Updated, thank you.
|
|
||
| if(CONFIG_USBD_VIDEO_CLASS) | ||
| zephyr_include_directories(.) | ||
| zephyr_sources(uvc.c) |
There was a problem hiding this comment.
You use uvc.c in CMakeLists.txt in commit prior to where uvc.c is introduced.
There was a problem hiding this comment.
Yes my bad, there was some bad rebase happening.
I think I fixed it in API3 without fixing it in uvc_common.
| enum uvc_control_type { | ||
| UVC_CONTROL_SIGNED, | ||
| UVC_CONTROL_UNSIGNED, | ||
| }; | ||
|
|
There was a problem hiding this comment.
It would be good to have the removals from usbd_uvc.c in "usb: uvc: move the header definition to include/" commit. I was initially wondering where enum uvc_control_type, struct uvc_control_map, struct uvc_guid_quirk came from.
There was a problem hiding this comment.
It seems like one of the commit got accidentally left into API2, and got merged.
I corrected it by merging the two commits.
Sorry for the confusion.
The public API file <zephyr/usb/class/usbd_uvc.h> lacked an include to <zephyr/drivers/video.h> making it fail depending on the order of the includes. Signed-off-by: Josuah Demangeon <josuah.demangeon@nordicsemi.no>
Move UVC helper functions to a file shared between UVC host and device. The arrays are not visible anymore from either USB host or device, but instead accessed through a front-end funciton. Signed-off-by: Josuah Demangeon <josuah.demangeon@nordicsemi.no>
|
Sorry for the "functinos" instead of "functions" typo in the commit message... |
|



In order to anticipate the introduction of a host class API, move some headers to a common directory for both device and host class implementation.
This was split from this PR as it has no dependency: