mali_base_mem_priv.h 1.4 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849
  1. /*
  2. *
  3. * (C) COPYRIGHT 2010-2014 ARM Limited. All rights reserved.
  4. *
  5. * This program is free software and is provided to you under the terms of the
  6. * GNU General Public License version 2 as published by the Free Software
  7. * Foundation, and any use by you of this program is subject to the terms
  8. * of such GNU licence.
  9. *
  10. * A copy of the licence is included with the program, and can also be obtained
  11. * from Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor,
  12. * Boston, MA 02110-1301, USA.
  13. *
  14. */
  15. #ifndef _BASE_MEM_PRIV_H_
  16. #define _BASE_MEM_PRIV_H_
  17. #define BASE_SYNCSET_OP_MSYNC (1U << 0)
  18. #define BASE_SYNCSET_OP_CSYNC (1U << 1)
  19. /*
  20. * This structure describe a basic memory coherency operation.
  21. * It can either be:
  22. * @li a sync from CPU to Memory:
  23. * - type = ::BASE_SYNCSET_OP_MSYNC
  24. * - mem_handle = a handle to the memory object on which the operation
  25. * is taking place
  26. * - user_addr = the address of the range to be synced
  27. * - size = the amount of data to be synced, in bytes
  28. * - offset is ignored.
  29. * @li a sync from Memory to CPU:
  30. * - type = ::BASE_SYNCSET_OP_CSYNC
  31. * - mem_handle = a handle to the memory object on which the operation
  32. * is taking place
  33. * - user_addr = the address of the range to be synced
  34. * - size = the amount of data to be synced, in bytes.
  35. * - offset is ignored.
  36. */
  37. struct basep_syncset {
  38. base_mem_handle mem_handle;
  39. u64 user_addr;
  40. u64 size;
  41. u8 type;
  42. u8 padding[7];
  43. };
  44. #endif // ifndef _BASE_MEM_PRIV_H_