resources.h 1020 B

123456789101112131415161718192021222324252627282930313233
  1. /* SPDX-License-Identifier: GPL-2.0-only */
  2. /*
  3. * Copyright (c) 2020-2022, The Linux Foundation. All rights reserved.
  4. */
  5. #ifndef _MSM_VIDC_RESOURCES_H_
  6. #define _MSM_VIDC_RESOURCES_H_
  7. struct msm_vidc_core;
  8. struct msm_vidc_resources_ops {
  9. int (*get)(struct msm_vidc_core *core);
  10. void (*put)(struct msm_vidc_core *core);
  11. int (*reset_bridge)(struct msm_vidc_core *core);
  12. int (*gdsc_on)(struct msm_vidc_core *core, const char *name);
  13. int (*gdsc_off)(struct msm_vidc_core *core, const char *name);
  14. int (*gdsc_hw_ctrl)(struct msm_vidc_core *core);
  15. int (*gdsc_sw_ctrl)(struct msm_vidc_core *core);
  16. int (*llcc)(struct msm_vidc_core *core, bool enable);
  17. int (*set_bw)(struct msm_vidc_core *core, unsigned long bw_ddr,
  18. unsigned long bw_llcc);
  19. int (*set_clks)(struct msm_vidc_core *core, u64 rate);
  20. int (*clk_disable)(struct msm_vidc_core *core, const char *name);
  21. int (*clk_enable)(struct msm_vidc_core *core, const char *name);
  22. };
  23. const struct msm_vidc_resources_ops *get_resources_ops(void);
  24. #endif