Lines Matching +full:pre +full:- +full:emphasis
1 // SPDX-License-Identifier: GPL-2.0
354 /* voltage swing 0, pre-emphasis 0->3 */
362 /* voltage swing 1, pre-emphasis 0->2 */
369 /* voltage swing 2, pre-emphasis 0->1 */
375 /* voltage swing 3, pre-emphasis 0 */
382 /* voltage swing 0, pre-emphasis 0->3 */
390 /* voltage swing 1, pre-emphasis 0->2 */
397 /* voltage swing 2, pre-emphasis 0->1 */
403 /* voltage swing 3, pre-emphasis 0 */
410 /* voltage swing 0, pre-emphasis 0->3 */
418 /* voltage swing 1, pre-emphasis 0->2 */
425 /* voltage swing 2, pre-emphasis 0->1 */
431 /* voltage swing 3, pre-emphasis 0 */
445 return -ENOMEM; in rockchip_hdptx_phy_parse_training_table()
447 if (device_property_read_u8_array(dev, "training-table", buf, size)) { in rockchip_hdptx_phy_parse_training_table()
491 if (dp->set_rate) { in rockchip_hdptx_phy_verify_config()
492 switch (dp->link_rate) { in rockchip_hdptx_phy_verify_config()
498 return -EINVAL; in rockchip_hdptx_phy_verify_config()
502 switch (dp->lanes) { in rockchip_hdptx_phy_verify_config()
509 return -EINVAL; in rockchip_hdptx_phy_verify_config()
512 if (dp->set_voltages) { in rockchip_hdptx_phy_verify_config()
513 for (i = 0; i < dp->lanes; i++) { in rockchip_hdptx_phy_verify_config()
514 if (dp->voltage[i] > 3 || dp->pre[i] > 3) in rockchip_hdptx_phy_verify_config()
515 return -EINVAL; in rockchip_hdptx_phy_verify_config()
517 if (dp->voltage[i] + dp->pre[i] > 3) in rockchip_hdptx_phy_verify_config()
518 return -EINVAL; in rockchip_hdptx_phy_verify_config()
531 switch (dp->link_rate) { in rockchip_hdptx_phy_set_voltage()
533 ctrl = &tx_drv_ctrl_rbr[dp->voltage[lane]][dp->pre[lane]]; in rockchip_hdptx_phy_set_voltage()
534 regmap_update_bits(hdptx->regmap, LANE_REG(lane, 0x0c44), in rockchip_hdptx_phy_set_voltage()
539 ctrl = &tx_drv_ctrl_hbr[dp->voltage[lane]][dp->pre[lane]]; in rockchip_hdptx_phy_set_voltage()
540 regmap_update_bits(hdptx->regmap, LANE_REG(lane, 0x0c44), in rockchip_hdptx_phy_set_voltage()
546 ctrl = &tx_drv_ctrl_hbr2[dp->voltage[lane]][dp->pre[lane]]; in rockchip_hdptx_phy_set_voltage()
547 regmap_update_bits(hdptx->regmap, LANE_REG(lane, 0x0c44), in rockchip_hdptx_phy_set_voltage()
553 regmap_update_bits(hdptx->regmap, LANE_REG(lane, 0x0c0c), in rockchip_hdptx_phy_set_voltage()
557 ctrl->tx_drv_lvl_ctrl)); in rockchip_hdptx_phy_set_voltage()
559 regmap_update_bits(hdptx->regmap, LANE_REG(lane, 0x0c10), in rockchip_hdptx_phy_set_voltage()
564 ctrl->tx_drv_post_lvl_ctrl)); in rockchip_hdptx_phy_set_voltage()
566 regmap_update_bits(hdptx->regmap, LANE_REG(lane, 0x0c18), in rockchip_hdptx_phy_set_voltage()
571 ctrl->ana_tx_drv_idrv_idn_ctrl) | in rockchip_hdptx_phy_set_voltage()
573 ctrl->ana_tx_drv_idrv_iup_ctrl) | in rockchip_hdptx_phy_set_voltage()
575 ctrl->ana_tx_drv_accdrv_en)); in rockchip_hdptx_phy_set_voltage()
577 regmap_update_bits(hdptx->regmap, LANE_REG(lane, 0x0c1c), in rockchip_hdptx_phy_set_voltage()
582 ctrl->ana_tx_drv_accdrv_ctrl)); in rockchip_hdptx_phy_set_voltage()
583 regmap_update_bits(hdptx->regmap, LANE_REG(lane, 0x0c6c), in rockchip_hdptx_phy_set_voltage()
586 regmap_update_bits(hdptx->regmap, LANE_REG(lane, 0x0c58), in rockchip_hdptx_phy_set_voltage()
589 regmap_update_bits(hdptx->regmap, LANE_REG(lane, 0x0c40), in rockchip_hdptx_phy_set_voltage()
601 for (lane = 0; lane < dp->lanes; lane++) in rockchip_hdptx_phy_set_voltages()
604 reset_control_deassert(hdptx->lane_reset); in rockchip_hdptx_phy_set_voltages()
606 ret = regmap_read_poll_timeout(hdptx->grf, HDPTXPHY_GRF_STATUS0, in rockchip_hdptx_phy_set_voltages()
610 dev_err(hdptx->dev, "timeout waiting for phy_rdy\n"); in rockchip_hdptx_phy_set_voltages()
619 reset_control_assert(hdptx->lane_reset); in rockchip_hdptx_phy_lane_disable()
621 regmap_update_bits(hdptx->regmap, 0x081c, LANE_EN, in rockchip_hdptx_phy_lane_disable()
624 rockchip_grf_write(hdptx->grf, HDPTXPHY_GRF_CON0, PLL_EN, in rockchip_hdptx_phy_lane_disable()
627 regmap_update_bits(hdptx->regmap, 0x0020, OVRD_LCPLL_EN | LCPLL_EN, in rockchip_hdptx_phy_lane_disable()
630 regmap_update_bits(hdptx->regmap, 0x00f4, OVRD_ROPLL_EN | ROPLL_EN, in rockchip_hdptx_phy_lane_disable()
638 if (!dp->lanes) { in rockchip_hdptx_phy_set_lanes()
643 regmap_update_bits(hdptx->regmap, 0x081c, LANE_EN, in rockchip_hdptx_phy_set_lanes()
644 FIELD_PREP(LANE_EN, GENMASK(dp->lanes - 1, 0))); in rockchip_hdptx_phy_set_lanes()
655 rockchip_grf_write(hdptx->grf, HDPTXPHY_GRF_CON0, PLL_EN, in rockchip_hdptx_phy_set_rate()
658 switch (dp->link_rate) { in rockchip_hdptx_phy_set_rate()
669 return -EINVAL; in rockchip_hdptx_phy_set_rate()
672 regmap_update_bits(hdptx->regmap, 0x0254, DP_TX_LINK_BW, in rockchip_hdptx_phy_set_rate()
675 if (dp->ssc) { in rockchip_hdptx_phy_set_rate()
676 regmap_update_bits(hdptx->regmap, 0x01d0, in rockchip_hdptx_phy_set_rate()
680 regmap_write(hdptx->regmap, 0x01d4, in rockchip_hdptx_phy_set_rate()
682 regmap_update_bits(hdptx->regmap, 0x01d8, in rockchip_hdptx_phy_set_rate()
685 regmap_update_bits(hdptx->regmap, 0x0264, SSC_EN, in rockchip_hdptx_phy_set_rate()
688 regmap_update_bits(hdptx->regmap, 0x01d0, in rockchip_hdptx_phy_set_rate()
692 regmap_write(hdptx->regmap, 0x01d4, in rockchip_hdptx_phy_set_rate()
694 regmap_update_bits(hdptx->regmap, 0x01d8, in rockchip_hdptx_phy_set_rate()
697 regmap_update_bits(hdptx->regmap, 0x0264, SSC_EN, in rockchip_hdptx_phy_set_rate()
701 regmap_update_bits(hdptx->regmap, 0x0020, OVRD_LCPLL_EN | LCPLL_EN, in rockchip_hdptx_phy_set_rate()
704 regmap_update_bits(hdptx->regmap, 0x00f4, OVRD_ROPLL_EN | ROPLL_EN, in rockchip_hdptx_phy_set_rate()
708 rockchip_grf_write(hdptx->grf, HDPTXPHY_GRF_CON0, PLL_EN, in rockchip_hdptx_phy_set_rate()
711 ret = regmap_read_poll_timeout(hdptx->grf, HDPTXPHY_GRF_STATUS0, in rockchip_hdptx_phy_set_rate()
715 dev_err(hdptx->dev, "timeout waiting for pll_lock_done\n"); in rockchip_hdptx_phy_set_rate()
730 return -EINVAL; in rockchip_hdptx_phy_configure()
732 ret = rockchip_hdptx_phy_verify_config(hdptx, &opts->dp); in rockchip_hdptx_phy_configure()
734 dev_err(hdptx->dev, "invalid params for phy configure\n"); in rockchip_hdptx_phy_configure()
738 if (opts->dp.set_rate) { in rockchip_hdptx_phy_configure()
739 ret = rockchip_hdptx_phy_set_rate(hdptx, &opts->dp); in rockchip_hdptx_phy_configure()
741 dev_err(hdptx->dev, "failed to set rate: %d\n", ret); in rockchip_hdptx_phy_configure()
746 if (opts->dp.set_lanes) { in rockchip_hdptx_phy_configure()
747 ret = rockchip_hdptx_phy_set_lanes(hdptx, &opts->dp); in rockchip_hdptx_phy_configure()
749 dev_err(hdptx->dev, "failed to set lanes: %d\n", ret); in rockchip_hdptx_phy_configure()
754 if (opts->dp.set_voltages) { in rockchip_hdptx_phy_configure()
755 ret = rockchip_hdptx_phy_set_voltages(hdptx, &opts->dp); in rockchip_hdptx_phy_configure()
757 dev_err(hdptx->dev, "failed to set voltages: %d\n", in rockchip_hdptx_phy_configure()
768 regmap_write(hdptx->regmap, 0x0144, FIELD_PREP(ROPLL_PMS_MDIV, 0x87)); in rockchip_hdptx_phy_dp_pll_init()
769 regmap_write(hdptx->regmap, 0x0148, FIELD_PREP(ROPLL_PMS_MDIV, 0x71)); in rockchip_hdptx_phy_dp_pll_init()
770 regmap_write(hdptx->regmap, 0x014c, FIELD_PREP(ROPLL_PMS_MDIV, 0x71)); in rockchip_hdptx_phy_dp_pll_init()
772 regmap_write(hdptx->regmap, 0x0154, in rockchip_hdptx_phy_dp_pll_init()
774 regmap_write(hdptx->regmap, 0x0158, in rockchip_hdptx_phy_dp_pll_init()
776 regmap_write(hdptx->regmap, 0x015c, in rockchip_hdptx_phy_dp_pll_init()
779 regmap_write(hdptx->regmap, 0x0164, in rockchip_hdptx_phy_dp_pll_init()
783 regmap_write(hdptx->regmap, 0x0168, in rockchip_hdptx_phy_dp_pll_init()
786 regmap_update_bits(hdptx->regmap, 0x016c, ROPLL_PMS_SDIV_HBR2, in rockchip_hdptx_phy_dp_pll_init()
789 regmap_update_bits(hdptx->regmap, 0x0178, ANA_ROPLL_SDM_EN, in rockchip_hdptx_phy_dp_pll_init()
791 regmap_update_bits(hdptx->regmap, 0x0178, in rockchip_hdptx_phy_dp_pll_init()
795 regmap_update_bits(hdptx->regmap, 0x0178, ROPLL_SDC_FRACTIONAL_EN_RBR, in rockchip_hdptx_phy_dp_pll_init()
797 regmap_update_bits(hdptx->regmap, 0x0178, ROPLL_SDC_FRACTIONAL_EN_HBR, in rockchip_hdptx_phy_dp_pll_init()
799 regmap_update_bits(hdptx->regmap, 0x0178, ROPLL_SDC_FRACTIONAL_EN_HBR2, in rockchip_hdptx_phy_dp_pll_init()
801 regmap_update_bits(hdptx->regmap, 0x017c, in rockchip_hdptx_phy_dp_pll_init()
806 regmap_write(hdptx->regmap, 0x0180, in rockchip_hdptx_phy_dp_pll_init()
808 regmap_write(hdptx->regmap, 0x0184, in rockchip_hdptx_phy_dp_pll_init()
810 regmap_write(hdptx->regmap, 0x0188, in rockchip_hdptx_phy_dp_pll_init()
813 regmap_update_bits(hdptx->regmap, 0x0190, in rockchip_hdptx_phy_dp_pll_init()
821 regmap_write(hdptx->regmap, 0x0194, in rockchip_hdptx_phy_dp_pll_init()
823 regmap_write(hdptx->regmap, 0x0198, in rockchip_hdptx_phy_dp_pll_init()
825 regmap_write(hdptx->regmap, 0x019c, in rockchip_hdptx_phy_dp_pll_init()
828 regmap_update_bits(hdptx->regmap, 0x01a4, ROPLL_SDC_N_RBR, in rockchip_hdptx_phy_dp_pll_init()
830 regmap_update_bits(hdptx->regmap, 0x01a8, in rockchip_hdptx_phy_dp_pll_init()
835 regmap_write(hdptx->regmap, 0x01b0, in rockchip_hdptx_phy_dp_pll_init()
837 regmap_write(hdptx->regmap, 0x01b4, in rockchip_hdptx_phy_dp_pll_init()
839 regmap_write(hdptx->regmap, 0x01b8, in rockchip_hdptx_phy_dp_pll_init()
842 regmap_write(hdptx->regmap, 0x01c0, in rockchip_hdptx_phy_dp_pll_init()
844 regmap_write(hdptx->regmap, 0x01c4, in rockchip_hdptx_phy_dp_pll_init()
846 regmap_write(hdptx->regmap, 0x01c8, in rockchip_hdptx_phy_dp_pll_init()
849 regmap_update_bits(hdptx->regmap, 0x01d0, in rockchip_hdptx_phy_dp_pll_init()
853 regmap_update_bits(hdptx->regmap, 0x01dc, ANA_ROPLL_SSC_CLK_DIV_SEL, in rockchip_hdptx_phy_dp_pll_init()
856 regmap_update_bits(hdptx->regmap, 0x0118, in rockchip_hdptx_phy_dp_pll_init()
860 regmap_update_bits(hdptx->regmap, 0x011c, in rockchip_hdptx_phy_dp_pll_init()
866 regmap_update_bits(hdptx->regmap, 0x0204, ANA_PLL_CD_TX_SER_RATE_SEL, in rockchip_hdptx_phy_dp_pll_init()
869 regmap_update_bits(hdptx->regmap, 0x025c, DIG_CLK_SEL, in rockchip_hdptx_phy_dp_pll_init()
871 regmap_update_bits(hdptx->regmap, 0x021c, ANA_PLL_TX_HS_CLK_EN, in rockchip_hdptx_phy_dp_pll_init()
873 regmap_update_bits(hdptx->regmap, 0x0204, in rockchip_hdptx_phy_dp_pll_init()
877 regmap_update_bits(hdptx->regmap, 0x0264, CMN_ROPLL_ALONE_MODE, in rockchip_hdptx_phy_dp_pll_init()
879 regmap_update_bits(hdptx->regmap, 0x0208, ANA_PLL_CD_VREG_GAIN_CTRL, in rockchip_hdptx_phy_dp_pll_init()
881 regmap_update_bits(hdptx->regmap, 0x00f0, ANA_LCPLL_RESERVED7, in rockchip_hdptx_phy_dp_pll_init()
883 regmap_update_bits(hdptx->regmap, 0x020c, ANA_PLL_CD_VREG_ICTRL, in rockchip_hdptx_phy_dp_pll_init()
885 regmap_update_bits(hdptx->regmap, 0x0214, ANA_PLL_SYNC_LOSS_DET_MODE, in rockchip_hdptx_phy_dp_pll_init()
887 regmap_update_bits(hdptx->regmap, 0x0210, PLL_LCRO_CLK_SEL, in rockchip_hdptx_phy_dp_pll_init()
889 regmap_update_bits(hdptx->regmap, 0x0268, HS_SPEED_SEL, in rockchip_hdptx_phy_dp_pll_init()
891 regmap_update_bits(hdptx->regmap, 0x026c, LS_SPEED_SEL, in rockchip_hdptx_phy_dp_pll_init()
900 regmap_update_bits(hdptx->regmap, 0x0414, ANA_SB_TX_HLVL_PROG, in rockchip_hdptx_phy_dp_aux_init()
902 regmap_update_bits(hdptx->regmap, 0x0418, ANA_SB_TX_LLVL_PROG, in rockchip_hdptx_phy_dp_aux_init()
905 regmap_update_bits(hdptx->regmap, 0x044c, in rockchip_hdptx_phy_dp_aux_init()
909 regmap_update_bits(hdptx->regmap, 0x0450, in rockchip_hdptx_phy_dp_aux_init()
913 regmap_update_bits(hdptx->regmap, 0x0454, in rockchip_hdptx_phy_dp_aux_init()
917 regmap_update_bits(hdptx->regmap, 0x0458, in rockchip_hdptx_phy_dp_aux_init()
920 regmap_update_bits(hdptx->regmap, 0x045c, in rockchip_hdptx_phy_dp_aux_init()
923 regmap_update_bits(hdptx->regmap, 0x0460, in rockchip_hdptx_phy_dp_aux_init()
926 regmap_update_bits(hdptx->regmap, 0x0468, SB_TG_CNT_RUN_NO_7_0, in rockchip_hdptx_phy_dp_aux_init()
928 regmap_update_bits(hdptx->regmap, 0x046c, in rockchip_hdptx_phy_dp_aux_init()
932 regmap_update_bits(hdptx->regmap, 0x0470, SB_AFC_STB_NUM, in rockchip_hdptx_phy_dp_aux_init()
934 regmap_update_bits(hdptx->regmap, 0x0474, SB_TG_OSC_CNT_MIN, in rockchip_hdptx_phy_dp_aux_init()
936 regmap_update_bits(hdptx->regmap, 0x0478, SB_TG_OSC_CNT_MAX, in rockchip_hdptx_phy_dp_aux_init()
938 regmap_update_bits(hdptx->regmap, 0x047c, SB_PWM_AFC_CTRL, in rockchip_hdptx_phy_dp_aux_init()
940 regmap_update_bits(hdptx->regmap, 0x0434, ANA_SB_DMRX_LPBK_DATA, in rockchip_hdptx_phy_dp_aux_init()
942 regmap_update_bits(hdptx->regmap, 0x0440, in rockchip_hdptx_phy_dp_aux_init()
946 regmap_update_bits(hdptx->regmap, 0x043c, ANA_SB_VREG_GAIN_CTRL, in rockchip_hdptx_phy_dp_aux_init()
948 regmap_update_bits(hdptx->regmap, 0x0408, ANA_SB_RXTERM_OFFSP, in rockchip_hdptx_phy_dp_aux_init()
950 regmap_update_bits(hdptx->regmap, 0x040c, ANA_SB_RXTERM_OFFSN, in rockchip_hdptx_phy_dp_aux_init()
952 regmap_update_bits(hdptx->regmap, 0x047c, SB_RCAL_RSTN, in rockchip_hdptx_phy_dp_aux_init()
954 regmap_update_bits(hdptx->regmap, 0x0410, SB_AUX_EN, in rockchip_hdptx_phy_dp_aux_init()
956 regmap_update_bits(hdptx->regmap, 0x0480, SB_AUX_EN_IN, in rockchip_hdptx_phy_dp_aux_init()
958 regmap_update_bits(hdptx->regmap, 0x040c, OVRD_SB_RX_RESCAL_DONE, in rockchip_hdptx_phy_dp_aux_init()
960 regmap_update_bits(hdptx->regmap, 0x0410, OVRD_SB_EN, in rockchip_hdptx_phy_dp_aux_init()
962 regmap_update_bits(hdptx->regmap, 0x0408, OVRD_SB_RXTERM_EN, in rockchip_hdptx_phy_dp_aux_init()
964 regmap_update_bits(hdptx->regmap, 0x043c, OVRD_SB_VREG_EN, in rockchip_hdptx_phy_dp_aux_init()
966 regmap_update_bits(hdptx->regmap, 0x0410, OVRD_SB_AUX_EN, in rockchip_hdptx_phy_dp_aux_init()
969 rockchip_grf_write(hdptx->grf, HDPTXPHY_GRF_CON0, BGR_EN, in rockchip_hdptx_phy_dp_aux_init()
971 rockchip_grf_write(hdptx->grf, HDPTXPHY_GRF_CON0, BIAS_EN, in rockchip_hdptx_phy_dp_aux_init()
975 reset_control_deassert(hdptx->init_reset); in rockchip_hdptx_phy_dp_aux_init()
977 reset_control_deassert(hdptx->cmn_reset); in rockchip_hdptx_phy_dp_aux_init()
980 regmap_update_bits(hdptx->regmap, 0x040c, SB_RX_RESCAL_DONE, in rockchip_hdptx_phy_dp_aux_init()
983 regmap_update_bits(hdptx->regmap, 0x0410, SB_EN, in rockchip_hdptx_phy_dp_aux_init()
986 regmap_update_bits(hdptx->regmap, 0x0408, SB_RXRERM_EN, in rockchip_hdptx_phy_dp_aux_init()
989 regmap_update_bits(hdptx->regmap, 0x043c, SB_VREG_EN, in rockchip_hdptx_phy_dp_aux_init()
992 regmap_update_bits(hdptx->regmap, 0x0410, SB_AUX_EN, in rockchip_hdptx_phy_dp_aux_init()
996 ret = regmap_read_poll_timeout(hdptx->grf, HDPTXPHY_GRF_STATUS0, in rockchip_hdptx_phy_dp_aux_init()
1000 dev_err(hdptx->dev, "timeout waiting for sb_rdy\n"); in rockchip_hdptx_phy_dp_aux_init()
1011 reset_control_assert(hdptx->lane_reset); in rockchip_hdptx_phy_reset()
1012 reset_control_assert(hdptx->cmn_reset); in rockchip_hdptx_phy_reset()
1013 reset_control_assert(hdptx->init_reset); in rockchip_hdptx_phy_reset()
1015 reset_control_assert(hdptx->apb_reset); in rockchip_hdptx_phy_reset()
1017 reset_control_deassert(hdptx->apb_reset); in rockchip_hdptx_phy_reset()
1020 regmap_update_bits(hdptx->regmap, LANE_REG(lane, 0x0c04), in rockchip_hdptx_phy_reset()
1025 rockchip_grf_write(hdptx->grf, HDPTXPHY_GRF_CON0, PLL_EN, in rockchip_hdptx_phy_reset()
1027 rockchip_grf_write(hdptx->grf, HDPTXPHY_GRF_CON0, BIAS_EN, in rockchip_hdptx_phy_reset()
1029 rockchip_grf_write(hdptx->grf, HDPTXPHY_GRF_CON0, BGR_EN, in rockchip_hdptx_phy_reset()
1037 regmap_read(hdptx->grf, HDPTXPHY_GRF_STATUS0, &status); in rockchip_hdptx_phy_enabled()
1049 ret = clk_bulk_prepare_enable(hdptx->nr_clks, hdptx->clks); in rockchip_hdptx_phy_power_on()
1059 u32 invert = hdptx->lane_polarity_invert[lane]; in rockchip_hdptx_phy_power_on()
1061 regmap_update_bits(hdptx->regmap, LANE_REG(lane, 0x0c78), in rockchip_hdptx_phy_power_on()
1067 rockchip_grf_write(hdptx->grf, HDPTXPHY_GRF_CON0, in rockchip_hdptx_phy_power_on()
1071 regmap_update_bits(hdptx->regmap, 0x0800, PROTOCOL_SEL, in rockchip_hdptx_phy_power_on()
1073 regmap_update_bits(hdptx->regmap, 0x0818, DATA_BUS_WIDTH, in rockchip_hdptx_phy_power_on()
1075 regmap_update_bits(hdptx->regmap, 0x0818, BUS_WIDTH_SEL, in rockchip_hdptx_phy_power_on()
1081 rockchip_grf_write(hdptx->grf, HDPTXPHY_GRF_CON0, in rockchip_hdptx_phy_power_on()
1085 regmap_update_bits(hdptx->regmap, 0x0800, PROTOCOL_SEL, in rockchip_hdptx_phy_power_on()
1098 clk_bulk_disable_unprepare(hdptx->nr_clks, hdptx->clks); in rockchip_hdptx_phy_power_off()
1140 struct device *dev = &pdev->dev; in rockchip_hdptx_phy_probe()
1149 return -ENOMEM; in rockchip_hdptx_phy_probe()
1151 hdptx->dev = dev; in rockchip_hdptx_phy_probe()
1158 hdptx->regmap = devm_regmap_init_mmio(dev, regs, in rockchip_hdptx_phy_probe()
1160 if (IS_ERR(hdptx->regmap)) in rockchip_hdptx_phy_probe()
1161 return dev_err_probe(dev, PTR_ERR(hdptx->regmap), in rockchip_hdptx_phy_probe()
1164 ret = devm_clk_bulk_get_all(dev, &hdptx->clks); in rockchip_hdptx_phy_probe()
1168 hdptx->nr_clks = ret; in rockchip_hdptx_phy_probe()
1170 hdptx->apb_reset = devm_reset_control_get(dev, "apb"); in rockchip_hdptx_phy_probe()
1171 if (IS_ERR(hdptx->apb_reset)) in rockchip_hdptx_phy_probe()
1172 return dev_err_probe(dev, PTR_ERR(hdptx->apb_reset), in rockchip_hdptx_phy_probe()
1175 hdptx->init_reset = devm_reset_control_get(dev, "init"); in rockchip_hdptx_phy_probe()
1176 if (IS_ERR(hdptx->init_reset)) in rockchip_hdptx_phy_probe()
1177 return dev_err_probe(dev, PTR_ERR(hdptx->init_reset), in rockchip_hdptx_phy_probe()
1180 hdptx->cmn_reset = devm_reset_control_get(dev, "cmn"); in rockchip_hdptx_phy_probe()
1181 if (IS_ERR(hdptx->cmn_reset)) in rockchip_hdptx_phy_probe()
1182 return dev_err_probe(dev, PTR_ERR(hdptx->cmn_reset), in rockchip_hdptx_phy_probe()
1185 hdptx->lane_reset = devm_reset_control_get(dev, "lane"); in rockchip_hdptx_phy_probe()
1186 if (IS_ERR(hdptx->lane_reset)) in rockchip_hdptx_phy_probe()
1187 return dev_err_probe(dev, PTR_ERR(hdptx->lane_reset), in rockchip_hdptx_phy_probe()
1190 hdptx->grf = syscon_regmap_lookup_by_phandle(dev->of_node, in rockchip_hdptx_phy_probe()
1192 if (IS_ERR(hdptx->grf)) in rockchip_hdptx_phy_probe()
1193 return dev_err_probe(dev, PTR_ERR(hdptx->grf), in rockchip_hdptx_phy_probe()
1196 device_property_read_u32_array(dev, "lane-polarity-invert", in rockchip_hdptx_phy_probe()
1197 hdptx->lane_polarity_invert, 4); in rockchip_hdptx_phy_probe()
1215 { .compatible = "rockchip,rk3588-hdptx-phy", },
1223 .name = "rockchip-hdptx-phy",
1229 MODULE_AUTHOR("Wyon Bi <bivvy.bi@rock-chips.com>");