Re: [PATCH v4 net-next 13/19] ionic: Add initial ethtool support
From: David Miller <davem@davemloft.net>
Date: 2019-07-23 21:35:13
From: Shannon Nelson <redacted> Date: Mon, 22 Jul 2019 14:40:17 -0700
+static int ionic_get_link_ksettings(struct net_device *netdev,
+ struct ethtool_link_ksettings *ks)
+{
+ struct lif *lif = netdev_priv(netdev);
+ struct ionic_dev *idev = &lif->ionic->idev;
+ int copper_seen = 0;Reverse christmas tree ordering here please.
+static int ionic_set_link_ksettings(struct net_device *netdev,
+ const struct ethtool_link_ksettings *ks)
+{
+ struct lif *lif = netdev_priv(netdev);
+ struct ionic *ionic = lif->ionic;
+ struct ionic_dev *idev = &lif->ionic->idev;
+ u8 fec_type = PORT_FEC_TYPE_NONE;
+ u32 req_rs, req_fc;
+ int err = 0;Likewise.
+static void ionic_get_pauseparam(struct net_device *netdev,
+ struct ethtool_pauseparam *pause)
+{
+ struct lif *lif = netdev_priv(netdev);
+ struct ionic_dev *idev = &lif->ionic->idev;
+ uint8_t pause_type = idev->port_info->config.pause_type;Likewise.
+static int ionic_set_pauseparam(struct net_device *netdev,
+ struct ethtool_pauseparam *pause)
+{
+ struct lif *lif = netdev_priv(netdev);
+ struct ionic *ionic = lif->ionic;
+ struct ionic_dev *idev = &lif->ionic->idev;
+ u32 requested_pause;
+ int err;Likewise.
+static int ionic_get_module_info(struct net_device *netdev,
+ struct ethtool_modinfo *modinfo)
+
+{
+ struct lif *lif = netdev_priv(netdev);
+ struct ionic_dev *idev = &lif->ionic->idev;
+ struct xcvr_status *xcvr;Likewise.
+static int ionic_get_module_eeprom(struct net_device *netdev,
+ struct ethtool_eeprom *ee,
+ u8 *data)
+{
+ struct lif *lif = netdev_priv(netdev);
+ struct ionic_dev *idev = &lif->ionic->idev;
+ struct xcvr_status *xcvr;
+ u32 len;Likewise.