ipa_smp2p.h 1.2 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647
  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_SMP2P_H_
  6. #define _IPA_SMP2P_H_
  7. #include <linux/types.h>
  8. struct ipa;
  9. /**
  10. * ipa_smp2p_init() - Initialize the IPA SMP2P subsystem
  11. * @ipa: IPA pointer
  12. * @modem_init: Whether the modem is responsible for GSI initialization
  13. *
  14. * Return: 0 if successful, or a negative error code
  15. *
  16. */
  17. int ipa_smp2p_init(struct ipa *ipa, bool modem_init);
  18. /**
  19. * ipa_smp2p_exit() - Inverse of ipa_smp2p_init()
  20. * @ipa: IPA pointer
  21. */
  22. void ipa_smp2p_exit(struct ipa *ipa);
  23. /**
  24. * ipa_smp2p_irq_disable_setup() - Disable the "setup ready" interrupt
  25. * @ipa: IPA pointer
  26. *
  27. * Disable the "ipa-setup-ready" interrupt from the modem.
  28. */
  29. void ipa_smp2p_irq_disable_setup(struct ipa *ipa);
  30. /**
  31. * ipa_smp2p_notify_reset() - Reset modem notification state
  32. * @ipa: IPA pointer
  33. *
  34. * If the modem crashes it queries the IPA power state. In cleaning
  35. * up after such a crash this is used to reset some state maintained
  36. * for managing this notification.
  37. */
  38. void ipa_smp2p_notify_reset(struct ipa *ipa);
  39. #endif /* _IPA_SMP2P_H_ */