net/ice: support new devices
[dpdk.git] / drivers / net / atlantic / atl_ethdev.c
index b2b3bd3..2fca914 100644 (file)
@@ -120,9 +120,6 @@ static int eth_atl_pci_remove(struct rte_pci_device *pci_dev);
 static int atl_dev_info_get(struct rte_eth_dev *dev,
                                struct rte_eth_dev_info *dev_info);
 
-int atl_logtype_init;
-int atl_logtype_driver;
-
 /*
  * The set of PCI devices this driver supports
  */
@@ -316,10 +313,6 @@ static const struct eth_dev_ops atl_eth_dev_ops = {
        .rx_queue_intr_enable = atl_dev_rx_queue_intr_enable,
        .rx_queue_intr_disable = atl_dev_rx_queue_intr_disable,
 
-       .rx_queue_count       = atl_rx_queue_count,
-       .rx_descriptor_status = atl_dev_rx_descriptor_status,
-       .tx_descriptor_status = atl_dev_tx_descriptor_status,
-
        /* EEPROM */
        .get_eeprom_length    = atl_dev_get_eeprom_length,
        .get_eeprom           = atl_dev_get_eeprom,
@@ -376,6 +369,11 @@ eth_atl_dev_init(struct rte_eth_dev *eth_dev)
        PMD_INIT_FUNC_TRACE();
 
        eth_dev->dev_ops = &atl_eth_dev_ops;
+
+       eth_dev->rx_queue_count       = atl_rx_queue_count;
+       eth_dev->rx_descriptor_status = atl_dev_rx_descriptor_status;
+       eth_dev->tx_descriptor_status = atl_dev_tx_descriptor_status;
+
        eth_dev->rx_pkt_burst = &atl_recv_pkts;
        eth_dev->tx_pkt_burst = &atl_xmit_pkts;
        eth_dev->tx_pkt_prepare = &atl_prep_pkts;
@@ -1397,8 +1395,7 @@ atl_dev_interrupt_action(struct rte_eth_dev *dev,
        /* Notify userapp if link status changed */
        if (!atl_dev_link_update(dev, 0)) {
                atl_dev_link_status_print(dev);
-               _rte_eth_dev_callback_process(dev,
-                       RTE_ETH_EVENT_INTR_LSC, NULL);
+               rte_eth_dev_callback_process(dev, RTE_ETH_EVENT_INTR_LSC, NULL);
        } else {
                if (hw->aq_fw_ops->send_macsec_req == NULL)
                        goto done;
@@ -1424,7 +1421,7 @@ atl_dev_interrupt_action(struct rte_eth_dev *dev,
                    resp.stats.egress_expired ||
                    resp.stats.ingress_expired) {
                        PMD_DRV_LOG(INFO, "RTE_ETH_EVENT_MACSEC");
-                       _rte_eth_dev_callback_process(dev,
+                       rte_eth_dev_callback_process(dev,
                                RTE_ETH_EVENT_MACSEC, NULL);
                }
        }
@@ -1929,13 +1926,5 @@ is_atlantic_supported(struct rte_eth_dev *dev)
 RTE_PMD_REGISTER_PCI(net_atlantic, rte_atl_pmd);
 RTE_PMD_REGISTER_PCI_TABLE(net_atlantic, pci_id_atl_map);
 RTE_PMD_REGISTER_KMOD_DEP(net_atlantic, "* igb_uio | uio_pci_generic");
-
-RTE_INIT(atl_init_log)
-{
-       atl_logtype_init = rte_log_register("pmd.net.atlantic.init");
-       if (atl_logtype_init >= 0)
-               rte_log_set_level(atl_logtype_init, RTE_LOG_NOTICE);
-       atl_logtype_driver = rte_log_register("pmd.net.atlantic.driver");
-       if (atl_logtype_driver >= 0)
-               rte_log_set_level(atl_logtype_driver, RTE_LOG_NOTICE);
-}
+RTE_LOG_REGISTER(atl_logtype_init, pmd.net.atlantic.init, NOTICE);
+RTE_LOG_REGISTER(atl_logtype_driver, pmd.net.atlantic.driver, NOTICE);