Skip to content

Commit

Permalink
doc: sfp-phylink: correct code indentation
Browse files Browse the repository at this point in the history
Using vim to edit the phylink documentation reveals some mistakes due
to the "invisible" pythonesque white space indentation that can't be
seen with other editors. Fix it.

Signed-off-by: Russell King <rmk+kernel@armlinux.org.uk>
Signed-off-by: David S. Miller <davem@davemloft.net>
  • Loading branch information
Russell King authored and David S. Miller committed Mar 3, 2020
1 parent 630fe59 commit c04d102
Showing 1 changed file with 16 additions and 16 deletions.
32 changes: 16 additions & 16 deletions Documentation/networking/sfp-phylink.rst
Original file line number Diff line number Diff line change
Expand Up @@ -138,27 +138,27 @@ this documentation.

.. code-block:: c
static int foo_ethtool_set_link_ksettings(struct net_device *dev,
const struct ethtool_link_ksettings *cmd)
{
struct foo_priv *priv = netdev_priv(dev);
return phylink_ethtool_ksettings_set(priv->phylink, cmd);
}

static int foo_ethtool_get_link_ksettings(struct net_device *dev,
struct ethtool_link_ksettings *cmd)
{
struct foo_priv *priv = netdev_priv(dev);
static int foo_ethtool_set_link_ksettings(struct net_device *dev,
const struct ethtool_link_ksettings *cmd)
{
struct foo_priv *priv = netdev_priv(dev);
return phylink_ethtool_ksettings_set(priv->phylink, cmd);
}

return phylink_ethtool_ksettings_get(priv->phylink, cmd);
}
static int foo_ethtool_get_link_ksettings(struct net_device *dev,
struct ethtool_link_ksettings *cmd)
{
struct foo_priv *priv = netdev_priv(dev);
return phylink_ethtool_ksettings_get(priv->phylink, cmd);
}

7. Replace the call to:
7. Replace the call to::

phy_dev = of_phy_connect(dev, node, link_func, flags, phy_interface);

and associated code with a call to:
and associated code with a call to::

err = phylink_of_phy_connect(priv->phylink, node, flags);

Expand Down

0 comments on commit c04d102

Please sign in to comment.