apex.h 698 B

12345678910111213141516171819202122232425262728293031
  1. /* SPDX-License-Identifier: GPL-2.0 */
  2. /*
  3. * Apex kernel-userspace interface definitions.
  4. *
  5. * Copyright (C) 2018 Google, Inc.
  6. */
  7. #ifndef __APEX_H__
  8. #define __APEX_H__
  9. #include <linux/ioctl.h>
  10. /* Clock Gating ioctl. */
  11. struct apex_gate_clock_ioctl {
  12. /* Enter or leave clock gated state. */
  13. u64 enable;
  14. /* If set, enter clock gating state, regardless of custom block's
  15. * internal idle state
  16. */
  17. u64 force_idle;
  18. };
  19. /* Base number for all Apex-common IOCTLs */
  20. #define APEX_IOCTL_BASE 0x7F
  21. /* Enable/Disable clock gating. */
  22. #define APEX_IOCTL_GATE_CLOCK \
  23. _IOW(APEX_IOCTL_BASE, 0, struct apex_gate_clock_ioctl)
  24. #endif /* __APEX_H__ */