Commit 60dcf58a authored by Aaro Koskinen's avatar Aaro Koskinen Committed by Greg Kroah-Hartman

staging: octeon: stop using cvmx_helper_link_autoconf()

Stop using cvmx_helper_link_autoconf(). We want to remove it in the future,
as it duplicates link state information into platform code for no reason.
Signed-off-by: default avatarAaro Koskinen <aaro.koskinen@iki.fi>
Signed-off-by: default avatarGreg Kroah-Hartman <gregkh@linuxfoundation.org>
parent 943407ce
...@@ -117,7 +117,10 @@ static void cvm_oct_rgmii_poll(struct net_device *dev) ...@@ -117,7 +117,10 @@ static void cvm_oct_rgmii_poll(struct net_device *dev)
cvmx_helper_link_info_t link_info; cvmx_helper_link_info_t link_info;
bool status_change; bool status_change;
link_info = cvmx_helper_link_autoconf(priv->port); link_info = cvmx_helper_link_get(priv->port);
if (priv->link_info != link_info.u64 &&
cvmx_helper_link_set(priv->port, link_info))
link_info.u64 = priv->link_info;
status_change = priv->link_info != link_info.u64; status_change = priv->link_info != link_info.u64;
priv->link_info = link_info.u64; priv->link_info = link_info.u64;
......
...@@ -521,8 +521,10 @@ void cvm_oct_link_poll(struct net_device *dev) ...@@ -521,8 +521,10 @@ void cvm_oct_link_poll(struct net_device *dev)
if (link_info.u64 == priv->link_info) if (link_info.u64 == priv->link_info)
return; return;
link_info = cvmx_helper_link_autoconf(priv->port); if (cvmx_helper_link_set(priv->port, link_info))
priv->link_info = link_info.u64; link_info.u64 = priv->link_info;
else
priv->link_info = link_info.u64;
if (link_info.s.link_up) { if (link_info.s.link_up) {
if (!netif_carrier_ok(dev)) if (!netif_carrier_ok(dev))
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment