• S
    phy: qcom-qmp: Move 'serdes' and 'cfg' into 'struct qcom_phy' · aa968cb1
    Stephen Boyd 提交于
    The serdes I/O region is where the PLL for the phy is controlled.
    Sometimes the PLL is shared between multiple phys, for example in the
    PCIe case where there are three phys inside the same wrapper. Other
    times the PLL is for a single phy, i.e. some USB3 phys. To complete the
    trifecta we have the USB3+DP combo phy where the USB3 and DP phys each
    have their own serdes region because they have their own PLL while they
    both share a common I/O region pertaining to the USB type-c pinout and
    cable orientation.
    
    Let's move the serdes iomem pointer into 'struct qmp_phy' so that we can
    correlate PLL control to the phy that uses it. This allows us to support
    the USB3+DP combo phy in this driver. This isn't a problem for the
    3-lane/phy PCIe phy because there is a common init function that is the
    only place the serdes region is programmed.
    
    Furthermore, move the configuration data that contains most of the
    register programming sequences to the qmp phy struct. This data isn't
    qmp wrapper specific. It is phy specific data used to tune various
    settings for things like pre-emphasis, bias, etc.
    Signed-off-by: NStephen Boyd <swboyd@chromium.org>
    Cc: Jeykumar Sankaran <jsanka@codeaurora.org>
    Cc: Chandan Uddaraju <chandanu@codeaurora.org>
    Cc: Vara Reddy <varar@codeaurora.org>
    Cc: Tanmay Shah <tanmay@codeaurora.org>
    Cc: Bjorn Andersson <bjorn.andersson@linaro.org>
    Cc: Manu Gautam <mgautam@codeaurora.org>
    Cc: Sandeep Maheswaram <sanm@codeaurora.org>
    Cc: Douglas Anderson <dianders@chromium.org>
    Cc: Sean Paul <seanpaul@chromium.org>
    Cc: Jonathan Marek <jonathan@marek.ca>
    Cc: Dmitry Baryshkov <dmitry.baryshkov@linaro.org>
    Cc: Rob Clark <robdclark@chromium.org>
    Link: https://lore.kernel.org/r/20200916231202.3637932-5-swboyd@chromium.orgSigned-off-by: NVinod Koul <vkoul@kernel.org>
    aa968cb1
phy-qcom-qmp.c 126.6 KB