Home
last modified time | relevance | path

Searched refs:hpriv (Results 1 – 25 of 43) sorted by relevance

12

/linux-5.19.10/drivers/ata/
Dlibahci_platform.c46 int ahci_platform_enable_phys(struct ahci_host_priv *hpriv) in ahci_platform_enable_phys() argument
50 for (i = 0; i < hpriv->nports; i++) { in ahci_platform_enable_phys()
51 rc = phy_init(hpriv->phys[i]); in ahci_platform_enable_phys()
55 rc = phy_set_mode(hpriv->phys[i], PHY_MODE_SATA); in ahci_platform_enable_phys()
57 phy_exit(hpriv->phys[i]); in ahci_platform_enable_phys()
61 rc = phy_power_on(hpriv->phys[i]); in ahci_platform_enable_phys()
63 phy_exit(hpriv->phys[i]); in ahci_platform_enable_phys()
72 phy_power_off(hpriv->phys[i]); in ahci_platform_enable_phys()
73 phy_exit(hpriv->phys[i]); in ahci_platform_enable_phys()
85 void ahci_platform_disable_phys(struct ahci_host_priv *hpriv) in ahci_platform_disable_phys() argument
[all …]
Dahci_mvebu.c32 int (*plat_config)(struct ahci_host_priv *hpriv);
36 static void ahci_mvebu_mbus_config(struct ahci_host_priv *hpriv, in ahci_mvebu_mbus_config() argument
42 writel(0, hpriv->mmio + AHCI_WINDOW_CTRL(i)); in ahci_mvebu_mbus_config()
43 writel(0, hpriv->mmio + AHCI_WINDOW_BASE(i)); in ahci_mvebu_mbus_config()
44 writel(0, hpriv->mmio + AHCI_WINDOW_SIZE(i)); in ahci_mvebu_mbus_config()
52 hpriv->mmio + AHCI_WINDOW_CTRL(i)); in ahci_mvebu_mbus_config()
53 writel(cs->base >> 16, hpriv->mmio + AHCI_WINDOW_BASE(i)); in ahci_mvebu_mbus_config()
55 hpriv->mmio + AHCI_WINDOW_SIZE(i)); in ahci_mvebu_mbus_config()
59 static void ahci_mvebu_regret_option(struct ahci_host_priv *hpriv) in ahci_mvebu_regret_option() argument
66 writel(0x4, hpriv->mmio + AHCI_VENDOR_SPECIFIC_0_ADDR); in ahci_mvebu_regret_option()
[all …]
Dahci_st.c54 static int st_ahci_deassert_resets(struct ahci_host_priv *hpriv, in st_ahci_deassert_resets() argument
57 struct st_ahci_drv_data *drv_data = hpriv->plat_data; in st_ahci_deassert_resets()
89 struct ahci_host_priv *hpriv = host->private_data; in st_ahci_host_stop() local
90 struct st_ahci_drv_data *drv_data = hpriv->plat_data; in st_ahci_host_stop()
100 ahci_platform_disable_resources(hpriv); in st_ahci_host_stop()
103 static int st_ahci_probe_resets(struct ahci_host_priv *hpriv, in st_ahci_probe_resets() argument
106 struct st_ahci_drv_data *drv_data = hpriv->plat_data; in st_ahci_probe_resets()
126 return st_ahci_deassert_resets(hpriv, dev); in st_ahci_probe_resets()
149 struct ahci_host_priv *hpriv; in st_ahci_probe() local
156 hpriv = ahci_platform_get_resources(pdev, 0); in st_ahci_probe()
[all …]
Dahci_brcm.c118 static void brcm_sata_alpm_init(struct ahci_host_priv *hpriv) in brcm_sata_alpm_init() argument
120 struct brcm_ahci_priv *priv = hpriv->plat_data; in brcm_sata_alpm_init()
125 host_caps = readl(hpriv->mmio + HOST_CAP); in brcm_sata_alpm_init()
127 hpriv->flags |= AHCI_HFLAG_YES_ALPM; in brcm_sata_alpm_init()
138 hpriv->mmio + SATA_PORT_PCTRL6(port_ctrl)); in brcm_sata_alpm_init()
217 static u32 brcm_ahci_get_portmask(struct ahci_host_priv *hpriv, in brcm_ahci_get_portmask() argument
222 impl = readl(hpriv->mmio + HOST_PORTS_IMPL); in brcm_ahci_get_portmask()
253 struct ahci_host_priv *hpriv = host->private_data; in brcm_ahci_read_id() local
254 struct brcm_ahci_priv *priv = hpriv->plat_data; in brcm_ahci_read_id()
255 void __iomem *mmio = hpriv->mmio; in brcm_ahci_read_id()
[all …]
Dsata_mv.c438 #define IS_GEN_I(hpriv) ((hpriv)->hp_flags & MV_HP_GEN_I) argument
439 #define IS_GEN_II(hpriv) ((hpriv)->hp_flags & MV_HP_GEN_II) argument
440 #define IS_GEN_IIE(hpriv) ((hpriv)->hp_flags & MV_HP_GEN_IIE) argument
441 #define IS_PCIE(hpriv) ((hpriv)->hp_flags & MV_HP_PCIE) argument
442 #define IS_SOC(hpriv) ((hpriv)->hp_flags & MV_HP_FLAG_SOC) argument
577 void (*phy_errata)(struct mv_host_priv *hpriv, void __iomem *mmio,
579 void (*enable_leds)(struct mv_host_priv *hpriv, void __iomem *mmio);
580 void (*read_preamp)(struct mv_host_priv *hpriv, int idx,
584 void (*reset_flash)(struct mv_host_priv *hpriv, void __iomem *mmio);
604 static void mv5_phy_errata(struct mv_host_priv *hpriv, void __iomem *mmio,
[all …]
Dlibahci.c262 struct ahci_host_priv *hpriv = ap->host->private_data; in ahci_show_host_caps() local
264 return sprintf(buf, "%x\n", hpriv->cap); in ahci_show_host_caps()
272 struct ahci_host_priv *hpriv = ap->host->private_data; in ahci_show_host_cap2() local
274 return sprintf(buf, "%x\n", hpriv->cap2); in ahci_show_host_cap2()
282 struct ahci_host_priv *hpriv = ap->host->private_data; in ahci_show_host_version() local
284 return sprintf(buf, "%x\n", hpriv->version); in ahci_show_host_version()
307 struct ahci_host_priv *hpriv = ap->host->private_data; in ahci_read_em_buffer() local
308 void __iomem *mmio = hpriv->mmio; in ahci_read_em_buffer()
309 void __iomem *em_mmio = mmio + hpriv->em_loc; in ahci_read_em_buffer()
320 !(hpriv->em_msg_type & EM_MSG_TYPE_SGPIO)) { in ahci_read_em_buffer()
[all …]
Dahci_mtk.c44 static int mtk_ahci_platform_resets(struct ahci_host_priv *hpriv, in mtk_ahci_platform_resets() argument
47 struct mtk_ahci_plat *plat = hpriv->plat_data; in mtk_ahci_platform_resets()
102 static int mtk_ahci_parse_property(struct ahci_host_priv *hpriv, in mtk_ahci_parse_property() argument
105 struct mtk_ahci_plat *plat = hpriv->plat_data; in mtk_ahci_parse_property()
121 of_property_read_u32(np, "ports-implemented", &hpriv->force_port_map); in mtk_ahci_parse_property()
130 struct ahci_host_priv *hpriv; in mtk_ahci_probe() local
137 hpriv = ahci_platform_get_resources(pdev, 0); in mtk_ahci_probe()
138 if (IS_ERR(hpriv)) in mtk_ahci_probe()
139 return PTR_ERR(hpriv); in mtk_ahci_probe()
141 hpriv->plat_data = plat; in mtk_ahci_probe()
[all …]
Dahci_seattle.c82 struct ahci_host_priv *hpriv = ap->host->private_data; in seattle_transmit_led_message() local
84 struct seattle_plat_data *plat_data = hpriv->plat_data; in seattle_transmit_led_message()
125 struct platform_device *pdev, struct ahci_host_priv *hpriv) in ahci_seattle_get_port_info() argument
145 hpriv->em_loc = 0; in ahci_seattle_get_port_info()
146 hpriv->em_buf_sz = 4; in ahci_seattle_get_port_info()
147 hpriv->em_msg_type = EM_MSG_TYPE_LED; in ahci_seattle_get_port_info()
148 hpriv->plat_data = plat_data; in ahci_seattle_get_port_info()
157 struct ahci_host_priv *hpriv; in ahci_seattle_probe() local
159 hpriv = ahci_platform_get_resources(pdev, 0); in ahci_seattle_probe()
160 if (IS_ERR(hpriv)) in ahci_seattle_probe()
[all …]
Dahci_sunxi.c150 struct ahci_host_priv *hpriv = ap->host->private_data; in ahci_sunxi_start_engine() local
196 sunxi_clrsetbits(hpriv->mmio + AHCI_P0DMACR, 0x0000ffff, 0x00004433); in ahci_sunxi_start_engine()
216 struct ahci_host_priv *hpriv; in ahci_sunxi_probe() local
219 hpriv = ahci_platform_get_resources(pdev, AHCI_PLATFORM_GET_RESETS); in ahci_sunxi_probe()
220 if (IS_ERR(hpriv)) in ahci_sunxi_probe()
221 return PTR_ERR(hpriv); in ahci_sunxi_probe()
223 hpriv->start_engine = ahci_sunxi_start_engine; in ahci_sunxi_probe()
225 rc = ahci_platform_enable_resources(hpriv); in ahci_sunxi_probe()
229 rc = ahci_sunxi_phy_init(dev, hpriv->mmio); in ahci_sunxi_probe()
233 hpriv->flags = AHCI_HFLAG_32BIT_ONLY | AHCI_HFLAG_NO_MSI | in ahci_sunxi_probe()
[all …]
Dahci_dm816.c61 static int ahci_dm816_phy_init(struct ahci_host_priv *hpriv, struct device *dev) in ahci_dm816_phy_init() argument
72 if (!hpriv->clks[1]) { in ahci_dm816_phy_init()
77 refclk_rate = clk_get_rate(hpriv->clks[1]); in ahci_dm816_phy_init()
93 writel(val, hpriv->mmio + AHCI_DM816_P0PHYCR_REG); in ahci_dm816_phy_init()
98 writel(val, hpriv->mmio + AHCI_DM816_P1PHYCR_REG); in ahci_dm816_phy_init()
144 struct ahci_host_priv *hpriv; in ahci_dm816_probe() local
147 hpriv = ahci_platform_get_resources(pdev, 0); in ahci_dm816_probe()
148 if (IS_ERR(hpriv)) in ahci_dm816_probe()
149 return PTR_ERR(hpriv); in ahci_dm816_probe()
151 rc = ahci_platform_enable_resources(hpriv); in ahci_dm816_probe()
[all …]
Dahci_xgene.c81 struct ahci_host_priv *hpriv; member
140 struct ahci_host_priv *hpriv = ap->host->private_data; in xgene_ahci_restart_engine() local
155 hpriv->stop_engine(ap); in xgene_ahci_restart_engine()
168 hpriv->start_engine(ap); in xgene_ahci_restart_engine()
192 struct ahci_host_priv *hpriv = ap->host->private_data; in xgene_ahci_qc_issue() local
193 struct xgene_ahci_context *ctx = hpriv->plat_data; in xgene_ahci_qc_issue()
269 void __iomem *mmio = ctx->hpriv->mmio; in xgene_ahci_set_phy_cfg()
355 struct ahci_host_priv *hpriv = ap->host->private_data; in xgene_ahci_do_hardreset() local
356 struct xgene_ahci_context *ctx = hpriv->plat_data; in xgene_ahci_do_hardreset()
394 struct ahci_host_priv *hpriv = ap->host->private_data; in xgene_ahci_hardreset() local
[all …]
Dahci_ceva.c123 static void ahci_ceva_setup(struct ahci_host_priv *hpriv) in ahci_ceva_setup() argument
125 void __iomem *mmio = hpriv->mmio; in ahci_ceva_setup()
126 struct ceva_ahci_priv *cevapriv = hpriv->plat_data; in ahci_ceva_setup()
196 struct ahci_host_priv *hpriv; in ceva_ahci_probe() local
213 hpriv = ahci_platform_get_resources(pdev, 0); in ceva_ahci_probe()
214 if (IS_ERR(hpriv)) in ceva_ahci_probe()
215 return PTR_ERR(hpriv); in ceva_ahci_probe()
218 rc = ahci_platform_enable_resources(hpriv); in ceva_ahci_probe()
224 rc = ahci_platform_enable_clks(hpriv); in ceva_ahci_probe()
230 for (i = 0; i < hpriv->nports; i++) { in ceva_ahci_probe()
[all …]
Dahci.c656 struct ahci_host_priv *hpriv) in ahci_pci_save_initial_config() argument
660 hpriv->force_port_map = 1; in ahci_pci_save_initial_config()
668 if (hpriv->flags & AHCI_HFLAG_MV_PATA) { in ahci_pci_save_initial_config()
670 hpriv->mask_port_map = 0x3; in ahci_pci_save_initial_config()
672 hpriv->mask_port_map = 0xf; in ahci_pci_save_initial_config()
677 ahci_save_initial_config(&pdev->dev, hpriv); in ahci_pci_save_initial_config()
682 struct ahci_host_priv *hpriv = host->private_data; in ahci_pci_init_controller() local
688 if (hpriv->flags & AHCI_HFLAG_MV_PATA) { in ahci_pci_init_controller()
711 struct ahci_host_priv *hpriv = ap->host->private_data; in ahci_vt8251_hardreset() local
715 hpriv->stop_engine(ap); in ahci_vt8251_hardreset()
[all …]
Dacard-ahci.c115 struct ahci_host_priv *hpriv = host->private_data; in acard_ahci_pci_device_suspend() local
116 void __iomem *mmio = hpriv->mmio; in acard_ahci_pci_device_suspend()
120 hpriv->flags & AHCI_HFLAG_NO_SUSPEND) { in acard_ahci_pci_device_suspend()
277 struct ahci_host_priv *hpriv = ap->host->private_data; in acard_ahci_port_start() local
289 if ((hpriv->cap & HOST_CAP_FBS) && sata_pmp_supported(ap)) { in acard_ahci_port_start()
294 else if (hpriv->flags & AHCI_HFLAG_YES_FBS) { in acard_ahci_port_start()
359 struct ahci_host_priv *hpriv; in acard_ahci_init_one() local
381 hpriv = devm_kzalloc(dev, sizeof(*hpriv), GFP_KERNEL); in acard_ahci_init_one()
382 if (!hpriv) in acard_ahci_init_one()
385 hpriv->irq = pdev->irq; in acard_ahci_init_one()
[all …]
Dsata_uli.c89 struct uli_priv *hpriv = ap->host->private_data; in get_scr_cfg_addr() local
90 return hpriv->scr_cfg_addr[ap->port_no] + (4 * sc_reg); in get_scr_cfg_addr()
134 struct uli_priv *hpriv; in uli_init_one() local
154 hpriv = devm_kzalloc(&pdev->dev, sizeof(*hpriv), GFP_KERNEL); in uli_init_one()
155 if (!hpriv) in uli_init_one()
157 host->private_data = hpriv; in uli_init_one()
173 hpriv->scr_cfg_addr[0] = ULI5287_BASE; in uli_init_one()
174 hpriv->scr_cfg_addr[1] = ULI5287_BASE + ULI5287_OFFS; in uli_init_one()
182 hpriv->scr_cfg_addr[2] = ULI5287_BASE + ULI5287_OFFS*4; in uli_init_one()
197 hpriv->scr_cfg_addr[3] = ULI5287_BASE + ULI5287_OFFS*5; in uli_init_one()
[all …]
Dahci_da850.c163 struct ahci_host_priv *hpriv; in ahci_da850_probe() local
170 hpriv = ahci_platform_get_resources(pdev, 0); in ahci_da850_probe()
171 if (IS_ERR(hpriv)) in ahci_da850_probe()
172 return PTR_ERR(hpriv); in ahci_da850_probe()
181 if (!hpriv->clks[0]) { in ahci_da850_probe()
186 hpriv->clks[0] = clk; in ahci_da850_probe()
194 if (!hpriv->clks[1]) { in ahci_da850_probe()
201 hpriv->clks[1] = clk; in ahci_da850_probe()
204 mpy = ahci_da850_calculate_mpy(clk_get_rate(hpriv->clks[1])); in ahci_da850_probe()
210 rc = ahci_platform_enable_resources(hpriv); in ahci_da850_probe()
[all …]
Dsata_highbank.c131 struct ahci_host_priv *hpriv = ap->host->private_data; in ecx_transmit_led_message() local
132 struct ecx_plat_data *pdata = hpriv->plat_data; in ecx_transmit_led_message()
146 if (!(hpriv->em_msg_type & EM_MSG_TYPE_LED)) in ecx_transmit_led_message()
178 struct ahci_host_priv *hpriv, in highbank_set_em_messages() argument
182 struct ecx_plat_data *pdata = hpriv->plat_data; in highbank_set_em_messages()
208 hpriv->em_loc = 0; in highbank_set_em_messages()
209 hpriv->em_buf_sz = 4; in highbank_set_em_messages()
210 hpriv->em_msg_type = EM_MSG_TYPE_LED; in highbank_set_em_messages()
391 struct ahci_host_priv *hpriv = ap->host->private_data; in ahci_highbank_hardreset() local
399 hpriv->stop_engine(ap); in ahci_highbank_hardreset()
[all …]
Dahci_qoriq.c98 struct ahci_host_priv *hpriv = ap->host->private_data; in ahci_qoriq_hardreset() local
99 struct ahci_qoriq_priv *qoriq_priv = hpriv->plat_data; in ahci_qoriq_hardreset()
106 hpriv->stop_engine(ap); in ahci_qoriq_hardreset()
143 hpriv->start_engine(ap); in ahci_qoriq_hardreset()
166 static int ahci_qoriq_phy_init(struct ahci_host_priv *hpriv) in ahci_qoriq_phy_init() argument
168 struct ahci_qoriq_priv *qpriv = hpriv->plat_data; in ahci_qoriq_phy_init()
169 void __iomem *reg_base = hpriv->mmio; in ahci_qoriq_phy_init()
263 struct ahci_host_priv *hpriv; in ahci_qoriq_probe() local
269 hpriv = ahci_platform_get_resources(pdev, 0); in ahci_qoriq_probe()
270 if (IS_ERR(hpriv)) in ahci_qoriq_probe()
[all …]
Dahci_platform.c46 struct ahci_host_priv *hpriv; in ahci_probe() local
50 hpriv = ahci_platform_get_resources(pdev, in ahci_probe()
52 if (IS_ERR(hpriv)) in ahci_probe()
53 return PTR_ERR(hpriv); in ahci_probe()
55 rc = ahci_platform_enable_resources(hpriv); in ahci_probe()
60 "ports-implemented", &hpriv->force_port_map); in ahci_probe()
63 hpriv->flags |= AHCI_HFLAG_NO_FBS | AHCI_HFLAG_NO_NCQ; in ahci_probe()
69 rc = ahci_platform_init_host(pdev, hpriv, port, in ahci_probe()
76 ahci_platform_disable_resources(hpriv); in ahci_probe()
Dahci_tegra.c152 int (*init)(struct ahci_host_priv *hpriv);
182 static void tegra_ahci_handle_quirks(struct ahci_host_priv *hpriv) in tegra_ahci_handle_quirks() argument
184 struct tegra_ahci_priv *tegra = hpriv->plat_data; in tegra_ahci_handle_quirks()
194 static int tegra124_ahci_init(struct ahci_host_priv *hpriv) in tegra124_ahci_init() argument
196 struct tegra_ahci_priv *tegra = hpriv->plat_data; in tegra124_ahci_init()
238 static int tegra_ahci_power_on(struct ahci_host_priv *hpriv) in tegra_ahci_power_on() argument
240 struct tegra_ahci_priv *tegra = hpriv->plat_data; in tegra_ahci_power_on()
259 ret = ahci_platform_enable_resources(hpriv); in tegra_ahci_power_on()
280 static void tegra_ahci_power_off(struct ahci_host_priv *hpriv) in tegra_ahci_power_off() argument
282 struct tegra_ahci_priv *tegra = hpriv->plat_data; in tegra_ahci_power_off()
[all …]
Dahci_imx.c225 static int imx_sata_phy_reset(struct ahci_host_priv *hpriv) in imx_sata_phy_reset() argument
227 struct imx_ahci_priv *imxpriv = hpriv->plat_data; in imx_sata_phy_reset()
228 void __iomem *mmio = hpriv->mmio; in imx_sata_phy_reset()
335 struct ahci_host_priv *hpriv = dev_get_drvdata(dev); in sata_ahci_read_temperature() local
336 void __iomem *mmio = hpriv->mmio; in sata_ahci_read_temperature()
445 static int imx8_sata_enable(struct ahci_host_priv *hpriv) in imx8_sata_enable() argument
449 struct imx_ahci_priv *imxpriv = hpriv->plat_data; in imx8_sata_enable()
646 static int imx_sata_enable(struct ahci_host_priv *hpriv) in imx_sata_enable() argument
648 struct imx_ahci_priv *imxpriv = hpriv->plat_data; in imx_sata_enable()
655 ret = ahci_platform_enable_regulators(hpriv); in imx_sata_enable()
[all …]
/linux-5.19.10/drivers/usb/renesas_usbhs/
Dmod_host.c109 #define usbhsh_for_each_udev(pos, hpriv, i) \ argument
110 __usbhsh_for_each_udev(1, pos, hpriv, i)
112 #define usbhsh_for_each_udev_with_dev0(pos, hpriv, i) \ argument
113 __usbhsh_for_each_udev(0, pos, hpriv, i)
155 static struct usbhsh_request *usbhsh_ureq_alloc(struct usbhsh_hpriv *hpriv, in usbhsh_ureq_alloc() argument
172 static void usbhsh_ureq_free(struct usbhsh_hpriv *hpriv, in usbhsh_ureq_free() argument
184 static int usbhsh_is_running(struct usbhsh_hpriv *hpriv) in usbhsh_is_running() argument
193 return (hpriv->mod.irq_attch == NULL); in usbhsh_is_running()
199 static void usbhsh_endpoint_sequence_save(struct usbhsh_hpriv *hpriv, in usbhsh_endpoint_sequence_save() argument
241 static struct usbhsh_device *usbhsh_device_get(struct usbhsh_hpriv *hpriv,
[all …]
/linux-5.19.10/drivers/misc/habanalabs/common/
Dhabanalabs_ioctl.c119 static int events_info(struct hl_fpriv *hpriv, struct hl_info_args *args) in events_info() argument
128 mutex_lock(&hpriv->notifier_event.lock); in events_info()
129 events_mask = hpriv->notifier_event.events_mask; in events_info()
130 hpriv->notifier_event.events_mask = 0; in events_info()
131 mutex_unlock(&hpriv->notifier_event.lock); in events_info()
136 static int dram_usage_info(struct hl_fpriv *hpriv, struct hl_info_args *args) in dram_usage_info() argument
138 struct hl_device *hdev = hpriv->hdev; in dram_usage_info()
152 if (hpriv->ctx) in dram_usage_info()
154 atomic64_read(&hpriv->ctx->dram_phys_mem); in dram_usage_info()
312 static int pci_counters_info(struct hl_fpriv *hpriv, struct hl_info_args *args) in pci_counters_info() argument
[all …]
Dhabanalabs_drv.c117 struct hl_fpriv *hpriv; in hl_device_open() local
130 hpriv = kzalloc(sizeof(*hpriv), GFP_KERNEL); in hl_device_open()
131 if (!hpriv) in hl_device_open()
134 hpriv->hdev = hdev; in hl_device_open()
135 filp->private_data = hpriv; in hl_device_open()
136 hpriv->filp = filp; in hl_device_open()
138 mutex_init(&hpriv->notifier_event.lock); in hl_device_open()
139 mutex_init(&hpriv->restore_phase_mutex); in hl_device_open()
140 kref_init(&hpriv->refcount); in hl_device_open()
143 hl_ctx_mgr_init(&hpriv->ctx_mgr); in hl_device_open()
[all …]
/linux-5.19.10/include/linux/
Dahci_platform.h22 int ahci_platform_enable_phys(struct ahci_host_priv *hpriv);
23 void ahci_platform_disable_phys(struct ahci_host_priv *hpriv);
24 int ahci_platform_enable_clks(struct ahci_host_priv *hpriv);
25 void ahci_platform_disable_clks(struct ahci_host_priv *hpriv);
26 int ahci_platform_enable_regulators(struct ahci_host_priv *hpriv);
27 void ahci_platform_disable_regulators(struct ahci_host_priv *hpriv);
28 int ahci_platform_enable_resources(struct ahci_host_priv *hpriv);
29 void ahci_platform_disable_resources(struct ahci_host_priv *hpriv);
33 struct ahci_host_priv *hpriv,

12