ddrphy_wrapper.h 383 B

1234567891011121314151617181920
  1. /*
  2. * Copyright (C) 2021-2024, STMicroelectronics - All Rights Reserved
  3. *
  4. * SPDX-License-Identifier: BSD-3-Clause
  5. */
  6. #ifndef DDRPHY_WRAPPER_H
  7. #define DDRPHY_WRAPPER_H
  8. static inline long long fmodll(long long x, long long y)
  9. {
  10. return x - ((x / y) * y);
  11. }
  12. static inline int fmodi(int x, int y)
  13. {
  14. return (int)fmodll((long long)x, (long long)y);
  15. }
  16. #endif /* DDRPHY_WRAPPER_H */