Lines Matching +full:bcm +full:- +full:sr
1 // SPDX-License-Identifier: GPL-2.0
3 * Copyright (C) 2016-2018 Broadcom
127 void __iomem *regs = phy_cfg->regs; in bcm_usb_ss_phy_init()
131 offset = phy_cfg->offset; in bcm_usb_ss_phy_init()
158 void __iomem *regs = phy_cfg->regs; in bcm_usb_hs_phy_init()
161 offset = phy_cfg->offset; in bcm_usb_hs_phy_init()
177 void __iomem *regs = phy_cfg->regs; in bcm_usb_phy_reset()
180 offset = phy_cfg->offset; in bcm_usb_phy_reset()
182 if (phy_cfg->type == USB_HS_PHY) { in bcm_usb_phy_reset()
195 int ret = -EINVAL; in bcm_usb_phy_init()
197 if (phy_cfg->type == USB_SS_PHY) in bcm_usb_phy_init()
199 else if (phy_cfg->type == USB_HS_PHY) in bcm_usb_phy_init()
219 return ERR_PTR(-EINVAL); in bcm_usb_phy_xlate()
221 if (phy_cfg->version == BCM_SR_USB_COMBO_PHY) { in bcm_usb_phy_xlate()
222 phy_idx = args->args[0]; in bcm_usb_phy_xlate()
225 return ERR_PTR(-ENODEV); in bcm_usb_phy_xlate()
229 return phy_cfg->phy; in bcm_usb_phy_xlate()
243 return -ENOMEM; in bcm_usb_phy_create()
266 return -ENOMEM; in bcm_usb_phy_create()
268 phy_cfg->regs = regs; in bcm_usb_phy_create()
269 phy_cfg->version = version; in bcm_usb_phy_create()
270 phy_cfg->offset = bcm_usb_hs_phy; in bcm_usb_phy_create()
271 phy_cfg->type = USB_HS_PHY; in bcm_usb_phy_create()
272 phy_cfg->phy = devm_phy_create(dev, node, &sr_phy_ops); in bcm_usb_phy_create()
273 if (IS_ERR(phy_cfg->phy)) in bcm_usb_phy_create()
274 return PTR_ERR(phy_cfg->phy); in bcm_usb_phy_create()
276 phy_set_drvdata(phy_cfg->phy, phy_cfg); in bcm_usb_phy_create()
278 return -ENODEV; in bcm_usb_phy_create()
287 .compatible = "brcm,sr-usb-combo-phy",
291 .compatible = "brcm,sr-usb-hs-phy",
300 struct device *dev = &pdev->dev; in bcm_usb_phy_probe()
301 struct device_node *dn = dev->of_node; in bcm_usb_phy_probe()
314 version = (uintptr_t)of_id->data; in bcm_usb_phy_probe()
316 return -ENODEV; in bcm_usb_phy_probe()
329 .name = "phy-bcm-sr-usb",