usb: device_next: introduce UDC_BUF_POOL_*_DEFINE macros

Introduce UDC_BUF_POOL_*_DEFINE macros based on NET_BUF_POOL_*_DEFINE
macros but use our own version of alloc and unref callbacks to get
buffers with specific alignment and granularity. Also, do not use ref
callback because it breaks alignment.
Also introduces helper macros for defining and checking UDC
driver-compliant static buffers.

Signed-off-by: Johann Fischer <johann.fischer@nordicsemi.no>
This commit is contained in:
Johann Fischer 2024-06-07 19:35:45 +02:00 committed by Fabio Baltieri
commit 67caae3aca
16 changed files with 222 additions and 23 deletions

View file

@ -16,3 +16,5 @@ API reference
*************
.. doxygengroup:: udc_api
.. doxygengroup:: udc_buf