Lines Matching refs:ctrl
135 struct serdes_ctrl *ctrl;
203 macro->ctrl->regs, HSIO_SD_CFG(idx));
209 macro->ctrl->regs, HSIO_MPLL_CFG(idx));
213 macro->ctrl->regs, HSIO_SD_CFG(idx));
217 macro->ctrl->regs, HSIO_MPLL_CFG(idx));
223 macro->ctrl->regs, HSIO_SD_CFG(idx));
229 macro->ctrl->regs, HSIO_MPLL_CFG(idx));
233 value = readl(macro->ctrl->regs + lan_offset(HSIO_SD_STAT(idx)));
236 dev_err(macro->ctrl->dev,
244 macro->ctrl->regs, HSIO_SD_CFG(idx));
248 value = readl(macro->ctrl->regs + lan_offset(HSIO_SD_STAT(idx)));
251 dev_err(macro->ctrl->dev,
261 macro->ctrl->regs, HSIO_SD_CFG(idx));
266 value = readl(macro->ctrl->regs + lan_offset(HSIO_SD_STAT(idx)));
269 dev_err(macro->ctrl->dev,
276 value = readl(macro->ctrl->regs + lan_offset(HSIO_SD_STAT(idx)));
279 dev_err(macro->ctrl->dev,
289 macro->ctrl->regs, HSIO_SD_CFG(idx));
386 conf.refclk125M = macro->ctrl->ref125;
410 macro->ctrl->regs, HSIO_RGMII_CFG(idx));
425 macro->ctrl->regs, HSIO_DLL_CFG(idx == 0 ? 0x0 : 0x2));
429 macro->ctrl->regs, HSIO_DLL_CFG(idx == 0 ? 0x0 : 0x2));
435 macro->ctrl->regs, HSIO_DLL_CFG(idx == 0 ? 0x1 : 0x3));
439 macro->ctrl->regs, HSIO_DLL_CFG(idx == 0 ? 0x1 : 0x3));
486 val = readl(macro->ctrl->regs + lan_offset(HSIO_HW_CFG));
489 macro->ctrl->regs, HSIO_HW_CFG);
521 struct serdes_ctrl *ctrl = dev_get_drvdata(dev);
531 struct serdes_macro *macro = phy_get_drvdata(ctrl->phys[i]);
537 return ctrl->phys[i];
543 static int serdes_phy_create(struct serdes_ctrl *ctrl, u8 idx, struct phy **phy)
547 *phy = devm_phy_create(ctrl->dev, NULL, &serdes_ops);
551 macro = devm_kzalloc(ctrl->dev, sizeof(*macro), GFP_KERNEL);
556 macro->ctrl = ctrl;
567 struct serdes_ctrl *ctrl;
573 ctrl = devm_kzalloc(&pdev->dev, sizeof(*ctrl), GFP_KERNEL);
574 if (!ctrl)
577 ctrl->dev = &pdev->dev;
578 ctrl->regs = devm_platform_get_and_ioremap_resource(pdev, 0, NULL);
579 if (IS_ERR(ctrl->regs))
580 return PTR_ERR(ctrl->regs);
587 ret = serdes_phy_create(ctrl, i, &ctrl->phys[i]);
594 ctrl->ref125 = (val == PLL_CONF_125MHZ ||
597 dev_set_drvdata(&pdev->dev, ctrl);
599 provider = devm_of_phy_provider_register(ctrl->dev,