Linux kernel mirror (for testing) git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
kernel os linux

phy: qcom-qmp: move PCS V5 registers to separate headers

Move PCS V5 registers to the separate headers.

Signed-off-by: Dmitry Baryshkov <dmitry.baryshkov@linaro.org>
Link: https://lore.kernel.org/r/20220705094320.1313312-17-dmitry.baryshkov@linaro.org
Signed-off-by: Vinod Koul <vkoul@kernel.org>

authored by

Dmitry Baryshkov and committed by
Vinod Koul
b7a2f882 41ad371f

+101 -58
+16
drivers/phy/qualcomm/phy-qcom-qmp-pcs-pcie-v5.h
··· 1 + /* Only for QMP V5 PHY - PCS_PCIE registers */ 2 + /* SPDX-License-Identifier: GPL-2.0 */ 3 + /* 4 + * Copyright (c) 2017, The Linux Foundation. All rights reserved. 5 + */ 6 + 7 + #ifndef QCOM_PHY_QMP_PCS_PCIE_V5_H_ 8 + #define QCOM_PHY_QMP_PCS_PCIE_V5_H_ 9 + 10 + /* Only for QMP V5 PHY - PCS_PCIE registers */ 11 + #define QPHY_V5_PCS_PCIE_ENDPOINT_REFCLK_DRIVE 0x20 12 + #define QPHY_V5_PCS_PCIE_INT_AUX_CLK_CONFIG1 0x54 13 + #define QPHY_V5_PCS_PCIE_OSC_DTCT_ACTIONS 0x94 14 + #define QPHY_V5_PCS_PCIE_EQ_CONFIG2 0xa8 15 + 16 + #endif
+27
drivers/phy/qualcomm/phy-qcom-qmp-pcs-ufs-v5.h
··· 1 + /* Only for QMP V5 PHY - UFS PCS registers */ 2 + /* SPDX-License-Identifier: GPL-2.0 */ 3 + /* 4 + * Copyright (c) 2017, The Linux Foundation. All rights reserved. 5 + */ 6 + 7 + #ifndef QCOM_PHY_QMP_PCS_UFS_V5_H_ 8 + #define QCOM_PHY_QMP_PCS_UFS_V5_H_ 9 + 10 + /* Only for QMP V5 PHY - UFS PCS registers */ 11 + #define QPHY_V5_PCS_UFS_TIMER_20US_CORECLK_STEPS_MSB 0x00c 12 + #define QPHY_V5_PCS_UFS_TIMER_20US_CORECLK_STEPS_LSB 0x010 13 + #define QPHY_V5_PCS_UFS_PLL_CNTL 0x02c 14 + #define QPHY_V5_PCS_UFS_TX_LARGE_AMP_DRV_LVL 0x030 15 + #define QPHY_V5_PCS_UFS_TX_SMALL_AMP_DRV_LVL 0x038 16 + #define QPHY_V5_PCS_UFS_TX_HSGEAR_CAPABILITY 0x074 17 + #define QPHY_V5_PCS_UFS_RX_HSGEAR_CAPABILITY 0x0b4 18 + #define QPHY_V5_PCS_UFS_DEBUG_BUS_CLKSEL 0x124 19 + #define QPHY_V5_PCS_UFS_RX_MIN_HIBERN8_TIME 0x150 20 + #define QPHY_V5_PCS_UFS_RX_SIGDET_CTRL1 0x154 21 + #define QPHY_V5_PCS_UFS_RX_SIGDET_CTRL2 0x158 22 + #define QPHY_V5_PCS_UFS_TX_PWM_GEAR_BAND 0x160 23 + #define QPHY_V5_PCS_UFS_TX_HS_GEAR_BAND 0x168 24 + #define QPHY_V5_PCS_UFS_TX_MID_TERM_CTRL1 0x1d8 25 + #define QPHY_V5_PCS_UFS_MULTI_LANE_CTRL1 0x1e0 26 + 27 + #endif
+36
drivers/phy/qualcomm/phy-qcom-qmp-pcs-usb-v5.h
··· 1 + /* SPDX-License-Identifier: GPL-2.0 */ 2 + /* 3 + * Copyright (c) 2017, The Linux Foundation. All rights reserved. 4 + */ 5 + 6 + #ifndef QCOM_PHY_QMP_PCS_USB_V5_H_ 7 + #define QCOM_PHY_QMP_PCS_USB_V5_H_ 8 + 9 + /* Only for QMP V5 PHY - USB3 have different offsets than V4 */ 10 + #define QPHY_V5_PCS_USB3_POWER_STATE_CONFIG1 0x000 11 + #define QPHY_V5_PCS_USB3_AUTONOMOUS_MODE_STATUS 0x004 12 + #define QPHY_V5_PCS_USB3_AUTONOMOUS_MODE_CTRL 0x008 13 + #define QPHY_V5_PCS_USB3_AUTONOMOUS_MODE_CTRL2 0x00c 14 + #define QPHY_V5_PCS_USB3_LFPS_RXTERM_IRQ_SOURCE_STATUS 0x010 15 + #define QPHY_V5_PCS_USB3_LFPS_RXTERM_IRQ_CLEAR 0x014 16 + #define QPHY_V5_PCS_USB3_LFPS_DET_HIGH_COUNT_VAL 0x018 17 + #define QPHY_V5_PCS_USB3_LFPS_TX_ECSTART 0x01c 18 + #define QPHY_V5_PCS_USB3_LFPS_PER_TIMER_VAL 0x020 19 + #define QPHY_V5_PCS_USB3_LFPS_TX_END_CNT_U3_START 0x024 20 + #define QPHY_V5_PCS_USB3_LFPS_CONFIG1 0x028 21 + #define QPHY_V5_PCS_USB3_RXEQTRAINING_LOCK_TIME 0x02c 22 + #define QPHY_V5_PCS_USB3_RXEQTRAINING_WAIT_TIME 0x030 23 + #define QPHY_V5_PCS_USB3_RXEQTRAINING_CTLE_TIME 0x034 24 + #define QPHY_V5_PCS_USB3_RXEQTRAINING_WAIT_TIME_S2 0x038 25 + #define QPHY_V5_PCS_USB3_RXEQTRAINING_DFE_TIME_S2 0x03c 26 + #define QPHY_V5_PCS_USB3_RCVR_DTCT_DLY_U3_L 0x040 27 + #define QPHY_V5_PCS_USB3_RCVR_DTCT_DLY_U3_H 0x044 28 + #define QPHY_V5_PCS_USB3_ARCVR_DTCT_EN_PERIOD 0x048 29 + #define QPHY_V5_PCS_USB3_ARCVR_DTCT_CM_DLY 0x04c 30 + #define QPHY_V5_PCS_USB3_TXONESZEROS_RUN_LENGTH 0x050 31 + #define QPHY_V5_PCS_USB3_ALFPS_DEGLITCH_VAL 0x054 32 + #define QPHY_V5_PCS_USB3_SIGDET_STARTUP_TIMER_VAL 0x058 33 + #define QPHY_V5_PCS_USB3_TEST_CONTROL 0x05c 34 + #define QPHY_V5_PCS_USB3_RXTERMINATION_DLY_SEL 0x060 35 + 36 + #endif
+17
drivers/phy/qualcomm/phy-qcom-qmp-pcs-v5.h
··· 1 + /* SPDX-License-Identifier: GPL-2.0 */ 2 + /* 3 + * Copyright (c) 2017, The Linux Foundation. All rights reserved. 4 + */ 5 + 6 + #ifndef QCOM_PHY_QMP_PCS_V5_H_ 7 + #define QCOM_PHY_QMP_PCS_V5_H_ 8 + 9 + /* Only for QMP V5 PHY - USB/PCIe PCS registers */ 10 + #define QPHY_V5_PCS_REFGEN_REQ_CONFIG1 0x0dc 11 + #define QPHY_V5_PCS_G3S2_PRE_GAIN 0x170 12 + #define QPHY_V5_PCS_RX_SIGDET_LVL 0x188 13 + #define QPHY_V5_PCS_RATE_SLEW_CNTRL1 0x198 14 + #define QPHY_V5_PCS_EQ_CONFIG2 0x1e0 15 + #define QPHY_V5_PCS_EQ_CONFIG3 0x1e4 16 + 17 + #endif
+5 -58
drivers/phy/qualcomm/phy-qcom-qmp.h
··· 30 30 #include "phy-qcom-qmp-pcs-usb-v4.h" 31 31 #include "phy-qcom-qmp-pcs-ufs-v4.h" 32 32 33 + #include "phy-qcom-qmp-pcs-v5.h" 34 + #include "phy-qcom-qmp-pcs-pcie-v5.h" 35 + #include "phy-qcom-qmp-pcs-usb-v5.h" 36 + #include "phy-qcom-qmp-pcs-ufs-v5.h" 37 + 33 38 /* Only for QMP V3 & V4 PHY - DP COM registers */ 34 39 #define QPHY_V3_DP_COM_PHY_MODE_CTRL 0x00 35 40 #define QPHY_V3_DP_COM_SW_RESET 0x04 ··· 339 334 #define QSERDES_V5_20_RX_RX_MARG_COARSE_THRESH5_RATE3 0x218 340 335 #define QSERDES_V5_20_RX_RX_MARG_COARSE_THRESH6_RATE3 0x220 341 336 342 - /* Only for QMP V5 PHY - USB/PCIe PCS registers */ 343 - #define QPHY_V5_PCS_REFGEN_REQ_CONFIG1 0x0dc 344 - #define QPHY_V5_PCS_G3S2_PRE_GAIN 0x170 345 - #define QPHY_V5_PCS_RX_SIGDET_LVL 0x188 346 - #define QPHY_V5_PCS_RATE_SLEW_CNTRL1 0x198 347 - #define QPHY_V5_PCS_EQ_CONFIG2 0x1e0 348 - #define QPHY_V5_PCS_EQ_CONFIG3 0x1e4 349 - 350 - /* Only for QMP V5 PHY - PCS_PCIE registers */ 351 - #define QPHY_V5_PCS_PCIE_ENDPOINT_REFCLK_DRIVE 0x20 352 - #define QPHY_V5_PCS_PCIE_INT_AUX_CLK_CONFIG1 0x54 353 - #define QPHY_V5_PCS_PCIE_OSC_DTCT_ACTIONS 0x94 354 - #define QPHY_V5_PCS_PCIE_EQ_CONFIG2 0xa8 355 - 356 337 /* Only for QMP V5_20 PHY - PCIe PCS registers */ 357 338 #define QPHY_V5_20_PCS_PCIE_ENDPOINT_REFCLK_DRIVE 0x01c 358 339 #define QPHY_V5_20_PCS_PCIE_OSC_DTCT_ACTIONS 0x090 ··· 346 355 #define QPHY_V5_20_PCS_PCIE_G4_EQ_CONFIG5 0x108 347 356 #define QPHY_V5_20_PCS_PCIE_G4_PRE_GAIN 0x15c 348 357 #define QPHY_V5_20_PCS_PCIE_RX_MARGINING_CONFIG3 0x184 349 - 350 - /* Only for QMP V5 PHY - UFS PCS registers */ 351 - #define QPHY_V5_PCS_UFS_TIMER_20US_CORECLK_STEPS_MSB 0x00c 352 - #define QPHY_V5_PCS_UFS_TIMER_20US_CORECLK_STEPS_LSB 0x010 353 - #define QPHY_V5_PCS_UFS_PLL_CNTL 0x02c 354 - #define QPHY_V5_PCS_UFS_TX_LARGE_AMP_DRV_LVL 0x030 355 - #define QPHY_V5_PCS_UFS_TX_SMALL_AMP_DRV_LVL 0x038 356 - #define QPHY_V5_PCS_UFS_TX_HSGEAR_CAPABILITY 0x074 357 - #define QPHY_V5_PCS_UFS_RX_HSGEAR_CAPABILITY 0x0b4 358 - #define QPHY_V5_PCS_UFS_DEBUG_BUS_CLKSEL 0x124 359 - #define QPHY_V5_PCS_UFS_RX_MIN_HIBERN8_TIME 0x150 360 - #define QPHY_V5_PCS_UFS_RX_SIGDET_CTRL1 0x154 361 - #define QPHY_V5_PCS_UFS_RX_SIGDET_CTRL2 0x158 362 - #define QPHY_V5_PCS_UFS_TX_PWM_GEAR_BAND 0x160 363 - #define QPHY_V5_PCS_UFS_TX_HS_GEAR_BAND 0x168 364 - #define QPHY_V5_PCS_UFS_TX_MID_TERM_CTRL1 0x1d8 365 - #define QPHY_V5_PCS_UFS_MULTI_LANE_CTRL1 0x1e0 366 - 367 - /* Only for QMP V5 PHY - USB3 have different offsets than V4 */ 368 - #define QPHY_V5_PCS_USB3_POWER_STATE_CONFIG1 0x000 369 - #define QPHY_V5_PCS_USB3_AUTONOMOUS_MODE_STATUS 0x004 370 - #define QPHY_V5_PCS_USB3_AUTONOMOUS_MODE_CTRL 0x008 371 - #define QPHY_V5_PCS_USB3_AUTONOMOUS_MODE_CTRL2 0x00c 372 - #define QPHY_V5_PCS_USB3_LFPS_RXTERM_IRQ_SOURCE_STATUS 0x010 373 - #define QPHY_V5_PCS_USB3_LFPS_RXTERM_IRQ_CLEAR 0x014 374 - #define QPHY_V5_PCS_USB3_LFPS_DET_HIGH_COUNT_VAL 0x018 375 - #define QPHY_V5_PCS_USB3_LFPS_TX_ECSTART 0x01c 376 - #define QPHY_V5_PCS_USB3_LFPS_PER_TIMER_VAL 0x020 377 - #define QPHY_V5_PCS_USB3_LFPS_TX_END_CNT_U3_START 0x024 378 - #define QPHY_V5_PCS_USB3_LFPS_CONFIG1 0x028 379 - #define QPHY_V5_PCS_USB3_RXEQTRAINING_LOCK_TIME 0x02c 380 - #define QPHY_V5_PCS_USB3_RXEQTRAINING_WAIT_TIME 0x030 381 - #define QPHY_V5_PCS_USB3_RXEQTRAINING_CTLE_TIME 0x034 382 - #define QPHY_V5_PCS_USB3_RXEQTRAINING_WAIT_TIME_S2 0x038 383 - #define QPHY_V5_PCS_USB3_RXEQTRAINING_DFE_TIME_S2 0x03c 384 - #define QPHY_V5_PCS_USB3_RCVR_DTCT_DLY_U3_L 0x040 385 - #define QPHY_V5_PCS_USB3_RCVR_DTCT_DLY_U3_H 0x044 386 - #define QPHY_V5_PCS_USB3_ARCVR_DTCT_EN_PERIOD 0x048 387 - #define QPHY_V5_PCS_USB3_ARCVR_DTCT_CM_DLY 0x04c 388 - #define QPHY_V5_PCS_USB3_TXONESZEROS_RUN_LENGTH 0x050 389 - #define QPHY_V5_PCS_USB3_ALFPS_DEGLITCH_VAL 0x054 390 - #define QPHY_V5_PCS_USB3_SIGDET_STARTUP_TIMER_VAL 0x058 391 - #define QPHY_V5_PCS_USB3_TEST_CONTROL 0x05c 392 - #define QPHY_V5_PCS_USB3_RXTERMINATION_DLY_SEL 0x060 393 358 394 359 #endif