Merge tag 'firewire-fixes-6.9-rc1' of git://git.kernel.org/pub/scm/linux/kernel/git...
[sfrench/cifs-2.6.git] / drivers / usb / typec / tcpm / qcom / qcom_pmic_typec_pdphy.h
1 /* SPDX-License-Identifier: GPL-2.0 */
2 /*
3  * Copyright (c) 2018-2019 The Linux Foundation. All rights reserved.
4  * Copyright (c) 2023, Linaro Ltd. All rights reserved.
5  */
6 #ifndef __QCOM_PMIC_PDPHY_H__
7 #define __QCOM_PMIC_PDPHY_H__
8
9 #include <linux/platform_device.h>
10 #include <linux/regmap.h>
11
12 /* Resources */
13 #define PMIC_PDPHY_MAX_IRQS             0x08
14
15 struct pmic_typec_pdphy_irq_params {
16         int                             virq;
17         char                            *irq_name;
18 };
19
20 struct pmic_typec_pdphy_resources {
21         unsigned int                            nr_irqs;
22         const struct pmic_typec_pdphy_irq_params        irq_params[PMIC_PDPHY_MAX_IRQS];
23 };
24
25 /* API */
26 struct pmic_typec_pdphy;
27
28 extern const struct pmic_typec_pdphy_resources pm8150b_pdphy_res;
29 int qcom_pmic_typec_pdphy_probe(struct platform_device *pdev,
30                                 struct pmic_typec *tcpm,
31                                 const struct pmic_typec_pdphy_resources *res,
32                                 struct regmap *regmap,
33                                 u32 base);
34 int qcom_pmic_typec_pdphy_stub_probe(struct platform_device *pdev,
35                                      struct pmic_typec *tcpm);
36
37 #endif /* __QCOM_PMIC_TYPEC_PDPHY_H__ */