Lines Matching refs:rc

51 	int rc, i;  in ahci_platform_enable_phys()  local
54 rc = phy_init(hpriv->phys[i]); in ahci_platform_enable_phys()
55 if (rc) in ahci_platform_enable_phys()
58 rc = phy_power_on(hpriv->phys[i]); in ahci_platform_enable_phys()
59 if (rc) { in ahci_platform_enable_phys()
72 return rc; in ahci_platform_enable_phys()
104 int c, rc; in ahci_platform_enable_clks() local
107 rc = clk_prepare_enable(hpriv->clks[c]); in ahci_platform_enable_clks()
108 if (rc) in ahci_platform_enable_clks()
116 return rc; in ahci_platform_enable_clks()
151 int rc, i; in ahci_platform_enable_regulators() local
157 rc = regulator_enable(hpriv->target_pwrs[i]); in ahci_platform_enable_regulators()
158 if (rc) in ahci_platform_enable_regulators()
169 return rc; in ahci_platform_enable_regulators()
208 int rc; in ahci_platform_enable_resources() local
210 rc = ahci_platform_enable_regulators(hpriv); in ahci_platform_enable_resources()
211 if (rc) in ahci_platform_enable_resources()
212 return rc; in ahci_platform_enable_resources()
214 rc = ahci_platform_enable_clks(hpriv); in ahci_platform_enable_resources()
215 if (rc) in ahci_platform_enable_resources()
218 rc = ahci_platform_enable_phys(hpriv); in ahci_platform_enable_resources()
219 if (rc) in ahci_platform_enable_resources()
230 return rc; in ahci_platform_enable_resources()
281 int rc; in ahci_platform_get_phy() local
288 rc = PTR_ERR(hpriv->phys[port]); in ahci_platform_get_phy()
289 switch (rc) { in ahci_platform_get_phy()
301 rc = 0; in ahci_platform_get_phy()
307 node->name, rc); in ahci_platform_get_phy()
312 return rc; in ahci_platform_get_phy()
319 int rc = 0; in ahci_platform_get_regulator() local
326 rc = PTR_ERR(target_pwr); in ahci_platform_get_regulator()
328 return rc; in ahci_platform_get_regulator()
353 int i, sz, enabled_ports = 0, rc = -ENOMEM, child_nodes; in ahci_platform_get_resources() local
370 rc = PTR_ERR(hpriv->mmio); in ahci_platform_get_resources()
387 rc = PTR_ERR(clk); in ahci_platform_get_resources()
388 if (rc == -EPROBE_DEFER) in ahci_platform_get_resources()
408 rc = -ENOMEM; in ahci_platform_get_resources()
414 rc = -ENOMEM; in ahci_platform_get_resources()
427 rc = -EINVAL; in ahci_platform_get_resources()
443 rc = ahci_platform_get_regulator(hpriv, port, in ahci_platform_get_resources()
445 if (rc == -EPROBE_DEFER) in ahci_platform_get_resources()
450 rc = ahci_platform_get_phy(hpriv, port, dev, child); in ahci_platform_get_resources()
451 if (rc) in ahci_platform_get_resources()
458 rc = -ENODEV; in ahci_platform_get_resources()
469 rc = ahci_platform_get_phy(hpriv, 0, dev, dev->of_node); in ahci_platform_get_resources()
470 if (rc) in ahci_platform_get_resources()
473 rc = ahci_platform_get_regulator(hpriv, 0, dev); in ahci_platform_get_resources()
474 if (rc == -EPROBE_DEFER) in ahci_platform_get_resources()
486 return ERR_PTR(rc); in ahci_platform_get_resources()
513 int i, irq, n_ports, rc; in ahci_platform_init_host() local
572 rc = dma_coerce_mask_and_coherent(dev, DMA_BIT_MASK(64)); in ahci_platform_init_host()
573 if (rc) { in ahci_platform_init_host()
574 rc = dma_coerce_mask_and_coherent(dev, in ahci_platform_init_host()
576 if (rc) { in ahci_platform_init_host()
578 return rc; in ahci_platform_init_host()
584 rc = ahci_reset_controller(host); in ahci_platform_init_host()
585 if (rc) in ahci_platform_init_host()
586 return rc; in ahci_platform_init_host()
654 int rc; in ahci_platform_resume_host() local
657 rc = ahci_reset_controller(host); in ahci_platform_resume_host()
658 if (rc) in ahci_platform_resume_host()
659 return rc; in ahci_platform_resume_host()
684 int rc; in ahci_platform_suspend() local
686 rc = ahci_platform_suspend_host(dev); in ahci_platform_suspend()
687 if (rc) in ahci_platform_suspend()
688 return rc; in ahci_platform_suspend()
710 int rc; in ahci_platform_resume() local
712 rc = ahci_platform_enable_resources(hpriv); in ahci_platform_resume()
713 if (rc) in ahci_platform_resume()
714 return rc; in ahci_platform_resume()
716 rc = ahci_platform_resume_host(dev); in ahci_platform_resume()
717 if (rc) in ahci_platform_resume()
730 return rc; in ahci_platform_resume()