Lines Matching defs:usbphyc_phy

337 	struct stm32_usbphyc_phy *usbphyc_phy = phy_get_drvdata(phy);
338 struct stm32_usbphyc *usbphyc = usbphyc_phy->usbphyc;
339 u32 reg_mon = STM32_USBPHYC_MONITOR(usbphyc_phy->index);
360 usbphyc_phy->active = true;
372 struct stm32_usbphyc_phy *usbphyc_phy = phy_get_drvdata(phy);
373 struct stm32_usbphyc *usbphyc = usbphyc_phy->usbphyc;
375 usbphyc_phy->active = false;
382 struct stm32_usbphyc_phy *usbphyc_phy = phy_get_drvdata(phy);
384 if (usbphyc_phy->vbus)
385 return regulator_enable(usbphyc_phy->vbus);
392 struct stm32_usbphyc_phy *usbphyc_phy = phy_get_drvdata(phy);
394 if (usbphyc_phy->vbus)
395 return regulator_disable(usbphyc_phy->vbus);
466 struct stm32_usbphyc_phy *usbphyc_phy = usbphyc->phys[index];
478 usbphyc_phy->tune |= INCURREN | FIELD_PREP(INCURRINT, val);
485 usbphyc_phy->tune |= LFSCAPEN;
488 usbphyc_phy->tune |= HSDRVSLEW;
494 usbphyc_phy->tune |= HSDRVDCCUR;
497 usbphyc_phy->tune |= HSDRVCURINCR | FIELD_PREP(HSDRVDCLEV, val);
505 usbphyc_phy->tune |= FSDRVRFADJ;
508 usbphyc_phy->tune |= HSDRVRFRED;
513 usbphyc_phy->tune |= FIELD_PREP(HSDRVCHKITRM, val);
521 usbphyc_phy->tune |= FIELD_PREP(HSDRVCHKZTRM, val);
529 usbphyc_phy->tune |= FIELD_PREP(SQLCHCTL, val);
535 usbphyc_phy->tune |= HDRXGNEQEN;
540 usbphyc_phy->tune |= FIELD_PREP(HSRXOFF, val);
546 usbphyc_phy->tune |= HSFALLPREEM;
549 usbphyc_phy->tune |= SHTCCTCTLPROT;
552 usbphyc_phy->tune |= STAGSEL;
555 usbphyc_phy->tune |= FIELD_PREP(OTPCOMP, otpcomp);
558 * By default, if no st,xxx tuning property is used, usbphyc_phy->tune is equal to
561 writel_relaxed(usbphyc_phy->tune, usbphyc->base + reg);
580 struct stm32_usbphyc_phy *usbphyc_phy = NULL;
586 usbphyc_phy = usbphyc->phys[port];
590 if (!usbphyc_phy) {
595 if (((usbphyc_phy->index == 0) && (args->args_count != 0)) ||
596 ((usbphyc_phy->index == 1) && (args->args_count != 1))) {
598 usbphyc_phy->index);
603 if (usbphyc_phy->index == 1) {
614 return usbphyc_phy->phy;
694 struct stm32_usbphyc_phy *usbphyc_phy;
707 usbphyc_phy = devm_kzalloc(dev, sizeof(*usbphyc_phy),
709 if (!usbphyc_phy) {
722 usbphyc->phys[port] = usbphyc_phy;
724 phy_set_drvdata(phy, usbphyc_phy);
791 struct stm32_usbphyc_phy *usbphyc_phy;
798 usbphyc_phy = usbphyc->phys[port];
799 writel_relaxed(usbphyc_phy->tune, usbphyc->base + STM32_USBPHYC_TUNE(port));