ipa_uc.h 1.3 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546
  1. /* SPDX-License-Identifier: GPL-2.0 */
  2. /* Copyright (c) 2012-2018, The Linux Foundation. All rights reserved.
  3. * Copyright (C) 2019-2022 Linaro Ltd.
  4. */
  5. #ifndef _IPA_UC_H_
  6. #define _IPA_UC_H_
  7. struct ipa;
  8. /**
  9. * ipa_uc_config() - Configure the IPA microcontroller subsystem
  10. * @ipa: IPA pointer
  11. */
  12. void ipa_uc_config(struct ipa *ipa);
  13. /**
  14. * ipa_uc_deconfig() - Inverse of ipa_uc_config()
  15. * @ipa: IPA pointer
  16. */
  17. void ipa_uc_deconfig(struct ipa *ipa);
  18. /**
  19. * ipa_uc_power() - Take a proxy power reference for the microcontroller
  20. * @ipa: IPA pointer
  21. *
  22. * The first time the modem boots, it loads firmware for and starts the
  23. * IPA-resident microcontroller. The microcontroller signals that it
  24. * has completed its initialization by sending an INIT_COMPLETED response
  25. * message to the AP. The AP must ensure the IPA is powered until
  26. * it receives this message, and to do so we take a "proxy" clock
  27. * reference on its behalf here. Once we receive the INIT_COMPLETED
  28. * message (in ipa_uc_response_hdlr()) we drop this power reference.
  29. */
  30. void ipa_uc_power(struct ipa *ipa);
  31. /**
  32. * ipa_uc_panic_notifier()
  33. * @ipa: IPA pointer
  34. *
  35. * Notifier function called when the system crashes, to inform the
  36. * microcontroller of the event.
  37. */
  38. void ipa_uc_panic_notifier(struct ipa *ipa);
  39. #endif /* _IPA_UC_H_ */