/arch/arm/mach-msm/avs.h

https://github.com/AICP/kernel_google_msm · C Header · 38 lines · 22 code · 4 blank · 12 comment · 0 complexity · d23ad2a8cd8bcfac23941294fa7d4694 MD5 · raw file

  1. /*
  2. * Copyright (c) 2009,2012, The Linux Foundation. All rights reserved.
  3. *
  4. * This program is free software; you can redistribute it and/or modify
  5. * it under the terms of the GNU General Public License version 2 and
  6. * only version 2 as published by the Free Software Foundation.
  7. *
  8. * This program is distributed in the hope that it will be useful,
  9. * but WITHOUT ANY WARRANTY; without even the implied warranty of
  10. * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
  11. * GNU General Public License for more details.
  12. */
  13. #ifndef AVS_H
  14. #define AVS_H
  15. #ifdef CONFIG_MSM_AVS_HW
  16. u32 avs_get_avscsr(void);
  17. void avs_set_avscsr(u32 avscsr);
  18. u32 avs_get_avsdscr(void);
  19. void avs_set_avsdscr(u32 avsdscr);
  20. void avs_disable(int cpu);
  21. void avs_enable(int cpu, u32 avsdscr);
  22. #else
  23. static inline u32 avs_get_avscsr(void)
  24. { return 0; }
  25. static inline void avs_set_avscsr(u32 avscsr) {}
  26. static inline u32 avs_get_avsdscr(void)
  27. { return 0; }
  28. static inline void avs_set_avsdscr(u32 avsdscr) {}
  29. static inline void avs_disable(int cpu) {}
  30. static inline void avs_enable(int cpu, u32 avsdscr) {}
  31. #endif
  32. #define AVS_DISABLE(cpu) avs_disable(cpu)
  33. #define AVS_ENABLE(cpu, x) avs_enable(cpu, x)
  34. #endif