zephyr/subsys/usb/device/bos_desc.h
Johann Fischer 29003ff264 usb: bos: cleanup Binary Device Object Store header
We could reuse the BOS header, but there are parts that are only needed
in the legacy device support or used internally and the tests. Move this
parts to the appropriate places.

Signed-off-by: Johann Fischer <johann.fischer@nordicsemi.no>
2024-05-17 16:25:02 +01:00

26 lines
571 B
C

/*
* Copyright (c) 2018 Intel Corporation
*
* SPDX-License-Identifier: Apache-2.0
*/
#ifndef ZEPHYR_INCLUDE_USB_DEVICE_BOS_DESC_H_
#define ZEPHYR_INCLUDE_USB_DEVICE_BOS_DESC_H_
#include <stdint.h>
#include <zephyr/usb/usb_ch9.h>
size_t usb_bos_get_length(void);
void usb_bos_fix_total_length(void);
const void *usb_bos_get_header(void);
#if defined(CONFIG_USB_DEVICE_BOS)
int usb_handle_bos(struct usb_setup_packet *setup, int32_t *len, uint8_t **data);
#else
#define usb_handle_bos(x, y, z) -ENOTSUP
#endif
#endif /* ZEPHYR_INCLUDE_USB_DEVICE_BOS_DESC_H_ */