usb_dcache.h 565 B

12345678910111213141516171819202122
  1. /*
  2. * Copyright (c) 2024, sakumisu
  3. *
  4. * SPDX-License-Identifier: Apache-2.0
  5. */
  6. #ifndef USB_DCACHE_H
  7. #define USB_DCACHE_H
  8. #ifdef CONFIG_USB_DCACHE_ENABLE
  9. #if CONFIG_USB_ALIGN_SIZE % 32
  10. #error "CONFIG_USB_ALIGN_SIZE must be multiple of 32"
  11. #endif
  12. void usb_dcache_clean(uintptr_t addr, size_t size);
  13. void usb_dcache_invalidate(uintptr_t addr, size_t size);
  14. void usb_dcache_flush(uintptr_t addr, size_t size);
  15. #else
  16. #define usb_dcache_clean(addr, size)
  17. #define usb_dcache_invalidate(addr, size)
  18. #define usb_dcache_flush(addr, size)
  19. #endif
  20. #endif /* USB_DCACHE_H */