dp_ctrl.h 1.3 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344
  1. /* SPDX-License-Identifier: GPL-2.0-only */
  2. /*
  3. * Copyright (c) 2012-2020, The Linux Foundation. All rights reserved.
  4. */
  5. #ifndef _DP_CTRL_H_
  6. #define _DP_CTRL_H_
  7. #include "dp_aux.h"
  8. #include "dp_panel.h"
  9. #include "dp_link.h"
  10. #include "dp_catalog.h"
  11. struct dp_ctrl {
  12. bool wide_bus_en;
  13. };
  14. struct phy;
  15. int dp_ctrl_on_link(struct dp_ctrl *dp_ctrl);
  16. int dp_ctrl_on_stream(struct dp_ctrl *dp_ctrl, bool force_link_train);
  17. void dp_ctrl_off_link_stream(struct dp_ctrl *dp_ctrl);
  18. void dp_ctrl_off_link(struct dp_ctrl *dp_ctrl);
  19. void dp_ctrl_off(struct dp_ctrl *dp_ctrl);
  20. void dp_ctrl_push_idle(struct dp_ctrl *dp_ctrl);
  21. irqreturn_t dp_ctrl_isr(struct dp_ctrl *dp_ctrl);
  22. void dp_ctrl_handle_sink_request(struct dp_ctrl *dp_ctrl);
  23. struct dp_ctrl *dp_ctrl_get(struct device *dev, struct dp_link *link,
  24. struct dp_panel *panel, struct drm_dp_aux *aux,
  25. struct dp_catalog *catalog,
  26. struct phy *phy);
  27. void dp_ctrl_reset_irq_ctrl(struct dp_ctrl *dp_ctrl, bool enable);
  28. void dp_ctrl_phy_init(struct dp_ctrl *dp_ctrl);
  29. void dp_ctrl_phy_exit(struct dp_ctrl *dp_ctrl);
  30. void dp_ctrl_irq_phy_exit(struct dp_ctrl *dp_ctrl);
  31. void dp_ctrl_set_psr(struct dp_ctrl *dp_ctrl, bool enable);
  32. void dp_ctrl_config_psr(struct dp_ctrl *dp_ctrl);
  33. int dp_ctrl_core_clk_enable(struct dp_ctrl *dp_ctrl);
  34. void dp_ctrl_core_clk_disable(struct dp_ctrl *dp_ctrl);
  35. #endif /* _DP_CTRL_H_ */