phy_drd           163 drivers/phy/samsung/phy-exynos5-usbdrd.c 	void (*phy_init)(struct exynos5_usbdrd_phy *phy_drd);
phy_drd           280 drivers/phy/samsung/phy-exynos5-usbdrd.c 	struct exynos5_usbdrd_phy *phy_drd = to_usbdrd_phy(inst);
phy_drd           283 drivers/phy/samsung/phy-exynos5-usbdrd.c 	reg = readl(phy_drd->reg_phy + EXYNOS5_DRD_PHYCLKRST);
phy_drd           293 drivers/phy/samsung/phy-exynos5-usbdrd.c 	switch (phy_drd->extrefclk) {
phy_drd           311 drivers/phy/samsung/phy-exynos5-usbdrd.c 		dev_dbg(phy_drd->dev, "unsupported ref clk\n");
phy_drd           326 drivers/phy/samsung/phy-exynos5-usbdrd.c 	struct exynos5_usbdrd_phy *phy_drd = to_usbdrd_phy(inst);
phy_drd           329 drivers/phy/samsung/phy-exynos5-usbdrd.c 	reg = readl(phy_drd->reg_phy + EXYNOS5_DRD_PHYCLKRST);
phy_drd           337 drivers/phy/samsung/phy-exynos5-usbdrd.c 	reg |= PHYCLKRST_FSEL(phy_drd->extrefclk);
phy_drd           342 drivers/phy/samsung/phy-exynos5-usbdrd.c static void exynos5_usbdrd_pipe3_init(struct exynos5_usbdrd_phy *phy_drd)
phy_drd           346 drivers/phy/samsung/phy-exynos5-usbdrd.c 	reg = readl(phy_drd->reg_phy + EXYNOS5_DRD_PHYPARAM1);
phy_drd           350 drivers/phy/samsung/phy-exynos5-usbdrd.c 	writel(reg, phy_drd->reg_phy + EXYNOS5_DRD_PHYPARAM1);
phy_drd           352 drivers/phy/samsung/phy-exynos5-usbdrd.c 	reg = readl(phy_drd->reg_phy + EXYNOS5_DRD_PHYTEST);
phy_drd           354 drivers/phy/samsung/phy-exynos5-usbdrd.c 	writel(reg, phy_drd->reg_phy + EXYNOS5_DRD_PHYTEST);
phy_drd           357 drivers/phy/samsung/phy-exynos5-usbdrd.c static void exynos5_usbdrd_utmi_init(struct exynos5_usbdrd_phy *phy_drd)
phy_drd           361 drivers/phy/samsung/phy-exynos5-usbdrd.c 	reg = readl(phy_drd->reg_phy + EXYNOS5_DRD_PHYPARAM0);
phy_drd           365 drivers/phy/samsung/phy-exynos5-usbdrd.c 	writel(reg, phy_drd->reg_phy + EXYNOS5_DRD_PHYPARAM0);
phy_drd           367 drivers/phy/samsung/phy-exynos5-usbdrd.c 	reg = readl(phy_drd->reg_phy + EXYNOS5_DRD_PHYPARAM1);
phy_drd           371 drivers/phy/samsung/phy-exynos5-usbdrd.c 	writel(reg, phy_drd->reg_phy + EXYNOS5_DRD_PHYPARAM1);
phy_drd           374 drivers/phy/samsung/phy-exynos5-usbdrd.c 	writel(PHYUTMI_OTGDISABLE, phy_drd->reg_phy + EXYNOS5_DRD_PHYUTMI);
phy_drd           376 drivers/phy/samsung/phy-exynos5-usbdrd.c 	reg = readl(phy_drd->reg_phy + EXYNOS5_DRD_PHYTEST);
phy_drd           378 drivers/phy/samsung/phy-exynos5-usbdrd.c 	writel(reg, phy_drd->reg_phy + EXYNOS5_DRD_PHYTEST);
phy_drd           386 drivers/phy/samsung/phy-exynos5-usbdrd.c 	struct exynos5_usbdrd_phy *phy_drd = to_usbdrd_phy(inst);
phy_drd           388 drivers/phy/samsung/phy-exynos5-usbdrd.c 	ret = clk_prepare_enable(phy_drd->clk);
phy_drd           393 drivers/phy/samsung/phy-exynos5-usbdrd.c 	writel(0x0, phy_drd->reg_phy + EXYNOS5_DRD_PHYREG0);
phy_drd           394 drivers/phy/samsung/phy-exynos5-usbdrd.c 	writel(0x0, phy_drd->reg_phy + EXYNOS5_DRD_PHYRESUME);
phy_drd           402 drivers/phy/samsung/phy-exynos5-usbdrd.c 	writel(reg, phy_drd->reg_phy + EXYNOS5_DRD_LINKSYSTEM);
phy_drd           404 drivers/phy/samsung/phy-exynos5-usbdrd.c 	reg = readl(phy_drd->reg_phy + EXYNOS5_DRD_PHYPARAM0);
phy_drd           407 drivers/phy/samsung/phy-exynos5-usbdrd.c 	writel(reg, phy_drd->reg_phy + EXYNOS5_DRD_PHYPARAM0);
phy_drd           410 drivers/phy/samsung/phy-exynos5-usbdrd.c 	reg = readl(phy_drd->reg_phy + EXYNOS5_DRD_PHYUTMICLKSEL);
phy_drd           412 drivers/phy/samsung/phy-exynos5-usbdrd.c 	writel(reg, phy_drd->reg_phy + EXYNOS5_DRD_PHYUTMICLKSEL);
phy_drd           415 drivers/phy/samsung/phy-exynos5-usbdrd.c 	inst->phy_cfg->phy_init(phy_drd);
phy_drd           431 drivers/phy/samsung/phy-exynos5-usbdrd.c 	writel(reg, phy_drd->reg_phy + EXYNOS5_DRD_PHYCLKRST);
phy_drd           436 drivers/phy/samsung/phy-exynos5-usbdrd.c 	writel(reg, phy_drd->reg_phy + EXYNOS5_DRD_PHYCLKRST);
phy_drd           438 drivers/phy/samsung/phy-exynos5-usbdrd.c 	clk_disable_unprepare(phy_drd->clk);
phy_drd           448 drivers/phy/samsung/phy-exynos5-usbdrd.c 	struct exynos5_usbdrd_phy *phy_drd = to_usbdrd_phy(inst);
phy_drd           450 drivers/phy/samsung/phy-exynos5-usbdrd.c 	ret = clk_prepare_enable(phy_drd->clk);
phy_drd           457 drivers/phy/samsung/phy-exynos5-usbdrd.c 	writel(reg, phy_drd->reg_phy + EXYNOS5_DRD_PHYUTMI);
phy_drd           460 drivers/phy/samsung/phy-exynos5-usbdrd.c 	reg = readl(phy_drd->reg_phy + EXYNOS5_DRD_PHYCLKRST);
phy_drd           464 drivers/phy/samsung/phy-exynos5-usbdrd.c 	writel(reg, phy_drd->reg_phy + EXYNOS5_DRD_PHYCLKRST);
phy_drd           467 drivers/phy/samsung/phy-exynos5-usbdrd.c 	reg = readl(phy_drd->reg_phy + EXYNOS5_DRD_PHYTEST);
phy_drd           470 drivers/phy/samsung/phy-exynos5-usbdrd.c 	writel(reg, phy_drd->reg_phy + EXYNOS5_DRD_PHYTEST);
phy_drd           472 drivers/phy/samsung/phy-exynos5-usbdrd.c 	clk_disable_unprepare(phy_drd->clk);
phy_drd           481 drivers/phy/samsung/phy-exynos5-usbdrd.c 	struct exynos5_usbdrd_phy *phy_drd = to_usbdrd_phy(inst);
phy_drd           483 drivers/phy/samsung/phy-exynos5-usbdrd.c 	dev_dbg(phy_drd->dev, "Request to power_on usbdrd_phy phy\n");
phy_drd           485 drivers/phy/samsung/phy-exynos5-usbdrd.c 	clk_prepare_enable(phy_drd->ref_clk);
phy_drd           486 drivers/phy/samsung/phy-exynos5-usbdrd.c 	if (!phy_drd->drv_data->has_common_clk_gate) {
phy_drd           487 drivers/phy/samsung/phy-exynos5-usbdrd.c 		clk_prepare_enable(phy_drd->pipeclk);
phy_drd           488 drivers/phy/samsung/phy-exynos5-usbdrd.c 		clk_prepare_enable(phy_drd->utmiclk);
phy_drd           489 drivers/phy/samsung/phy-exynos5-usbdrd.c 		clk_prepare_enable(phy_drd->itpclk);
phy_drd           493 drivers/phy/samsung/phy-exynos5-usbdrd.c 	if (phy_drd->vbus_boost) {
phy_drd           494 drivers/phy/samsung/phy-exynos5-usbdrd.c 		ret = regulator_enable(phy_drd->vbus_boost);
phy_drd           496 drivers/phy/samsung/phy-exynos5-usbdrd.c 			dev_err(phy_drd->dev,
phy_drd           502 drivers/phy/samsung/phy-exynos5-usbdrd.c 	if (phy_drd->vbus) {
phy_drd           503 drivers/phy/samsung/phy-exynos5-usbdrd.c 		ret = regulator_enable(phy_drd->vbus);
phy_drd           505 drivers/phy/samsung/phy-exynos5-usbdrd.c 			dev_err(phy_drd->dev, "Failed to enable VBUS supply\n");
phy_drd           516 drivers/phy/samsung/phy-exynos5-usbdrd.c 	if (phy_drd->vbus_boost)
phy_drd           517 drivers/phy/samsung/phy-exynos5-usbdrd.c 		regulator_disable(phy_drd->vbus_boost);
phy_drd           520 drivers/phy/samsung/phy-exynos5-usbdrd.c 	clk_disable_unprepare(phy_drd->ref_clk);
phy_drd           521 drivers/phy/samsung/phy-exynos5-usbdrd.c 	if (!phy_drd->drv_data->has_common_clk_gate) {
phy_drd           522 drivers/phy/samsung/phy-exynos5-usbdrd.c 		clk_disable_unprepare(phy_drd->itpclk);
phy_drd           523 drivers/phy/samsung/phy-exynos5-usbdrd.c 		clk_disable_unprepare(phy_drd->utmiclk);
phy_drd           524 drivers/phy/samsung/phy-exynos5-usbdrd.c 		clk_disable_unprepare(phy_drd->pipeclk);
phy_drd           533 drivers/phy/samsung/phy-exynos5-usbdrd.c 	struct exynos5_usbdrd_phy *phy_drd = to_usbdrd_phy(inst);
phy_drd           535 drivers/phy/samsung/phy-exynos5-usbdrd.c 	dev_dbg(phy_drd->dev, "Request to power_off usbdrd_phy phy\n");
phy_drd           541 drivers/phy/samsung/phy-exynos5-usbdrd.c 	if (phy_drd->vbus)
phy_drd           542 drivers/phy/samsung/phy-exynos5-usbdrd.c 		regulator_disable(phy_drd->vbus);
phy_drd           543 drivers/phy/samsung/phy-exynos5-usbdrd.c 	if (phy_drd->vbus_boost)
phy_drd           544 drivers/phy/samsung/phy-exynos5-usbdrd.c 		regulator_disable(phy_drd->vbus_boost);
phy_drd           546 drivers/phy/samsung/phy-exynos5-usbdrd.c 	clk_disable_unprepare(phy_drd->ref_clk);
phy_drd           547 drivers/phy/samsung/phy-exynos5-usbdrd.c 	if (!phy_drd->drv_data->has_common_clk_gate) {
phy_drd           548 drivers/phy/samsung/phy-exynos5-usbdrd.c 		clk_disable_unprepare(phy_drd->itpclk);
phy_drd           549 drivers/phy/samsung/phy-exynos5-usbdrd.c 		clk_disable_unprepare(phy_drd->pipeclk);
phy_drd           550 drivers/phy/samsung/phy-exynos5-usbdrd.c 		clk_disable_unprepare(phy_drd->utmiclk);
phy_drd           556 drivers/phy/samsung/phy-exynos5-usbdrd.c static int crport_handshake(struct exynos5_usbdrd_phy *phy_drd,
phy_drd           562 drivers/phy/samsung/phy-exynos5-usbdrd.c 	writel(val | cmd, phy_drd->reg_phy + EXYNOS5_DRD_PHYREG0);
phy_drd           565 drivers/phy/samsung/phy-exynos5-usbdrd.c 		result = readl(phy_drd->reg_phy + EXYNOS5_DRD_PHYREG1);
phy_drd           573 drivers/phy/samsung/phy-exynos5-usbdrd.c 		dev_err(phy_drd->dev,
phy_drd           580 drivers/phy/samsung/phy-exynos5-usbdrd.c 	writel(val, phy_drd->reg_phy + EXYNOS5_DRD_PHYREG0);
phy_drd           583 drivers/phy/samsung/phy-exynos5-usbdrd.c 		result = readl(phy_drd->reg_phy + EXYNOS5_DRD_PHYREG1);
phy_drd           591 drivers/phy/samsung/phy-exynos5-usbdrd.c 		dev_err(phy_drd->dev,
phy_drd           599 drivers/phy/samsung/phy-exynos5-usbdrd.c static int crport_ctrl_write(struct exynos5_usbdrd_phy *phy_drd,
phy_drd           606 drivers/phy/samsung/phy-exynos5-usbdrd.c 	       phy_drd->reg_phy + EXYNOS5_DRD_PHYREG0);
phy_drd           607 drivers/phy/samsung/phy-exynos5-usbdrd.c 	ret = crport_handshake(phy_drd, PHYREG0_CR_DATA_IN(addr),
phy_drd           614 drivers/phy/samsung/phy-exynos5-usbdrd.c 	       phy_drd->reg_phy + EXYNOS5_DRD_PHYREG0);
phy_drd           615 drivers/phy/samsung/phy-exynos5-usbdrd.c 	ret = crport_handshake(phy_drd, PHYREG0_CR_DATA_IN(data),
phy_drd           620 drivers/phy/samsung/phy-exynos5-usbdrd.c 	ret = crport_handshake(phy_drd, PHYREG0_CR_DATA_IN(data),
phy_drd           631 drivers/phy/samsung/phy-exynos5-usbdrd.c static int exynos5420_usbdrd_phy_calibrate(struct exynos5_usbdrd_phy *phy_drd)
phy_drd           645 drivers/phy/samsung/phy-exynos5-usbdrd.c 	ret = crport_ctrl_write(phy_drd,
phy_drd           649 drivers/phy/samsung/phy-exynos5-usbdrd.c 		dev_err(phy_drd->dev,
phy_drd           659 drivers/phy/samsung/phy-exynos5-usbdrd.c 	ret = crport_ctrl_write(phy_drd,
phy_drd           663 drivers/phy/samsung/phy-exynos5-usbdrd.c 		dev_err(phy_drd->dev,
phy_drd           677 drivers/phy/samsung/phy-exynos5-usbdrd.c 	switch (phy_drd->extrefclk) {
phy_drd           691 drivers/phy/samsung/phy-exynos5-usbdrd.c 	ret = crport_ctrl_write(phy_drd,
phy_drd           695 drivers/phy/samsung/phy-exynos5-usbdrd.c 		dev_err(phy_drd->dev,
phy_drd           704 drivers/phy/samsung/phy-exynos5-usbdrd.c 	struct exynos5_usbdrd_phy *phy_drd = dev_get_drvdata(dev);
phy_drd           709 drivers/phy/samsung/phy-exynos5-usbdrd.c 	return phy_drd->phys[args->args[0]].phy;
phy_drd           715 drivers/phy/samsung/phy-exynos5-usbdrd.c 	struct exynos5_usbdrd_phy *phy_drd = to_usbdrd_phy(inst);
phy_drd           717 drivers/phy/samsung/phy-exynos5-usbdrd.c 	return exynos5420_usbdrd_phy_calibrate(phy_drd);
phy_drd           729 drivers/phy/samsung/phy-exynos5-usbdrd.c static int exynos5_usbdrd_phy_clk_handle(struct exynos5_usbdrd_phy *phy_drd)
phy_drd           734 drivers/phy/samsung/phy-exynos5-usbdrd.c 	phy_drd->clk = devm_clk_get(phy_drd->dev, "phy");
phy_drd           735 drivers/phy/samsung/phy-exynos5-usbdrd.c 	if (IS_ERR(phy_drd->clk)) {
phy_drd           736 drivers/phy/samsung/phy-exynos5-usbdrd.c 		dev_err(phy_drd->dev, "Failed to get phy clock\n");
phy_drd           737 drivers/phy/samsung/phy-exynos5-usbdrd.c 		return PTR_ERR(phy_drd->clk);
phy_drd           740 drivers/phy/samsung/phy-exynos5-usbdrd.c 	phy_drd->ref_clk = devm_clk_get(phy_drd->dev, "ref");
phy_drd           741 drivers/phy/samsung/phy-exynos5-usbdrd.c 	if (IS_ERR(phy_drd->ref_clk)) {
phy_drd           742 drivers/phy/samsung/phy-exynos5-usbdrd.c 		dev_err(phy_drd->dev, "Failed to get phy reference clock\n");
phy_drd           743 drivers/phy/samsung/phy-exynos5-usbdrd.c 		return PTR_ERR(phy_drd->ref_clk);
phy_drd           745 drivers/phy/samsung/phy-exynos5-usbdrd.c 	ref_rate = clk_get_rate(phy_drd->ref_clk);
phy_drd           747 drivers/phy/samsung/phy-exynos5-usbdrd.c 	ret = exynos5_rate_to_clk(ref_rate, &phy_drd->extrefclk);
phy_drd           749 drivers/phy/samsung/phy-exynos5-usbdrd.c 		dev_err(phy_drd->dev, "Clock rate (%ld) not supported\n",
phy_drd           754 drivers/phy/samsung/phy-exynos5-usbdrd.c 	if (!phy_drd->drv_data->has_common_clk_gate) {
phy_drd           755 drivers/phy/samsung/phy-exynos5-usbdrd.c 		phy_drd->pipeclk = devm_clk_get(phy_drd->dev, "phy_pipe");
phy_drd           756 drivers/phy/samsung/phy-exynos5-usbdrd.c 		if (IS_ERR(phy_drd->pipeclk)) {
phy_drd           757 drivers/phy/samsung/phy-exynos5-usbdrd.c 			dev_info(phy_drd->dev,
phy_drd           759 drivers/phy/samsung/phy-exynos5-usbdrd.c 			phy_drd->pipeclk = NULL;
phy_drd           762 drivers/phy/samsung/phy-exynos5-usbdrd.c 		phy_drd->utmiclk = devm_clk_get(phy_drd->dev, "phy_utmi");
phy_drd           763 drivers/phy/samsung/phy-exynos5-usbdrd.c 		if (IS_ERR(phy_drd->utmiclk)) {
phy_drd           764 drivers/phy/samsung/phy-exynos5-usbdrd.c 			dev_info(phy_drd->dev,
phy_drd           766 drivers/phy/samsung/phy-exynos5-usbdrd.c 			phy_drd->utmiclk = NULL;
phy_drd           769 drivers/phy/samsung/phy-exynos5-usbdrd.c 		phy_drd->itpclk = devm_clk_get(phy_drd->dev, "itp");
phy_drd           770 drivers/phy/samsung/phy-exynos5-usbdrd.c 		if (IS_ERR(phy_drd->itpclk)) {
phy_drd           771 drivers/phy/samsung/phy-exynos5-usbdrd.c 			dev_info(phy_drd->dev,
phy_drd           773 drivers/phy/samsung/phy-exynos5-usbdrd.c 			phy_drd->itpclk = NULL;
phy_drd           843 drivers/phy/samsung/phy-exynos5-usbdrd.c 	struct exynos5_usbdrd_phy *phy_drd;
phy_drd           852 drivers/phy/samsung/phy-exynos5-usbdrd.c 	phy_drd = devm_kzalloc(dev, sizeof(*phy_drd), GFP_KERNEL);
phy_drd           853 drivers/phy/samsung/phy-exynos5-usbdrd.c 	if (!phy_drd)
phy_drd           856 drivers/phy/samsung/phy-exynos5-usbdrd.c 	dev_set_drvdata(dev, phy_drd);
phy_drd           857 drivers/phy/samsung/phy-exynos5-usbdrd.c 	phy_drd->dev = dev;
phy_drd           860 drivers/phy/samsung/phy-exynos5-usbdrd.c 	phy_drd->reg_phy = devm_ioremap_resource(dev, res);
phy_drd           861 drivers/phy/samsung/phy-exynos5-usbdrd.c 	if (IS_ERR(phy_drd->reg_phy))
phy_drd           862 drivers/phy/samsung/phy-exynos5-usbdrd.c 		return PTR_ERR(phy_drd->reg_phy);
phy_drd           868 drivers/phy/samsung/phy-exynos5-usbdrd.c 	phy_drd->drv_data = drv_data;
phy_drd           870 drivers/phy/samsung/phy-exynos5-usbdrd.c 	ret = exynos5_usbdrd_phy_clk_handle(phy_drd);
phy_drd           894 drivers/phy/samsung/phy-exynos5-usbdrd.c 		pmu_offset = phy_drd->drv_data->pmu_offset_usbdrd1_phy;
phy_drd           898 drivers/phy/samsung/phy-exynos5-usbdrd.c 		pmu_offset = phy_drd->drv_data->pmu_offset_usbdrd0_phy;
phy_drd           903 drivers/phy/samsung/phy-exynos5-usbdrd.c 	phy_drd->vbus = devm_regulator_get(dev, "vbus");
phy_drd           904 drivers/phy/samsung/phy-exynos5-usbdrd.c 	if (IS_ERR(phy_drd->vbus)) {
phy_drd           905 drivers/phy/samsung/phy-exynos5-usbdrd.c 		ret = PTR_ERR(phy_drd->vbus);
phy_drd           910 drivers/phy/samsung/phy-exynos5-usbdrd.c 		phy_drd->vbus = NULL;
phy_drd           913 drivers/phy/samsung/phy-exynos5-usbdrd.c 	phy_drd->vbus_boost = devm_regulator_get(dev, "vbus-boost");
phy_drd           914 drivers/phy/samsung/phy-exynos5-usbdrd.c 	if (IS_ERR(phy_drd->vbus_boost)) {
phy_drd           915 drivers/phy/samsung/phy-exynos5-usbdrd.c 		ret = PTR_ERR(phy_drd->vbus_boost);
phy_drd           920 drivers/phy/samsung/phy-exynos5-usbdrd.c 		phy_drd->vbus_boost = NULL;
phy_drd           933 drivers/phy/samsung/phy-exynos5-usbdrd.c 		phy_drd->phys[i].phy = phy;
phy_drd           934 drivers/phy/samsung/phy-exynos5-usbdrd.c 		phy_drd->phys[i].index = i;
phy_drd           935 drivers/phy/samsung/phy-exynos5-usbdrd.c 		phy_drd->phys[i].reg_pmu = reg_pmu;
phy_drd           936 drivers/phy/samsung/phy-exynos5-usbdrd.c 		phy_drd->phys[i].pmu_offset = pmu_offset;
phy_drd           937 drivers/phy/samsung/phy-exynos5-usbdrd.c 		phy_drd->phys[i].phy_cfg = &drv_data->phy_cfg[i];
phy_drd           938 drivers/phy/samsung/phy-exynos5-usbdrd.c 		phy_set_drvdata(phy, &phy_drd->phys[i]);
phy_drd           944 drivers/phy/samsung/phy-exynos5-usbdrd.c 		dev_err(phy_drd->dev, "Failed to register phy provider\n");