Lines Matching refs:ctrl_usb
122 struct am335x_control_usb *ctrl_usb; in am335x_get_phy_control() local
132 ctrl_usb = dev_get_drvdata(dev); in am335x_get_phy_control()
133 if (!ctrl_usb) in am335x_get_phy_control()
135 return &ctrl_usb->phy_ctrl; in am335x_get_phy_control()
142 struct am335x_control_usb *ctrl_usb; in am335x_control_usb_probe() local
152 ctrl_usb = devm_kzalloc(&pdev->dev, sizeof(*ctrl_usb), GFP_KERNEL); in am335x_control_usb_probe()
153 if (!ctrl_usb) in am335x_control_usb_probe()
156 ctrl_usb->dev = &pdev->dev; in am335x_control_usb_probe()
159 ctrl_usb->phy_reg = devm_ioremap_resource(&pdev->dev, res); in am335x_control_usb_probe()
160 if (IS_ERR(ctrl_usb->phy_reg)) in am335x_control_usb_probe()
161 return PTR_ERR(ctrl_usb->phy_reg); in am335x_control_usb_probe()
164 ctrl_usb->wkup = devm_ioremap_resource(&pdev->dev, res); in am335x_control_usb_probe()
165 if (IS_ERR(ctrl_usb->wkup)) in am335x_control_usb_probe()
166 return PTR_ERR(ctrl_usb->wkup); in am335x_control_usb_probe()
168 spin_lock_init(&ctrl_usb->lock); in am335x_control_usb_probe()
169 ctrl_usb->phy_ctrl = *phy_ctrl; in am335x_control_usb_probe()
171 dev_set_drvdata(ctrl_usb->dev, ctrl_usb); in am335x_control_usb_probe()