pl310.h 1.2 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657
  1. /*
  2. * (C) Copyright 2010
  3. * Texas Instruments, <www.ti.com>
  4. * Aneesh V <aneesh@ti.com>
  5. *
  6. * SPDX-License-Identifier: GPL-2.0+
  7. */
  8. #ifndef _PL310_H_
  9. #define _PL310_H_
  10. #include <linux/types.h>
  11. /* Register bit fields */
  12. #define PL310_AUX_CTRL_ASSOCIATIVITY_MASK (1 << 16)
  13. struct pl310_regs {
  14. u32 pl310_cache_id;
  15. u32 pl310_cache_type;
  16. u32 pad1[62];
  17. u32 pl310_ctrl;
  18. u32 pl310_aux_ctrl;
  19. u32 pl310_tag_latency_ctrl;
  20. u32 pl310_data_latency_ctrl;
  21. u32 pad2[60];
  22. u32 pl310_event_cnt_ctrl;
  23. u32 pl310_event_cnt1_cfg;
  24. u32 pl310_event_cnt0_cfg;
  25. u32 pl310_event_cnt1_val;
  26. u32 pl310_event_cnt0_val;
  27. u32 pl310_intr_mask;
  28. u32 pl310_masked_intr_stat;
  29. u32 pl310_raw_intr_stat;
  30. u32 pl310_intr_clear;
  31. u32 pad3[323];
  32. u32 pl310_cache_sync;
  33. u32 pad4[15];
  34. u32 pl310_inv_line_pa;
  35. u32 pad5[2];
  36. u32 pl310_inv_way;
  37. u32 pad6[12];
  38. u32 pl310_clean_line_pa;
  39. u32 pad7[1];
  40. u32 pl310_clean_line_idx;
  41. u32 pl310_clean_way;
  42. u32 pad8[12];
  43. u32 pl310_clean_inv_line_pa;
  44. u32 pad9[1];
  45. u32 pl310_clean_inv_line_idx;
  46. u32 pl310_clean_inv_way;
  47. };
  48. void pl310_inval_all(void);
  49. void pl310_clean_inval_all(void);
  50. void pl310_inval_range(u32 start, u32 end);
  51. void pl310_clean_inval_range(u32 start, u32 end);
  52. #endif