diff options
author | Stefan Roese <sr@denx.de> | 2017-04-24 18:45:24 +0300 |
---|---|---|
committer | Stefan Roese <sr@denx.de> | 2017-05-09 13:38:18 +0200 |
commit | 6ecc0b1cdfcb41e567aca53824ba36e50f658273 (patch) | |
tree | 3e5cfefad0ed882ffe9beb81f7a81db157f90c53 /drivers/phy/marvell/comphy_mux.c | |
parent | e89acc4bf1bfa9239e03a737ed8967ffcc71f5f7 (diff) | |
download | u-boot-6ecc0b1cdfcb41e567aca53824ba36e50f658273.zip u-boot-6ecc0b1cdfcb41e567aca53824ba36e50f658273.tar.gz u-boot-6ecc0b1cdfcb41e567aca53824ba36e50f658273.tar.bz2 |
phy: marvell: add IGNORE COMPHY type
This type tells u-boot to preserve the COMPHY settings as is
it is usefull in situations where the COMPHY was initialized by
earlier firmware.
Note that IGNORE is different from UNCONNECTED since setting
UNCONNECTED type will disconnect the COMPHY in the COMPHY MUX
which is a desired behaviour
Signed-off-by: Yehuda Yitschak <yehuday@marvell.com>
Signed-off-by: Stefan Roese <sr@denx.de>
Signed-off-by: Igal Liberman <igall@marvell.com>
Reviewed-by: Stefan Roese <sr@denx.de>
Diffstat (limited to 'drivers/phy/marvell/comphy_mux.c')
-rw-r--r-- | drivers/phy/marvell/comphy_mux.c | 7 |
1 files changed, 7 insertions, 0 deletions
diff --git a/drivers/phy/marvell/comphy_mux.c b/drivers/phy/marvell/comphy_mux.c index 1dc7426..b036fb1 100644 --- a/drivers/phy/marvell/comphy_mux.c +++ b/drivers/phy/marvell/comphy_mux.c @@ -27,6 +27,10 @@ static void comphy_mux_check_config(struct comphy_mux_data *mux_data, for (lane = 0; lane < comphy_max_lanes; lane++, comphy_map_data++, mux_data++) { + /* Don't check ignored COMPHYs */ + if (comphy_map_data->type == PHY_TYPE_IGNORE) + continue; + mux_opt = mux_data->mux_values; for (opt = 0, valid = 0; opt < mux_data->max_lane_values; opt++, mux_opt++) { @@ -83,6 +87,9 @@ static void comphy_mux_reg_write(struct comphy_mux_data *mux_data, for (lane = 0; lane < comphy_max_lanes; lane++, comphy_map_data++, mux_data++) { + if (comphy_map_data->type == PHY_TYPE_IGNORE) + continue; + offset = lane * bitcount; mask = (((1 << bitcount) - 1) << offset); value = (comphy_mux_get_mux_value(mux_data, |