From: David Marchand <david.marchand@6wind.com>
To: dev@dpdk.org
Subject: [dpdk-dev] [PATCH v3 11/20] i40e: clean log messages
Date: Wed, 17 Sep 2014 15:46:43 +0200 [thread overview]
Message-ID: <1410961612-8571-12-git-send-email-david.marchand@6wind.com> (raw)
In-Reply-To: <1410961612-8571-1-git-send-email-david.marchand@6wind.com>
Clean log messages:
- remove leading \n in some messages,
- remove trailing \n in some messages,
- split multi lines messages.
Signed-off-by: David Marchand <david.marchand@6wind.com>
v2 Reviewed-by: Jay Rolette <rolette@infiniteio.com>
v2 Acked-by: Bruce Richardson <bruce.richardson@intel.com>
---
lib/librte_pmd_i40e/i40e_ethdev.c | 248 +++++++++++++++++-----------------
lib/librte_pmd_i40e/i40e_ethdev_vf.c | 114 ++++++++--------
lib/librte_pmd_i40e/i40e_pf.c | 72 +++++-----
lib/librte_pmd_i40e/i40e_rxtx.c | 76 +++++------
4 files changed, 255 insertions(+), 255 deletions(-)
diff --git a/lib/librte_pmd_i40e/i40e_ethdev.c b/lib/librte_pmd_i40e/i40e_ethdev.c
index aadb548..a00d6ca 100644
--- a/lib/librte_pmd_i40e/i40e_ethdev.c
+++ b/lib/librte_pmd_i40e/i40e_ethdev.c
@@ -371,7 +371,7 @@ eth_i40e_dev_init(__rte_unused struct eth_driver *eth_drv,
hw->hw_addr = (uint8_t *)(pci_dev->mem_resource[0].addr);
if (!hw->hw_addr) {
PMD_INIT_LOG(ERR, "Hardware is not available, "
- "as address is NULL\n");
+ "as address is NULL");
return -ENODEV;
}
@@ -406,7 +406,7 @@ eth_i40e_dev_init(__rte_unused struct eth_driver *eth_drv,
PMD_INIT_LOG(ERR, "Failed to init adminq: %d", ret);
return -EIO;
}
- PMD_INIT_LOG(INFO, "FW %d.%d API %d.%d NVM %02d.%02d.%02d eetrack %04x\n",
+ PMD_INIT_LOG(INFO, "FW %d.%d API %d.%d NVM %02d.%02d.%02d eetrack %04x",
hw->aq.fw_maj_ver, hw->aq.fw_min_ver,
hw->aq.api_maj_ver, hw->aq.api_min_ver,
((hw->nvm.version >> 12) & 0xf),
@@ -416,7 +416,7 @@ eth_i40e_dev_init(__rte_unused struct eth_driver *eth_drv,
/* Disable LLDP */
ret = i40e_aq_stop_lldp(hw, true, NULL);
if (ret != I40E_SUCCESS) /* Its failure can be ignored */
- PMD_INIT_LOG(INFO, "Failed to stop lldp\n");
+ PMD_INIT_LOG(INFO, "Failed to stop lldp");
/* Clear PXE mode */
i40e_clear_pxe_mode(hw);
@@ -438,13 +438,13 @@ eth_i40e_dev_init(__rte_unused struct eth_driver *eth_drv,
/* Initialize the queue management */
ret = i40e_res_pool_init(&pf->qp_pool, 0, hw->func_caps.num_tx_qp);
if (ret < 0) {
- PMD_INIT_LOG(ERR, "Failed to init queue pool\n");
+ PMD_INIT_LOG(ERR, "Failed to init queue pool");
goto err_qp_pool_init;
}
ret = i40e_res_pool_init(&pf->msix_pool, 1,
hw->func_caps.num_msix_vectors - 1);
if (ret < 0) {
- PMD_INIT_LOG(ERR, "Failed to init MSIX pool\n");
+ PMD_INIT_LOG(ERR, "Failed to init MSIX pool");
goto err_msix_pool_init;
}
@@ -722,9 +722,9 @@ i40e_phy_conf_link(struct i40e_hw *hw, uint8_t abilities, uint8_t force_speed)
phy_conf.eeer = phy_ab.eeer_val;
phy_conf.low_power_ctrl = phy_ab.d3_lpan;
- PMD_DRV_LOG(DEBUG, "\n\tCurrent: abilities %x, link_speed %x\n"
- "\tConfig: abilities %x, link_speed %x",
- phy_ab.abilities, phy_ab.link_speed,
+ PMD_DRV_LOG(DEBUG, "\tCurrent: abilities %x, link_speed %x",
+ phy_ab.abilities, phy_ab.link_speed);
+ PMD_DRV_LOG(DEBUG, "\tConfig: abilities %x, link_speed %x",
phy_conf.abilities, phy_conf.link_speed);
status = i40e_aq_set_phy_config(hw, &phy_conf, NULL);
@@ -762,7 +762,7 @@ i40e_dev_start(struct rte_eth_dev *dev)
if ((dev->data->dev_conf.link_duplex != ETH_LINK_AUTONEG_DUPLEX) &&
(dev->data->dev_conf.link_duplex != ETH_LINK_FULL_DUPLEX)) {
- PMD_INIT_LOG(ERR, "Invalid link_duplex (%hu) for port %hhu\n",
+ PMD_INIT_LOG(ERR, "Invalid link_duplex (%hu) for port %hhu",
dev->data->dev_conf.link_duplex,
dev->data->port_id);
return -EINVAL;
@@ -771,7 +771,7 @@ i40e_dev_start(struct rte_eth_dev *dev)
/* Initialize VSI */
ret = i40e_vsi_init(vsi);
if (ret != I40E_SUCCESS) {
- PMD_DRV_LOG(ERR, "Failed to init VSI\n");
+ PMD_DRV_LOG(ERR, "Failed to init VSI");
goto err_up;
}
@@ -782,7 +782,7 @@ i40e_dev_start(struct rte_eth_dev *dev)
/* Enable all queues which have been configured */
ret = i40e_vsi_switch_queues(vsi, TRUE);
if (ret != I40E_SUCCESS) {
- PMD_DRV_LOG(ERR, "Failed to enable VSI\n");
+ PMD_DRV_LOG(ERR, "Failed to enable VSI");
goto err_up;
}
@@ -790,13 +790,13 @@ i40e_dev_start(struct rte_eth_dev *dev)
if ((vsi->type == I40E_VSI_MAIN) || (vsi->type == I40E_VSI_VMDQ2)) {
ret = i40e_aq_set_vsi_broadcast(hw, vsi->seid, true, NULL);
if (ret != I40E_SUCCESS)
- PMD_DRV_LOG(INFO, "fail to set vsi broadcast\n");
+ PMD_DRV_LOG(INFO, "fail to set vsi broadcast");
}
/* Apply link configure */
ret = i40e_apply_link_speed(dev);
if (I40E_SUCCESS != ret) {
- PMD_DRV_LOG(ERR, "Fail to apply link setting\n");
+ PMD_DRV_LOG(ERR, "Fail to apply link setting");
goto err_up;
}
@@ -871,12 +871,12 @@ i40e_dev_promiscuous_enable(struct rte_eth_dev *dev)
status = i40e_aq_set_vsi_unicast_promiscuous(hw, vsi->seid,
true, NULL);
if (status != I40E_SUCCESS)
- PMD_DRV_LOG(ERR, "Failed to enable unicast promiscuous\n");
+ PMD_DRV_LOG(ERR, "Failed to enable unicast promiscuous");
status = i40e_aq_set_vsi_multicast_promiscuous(hw, vsi->seid,
TRUE, NULL);
if (status != I40E_SUCCESS)
- PMD_DRV_LOG(ERR, "Failed to enable multicast promiscuous\n");
+ PMD_DRV_LOG(ERR, "Failed to enable multicast promiscuous");
}
@@ -891,12 +891,12 @@ i40e_dev_promiscuous_disable(struct rte_eth_dev *dev)
status = i40e_aq_set_vsi_unicast_promiscuous(hw, vsi->seid,
false, NULL);
if (status != I40E_SUCCESS)
- PMD_DRV_LOG(ERR, "Failed to disable unicast promiscuous\n");
+ PMD_DRV_LOG(ERR, "Failed to disable unicast promiscuous");
status = i40e_aq_set_vsi_multicast_promiscuous(hw, vsi->seid,
false, NULL);
if (status != I40E_SUCCESS)
- PMD_DRV_LOG(ERR, "Failed to disable multicast promiscuous\n");
+ PMD_DRV_LOG(ERR, "Failed to disable multicast promiscuous");
}
static void
@@ -909,7 +909,7 @@ i40e_dev_allmulticast_enable(struct rte_eth_dev *dev)
ret = i40e_aq_set_vsi_multicast_promiscuous(hw, vsi->seid, TRUE, NULL);
if (ret != I40E_SUCCESS)
- PMD_DRV_LOG(ERR, "Failed to enable multicast promiscuous\n");
+ PMD_DRV_LOG(ERR, "Failed to enable multicast promiscuous");
}
static void
@@ -926,7 +926,7 @@ i40e_dev_allmulticast_disable(struct rte_eth_dev *dev)
ret = i40e_aq_set_vsi_multicast_promiscuous(hw,
vsi->seid, FALSE, NULL);
if (ret != I40E_SUCCESS)
- PMD_DRV_LOG(ERR, "Failed to disable multicast promiscuous\n");
+ PMD_DRV_LOG(ERR, "Failed to disable multicast promiscuous");
}
/*
@@ -971,7 +971,7 @@ i40e_dev_link_update(struct rte_eth_dev *dev,
if (status != I40E_SUCCESS) {
link.link_speed = ETH_LINK_SPEED_100;
link.link_duplex = ETH_LINK_FULL_DUPLEX;
- PMD_DRV_LOG(ERR, "Failed to get link info\n");
+ PMD_DRV_LOG(ERR, "Failed to get link info");
goto out;
}
@@ -1519,12 +1519,12 @@ i40e_macaddr_add(struct rte_eth_dev *dev,
int ret;
if (!is_valid_assigned_ether_addr(mac_addr)) {
- PMD_DRV_LOG(ERR, "Invalid ethernet address\n");
+ PMD_DRV_LOG(ERR, "Invalid ethernet address");
return;
}
if (is_same_ether_addr(mac_addr, &(pf->dev_addr))) {
- PMD_DRV_LOG(INFO, "Ignore adding permanent mac address\n");
+ PMD_DRV_LOG(INFO, "Ignore adding permanent mac address");
return;
}
@@ -1532,7 +1532,7 @@ i40e_macaddr_add(struct rte_eth_dev *dev,
ret = i40e_aq_mac_address_write(hw, I40E_AQC_WRITE_TYPE_LAA_ONLY,
mac_addr->addr_bytes, NULL);
if (ret != I40E_SUCCESS) {
- PMD_DRV_LOG(ERR, "Failed to write mac address\n");
+ PMD_DRV_LOG(ERR, "Failed to write mac address");
return;
}
@@ -1542,7 +1542,7 @@ i40e_macaddr_add(struct rte_eth_dev *dev,
ret = i40e_vsi_add_mac(vsi, mac_addr);
if (ret != I40E_SUCCESS) {
- PMD_DRV_LOG(ERR, "Failed to add MACVLAN filter\n");
+ PMD_DRV_LOG(ERR, "Failed to add MACVLAN filter");
return;
}
@@ -1572,7 +1572,7 @@ i40e_macaddr_remove(struct rte_eth_dev *dev, uint32_t index)
ret = i40e_aq_mac_address_write(hw, I40E_AQC_WRITE_TYPE_LAA_ONLY,
hw->mac.perm_addr, NULL);
if (ret != I40E_SUCCESS) {
- PMD_DRV_LOG(ERR, "Failed to write mac address\n");
+ PMD_DRV_LOG(ERR, "Failed to write mac address");
return;
}
@@ -1793,7 +1793,7 @@ i40e_get_cap(struct i40e_hw *hw)
I40E_MAX_CAP_ELE_NUM;
buf = rte_zmalloc("i40e", len, 0);
if (!buf) {
- PMD_DRV_LOG(ERR, "Failed to allocate memory\n");
+ PMD_DRV_LOG(ERR, "Failed to allocate memory");
return I40E_ERR_NO_MEMORY;
}
@@ -1801,7 +1801,7 @@ i40e_get_cap(struct i40e_hw *hw)
ret = i40e_aq_discover_capabilities(hw, buf, len, &size,
i40e_aqc_opc_list_func_capabilities, NULL);
if (ret != I40E_SUCCESS)
- PMD_DRV_LOG(ERR, "Failed to discover capabilities\n");
+ PMD_DRV_LOG(ERR, "Failed to discover capabilities");
/* Free the temporary buffer after being used */
rte_free(buf);
@@ -1818,13 +1818,13 @@ i40e_pf_parameter_init(struct rte_eth_dev *dev)
/* First check if FW support SRIOV */
if (dev->pci_dev->max_vfs && !hw->func_caps.sr_iov_1_1) {
- PMD_INIT_LOG(ERR, "HW configuration doesn't support SRIOV\n");
+ PMD_INIT_LOG(ERR, "HW configuration doesn't support SRIOV");
return -EINVAL;
}
pf->flags = I40E_FLAG_HEADER_SPLIT_DISABLED;
pf->max_num_vsi = RTE_MIN(hw->func_caps.num_vsis, I40E_MAX_NUM_VSIS);
- PMD_INIT_LOG(INFO, "Max supported VSIs:%u\n", pf->max_num_vsi);
+ PMD_INIT_LOG(INFO, "Max supported VSIs:%u", pf->max_num_vsi);
/* Allocate queues for pf */
if (hw->func_caps.rss) {
pf->flags |= I40E_FLAG_RSS;
@@ -1836,28 +1836,28 @@ i40e_pf_parameter_init(struct rte_eth_dev *dev)
sum_queues = pf->lan_nb_qps;
/* Default VSI is not counted in */
sum_vsis = 0;
- PMD_INIT_LOG(INFO, "PF queue pairs:%u\n", pf->lan_nb_qps);
+ PMD_INIT_LOG(INFO, "PF queue pairs:%u", pf->lan_nb_qps);
if (hw->func_caps.sr_iov_1_1 && dev->pci_dev->max_vfs) {
pf->flags |= I40E_FLAG_SRIOV;
pf->vf_nb_qps = RTE_LIBRTE_I40E_QUEUE_NUM_PER_VF;
if (dev->pci_dev->max_vfs > hw->func_caps.num_vfs) {
PMD_INIT_LOG(ERR, "Config VF number %u, "
- "max supported %u.\n",
+ "max supported %u.",
dev->pci_dev->max_vfs,
hw->func_caps.num_vfs);
return -EINVAL;
}
if (pf->vf_nb_qps > I40E_MAX_QP_NUM_PER_VF) {
PMD_INIT_LOG(ERR, "FVL VF queue %u, "
- "max support %u queues.\n",
+ "max support %u queues.",
pf->vf_nb_qps, I40E_MAX_QP_NUM_PER_VF);
return -EINVAL;
}
pf->vf_num = dev->pci_dev->max_vfs;
sum_queues += pf->vf_nb_qps * pf->vf_num;
sum_vsis += pf->vf_num;
- PMD_INIT_LOG(INFO, "Max VF num:%u each has queue pairs:%u\n",
+ PMD_INIT_LOG(INFO, "Max VF num:%u each has queue pairs:%u",
pf->vf_num, pf->vf_nb_qps);
} else
pf->vf_num = 0;
@@ -1867,7 +1867,7 @@ i40e_pf_parameter_init(struct rte_eth_dev *dev)
pf->vmdq_nb_qps = I40E_DEFAULT_QP_NUM_VMDQ;
sum_queues += pf->vmdq_nb_qps;
sum_vsis += 1;
- PMD_INIT_LOG(INFO, "VMDQ queue pairs:%u\n", pf->vmdq_nb_qps);
+ PMD_INIT_LOG(INFO, "VMDQ queue pairs:%u", pf->vmdq_nb_qps);
}
if (hw->func_caps.fd) {
@@ -1881,18 +1881,18 @@ i40e_pf_parameter_init(struct rte_eth_dev *dev)
if (sum_vsis > pf->max_num_vsi ||
sum_queues > hw->func_caps.num_rx_qp) {
- PMD_INIT_LOG(ERR, "VSI/QUEUE setting can't be satisfied\n");
- PMD_INIT_LOG(ERR, "Max VSIs: %u, asked:%u\n",
+ PMD_INIT_LOG(ERR, "VSI/QUEUE setting can't be satisfied");
+ PMD_INIT_LOG(ERR, "Max VSIs: %u, asked:%u",
pf->max_num_vsi, sum_vsis);
- PMD_INIT_LOG(ERR, "Total queue pairs:%u, asked:%u\n",
+ PMD_INIT_LOG(ERR, "Total queue pairs:%u, asked:%u",
hw->func_caps.num_rx_qp, sum_queues);
return -EINVAL;
}
- /* Each VSI occupy 1 MSIX interrupt at least, plus IRQ0 for misc intr cause */
+ /* Each VSI occupy 1 MSIX interrupt at least, plus IRQ0 for misc intr
+ * cause */
if (sum_vsis > hw->func_caps.num_msix_vectors - 1) {
- PMD_INIT_LOG(ERR, "Too many VSIs(%u), "
- "MSIX intr(%u) not enough\n",
+ PMD_INIT_LOG(ERR, "Too many VSIs(%u), MSIX intr(%u) not enough",
sum_vsis, hw->func_caps.num_msix_vectors);
return -EINVAL;
}
@@ -1911,7 +1911,7 @@ i40e_pf_get_switch_config(struct i40e_pf *pf)
switch_config = (struct i40e_aqc_get_switch_config_resp *)\
rte_zmalloc("i40e", I40E_AQ_LARGE_BUF, 0);
if (!switch_config) {
- PMD_DRV_LOG(ERR, "Failed to allocated memory\n");
+ PMD_DRV_LOG(ERR, "Failed to allocated memory");
return -ENOMEM;
}
@@ -1919,12 +1919,12 @@ i40e_pf_get_switch_config(struct i40e_pf *pf)
ret = i40e_aq_get_switch_config(hw, switch_config,
I40E_AQ_LARGE_BUF, &start_seid, NULL);
if (ret != I40E_SUCCESS) {
- PMD_DRV_LOG(ERR, "Failed to get switch configurations\n");
+ PMD_DRV_LOG(ERR, "Failed to get switch configurations");
goto fail;
}
num_reported = rte_le_to_cpu_16(switch_config->header.num_reported);
if (num_reported != 1) { /* The number should be 1 */
- PMD_DRV_LOG(ERR, "Wrong number of switch config reported\n");
+ PMD_DRV_LOG(ERR, "Wrong number of switch config reported");
goto fail;
}
@@ -1934,7 +1934,7 @@ i40e_pf_get_switch_config(struct i40e_pf *pf)
pf->mac_seid = rte_le_to_cpu_16(element->uplink_seid);
pf->main_vsi_seid = rte_le_to_cpu_16(element->seid);
} else
- PMD_DRV_LOG(INFO, "Unknown element type\n");
+ PMD_DRV_LOG(INFO, "Unknown element type");
fail:
rte_free(switch_config);
@@ -1953,7 +1953,7 @@ i40e_res_pool_init (struct i40e_res_pool_info *pool, uint32_t base,
entry = rte_zmalloc("i40e", sizeof(*entry), 0);
if (entry == NULL) {
- PMD_DRV_LOG(ERR, "Failed to allocate memory for resource pool\n");
+ PMD_DRV_LOG(ERR, "Failed to allocate memory for resource pool");
return -ENOMEM;
}
@@ -2006,7 +2006,7 @@ i40e_res_pool_free(struct i40e_res_pool_info *pool,
int insert;
if (pool == NULL) {
- PMD_DRV_LOG(ERR, "Invalid parameter\n");
+ PMD_DRV_LOG(ERR, "Invalid parameter");
return -EINVAL;
}
@@ -2022,7 +2022,7 @@ i40e_res_pool_free(struct i40e_res_pool_info *pool,
/* Not find, return */
if (valid_entry == NULL) {
- PMD_DRV_LOG(ERR, "Failed to find entry\n");
+ PMD_DRV_LOG(ERR, "Failed to find entry");
return -EINVAL;
}
@@ -2091,12 +2091,12 @@ i40e_res_pool_alloc(struct i40e_res_pool_info *pool,
struct pool_entry *entry, *valid_entry;
if (pool == NULL || num == 0) {
- PMD_DRV_LOG(ERR, "Invalid parameter\n");
+ PMD_DRV_LOG(ERR, "Invalid parameter");
return -EINVAL;
}
if (pool->num_free < num) {
- PMD_DRV_LOG(ERR, "No resource. ask:%u, available:%u\n",
+ PMD_DRV_LOG(ERR, "No resource. ask:%u, available:%u",
num, pool->num_free);
return -ENOMEM;
}
@@ -2117,7 +2117,7 @@ i40e_res_pool_alloc(struct i40e_res_pool_info *pool,
/* Not find one to satisfy the request, return */
if (valid_entry == NULL) {
- PMD_DRV_LOG(ERR, "No valid entry found\n");
+ PMD_DRV_LOG(ERR, "No valid entry found");
return -ENOMEM;
}
/**
@@ -2135,7 +2135,7 @@ i40e_res_pool_alloc(struct i40e_res_pool_info *pool,
entry = rte_zmalloc("res_pool", sizeof(*entry), 0);
if (entry == NULL) {
PMD_DRV_LOG(ERR, "Failed to allocate memory for "
- "resource pool\n");
+ "resource pool");
return -ENOMEM;
}
entry->base = valid_entry->base;
@@ -2170,13 +2170,13 @@ validate_tcmap_parameter(struct i40e_vsi *vsi, uint8_t enabled_tcmap)
/* If DCB is not supported, only default TC is supported */
if (!hw->func_caps.dcb && enabled_tcmap != I40E_DEFAULT_TCMAP) {
- PMD_DRV_LOG(ERR, "DCB is not enabled, only TC0 is supported\n");
+ PMD_DRV_LOG(ERR, "DCB is not enabled, only TC0 is supported");
return -EINVAL;
}
if (!bitmap_is_subset(hw->func_caps.enabled_tcmap, enabled_tcmap)) {
PMD_DRV_LOG(ERR, "Enabled TC map 0x%x not applicable to "
- "HW support 0x%x\n", hw->func_caps.enabled_tcmap,
+ "HW support 0x%x", hw->func_caps.enabled_tcmap,
enabled_tcmap);
return -EINVAL;
}
@@ -2193,7 +2193,7 @@ i40e_vsi_vlan_pvid_set(struct i40e_vsi *vsi,
int ret;
if (vsi == NULL || info == NULL) {
- PMD_DRV_LOG(ERR, "invalid parameters\n");
+ PMD_DRV_LOG(ERR, "invalid parameters");
return I40E_ERR_PARAM;
}
@@ -2225,7 +2225,7 @@ i40e_vsi_vlan_pvid_set(struct i40e_vsi *vsi,
hw = I40E_VSI_TO_HW(vsi);
ret = i40e_aq_update_vsi_params(hw, &ctxt, NULL);
if (ret != I40E_SUCCESS)
- PMD_DRV_LOG(ERR, "Failed to update VSI params\n");
+ PMD_DRV_LOG(ERR, "Failed to update VSI params");
return ret;
}
@@ -2242,7 +2242,7 @@ i40e_vsi_update_tc_bandwidth(struct i40e_vsi *vsi, uint8_t enabled_tcmap)
return ret;
if (!vsi->seid) {
- PMD_DRV_LOG(ERR, "seid not valid\n");
+ PMD_DRV_LOG(ERR, "seid not valid");
return -EINVAL;
}
@@ -2254,7 +2254,7 @@ i40e_vsi_update_tc_bandwidth(struct i40e_vsi *vsi, uint8_t enabled_tcmap)
ret = i40e_aq_config_vsi_tc_bw(hw, vsi->seid, &tc_bw_data, NULL);
if (ret != I40E_SUCCESS) {
- PMD_DRV_LOG(ERR, "Failed to configure TC BW\n");
+ PMD_DRV_LOG(ERR, "Failed to configure TC BW");
return ret;
}
@@ -2332,7 +2332,7 @@ i40e_veb_release(struct i40e_veb *veb)
return -EINVAL;
if (!TAILQ_EMPTY(&veb->head)) {
- PMD_DRV_LOG(ERR, "VEB still has VSI attached, can't remove\n");
+ PMD_DRV_LOG(ERR, "VEB still has VSI attached, can't remove");
return -EACCES;
}
@@ -2356,14 +2356,14 @@ i40e_veb_setup(struct i40e_pf *pf, struct i40e_vsi *vsi)
if (NULL == pf || vsi == NULL) {
PMD_DRV_LOG(ERR, "veb setup failed, "
- "associated VSI shouldn't null\n");
+ "associated VSI shouldn't null");
return NULL;
}
hw = I40E_PF_TO_HW(pf);
veb = rte_zmalloc("i40e_veb", sizeof(struct i40e_veb), 0);
if (!veb) {
- PMD_DRV_LOG(ERR, "Failed to allocate memory for veb\n");
+ PMD_DRV_LOG(ERR, "Failed to allocate memory for veb");
goto fail;
}
@@ -2375,7 +2375,7 @@ i40e_veb_setup(struct i40e_pf *pf, struct i40e_vsi *vsi)
I40E_DEFAULT_TCMAP, false, false, &veb->seid, NULL);
if (ret != I40E_SUCCESS) {
- PMD_DRV_LOG(ERR, "Add veb failed, aq_err: %d\n",
+ PMD_DRV_LOG(ERR, "Add veb failed, aq_err: %d",
hw->aq.asq_last_status);
goto fail;
}
@@ -2384,7 +2384,7 @@ i40e_veb_setup(struct i40e_pf *pf, struct i40e_vsi *vsi)
ret = i40e_aq_get_veb_parameters(hw, veb->seid, NULL, NULL,
&veb->stats_idx, NULL, NULL, NULL);
if (ret != I40E_SUCCESS) {
- PMD_DRV_LOG(ERR, "Get veb statics index failed, aq_err: %d\n",
+ PMD_DRV_LOG(ERR, "Get veb statics index failed, aq_err: %d",
hw->aq.asq_last_status);
goto fail;
}
@@ -2432,7 +2432,7 @@ i40e_vsi_release(struct i40e_vsi *vsi)
if (vsi->type != I40E_VSI_MAIN) {
/* Remove vsi from parent's sibling list */
if (vsi->parent_vsi == NULL || vsi->parent_vsi->veb == NULL) {
- PMD_DRV_LOG(ERR, "VSI's parent VSI is NULL\n");
+ PMD_DRV_LOG(ERR, "VSI's parent VSI is NULL");
return I40E_ERR_PARAM;
}
TAILQ_REMOVE(&vsi->parent_vsi->veb->head,
@@ -2441,7 +2441,7 @@ i40e_vsi_release(struct i40e_vsi *vsi)
/* Remove all switch element of the VSI */
ret = i40e_aq_delete_element(hw, vsi->seid, NULL);
if (ret != I40E_SUCCESS)
- PMD_DRV_LOG(ERR, "Failed to delete element\n");
+ PMD_DRV_LOG(ERR, "Failed to delete element");
}
i40e_res_pool_free(&pf->qp_pool, vsi->base_queue);
@@ -2472,11 +2472,11 @@ i40e_update_default_filter_setting(struct i40e_vsi *vsi)
struct i40e_mac_filter *f;
PMD_DRV_LOG(WARNING, "Cannot remove the default "
- "macvlan filter\n");
+ "macvlan filter");
/* It needs to add the permanent mac into mac list */
f = rte_zmalloc("macv_filter", sizeof(*f), 0);
if (f == NULL) {
- PMD_DRV_LOG(ERR, "failed to allocate memory\n");
+ PMD_DRV_LOG(ERR, "failed to allocate memory");
return I40E_ERR_NO_MEMORY;
}
(void)rte_memcpy(&f->macaddr.addr_bytes, hw->mac.perm_addr,
@@ -2502,7 +2502,7 @@ i40e_vsi_dump_bw_config(struct i40e_vsi *vsi)
memset(&bw_config, 0, sizeof(bw_config));
ret = i40e_aq_query_vsi_bw_config(hw, vsi->seid, &bw_config, NULL);
if (ret != I40E_SUCCESS) {
- PMD_DRV_LOG(ERR, "VSI failed to get bandwidth configuration %u\n",
+ PMD_DRV_LOG(ERR, "VSI failed to get bandwidth configuration %u",
hw->aq.asq_last_status);
return ret;
}
@@ -2512,17 +2512,17 @@ i40e_vsi_dump_bw_config(struct i40e_vsi *vsi)
&ets_sla_config, NULL);
if (ret != I40E_SUCCESS) {
PMD_DRV_LOG(ERR, "VSI failed to get TC bandwdith "
- "configuration %u\n", hw->aq.asq_last_status);
+ "configuration %u", hw->aq.asq_last_status);
return ret;
}
/* Not store the info yet, just print out */
- PMD_DRV_LOG(INFO, "VSI bw limit:%u\n", bw_config.port_bw_limit);
- PMD_DRV_LOG(INFO, "VSI max_bw:%u\n", bw_config.max_bw);
+ PMD_DRV_LOG(INFO, "VSI bw limit:%u", bw_config.port_bw_limit);
+ PMD_DRV_LOG(INFO, "VSI max_bw:%u", bw_config.max_bw);
for (i = 0; i < I40E_MAX_TRAFFIC_CLASS; i++) {
- PMD_DRV_LOG(INFO, "\tVSI TC%u:share credits %u\n", i,
+ PMD_DRV_LOG(INFO, "\tVSI TC%u:share credits %u", i,
ets_sla_config.share_credits[i]);
- PMD_DRV_LOG(INFO, "\tVSI TC%u:credits %u\n", i,
+ PMD_DRV_LOG(INFO, "\tVSI TC%u:credits %u", i,
rte_le_to_cpu_16(ets_sla_config.credits[i]));
PMD_DRV_LOG(INFO, "\tVSI TC%u: max credits: %u", i,
rte_le_to_cpu_16(ets_sla_config.credits[i / 4]) >>
@@ -2548,13 +2548,13 @@ i40e_vsi_setup(struct i40e_pf *pf,
if (type != I40E_VSI_MAIN && uplink_vsi == NULL) {
PMD_DRV_LOG(ERR, "VSI setup failed, "
- "VSI link shouldn't be NULL\n");
+ "VSI link shouldn't be NULL");
return NULL;
}
if (type == I40E_VSI_MAIN && uplink_vsi != NULL) {
PMD_DRV_LOG(ERR, "VSI setup failed, MAIN VSI "
- "uplink VSI should be NULL\n");
+ "uplink VSI should be NULL");
return NULL;
}
@@ -2563,14 +2563,14 @@ i40e_vsi_setup(struct i40e_pf *pf,
uplink_vsi->veb = i40e_veb_setup(pf, uplink_vsi);
if (NULL == uplink_vsi->veb) {
- PMD_DRV_LOG(ERR, "VEB setup failed\n");
+ PMD_DRV_LOG(ERR, "VEB setup failed");
return NULL;
}
}
vsi = rte_zmalloc("i40e_vsi", sizeof(struct i40e_vsi), 0);
if (!vsi) {
- PMD_DRV_LOG(ERR, "Failed to allocate memory for vsi\n");
+ PMD_DRV_LOG(ERR, "Failed to allocate memory for vsi");
return NULL;
}
TAILQ_INIT(&vsi->mac_list);
@@ -2628,7 +2628,7 @@ i40e_vsi_setup(struct i40e_pf *pf,
ctxt.vf_num = 0;
ret = i40e_aq_get_vsi_params(hw, &ctxt, NULL);
if (ret != I40E_SUCCESS) {
- PMD_DRV_LOG(ERR, "Failed to get VSI params\n");
+ PMD_DRV_LOG(ERR, "Failed to get VSI params");
goto fail_msix_alloc;
}
(void)rte_memcpy(&vsi->info, &ctxt.info,
@@ -2639,7 +2639,7 @@ i40e_vsi_setup(struct i40e_pf *pf,
/* Configure tc, enabled TC0 only */
if (i40e_vsi_update_tc_bandwidth(vsi, I40E_DEFAULT_TCMAP) !=
I40E_SUCCESS) {
- PMD_DRV_LOG(ERR, "Failed to update TC bandwidth\n");
+ PMD_DRV_LOG(ERR, "Failed to update TC bandwidth");
goto fail_msix_alloc;
}
@@ -2655,7 +2655,7 @@ i40e_vsi_setup(struct i40e_pf *pf,
I40E_DEFAULT_TCMAP);
if (ret != I40E_SUCCESS) {
PMD_DRV_LOG(ERR, "Failed to configure "
- "TC queue mapping\n");
+ "TC queue mapping");
goto fail_msix_alloc;
}
ctxt.seid = vsi->seid;
@@ -2666,7 +2666,7 @@ i40e_vsi_setup(struct i40e_pf *pf,
/* Update VSI parameters */
ret = i40e_aq_update_vsi_params(hw, &ctxt, NULL);
if (ret != I40E_SUCCESS) {
- PMD_DRV_LOG(ERR, "Failed to update VSI params\n");
+ PMD_DRV_LOG(ERR, "Failed to update VSI params");
goto fail_msix_alloc;
}
@@ -2718,7 +2718,7 @@ i40e_vsi_setup(struct i40e_pf *pf,
I40E_DEFAULT_TCMAP);
if (ret != I40E_SUCCESS) {
PMD_DRV_LOG(ERR, "Failed to configure "
- "TC queue mapping\n");
+ "TC queue mapping");
goto fail_msix_alloc;
}
ctxt.info.up_enable_bits = I40E_DEFAULT_TCMAP;
@@ -2730,14 +2730,14 @@ i40e_vsi_setup(struct i40e_pf *pf,
*/
}
else {
- PMD_DRV_LOG(ERR, "VSI: Not support other type VSI yet\n");
+ PMD_DRV_LOG(ERR, "VSI: Not support other type VSI yet");
goto fail_msix_alloc;
}
if (vsi->type != I40E_VSI_MAIN) {
ret = i40e_aq_add_vsi(hw, &ctxt, NULL);
if (ret) {
- PMD_DRV_LOG(ERR, "add vsi failed, aq_err=%d\n",
+ PMD_DRV_LOG(ERR, "add vsi failed, aq_err=%d",
hw->aq.asq_last_status);
goto fail_msix_alloc;
}
@@ -2753,7 +2753,7 @@ i40e_vsi_setup(struct i40e_pf *pf,
/* MAC/VLAN configuration */
ret = i40e_vsi_add_mac(vsi, &broadcast);
if (ret != I40E_SUCCESS) {
- PMD_DRV_LOG(ERR, "Failed to add MACVLAN filter\n");
+ PMD_DRV_LOG(ERR, "Failed to add MACVLAN filter");
goto fail_msix_alloc;
}
@@ -2805,7 +2805,7 @@ i40e_vsi_config_vlan_stripping(struct i40e_vsi *vsi, bool on)
(void)rte_memcpy(&ctxt.info, &vsi->info, sizeof(vsi->info));
ret = i40e_aq_update_vsi_params(hw, &ctxt, NULL);
if (ret)
- PMD_DRV_LOG(INFO, "Update VSI failed to %s vlan stripping\n",
+ PMD_DRV_LOG(INFO, "Update VSI failed to %s vlan stripping",
on ? "enable" : "disable");
return ret;
@@ -2826,7 +2826,7 @@ i40e_dev_init_vlan(struct rte_eth_dev *dev)
ret = i40e_vlan_pvid_set(dev, data->dev_conf.txmode.pvid,
data->dev_conf.txmode.hw_vlan_insert_pvid);
if (ret)
- PMD_DRV_LOG(INFO, "Failed to update VSI params\n");
+ PMD_DRV_LOG(INFO, "Failed to update VSI params");
return ret;
}
@@ -2851,13 +2851,13 @@ i40e_update_flow_control(struct i40e_hw *hw)
memset(&link_status, 0, sizeof(link_status));
ret = i40e_aq_get_link_info(hw, FALSE, &link_status, NULL);
if (ret != I40E_SUCCESS) {
- PMD_DRV_LOG(ERR, "Failed to get link status information\n");
+ PMD_DRV_LOG(ERR, "Failed to get link status information");
goto write_reg; /* Disable flow control */
}
an_info = hw->phy.link_info.an_info;
if (!(an_info & I40E_AQ_AN_COMPLETED)) {
- PMD_DRV_LOG(INFO, "Link auto negotiation not completed\n");
+ PMD_DRV_LOG(INFO, "Link auto negotiation not completed");
ret = I40E_ERR_NOT_READY;
goto write_reg; /* Disable flow control */
}
@@ -2995,7 +2995,7 @@ i40e_switch_tx_queue(struct i40e_hw *hw, uint16_t q_idx, bool on)
}
/* Check if it is timeout */
if (j >= I40E_CHK_Q_ENA_COUNT) {
- PMD_DRV_LOG(ERR, "Failed to %s tx queue[%u]\n",
+ PMD_DRV_LOG(ERR, "Failed to %s tx queue[%u]",
(on ? "enable" : "disable"), q_idx);
return I40E_ERR_TIMEOUT;
}
@@ -3074,7 +3074,7 @@ i40e_switch_rx_queue(struct i40e_hw *hw, uint16_t q_idx, bool on)
/* Check if it is timeout */
if (j >= I40E_CHK_Q_ENA_COUNT) {
- PMD_DRV_LOG(ERR, "Failed to %s rx queue[%u]\n",
+ PMD_DRV_LOG(ERR, "Failed to %s rx queue[%u]",
(on ? "enable" : "disable"), q_idx);
return I40E_ERR_TIMEOUT;
}
@@ -3118,7 +3118,7 @@ i40e_vsi_switch_queues(struct i40e_vsi *vsi, bool on)
/* enable rx queues before enabling tx queues */
ret = i40e_vsi_switch_rx_queues(vsi, on);
if (ret) {
- PMD_DRV_LOG(ERR, "Failed to switch rx queues\n");
+ PMD_DRV_LOG(ERR, "Failed to switch rx queues");
return ret;
}
ret = i40e_vsi_switch_tx_queues(vsi, on);
@@ -3126,7 +3126,7 @@ i40e_vsi_switch_queues(struct i40e_vsi *vsi, bool on)
/* Stop tx queues before stopping rx queues */
ret = i40e_vsi_switch_tx_queues(vsi, on);
if (ret) {
- PMD_DRV_LOG(ERR, "Failed to switch tx queues\n");
+ PMD_DRV_LOG(ERR, "Failed to switch tx queues");
return ret;
}
ret = i40e_vsi_switch_rx_queues(vsi, on);
@@ -3167,7 +3167,7 @@ i40e_vsi_rx_init(struct i40e_vsi *vsi)
ret = i40e_rx_queue_init(data->rx_queues[i]);
if (ret != I40E_SUCCESS) {
PMD_DRV_LOG(ERR, "Failed to do RX queue "
- "initialization\n");
+ "initialization");
break;
}
}
@@ -3183,12 +3183,12 @@ i40e_vsi_init(struct i40e_vsi *vsi)
err = i40e_vsi_tx_init(vsi);
if (err) {
- PMD_DRV_LOG(ERR, "Failed to do vsi TX initialization\n");
+ PMD_DRV_LOG(ERR, "Failed to do vsi TX initialization");
return err;
}
err = i40e_vsi_rx_init(vsi);
if (err) {
- PMD_DRV_LOG(ERR, "Failed to do vsi RX initialization\n");
+ PMD_DRV_LOG(ERR, "Failed to do vsi RX initialization");
return err;
}
@@ -3317,14 +3317,14 @@ i40e_dev_handle_vfr_event(struct rte_eth_dev *dev)
/* Clear the event first */
I40E_WRITE_REG(hw, I40E_GLGEN_VFLRSTAT(index),
(0x1 << offset));
- PMD_DRV_LOG(INFO, "VF %u reset occured\n", abs_vf_id);
+ PMD_DRV_LOG(INFO, "VF %u reset occured", abs_vf_id);
/**
* Only notify a VF reset event occured,
* don't trigger another SW reset
*/
ret = i40e_pf_host_vf_reset(&pf->vfs[i], 0);
if (ret != I40E_SUCCESS)
- PMD_DRV_LOG(ERR, "Failed to do VF reset\n");
+ PMD_DRV_LOG(ERR, "Failed to do VF reset");
}
}
}
@@ -3340,7 +3340,7 @@ i40e_dev_handle_aq_msg(struct rte_eth_dev *dev)
info.msg_size = I40E_AQ_BUF_SZ;
info.msg_buf = rte_zmalloc("msg_buffer", I40E_AQ_BUF_SZ, 0);
if (!info.msg_buf) {
- PMD_DRV_LOG(ERR, "Failed to allocate mem\n");
+ PMD_DRV_LOG(ERR, "Failed to allocate mem");
return;
}
@@ -3350,7 +3350,7 @@ i40e_dev_handle_aq_msg(struct rte_eth_dev *dev)
if (ret != I40E_SUCCESS) {
PMD_DRV_LOG(INFO, "Failed to read msg from AdminQ, "
- "aq_err: %u\n", hw->aq.asq_last_status);
+ "aq_err: %u", hw->aq.asq_last_status);
break;
}
opcode = rte_le_to_cpu_16(info.desc.opcode);
@@ -3366,7 +3366,7 @@ i40e_dev_handle_aq_msg(struct rte_eth_dev *dev)
info.msg_size);
break;
default:
- PMD_DRV_LOG(ERR, "Request %u is not supported yet\n",
+ PMD_DRV_LOG(ERR, "Request %u is not supported yet",
opcode);
break;
}
@@ -3404,38 +3404,38 @@ i40e_dev_interrupt_handler(__rte_unused struct rte_intr_handle *handle,
/* Shared IRQ case, return */
if (!(cause & I40E_PFINT_ICR0_INTEVENT_MASK)) {
PMD_DRV_LOG(INFO, "Port%d INT0:share IRQ case, "
- "no INT event to process\n", hw->pf_id);
+ "no INT event to process", hw->pf_id);
goto done;
}
if (cause & I40E_PFINT_ICR0_LINK_STAT_CHANGE_MASK) {
- PMD_DRV_LOG(INFO, "INT:Link status changed\n");
+ PMD_DRV_LOG(INFO, "INT:Link status changed");
i40e_dev_link_update(dev, 0);
}
if (cause & I40E_PFINT_ICR0_ECC_ERR_MASK)
- PMD_DRV_LOG(INFO, "INT:Unrecoverable ECC Error\n");
+ PMD_DRV_LOG(INFO, "INT:Unrecoverable ECC Error");
if (cause & I40E_PFINT_ICR0_MAL_DETECT_MASK)
- PMD_DRV_LOG(INFO, "INT:Malicious programming detected\n");
+ PMD_DRV_LOG(INFO, "INT:Malicious programming detected");
if (cause & I40E_PFINT_ICR0_GRST_MASK)
- PMD_DRV_LOG(INFO, "INT:Global Resets Requested\n");
+ PMD_DRV_LOG(INFO, "INT:Global Resets Requested");
if (cause & I40E_PFINT_ICR0_PCI_EXCEPTION_MASK)
- PMD_DRV_LOG(INFO, "INT:PCI EXCEPTION occured\n");
+ PMD_DRV_LOG(INFO, "INT:PCI EXCEPTION occured");
if (cause & I40E_PFINT_ICR0_HMC_ERR_MASK)
- PMD_DRV_LOG(INFO, "INT:HMC error occured\n");
+ PMD_DRV_LOG(INFO, "INT:HMC error occured");
/* Add processing func to deal with VF reset vent */
if (cause & I40E_PFINT_ICR0_VFLR_MASK) {
- PMD_DRV_LOG(INFO, "INT:VF reset detected\n");
+ PMD_DRV_LOG(INFO, "INT:VF reset detected");
i40e_dev_handle_vfr_event(dev);
}
/* Find admin queue event */
if (cause & I40E_PFINT_ICR0_ADMINQ_MASK) {
- PMD_DRV_LOG(INFO, "INT:ADMINQ event\n");
+ PMD_DRV_LOG(INFO, "INT:ADMINQ event");
i40e_dev_handle_aq_msg(dev);
}
@@ -3465,7 +3465,7 @@ i40e_add_macvlan_filters(struct i40e_vsi *vsi,
req_list = rte_zmalloc("macvlan_add", ele_buff_size, 0);
if (req_list == NULL) {
- PMD_DRV_LOG(ERR, "Fail to allocate memory\n");
+ PMD_DRV_LOG(ERR, "Fail to allocate memory");
return I40E_ERR_NO_MEMORY;
}
@@ -3487,7 +3487,7 @@ i40e_add_macvlan_filters(struct i40e_vsi *vsi,
ret = i40e_aq_add_macvlan(hw, vsi->seid, req_list,
actual_num, NULL);
if (ret != I40E_SUCCESS) {
- PMD_DRV_LOG(ERR, "Failed to add macvlan filter\n");
+ PMD_DRV_LOG(ERR, "Failed to add macvlan filter");
goto DONE;
}
num += actual_num;
@@ -3517,7 +3517,7 @@ i40e_remove_macvlan_filters(struct i40e_vsi *vsi,
req_list = rte_zmalloc("macvlan_remove", ele_buff_size, 0);
if (req_list == NULL) {
- PMD_DRV_LOG(ERR, "Fail to allocate memory\n");
+ PMD_DRV_LOG(ERR, "Fail to allocate memory");
return I40E_ERR_NO_MEMORY;
}
@@ -3537,7 +3537,7 @@ i40e_remove_macvlan_filters(struct i40e_vsi *vsi,
ret = i40e_aq_remove_macvlan(hw, vsi->seid, req_list,
actual_num, NULL);
if (ret != I40E_SUCCESS) {
- PMD_DRV_LOG(ERR, "Failed to remove macvlan filter\n");
+ PMD_DRV_LOG(ERR, "Failed to remove macvlan filter");
goto DONE;
}
num += actual_num;
@@ -3625,7 +3625,7 @@ i40e_find_all_vlan_for_mac(struct i40e_vsi *vsi,
if (vsi->vfta[j] & (1 << k)) {
if (i > num - 1) {
PMD_DRV_LOG(ERR, "vlan number "
- "not match\n");
+ "not match");
return I40E_ERR_PARAM;
}
(void)rte_memcpy(&mv_f[i].macaddr,
@@ -3654,7 +3654,7 @@ i40e_find_all_mac_for_vlan(struct i40e_vsi *vsi,
TAILQ_FOREACH(f, &vsi->mac_list, next) {
if (i > num - 1) {
- PMD_DRV_LOG(ERR, "buffer number not match\n");
+ PMD_DRV_LOG(ERR, "buffer number not match");
return I40E_ERR_PARAM;
}
(void)rte_memcpy(&mv_f[i].macaddr, &f->macaddr, ETH_ADDR_LEN);
@@ -3684,7 +3684,7 @@ i40e_vsi_remove_all_macvlan_filter(struct i40e_vsi *vsi)
mv_f = rte_zmalloc("macvlan_data", num * sizeof(*mv_f), 0);
if (mv_f == NULL) {
- PMD_DRV_LOG(ERR, "failed to allocate memory\n");
+ PMD_DRV_LOG(ERR, "failed to allocate memory");
return I40E_ERR_NO_MEMORY;
}
@@ -3730,14 +3730,14 @@ i40e_vsi_add_vlan(struct i40e_vsi *vsi, uint16_t vlan)
mac_num = vsi->mac_num;
if (mac_num == 0) {
- PMD_DRV_LOG(ERR, "Error! VSI doesn't have a mac addr\n");
+ PMD_DRV_LOG(ERR, "Error! VSI doesn't have a mac addr");
return I40E_ERR_PARAM;
}
mv_f = rte_zmalloc("macvlan_data", mac_num * sizeof(*mv_f), 0);
if (mv_f == NULL) {
- PMD_DRV_LOG(ERR, "failed to allocate memory\n");
+ PMD_DRV_LOG(ERR, "failed to allocate memory");
return I40E_ERR_NO_MEMORY;
}
@@ -3781,14 +3781,14 @@ i40e_vsi_delete_vlan(struct i40e_vsi *vsi, uint16_t vlan)
mac_num = vsi->mac_num;
if (mac_num == 0) {
- PMD_DRV_LOG(ERR, "Error! VSI doesn't have a mac addr\n");
+ PMD_DRV_LOG(ERR, "Error! VSI doesn't have a mac addr");
return I40E_ERR_PARAM;
}
mv_f = rte_zmalloc("macvlan_data", mac_num * sizeof(*mv_f), 0);
if (mv_f == NULL) {
- PMD_DRV_LOG(ERR, "failed to allocate memory\n");
+ PMD_DRV_LOG(ERR, "failed to allocate memory");
return I40E_ERR_NO_MEMORY;
}
@@ -3848,7 +3848,7 @@ i40e_vsi_add_mac(struct i40e_vsi *vsi, struct ether_addr *addr)
mv_f = rte_zmalloc("macvlan_data", vlan_num * sizeof(*mv_f), 0);
if (mv_f == NULL) {
- PMD_DRV_LOG(ERR, "failed to allocate memory\n");
+ PMD_DRV_LOG(ERR, "failed to allocate memory");
return I40E_ERR_NO_MEMORY;
}
@@ -3863,7 +3863,7 @@ i40e_vsi_add_mac(struct i40e_vsi *vsi, struct ether_addr *addr)
/* Add the mac addr into mac list */
f = rte_zmalloc("macv_filter", sizeof(*f), 0);
if (f == NULL) {
- PMD_DRV_LOG(ERR, "failed to allocate memory\n");
+ PMD_DRV_LOG(ERR, "failed to allocate memory");
ret = I40E_ERR_NO_MEMORY;
goto DONE;
}
@@ -3893,12 +3893,12 @@ i40e_vsi_delete_mac(struct i40e_vsi *vsi, struct ether_addr *addr)
vlan_num = vsi->vlan_num;
if (vlan_num == 0) {
- PMD_DRV_LOG(ERR, "VLAN number shouldn't be 0\n");
+ PMD_DRV_LOG(ERR, "VLAN number shouldn't be 0");
return I40E_ERR_PARAM;
}
mv_f = rte_zmalloc("macvlan_data", vlan_num * sizeof(*mv_f), 0);
if (mv_f == NULL) {
- PMD_DRV_LOG(ERR, "failed to allocate memory\n");
+ PMD_DRV_LOG(ERR, "failed to allocate memory");
return I40E_ERR_NO_MEMORY;
}
diff --git a/lib/librte_pmd_i40e/i40e_ethdev_vf.c b/lib/librte_pmd_i40e/i40e_ethdev_vf.c
index 17009bd..f6c4873 100644
--- a/lib/librte_pmd_i40e/i40e_ethdev_vf.c
+++ b/lib/librte_pmd_i40e/i40e_ethdev_vf.c
@@ -205,21 +205,21 @@ i40evf_parse_pfmsg(struct i40e_vf *vf,
vf->link_up =
vpe->event_data.link_event.link_status;
vf->pend_msg |= PFMSG_LINK_CHANGE;
- PMD_DRV_LOG(INFO, "Link status update:%s\n",
+ PMD_DRV_LOG(INFO, "Link status update:%s",
vf->link_up ? "up" : "down");
break;
case I40E_VIRTCHNL_EVENT_RESET_IMPENDING:
vf->vf_reset = true;
vf->pend_msg |= PFMSG_RESET_IMPENDING;
- PMD_DRV_LOG(INFO, "vf is reseting\n");
+ PMD_DRV_LOG(INFO, "vf is reseting");
break;
case I40E_VIRTCHNL_EVENT_PF_DRIVER_CLOSE:
vf->dev_closed = true;
vf->pend_msg |= PFMSG_DRIVER_CLOSE;
- PMD_DRV_LOG(INFO, "PF driver closed\n");
+ PMD_DRV_LOG(INFO, "PF driver closed");
break;
default:
- PMD_DRV_LOG(ERR, "%s: Unknown event %d from pf\n",
+ PMD_DRV_LOG(ERR, "%s: Unknown event %d from pf",
__func__, vpe->event);
}
} else {
@@ -314,7 +314,7 @@ _atomic_set_cmd(struct i40e_vf *vf, enum i40e_virtchnl_ops ops)
I40E_VIRTCHNL_OP_UNKNOWN, ops);
if (!ret)
- PMD_DRV_LOG(ERR, "There is incomplete cmd %d\n", vf->pend_cmd);
+ PMD_DRV_LOG(ERR, "There is incomplete cmd %d", vf->pend_cmd);
return !ret;
}
@@ -338,7 +338,7 @@ i40evf_execute_vf_cmd(struct rte_eth_dev *dev, struct vf_cmd_info *args)
err = i40e_aq_send_msg_to_pf(hw, args->ops, I40E_SUCCESS,
args->in_args, args->in_args_size, NULL);
if (err) {
- PMD_DRV_LOG(ERR, "fail to send cmd %d\n", args->ops);
+ PMD_DRV_LOG(ERR, "fail to send cmd %d", args->ops);
return err;
}
@@ -347,9 +347,9 @@ i40evf_execute_vf_cmd(struct rte_eth_dev *dev, struct vf_cmd_info *args)
if (!err && args->ops == info.ops)
_clear_cmd(vf);
else if (err)
- PMD_DRV_LOG(ERR, "Failed to read message from AdminQ\n");
+ PMD_DRV_LOG(ERR, "Failed to read message from AdminQ");
else if (args->ops != info.ops)
- PMD_DRV_LOG(ERR, "command mismatch, expect %u, get %u\n",
+ PMD_DRV_LOG(ERR, "command mismatch, expect %u, get %u",
args->ops, info.ops);
return (err | info.result);
@@ -377,7 +377,7 @@ i40evf_check_api_version(struct rte_eth_dev *dev)
err = i40evf_execute_vf_cmd(dev, &args);
if (err) {
- PMD_INIT_LOG(ERR, "fail to execute command OP_VERSION\n");
+ PMD_INIT_LOG(ERR, "fail to execute command OP_VERSION");
return err;
}
@@ -385,13 +385,13 @@ i40evf_check_api_version(struct rte_eth_dev *dev)
/* We are talking with DPDK host */
if (pver->major == I40E_DPDK_VERSION_MAJOR) {
vf->host_is_dpdk = TRUE;
- PMD_DRV_LOG(INFO, "Detect PF host is DPDK app\n");
+ PMD_DRV_LOG(INFO, "Detect PF host is DPDK app");
}
/* It's linux host driver */
else if ((pver->major != version.major) ||
(pver->minor != version.minor)) {
PMD_INIT_LOG(ERR, "pf/vf API version mismatch. "
- "(%u.%u)-(%u.%u)\n", pver->major, pver->minor,
+ "(%u.%u)-(%u.%u)", pver->major, pver->minor,
version.major, version.minor);
return -1;
}
@@ -417,7 +417,7 @@ i40evf_get_vf_resource(struct rte_eth_dev *dev)
err = i40evf_execute_vf_cmd(dev, &args);
if (err) {
- PMD_DRV_LOG(ERR, "fail to execute command OP_GET_VF_RESOURCE\n");
+ PMD_DRV_LOG(ERR, "fail to execute command OP_GET_VF_RESOURCE");
return err;
}
@@ -460,7 +460,7 @@ i40evf_config_promisc(struct rte_eth_dev *dev,
if (err)
PMD_DRV_LOG(ERR, "fail to execute command "
- "CONFIG_PROMISCUOUS_MODE\n");
+ "CONFIG_PROMISCUOUS_MODE");
return err;
}
@@ -485,7 +485,7 @@ i40evf_config_vlan_offload(struct rte_eth_dev *dev,
err = i40evf_execute_vf_cmd(dev, &args);
if (err)
- PMD_DRV_LOG(ERR, "fail to execute command CFG_VLAN_OFFLOAD\n");
+ PMD_DRV_LOG(ERR, "fail to execute command CFG_VLAN_OFFLOAD");
return err;
}
@@ -500,7 +500,7 @@ i40evf_config_vlan_pvid(struct rte_eth_dev *dev,
struct i40e_virtchnl_pvid_info tpid_info;
if (dev == NULL || info == NULL) {
- PMD_DRV_LOG(ERR, "invalid parameters\n");
+ PMD_DRV_LOG(ERR, "invalid parameters");
return I40E_ERR_PARAM;
}
@@ -516,7 +516,7 @@ i40evf_config_vlan_pvid(struct rte_eth_dev *dev,
err = i40evf_execute_vf_cmd(dev, &args);
if (err)
- PMD_DRV_LOG(ERR, "fail to execute command CFG_VLAN_PVID\n");
+ PMD_DRV_LOG(ERR, "fail to execute command CFG_VLAN_PVID");
return err;
}
@@ -540,7 +540,7 @@ i40evf_configure_queues(struct rte_eth_dev *dev)
len = sizeof(*queue_info) + sizeof(*queue_cfg) * nb_qpairs;
queue_info = rte_zmalloc("queue_info", len, 0);
if (queue_info == NULL) {
- PMD_INIT_LOG(ERR, "failed alloc memory for queue_info\n");
+ PMD_INIT_LOG(ERR, "failed alloc memory for queue_info");
return -1;
}
queue_info->vsi_id = vf->vsi_res->vsi_id;
@@ -593,7 +593,7 @@ i40evf_configure_queues(struct rte_eth_dev *dev)
err = i40evf_execute_vf_cmd(dev, &args);
if (err)
PMD_DRV_LOG(ERR, "fail to execute command "
- "OP_CONFIG_VSI_QUEUES\n");
+ "OP_CONFIG_VSI_QUEUES");
rte_free(queue_info);
return err;
@@ -628,7 +628,7 @@ i40evf_config_irq_map(struct rte_eth_dev *dev)
args.out_size = I40E_AQ_BUF_SZ;
err = i40evf_execute_vf_cmd(dev, &args);
if (err)
- PMD_DRV_LOG(ERR, "fail to execute command OP_ENABLE_QUEUES\n");
+ PMD_DRV_LOG(ERR, "fail to execute command OP_ENABLE_QUEUES");
return err;
}
@@ -659,7 +659,7 @@ i40evf_switch_queue(struct rte_eth_dev *dev, bool isrx, uint16_t qid,
args.out_size = I40E_AQ_BUF_SZ;
err = i40evf_execute_vf_cmd(dev, &args);
if (err)
- PMD_DRV_LOG(ERR, "fail to switch %s %u %s\n",
+ PMD_DRV_LOG(ERR, "fail to switch %s %u %s",
isrx ? "RX" : "TX", qid, on ? "on" : "off");
return err;
@@ -678,7 +678,7 @@ i40evf_start_queues(struct rte_eth_dev *dev)
if (rxq->start_rx_per_q)
continue;
if (i40evf_dev_rx_queue_start(dev, i) != 0) {
- PMD_DRV_LOG(ERR, "Fail to start queue %u\n", i);
+ PMD_DRV_LOG(ERR, "Fail to start queue %u", i);
return -1;
}
}
@@ -688,7 +688,7 @@ i40evf_start_queues(struct rte_eth_dev *dev)
if (txq->start_tx_per_q)
continue;
if (i40evf_dev_tx_queue_start(dev, i) != 0) {
- PMD_DRV_LOG(ERR, "Fail to start queue %u\n", i);
+ PMD_DRV_LOG(ERR, "Fail to start queue %u", i);
return -1;
}
}
@@ -704,7 +704,7 @@ i40evf_stop_queues(struct rte_eth_dev *dev)
/* Stop TX queues first */
for (i = 0; i < dev->data->nb_tx_queues; i++) {
if (i40evf_dev_tx_queue_stop(dev, i) != 0) {
- PMD_DRV_LOG(ERR, "Fail to start queue %u\n", i);
+ PMD_DRV_LOG(ERR, "Fail to start queue %u", i);
return -1;
}
}
@@ -712,7 +712,7 @@ i40evf_stop_queues(struct rte_eth_dev *dev)
/* Then stop RX queues */
for (i = 0; i < dev->data->nb_rx_queues; i++) {
if (i40evf_dev_rx_queue_stop(dev, i) != 0) {
- PMD_DRV_LOG(ERR, "Fail to start queue %u\n", i);
+ PMD_DRV_LOG(ERR, "Fail to start queue %u", i);
return -1;
}
}
@@ -731,7 +731,7 @@ i40evf_add_mac_addr(struct rte_eth_dev *dev, struct ether_addr *addr)
struct vf_cmd_info args;
if (i40e_validate_mac_addr(addr->addr_bytes) != I40E_SUCCESS) {
- PMD_DRV_LOG(ERR, "Invalid mac:%x:%x:%x:%x:%x:%x\n",
+ PMD_DRV_LOG(ERR, "Invalid mac:%x:%x:%x:%x:%x:%x",
addr->addr_bytes[0], addr->addr_bytes[1],
addr->addr_bytes[2], addr->addr_bytes[3],
addr->addr_bytes[4], addr->addr_bytes[5]);
@@ -752,7 +752,7 @@ i40evf_add_mac_addr(struct rte_eth_dev *dev, struct ether_addr *addr)
err = i40evf_execute_vf_cmd(dev, &args);
if (err)
PMD_DRV_LOG(ERR, "fail to execute command "
- "OP_ADD_ETHER_ADDRESS\n");
+ "OP_ADD_ETHER_ADDRESS");
return err;
}
@@ -768,7 +768,7 @@ i40evf_del_mac_addr(struct rte_eth_dev *dev, struct ether_addr *addr)
struct vf_cmd_info args;
if (i40e_validate_mac_addr(addr->addr_bytes) != I40E_SUCCESS) {
- PMD_DRV_LOG(ERR, "Invalid mac:%x-%x-%x-%x-%x-%x\n",
+ PMD_DRV_LOG(ERR, "Invalid mac:%x-%x-%x-%x-%x-%x",
addr->addr_bytes[0], addr->addr_bytes[1],
addr->addr_bytes[2], addr->addr_bytes[3],
addr->addr_bytes[4], addr->addr_bytes[5]);
@@ -789,7 +789,7 @@ i40evf_del_mac_addr(struct rte_eth_dev *dev, struct ether_addr *addr)
err = i40evf_execute_vf_cmd(dev, &args);
if (err)
PMD_DRV_LOG(ERR, "fail to execute command "
- "OP_DEL_ETHER_ADDRESS\n");
+ "OP_DEL_ETHER_ADDRESS");
return err;
}
@@ -813,7 +813,7 @@ i40evf_get_statics(struct rte_eth_dev *dev, struct rte_eth_stats *stats)
err = i40evf_execute_vf_cmd(dev, &args);
if (err) {
- PMD_DRV_LOG(ERR, "fail to execute command OP_GET_STATS\n");
+ PMD_DRV_LOG(ERR, "fail to execute command OP_GET_STATS");
return err;
}
pstats = (struct i40e_eth_stats *)args.out_buffer;
@@ -851,7 +851,7 @@ i40evf_add_vlan(struct rte_eth_dev *dev, uint16_t vlanid)
args.out_size = I40E_AQ_BUF_SZ;
err = i40evf_execute_vf_cmd(dev, &args);
if (err)
- PMD_DRV_LOG(ERR, "fail to execute command OP_ADD_VLAN\n");
+ PMD_DRV_LOG(ERR, "fail to execute command OP_ADD_VLAN");
return err;
}
@@ -878,7 +878,7 @@ i40evf_del_vlan(struct rte_eth_dev *dev, uint16_t vlanid)
args.out_size = I40E_AQ_BUF_SZ;
err = i40evf_execute_vf_cmd(dev, &args);
if (err)
- PMD_DRV_LOG(ERR, "fail to execute command OP_DEL_VLAN\n");
+ PMD_DRV_LOG(ERR, "fail to execute command OP_DEL_VLAN");
return err;
}
@@ -897,7 +897,7 @@ i40evf_get_link_status(struct rte_eth_dev *dev, struct rte_eth_link *link)
args.out_size = I40E_AQ_BUF_SZ;
err = i40evf_execute_vf_cmd(dev, &args);
if (err) {
- PMD_DRV_LOG(ERR, "fail to execute command OP_GET_LINK_STAT\n");
+ PMD_DRV_LOG(ERR, "fail to execute command OP_GET_LINK_STAT");
return err;
}
@@ -933,7 +933,7 @@ i40evf_reset_vf(struct i40e_hw *hw)
int i, reset;
if (i40e_vf_reset(hw) != I40E_SUCCESS) {
- PMD_INIT_LOG(ERR, "Reset VF NIC failed\n");
+ PMD_INIT_LOG(ERR, "Reset VF NIC failed");
return -1;
}
/**
@@ -958,7 +958,7 @@ i40evf_reset_vf(struct i40e_hw *hw)
}
if (i >= MAX_RESET_WAIT_CNT) {
- PMD_INIT_LOG(ERR, "Reset VF NIC failed\n");
+ PMD_INIT_LOG(ERR, "Reset VF NIC failed");
return -1;
}
@@ -974,49 +974,49 @@ i40evf_init_vf(struct rte_eth_dev *dev)
err = i40evf_set_mac_type(hw);
if (err) {
- PMD_INIT_LOG(ERR, "set_mac_type failed: %d\n", err);
+ PMD_INIT_LOG(ERR, "set_mac_type failed: %d", err);
goto err;
}
i40e_init_adminq_parameter(hw);
err = i40e_init_adminq(hw);
if (err) {
- PMD_INIT_LOG(ERR, "init_adminq failed: %d\n", err);
+ PMD_INIT_LOG(ERR, "init_adminq failed: %d", err);
goto err;
}
/* Reset VF and wait until it's complete */
if (i40evf_reset_vf(hw)) {
- PMD_INIT_LOG(ERR, "reset NIC failed\n");
+ PMD_INIT_LOG(ERR, "reset NIC failed");
goto err_aq;
}
/* VF reset, shutdown admin queue and initialize again */
if (i40e_shutdown_adminq(hw) != I40E_SUCCESS) {
- PMD_INIT_LOG(ERR, "i40e_shutdown_adminq failed\n");
+ PMD_INIT_LOG(ERR, "i40e_shutdown_adminq failed");
return -1;
}
i40e_init_adminq_parameter(hw);
if (i40e_init_adminq(hw) != I40E_SUCCESS) {
- PMD_INIT_LOG(ERR, "init_adminq failed\n");
+ PMD_INIT_LOG(ERR, "init_adminq failed");
return -1;
}
if (i40evf_check_api_version(dev) != 0) {
- PMD_INIT_LOG(ERR, "check_api version failed\n");
+ PMD_INIT_LOG(ERR, "check_api version failed");
goto err_aq;
}
bufsz = sizeof(struct i40e_virtchnl_vf_resource) +
(I40E_MAX_VF_VSI * sizeof(struct i40e_virtchnl_vsi_resource));
vf->vf_res = rte_zmalloc("vf_res", bufsz, 0);
if (!vf->vf_res) {
- PMD_INIT_LOG(ERR, "unable to allocate vf_res memory\n");
+ PMD_INIT_LOG(ERR, "unable to allocate vf_res memory");
goto err_aq;
}
if (i40evf_get_vf_resource(dev) != 0) {
- PMD_INIT_LOG(ERR, "i40evf_get_vf_config failed\n");
+ PMD_INIT_LOG(ERR, "i40evf_get_vf_config failed");
goto err_alloc;
}
@@ -1027,7 +1027,7 @@ i40evf_init_vf(struct rte_eth_dev *dev)
}
if (!vf->vsi_res) {
- PMD_INIT_LOG(ERR, "no LAN VSI found\n");
+ PMD_INIT_LOG(ERR, "no LAN VSI found");
goto err_alloc;
}
@@ -1086,7 +1086,7 @@ i40evf_dev_init(__rte_unused struct eth_driver *eth_drv,
hw->hw_addr = (void *)eth_dev->pci_dev->mem_resource[0].addr;
if(i40evf_init_vf(eth_dev) != 0) {
- PMD_INIT_LOG(ERR, "Init vf failed\n");
+ PMD_INIT_LOG(ERR, "Init vf failed");
return -1;
}
@@ -1223,7 +1223,7 @@ i40evf_dev_rx_queue_start(struct rte_eth_dev *dev, uint16_t rx_queue_id)
err = i40e_alloc_rx_queue_mbufs(rxq);
if (err) {
- PMD_DRV_LOG(ERR, "Failed to allocate RX queue mbuf\n");
+ PMD_DRV_LOG(ERR, "Failed to allocate RX queue mbuf");
return err;
}
@@ -1237,7 +1237,7 @@ i40evf_dev_rx_queue_start(struct rte_eth_dev *dev, uint16_t rx_queue_id)
err = i40evf_switch_queue(dev, TRUE, rx_queue_id, TRUE);
if (err)
- PMD_DRV_LOG(ERR, "Failed to switch RX queue %u on\n",
+ PMD_DRV_LOG(ERR, "Failed to switch RX queue %u on",
rx_queue_id);
}
@@ -1256,7 +1256,7 @@ i40evf_dev_rx_queue_stop(struct rte_eth_dev *dev, uint16_t rx_queue_id)
err = i40evf_switch_queue(dev, TRUE, rx_queue_id, FALSE);
if (err) {
- PMD_DRV_LOG(ERR, "Failed to switch RX queue %u off\n",
+ PMD_DRV_LOG(ERR, "Failed to switch RX queue %u off",
rx_queue_id);
return err;
}
@@ -1281,7 +1281,7 @@ i40evf_dev_tx_queue_start(struct rte_eth_dev *dev, uint16_t tx_queue_id)
err = i40evf_switch_queue(dev, FALSE, tx_queue_id, TRUE);
if (err)
- PMD_DRV_LOG(ERR, "Failed to switch TX queue %u on\n",
+ PMD_DRV_LOG(ERR, "Failed to switch TX queue %u on",
tx_queue_id);
}
@@ -1300,7 +1300,7 @@ i40evf_dev_tx_queue_stop(struct rte_eth_dev *dev, uint16_t tx_queue_id)
err = i40evf_switch_queue(dev, FALSE, tx_queue_id, FALSE);
if (err) {
- PMD_DRV_LOG(ERR, "Failed to switch TX queue %u of\n",
+ PMD_DRV_LOG(ERR, "Failed to switch TX queue %u of",
tx_queue_id);
return err;
}
@@ -1386,7 +1386,7 @@ i40evf_dev_start(struct rte_eth_dev *dev)
vf->max_pkt_len > I40E_FRAME_SIZE_MAX) {
PMD_DRV_LOG(ERR, "maximum packet length must "
"be larger than %u and smaller than %u,"
- "as jumbo frame is enabled\n",
+ "as jumbo frame is enabled",
(uint32_t)ETHER_MAX_LEN,
(uint32_t)I40E_FRAME_SIZE_MAX);
return I40E_ERR_CONFIG;
@@ -1396,7 +1396,7 @@ i40evf_dev_start(struct rte_eth_dev *dev)
vf->max_pkt_len > ETHER_MAX_LEN) {
PMD_DRV_LOG(ERR, "maximum packet length must be "
"larger than %u and smaller than %u, "
- "as jumbo frame is disabled\n",
+ "as jumbo frame is disabled",
(uint32_t)ETHER_MIN_LEN,
(uint32_t)ETHER_MAX_LEN);
return I40E_ERR_CONFIG;
@@ -1407,18 +1407,18 @@ i40evf_dev_start(struct rte_eth_dev *dev)
dev->data->nb_tx_queues);
if (i40evf_rx_init(dev) != 0){
- PMD_DRV_LOG(ERR, "failed to do RX init\n");
+ PMD_DRV_LOG(ERR, "failed to do RX init");
return -1;
}
i40evf_tx_init(dev);
if (i40evf_configure_queues(dev) != 0) {
- PMD_DRV_LOG(ERR, "configure queues failed\n");
+ PMD_DRV_LOG(ERR, "configure queues failed");
goto err_queue;
}
if (i40evf_config_irq_map(dev)) {
- PMD_DRV_LOG(ERR, "config_irq_map failed\n");
+ PMD_DRV_LOG(ERR, "config_irq_map failed");
goto err_queue;
}
@@ -1426,12 +1426,12 @@ i40evf_dev_start(struct rte_eth_dev *dev)
(void)rte_memcpy(mac_addr.addr_bytes, hw->mac.addr,
sizeof(mac_addr.addr_bytes));
if (i40evf_add_mac_addr(dev, &mac_addr)) {
- PMD_DRV_LOG(ERR, "Failed to add mac addr\n");
+ PMD_DRV_LOG(ERR, "Failed to add mac addr");
goto err_queue;
}
if (i40evf_start_queues(dev) != 0) {
- PMD_DRV_LOG(ERR, "enable queues failed\n");
+ PMD_DRV_LOG(ERR, "enable queues failed");
goto err_mac;
}
@@ -1555,7 +1555,7 @@ i40evf_dev_stats_get(struct rte_eth_dev *dev, struct rte_eth_stats *stats)
{
memset(stats, 0, sizeof(*stats));
if (i40evf_get_statics(dev, stats))
- PMD_DRV_LOG(ERR, "Get statics failed\n");
+ PMD_DRV_LOG(ERR, "Get statics failed");
}
static void
diff --git a/lib/librte_pmd_i40e/i40e_pf.c b/lib/librte_pmd_i40e/i40e_pf.c
index ed9773a..682ff44 100644
--- a/lib/librte_pmd_i40e/i40e_pf.c
+++ b/lib/librte_pmd_i40e/i40e_pf.c
@@ -158,7 +158,7 @@ i40e_pf_host_vf_reset(struct i40e_pf_vf *vf, bool do_hw_reset)
}
if (i >= VFRESET_MAX_WAIT_CNT) {
- PMD_DRV_LOG(ERR, "VF reset timeout\n");
+ PMD_DRV_LOG(ERR, "VF reset timeout");
return -ETIMEDOUT;
}
@@ -171,7 +171,7 @@ i40e_pf_host_vf_reset(struct i40e_pf_vf *vf, bool do_hw_reset)
qsel.tx_queues = qsel.rx_queues;
ret = i40e_pf_host_switch_queues(vf, &qsel, false);
if (ret != I40E_SUCCESS) {
- PMD_DRV_LOG(ERR, "Disable VF queues failed\n");
+ PMD_DRV_LOG(ERR, "Disable VF queues failed");
return -EFAULT;
}
@@ -190,7 +190,7 @@ i40e_pf_host_vf_reset(struct i40e_pf_vf *vf, bool do_hw_reset)
/* remove VSI */
ret = i40e_vsi_release(vf->vsi);
if (ret != I40E_SUCCESS) {
- PMD_DRV_LOG(ERR, "Release VSI failed\n");
+ PMD_DRV_LOG(ERR, "Release VSI failed");
return -EFAULT;
}
}
@@ -209,7 +209,7 @@ i40e_pf_host_vf_reset(struct i40e_pf_vf *vf, bool do_hw_reset)
}
if (i >= VFRESET_MAX_WAIT_CNT) {
- PMD_DRV_LOG(ERR, "Wait VF PCI transaction end timeout\n");
+ PMD_DRV_LOG(ERR, "Wait VF PCI transaction end timeout");
return -ETIMEDOUT;
}
@@ -225,13 +225,13 @@ i40e_pf_host_vf_reset(struct i40e_pf_vf *vf, bool do_hw_reset)
vf->vsi = i40e_vsi_setup(vf->pf, I40E_VSI_SRIOV,
vf->pf->main_vsi, vf->vf_idx);
if (vf->vsi == NULL) {
- PMD_DRV_LOG(ERR, "Add vsi failed\n");
+ PMD_DRV_LOG(ERR, "Add vsi failed");
return -EFAULT;
}
ret = i40e_pf_vf_queues_mapping(vf);
if (ret != I40E_SUCCESS) {
- PMD_DRV_LOG(ERR, "queue mapping error\n");
+ PMD_DRV_LOG(ERR, "queue mapping error");
i40e_vsi_release(vf->vsi);
return -EFAULT;
}
@@ -295,7 +295,7 @@ i40e_pf_host_process_cmd_get_vf_resource(struct i40e_pf_vf *vf)
vf_res = rte_zmalloc("i40e_vf_res", len, 0);
if (vf_res == NULL) {
- PMD_DRV_LOG(ERR, "failed to allocate mem\n");
+ PMD_DRV_LOG(ERR, "failed to allocate mem");
ret = I40E_ERR_NO_MEMORY;
vf_res = NULL;
len = 0;
@@ -421,7 +421,7 @@ i40e_pf_host_process_cmd_config_vsi_queues(struct i40e_pf_vf *vf,
if (msg == NULL || msglen <= sizeof(*qconfig) ||
qconfig->num_queue_pairs > vsi->nb_qps) {
- PMD_DRV_LOG(ERR, "vsi_queue_config_info argument wrong\n");
+ PMD_DRV_LOG(ERR, "vsi_queue_config_info argument wrong");
ret = I40E_ERR_PARAM;
goto send_msg;
}
@@ -466,20 +466,20 @@ i40e_pf_host_process_cmd_config_irq_map(struct i40e_pf_vf *vf,
(struct i40e_virtchnl_irq_map_info *)msg;
if (msg == NULL || msglen < sizeof(struct i40e_virtchnl_irq_map_info)) {
- PMD_DRV_LOG(ERR, "buffer too short\n");
+ PMD_DRV_LOG(ERR, "buffer too short");
ret = I40E_ERR_PARAM;
goto send_msg;
}
/* Assume VF only have 1 vector to bind all queues */
if (irqmap->num_vectors != 1) {
- PMD_DRV_LOG(ERR, "DKDK host only support 1 vector\n");
+ PMD_DRV_LOG(ERR, "DKDK host only support 1 vector");
ret = I40E_ERR_PARAM;
goto send_msg;
}
if (irqmap->vecmap[0].vector_id == 0) {
- PMD_DRV_LOG(ERR, "DPDK host don't support use IRQ0\n");
+ PMD_DRV_LOG(ERR, "DPDK host don't support use IRQ0");
ret = I40E_ERR_PARAM;
goto send_msg;
}
@@ -601,7 +601,7 @@ i40e_pf_host_process_cmd_add_ether_address(struct i40e_pf_vf *vf,
struct ether_addr *mac;
if (msg == NULL || msglen <= sizeof(*addr_list)) {
- PMD_DRV_LOG(ERR, "add_ether_address argument too short\n");
+ PMD_DRV_LOG(ERR, "add_ether_address argument too short");
ret = I40E_ERR_PARAM;
goto send_msg;
}
@@ -634,7 +634,7 @@ i40e_pf_host_process_cmd_del_ether_address(struct i40e_pf_vf *vf,
struct ether_addr *mac;
if (msg == NULL || msglen <= sizeof(*addr_list)) {
- PMD_DRV_LOG(ERR, "delete_ether_address argument too short\n");
+ PMD_DRV_LOG(ERR, "delete_ether_address argument too short");
ret = I40E_ERR_PARAM;
goto send_msg;
}
@@ -667,7 +667,7 @@ i40e_pf_host_process_cmd_add_vlan(struct i40e_pf_vf *vf,
uint16_t *vid;
if (msg == NULL || msglen <= sizeof(*vlan_filter_list)) {
- PMD_DRV_LOG(ERR, "add_vlan argument too short\n");
+ PMD_DRV_LOG(ERR, "add_vlan argument too short");
ret = I40E_ERR_PARAM;
goto send_msg;
}
@@ -699,7 +699,7 @@ i40e_pf_host_process_cmd_del_vlan(struct i40e_pf_vf *vf,
uint16_t *vid;
if (msg == NULL || msglen <= sizeof(*vlan_filter_list)) {
- PMD_DRV_LOG(ERR, "delete_vlan argument too short\n");
+ PMD_DRV_LOG(ERR, "delete_vlan argument too short");
ret = I40E_ERR_PARAM;
goto send_msg;
}
@@ -796,7 +796,7 @@ i40e_pf_host_process_cmd_cfg_vlan_offload(
ret = i40e_vsi_config_vlan_stripping(vf->vsi,
!!offload->enable_vlan_strip);
if (ret != 0)
- PMD_DRV_LOG(ERR, "Failed to configure vlan stripping\n");
+ PMD_DRV_LOG(ERR, "Failed to configure vlan stripping");
send_msg:
i40e_pf_host_send_msg_to_vf(vf, I40E_VIRTCHNL_OP_CFG_VLAN_OFFLOAD,
@@ -842,13 +842,13 @@ i40e_pf_host_handle_vf_msg(struct rte_eth_dev *dev,
uint16_t vf_id = abs_vf_id - hw->func_caps.vf_base_id;
if (!dev || vf_id > pf->vf_num - 1 || !pf->vfs) {
- PMD_DRV_LOG(ERR, "invalid argument\n");
+ PMD_DRV_LOG(ERR, "invalid argument");
return;
}
vf = &pf->vfs[vf_id];
if (!vf->vsi) {
- PMD_DRV_LOG(ERR, "NO VSI associated with VF found\n");
+ PMD_DRV_LOG(ERR, "NO VSI associated with VF found");
i40e_pf_host_send_msg_to_vf(vf, opcode,
I40E_ERR_NO_AVAILABLE_VSI, NULL, 0);
return;
@@ -856,81 +856,81 @@ i40e_pf_host_handle_vf_msg(struct rte_eth_dev *dev,
switch (opcode) {
case I40E_VIRTCHNL_OP_VERSION :
- PMD_DRV_LOG(INFO, "OP_VERSION received\n");
+ PMD_DRV_LOG(INFO, "OP_VERSION received");
i40e_pf_host_process_cmd_version(vf);
break;
case I40E_VIRTCHNL_OP_RESET_VF :
- PMD_DRV_LOG(INFO, "OP_RESET_VF received\n");
+ PMD_DRV_LOG(INFO, "OP_RESET_VF received");
i40e_pf_host_process_cmd_reset_vf(vf);
break;
case I40E_VIRTCHNL_OP_GET_VF_RESOURCES:
- PMD_DRV_LOG(INFO, "OP_GET_VF_RESOURCES received\n");
+ PMD_DRV_LOG(INFO, "OP_GET_VF_RESOURCES received");
i40e_pf_host_process_cmd_get_vf_resource(vf);
break;
case I40E_VIRTCHNL_OP_CONFIG_VSI_QUEUES:
- PMD_DRV_LOG(INFO, "OP_CONFIG_VSI_QUEUES received\n");
+ PMD_DRV_LOG(INFO, "OP_CONFIG_VSI_QUEUES received");
i40e_pf_host_process_cmd_config_vsi_queues(vf,
msg, msglen);
break;
case I40E_VIRTCHNL_OP_CONFIG_IRQ_MAP:
- PMD_DRV_LOG(INFO, "OP_CONFIG_IRQ_MAP received\n");
+ PMD_DRV_LOG(INFO, "OP_CONFIG_IRQ_MAP received");
i40e_pf_host_process_cmd_config_irq_map(vf, msg, msglen);
break;
case I40E_VIRTCHNL_OP_ENABLE_QUEUES:
- PMD_DRV_LOG(INFO, "OP_ENABLE_QUEUES received\n");
+ PMD_DRV_LOG(INFO, "OP_ENABLE_QUEUES received");
i40e_pf_host_process_cmd_enable_queues(vf,
msg, msglen);
break;
case I40E_VIRTCHNL_OP_DISABLE_QUEUES:
- PMD_DRV_LOG(INFO, "OP_DISABLE_QUEUE received\n");
+ PMD_DRV_LOG(INFO, "OP_DISABLE_QUEUE received");
i40e_pf_host_process_cmd_disable_queues(vf,
msg, msglen);
break;
case I40E_VIRTCHNL_OP_ADD_ETHER_ADDRESS:
- PMD_DRV_LOG(INFO, "OP_ADD_ETHER_ADDRESS received\n");
+ PMD_DRV_LOG(INFO, "OP_ADD_ETHER_ADDRESS received");
i40e_pf_host_process_cmd_add_ether_address(vf,
msg, msglen);
break;
case I40E_VIRTCHNL_OP_DEL_ETHER_ADDRESS:
- PMD_DRV_LOG(INFO, "OP_DEL_ETHER_ADDRESS received\n");
+ PMD_DRV_LOG(INFO, "OP_DEL_ETHER_ADDRESS received");
i40e_pf_host_process_cmd_del_ether_address(vf,
msg, msglen);
break;
case I40E_VIRTCHNL_OP_ADD_VLAN:
- PMD_DRV_LOG(INFO, "OP_ADD_VLAN received\n");
+ PMD_DRV_LOG(INFO, "OP_ADD_VLAN received");
i40e_pf_host_process_cmd_add_vlan(vf, msg, msglen);
break;
case I40E_VIRTCHNL_OP_DEL_VLAN:
- PMD_DRV_LOG(INFO, "OP_DEL_VLAN received\n");
+ PMD_DRV_LOG(INFO, "OP_DEL_VLAN received");
i40e_pf_host_process_cmd_del_vlan(vf, msg, msglen);
break;
case I40E_VIRTCHNL_OP_CONFIG_PROMISCUOUS_MODE:
- PMD_DRV_LOG(INFO, "OP_CONFIG_PROMISCUOUS_MODE received\n");
+ PMD_DRV_LOG(INFO, "OP_CONFIG_PROMISCUOUS_MODE received");
i40e_pf_host_process_cmd_config_promisc_mode(vf, msg, msglen);
break;
case I40E_VIRTCHNL_OP_GET_STATS:
- PMD_DRV_LOG(INFO, "OP_GET_STATS received\n");
+ PMD_DRV_LOG(INFO, "OP_GET_STATS received");
i40e_pf_host_process_cmd_get_stats(vf);
break;
case I40E_VIRTCHNL_OP_GET_LINK_STAT:
- PMD_DRV_LOG(INFO, "OP_GET_LINK_STAT received\n");
+ PMD_DRV_LOG(INFO, "OP_GET_LINK_STAT received");
i40e_pf_host_process_cmd_get_link_status(vf);
break;
case I40E_VIRTCHNL_OP_CFG_VLAN_OFFLOAD:
- PMD_DRV_LOG(INFO, "OP_CFG_VLAN_OFFLOAD received\n");
+ PMD_DRV_LOG(INFO, "OP_CFG_VLAN_OFFLOAD received");
i40e_pf_host_process_cmd_cfg_vlan_offload(vf, msg, msglen);
break;
case I40E_VIRTCHNL_OP_CFG_VLAN_PVID:
- PMD_DRV_LOG(INFO, "OP_CFG_VLAN_PVID received\n");
+ PMD_DRV_LOG(INFO, "OP_CFG_VLAN_PVID received");
i40e_pf_host_process_cmd_cfg_pvid(vf, msg, msglen);
break;
/* Don't add command supported below, which will
* return an error code.
*/
case I40E_VIRTCHNL_OP_FCOE:
- PMD_DRV_LOG(ERR, "OP_FCOE received, not supported\n");
+ PMD_DRV_LOG(ERR, "OP_FCOE received, not supported");
default:
- PMD_DRV_LOG(ERR, "%u received, not supported\n", opcode);
+ PMD_DRV_LOG(ERR, "%u received, not supported", opcode);
i40e_pf_host_send_msg_to_vf(vf, opcode,
I40E_ERR_PARAM, NULL, 0);
break;
diff --git a/lib/librte_pmd_i40e/i40e_rxtx.c b/lib/librte_pmd_i40e/i40e_rxtx.c
index 99a6572..22f9fd5 100644
--- a/lib/librte_pmd_i40e/i40e_rxtx.c
+++ b/lib/librte_pmd_i40e/i40e_rxtx.c
@@ -420,13 +420,13 @@ i40e_txd_enable_checksum(uint32_t ol_flags,
uint8_t l3_len)
{
if (!l2_len) {
- PMD_DRV_LOG(DEBUG, "L2 length set to 0\n");
+ PMD_DRV_LOG(DEBUG, "L2 length set to 0");
return;
}
*td_offset |= (l2_len >> 1) << I40E_TX_DESC_LENGTH_MACLEN_SHIFT;
if (!l3_len) {
- PMD_DRV_LOG(DEBUG, "L3 length set to 0\n");
+ PMD_DRV_LOG(DEBUG, "L3 length set to 0");
return;
}
@@ -676,7 +676,7 @@ i40e_rx_alloc_bufs(struct i40e_rx_queue *rxq)
diag = rte_mempool_get_bulk(rxq->mp, (void *)rxep,
rxq->rx_free_thresh);
if (unlikely(diag != 0)) {
- PMD_DRV_LOG(ERR, "Failed to get mbufs in bulk\n");
+ PMD_DRV_LOG(ERR, "Failed to get mbufs in bulk");
return -ENOMEM;
}
@@ -728,7 +728,7 @@ rx_recv_pkts(void *rx_queue, struct rte_mbuf **rx_pkts, uint16_t nb_pkts)
uint16_t i, j;
PMD_RX_LOG(DEBUG, "Rx mbuf alloc failed for "
- "port_id=%u, queue_id=%u\n",
+ "port_id=%u, queue_id=%u",
rxq->port_id, rxq->queue_id);
rxq->rx_nb_avail = 0;
rxq->rx_tail = (uint16_t)(rxq->rx_tail - nb_rx);
@@ -1440,7 +1440,7 @@ i40e_dev_rx_queue_start(struct rte_eth_dev *dev, uint16_t rx_queue_id)
err = i40e_alloc_rx_queue_mbufs(rxq);
if (err) {
- PMD_DRV_LOG(ERR, "Failed to allocate RX queue mbuf\n");
+ PMD_DRV_LOG(ERR, "Failed to allocate RX queue mbuf");
return err;
}
@@ -1452,7 +1452,7 @@ i40e_dev_rx_queue_start(struct rte_eth_dev *dev, uint16_t rx_queue_id)
err = i40e_switch_rx_queue(hw, rx_queue_id + q_base, TRUE);
if (err) {
- PMD_DRV_LOG(ERR, "Failed to switch RX queue %u on\n",
+ PMD_DRV_LOG(ERR, "Failed to switch RX queue %u on",
rx_queue_id);
i40e_rx_queue_release_mbufs(rxq);
@@ -1478,7 +1478,7 @@ i40e_dev_rx_queue_stop(struct rte_eth_dev *dev, uint16_t rx_queue_id)
err = i40e_switch_rx_queue(hw, rx_queue_id + q_base, FALSE);
if (err) {
- PMD_DRV_LOG(ERR, "Failed to switch RX queue %u off\n",
+ PMD_DRV_LOG(ERR, "Failed to switch RX queue %u off",
rx_queue_id);
return err;
}
@@ -1502,7 +1502,7 @@ i40e_dev_tx_queue_start(struct rte_eth_dev *dev, uint16_t tx_queue_id)
if (tx_queue_id < dev->data->nb_tx_queues) {
err = i40e_switch_tx_queue(hw, tx_queue_id + q_base, TRUE);
if (err)
- PMD_DRV_LOG(ERR, "Failed to switch TX queue %u on\n",
+ PMD_DRV_LOG(ERR, "Failed to switch TX queue %u on",
tx_queue_id);
}
@@ -1524,7 +1524,7 @@ i40e_dev_tx_queue_stop(struct rte_eth_dev *dev, uint16_t tx_queue_id)
err = i40e_switch_tx_queue(hw, tx_queue_id + q_base, FALSE);
if (err) {
- PMD_DRV_LOG(ERR, "Failed to switch TX queue %u of\n",
+ PMD_DRV_LOG(ERR, "Failed to switch TX queue %u of",
tx_queue_id);
return err;
}
@@ -1553,14 +1553,14 @@ i40e_dev_rx_queue_setup(struct rte_eth_dev *dev,
if (!vsi || queue_idx >= vsi->nb_qps) {
PMD_DRV_LOG(ERR, "VSI not available or queue "
- "index exceeds the maximum\n");
+ "index exceeds the maximum");
return I40E_ERR_PARAM;
}
if (((nb_desc * sizeof(union i40e_rx_desc)) % I40E_ALIGN) != 0 ||
(nb_desc > I40E_MAX_RING_DESC) ||
(nb_desc < I40E_MIN_RING_DESC)) {
PMD_DRV_LOG(ERR, "Number (%u) of receive descriptors is "
- "invalid\n", nb_desc);
+ "invalid", nb_desc);
return I40E_ERR_PARAM;
}
@@ -1577,7 +1577,7 @@ i40e_dev_rx_queue_setup(struct rte_eth_dev *dev,
socket_id);
if (!rxq) {
PMD_DRV_LOG(ERR, "Failed to allocate memory for "
- "rx queue data structure\n");
+ "rx queue data structure");
return (-ENOMEM);
}
rxq->mp = mp;
@@ -1602,7 +1602,7 @@ i40e_dev_rx_queue_setup(struct rte_eth_dev *dev,
socket_id);
if (!rz) {
i40e_dev_rx_queue_release(rxq);
- PMD_DRV_LOG(ERR, "Failed to reserve DMA memory for RX\n");
+ PMD_DRV_LOG(ERR, "Failed to reserve DMA memory for RX");
return (-ENOMEM);
}
@@ -1631,7 +1631,7 @@ i40e_dev_rx_queue_setup(struct rte_eth_dev *dev,
socket_id);
if (!rxq->sw_ring) {
i40e_dev_rx_queue_release(rxq);
- PMD_DRV_LOG(ERR, "Failed to allocate memory for SW ring\n");
+ PMD_DRV_LOG(ERR, "Failed to allocate memory for SW ring");
return (-ENOMEM);
}
@@ -1645,7 +1645,7 @@ i40e_dev_rx_queue_setup(struct rte_eth_dev *dev,
#ifdef RTE_LIBRTE_I40E_RX_ALLOW_BULK_ALLOC
PMD_INIT_LOG(DEBUG, "Rx Burst Bulk Alloc Preconditions are "
"satisfied. Rx Burst Bulk Alloc function will be "
- "used on port=%d, queue=%d.\n",
+ "used on port=%d, queue=%d.",
rxq->port_id, rxq->queue_id);
dev->rx_pkt_burst = i40e_recv_pkts_bulk_alloc;
#endif /* RTE_LIBRTE_I40E_RX_ALLOW_BULK_ALLOC */
@@ -1653,7 +1653,7 @@ i40e_dev_rx_queue_setup(struct rte_eth_dev *dev,
PMD_INIT_LOG(DEBUG, "Rx Burst Bulk Alloc Preconditions are "
"not satisfied, Scattered Rx is requested, "
"or RTE_LIBRTE_I40E_RX_ALLOW_BULK_ALLOC is "
- "not enabled on port=%d, queue=%d.\n",
+ "not enabled on port=%d, queue=%d.",
rxq->port_id, rxq->queue_id);
}
@@ -1666,7 +1666,7 @@ i40e_dev_rx_queue_release(void *rxq)
struct i40e_rx_queue *q = (struct i40e_rx_queue *)rxq;
if (!q) {
- PMD_DRV_LOG(DEBUG, "Pointer to rxq is NULL\n");
+ PMD_DRV_LOG(DEBUG, "Pointer to rxq is NULL");
return;
}
@@ -1684,7 +1684,7 @@ i40e_dev_rx_queue_count(struct rte_eth_dev *dev, uint16_t rx_queue_id)
uint16_t desc = 0;
if (unlikely(rx_queue_id >= dev->data->nb_rx_queues)) {
- PMD_DRV_LOG(ERR, "Invalid RX queue id %u\n", rx_queue_id);
+ PMD_DRV_LOG(ERR, "Invalid RX queue id %u", rx_queue_id);
return 0;
}
@@ -1718,7 +1718,7 @@ i40e_dev_rx_descriptor_done(void *rx_queue, uint16_t offset)
int ret;
if (unlikely(offset >= rxq->nb_rx_desc)) {
- PMD_DRV_LOG(ERR, "Invalid RX queue id %u\n", offset);
+ PMD_DRV_LOG(ERR, "Invalid RX queue id %u", offset);
return 0;
}
@@ -1750,7 +1750,7 @@ i40e_dev_tx_queue_setup(struct rte_eth_dev *dev,
if (!vsi || queue_idx >= vsi->nb_qps) {
PMD_DRV_LOG(ERR, "VSI is NULL, or queue index (%u) "
- "exceeds the maximum\n", queue_idx);
+ "exceeds the maximum", queue_idx);
return I40E_ERR_PARAM;
}
@@ -1758,7 +1758,7 @@ i40e_dev_tx_queue_setup(struct rte_eth_dev *dev,
(nb_desc > I40E_MAX_RING_DESC) ||
(nb_desc < I40E_MIN_RING_DESC)) {
PMD_DRV_LOG(ERR, "Number (%u) of transmit descriptors is "
- "invalid\n", nb_desc);
+ "invalid", nb_desc);
return I40E_ERR_PARAM;
}
@@ -1847,7 +1847,7 @@ i40e_dev_tx_queue_setup(struct rte_eth_dev *dev,
socket_id);
if (!txq) {
PMD_DRV_LOG(ERR, "Failed to allocate memory for "
- "tx queue structure\n");
+ "tx queue structure");
return (-ENOMEM);
}
@@ -1861,7 +1861,7 @@ i40e_dev_tx_queue_setup(struct rte_eth_dev *dev,
socket_id);
if (!tz) {
i40e_dev_tx_queue_release(txq);
- PMD_DRV_LOG(ERR, "Failed to reserve DMA memory for TX\n");
+ PMD_DRV_LOG(ERR, "Failed to reserve DMA memory for TX");
return (-ENOMEM);
}
@@ -1893,7 +1893,7 @@ i40e_dev_tx_queue_setup(struct rte_eth_dev *dev,
socket_id);
if (!txq->sw_ring) {
i40e_dev_tx_queue_release(txq);
- PMD_DRV_LOG(ERR, "Failed to allocate memory for SW TX ring\n");
+ PMD_DRV_LOG(ERR, "Failed to allocate memory for SW TX ring");
return (-ENOMEM);
}
@@ -1904,10 +1904,10 @@ i40e_dev_tx_queue_setup(struct rte_eth_dev *dev,
/* Use a simple TX queue without offloads or multi segs if possible */
if (((txq->txq_flags & I40E_SIMPLE_FLAGS) == I40E_SIMPLE_FLAGS) &&
(txq->tx_rs_thresh >= I40E_TX_MAX_BURST)) {
- PMD_INIT_LOG(INFO, "Using simple tx path\n");
+ PMD_INIT_LOG(INFO, "Using simple tx path");
dev->tx_pkt_burst = i40e_xmit_pkts_simple;
} else {
- PMD_INIT_LOG(INFO, "Using full-featured tx path\n");
+ PMD_INIT_LOG(INFO, "Using full-featured tx path");
dev->tx_pkt_burst = i40e_xmit_pkts;
}
@@ -1920,7 +1920,7 @@ i40e_dev_tx_queue_release(void *txq)
struct i40e_tx_queue *q = (struct i40e_tx_queue *)txq;
if (!q) {
- PMD_DRV_LOG(DEBUG, "Pointer to TX queue is NULL\n");
+ PMD_DRV_LOG(DEBUG, "Pointer to TX queue is NULL");
return;
}
@@ -1961,7 +1961,7 @@ i40e_rx_queue_release_mbufs(struct i40e_rx_queue *rxq)
uint16_t i;
if (!rxq || !rxq->sw_ring) {
- PMD_DRV_LOG(DEBUG, "Pointer to rxq or sw_ring is NULL\n");
+ PMD_DRV_LOG(DEBUG, "Pointer to rxq or sw_ring is NULL");
return;
}
@@ -2021,7 +2021,7 @@ i40e_tx_queue_release_mbufs(struct i40e_tx_queue *txq)
uint16_t i;
if (!txq || !txq->sw_ring) {
- PMD_DRV_LOG(DEBUG, "Pointer to rxq or sw_ring is NULL\n");
+ PMD_DRV_LOG(DEBUG, "Pointer to rxq or sw_ring is NULL");
return;
}
@@ -2040,7 +2040,7 @@ i40e_reset_tx_queue(struct i40e_tx_queue *txq)
uint16_t i, prev, size;
if (!txq) {
- PMD_DRV_LOG(DEBUG, "Pointer to txq is NULL\n");
+ PMD_DRV_LOG(DEBUG, "Pointer to txq is NULL");
return;
}
@@ -2091,13 +2091,13 @@ i40e_tx_queue_init(struct i40e_tx_queue *txq)
err = i40e_clear_lan_tx_queue_context(hw, pf_q);
if (err != I40E_SUCCESS) {
- PMD_DRV_LOG(ERR, "Failure of clean lan tx queue context\n");
+ PMD_DRV_LOG(ERR, "Failure of clean lan tx queue context");
return err;
}
err = i40e_set_lan_tx_queue_context(hw, pf_q, &tx_ctx);
if (err != I40E_SUCCESS) {
- PMD_DRV_LOG(ERR, "Failure of set lan tx queue context\n");
+ PMD_DRV_LOG(ERR, "Failure of set lan tx queue context");
return err;
}
@@ -2125,7 +2125,7 @@ i40e_alloc_rx_queue_mbufs(struct i40e_rx_queue *rxq)
struct rte_mbuf *mbuf = rte_rxmbuf_alloc(rxq->mp);
if (unlikely(!mbuf)) {
- PMD_DRV_LOG(ERR, "Failed to allocate mbuf for RX\n");
+ PMD_DRV_LOG(ERR, "Failed to allocate mbuf for RX");
return -ENOMEM;
}
@@ -2193,7 +2193,7 @@ i40e_rx_queue_config(struct i40e_rx_queue *rxq)
rxq->max_pkt_len > I40E_FRAME_SIZE_MAX) {
PMD_DRV_LOG(ERR, "maximum packet length must "
"be larger than %u and smaller than %u,"
- "as jumbo frame is enabled\n",
+ "as jumbo frame is enabled",
(uint32_t)ETHER_MAX_LEN,
(uint32_t)I40E_FRAME_SIZE_MAX);
return I40E_ERR_CONFIG;
@@ -2203,7 +2203,7 @@ i40e_rx_queue_config(struct i40e_rx_queue *rxq)
rxq->max_pkt_len > ETHER_MAX_LEN) {
PMD_DRV_LOG(ERR, "maximum packet length must be "
"larger than %u and smaller than %u, "
- "as jumbo frame is disabled\n",
+ "as jumbo frame is disabled",
(uint32_t)ETHER_MIN_LEN,
(uint32_t)ETHER_MAX_LEN);
return I40E_ERR_CONFIG;
@@ -2228,7 +2228,7 @@ i40e_rx_queue_init(struct i40e_rx_queue *rxq)
err = i40e_rx_queue_config(rxq);
if (err < 0) {
- PMD_DRV_LOG(ERR, "Failed to config RX queue\n");
+ PMD_DRV_LOG(ERR, "Failed to config RX queue");
return err;
}
@@ -2260,12 +2260,12 @@ i40e_rx_queue_init(struct i40e_rx_queue *rxq)
err = i40e_clear_lan_rx_queue_context(hw, pf_q);
if (err != I40E_SUCCESS) {
- PMD_DRV_LOG(ERR, "Failed to clear LAN RX queue context\n");
+ PMD_DRV_LOG(ERR, "Failed to clear LAN RX queue context");
return err;
}
err = i40e_set_lan_rx_queue_context(hw, pf_q, &rx_ctx);
if (err != I40E_SUCCESS) {
- PMD_DRV_LOG(ERR, "Failed to set LAN RX queue context\n");
+ PMD_DRV_LOG(ERR, "Failed to set LAN RX queue context");
return err;
}
--
1.7.10.4
next prev parent reply other threads:[~2014-09-17 13:41 UTC|newest]
Thread overview: 25+ messages / expand[flat|nested] mbox.gz Atom feed top
2014-09-17 13:46 [dpdk-dev] [PATCH v3 00/20] cleanup logs in main PMDs David Marchand
2014-09-17 13:46 ` [dpdk-dev] [PATCH v3 01/20] ixgbe: use the right debug macro David Marchand
2014-09-17 13:46 ` [dpdk-dev] [PATCH v3 02/20] ixgbe/base: add a raw macro for use by shared code David Marchand
2014-09-17 13:46 ` [dpdk-dev] [PATCH v3 03/20] ixgbe: indent logs sections David Marchand
2014-09-17 13:46 ` [dpdk-dev] [PATCH v3 04/20] ixgbe: clean log messages David Marchand
2014-09-17 13:46 ` [dpdk-dev] [PATCH v3 05/20] ixgbe: always log init messages David Marchand
2014-09-17 13:46 ` [dpdk-dev] [PATCH v3 06/20] ixgbe: add a message when forcing scatter mode David Marchand
2014-09-17 13:46 ` [dpdk-dev] [PATCH v3 07/20] ixgbe: add log messages when rx bulk mode is not usable David Marchand
2014-09-17 13:46 ` [dpdk-dev] [PATCH v3 08/20] i40e: use the right debug macro David Marchand
2014-09-17 13:46 ` [dpdk-dev] [PATCH v3 09/20] i40e/base: add a raw macro for use by shared code David Marchand
2014-09-17 13:46 ` [dpdk-dev] [PATCH v3 10/20] i40e: indent logs sections David Marchand
2014-09-17 13:46 ` David Marchand [this message]
2014-09-17 13:46 ` [dpdk-dev] [PATCH v3 12/20] i40e: always log init messages David Marchand
2014-09-17 13:46 ` [dpdk-dev] [PATCH v3 13/20] i40e: add log messages when rx bulk mode is not usable David Marchand
2014-09-17 13:46 ` [dpdk-dev] [PATCH v3 14/20] e1000: use the right debug macro David Marchand
2014-09-17 13:46 ` [dpdk-dev] [PATCH v3 15/20] e1000/base: add a raw macro for use by shared code David Marchand
2014-09-17 13:46 ` [dpdk-dev] [PATCH v3 16/20] e1000: indent logs sections David Marchand
2014-09-17 13:46 ` [dpdk-dev] [PATCH v3 17/20] e1000: clean log messages David Marchand
2014-09-17 13:46 ` [dpdk-dev] [PATCH v3 18/20] e1000: always log init messages David Marchand
2014-09-17 13:46 ` [dpdk-dev] [PATCH v3 19/20] e1000: add a message when forcing scatter mode David Marchand
2014-09-17 13:46 ` [dpdk-dev] [PATCH v3 20/20] eal: set log level from command line David Marchand
2014-09-17 14:45 ` Neil Horman
2014-09-18 7:46 ` David Marchand
2014-09-18 10:27 ` Neil Horman
2014-09-19 7:52 ` [dpdk-dev] [PATCH v3 00/20] cleanup logs in main PMDs Thomas Monjalon
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=1410961612-8571-12-git-send-email-david.marchand@6wind.com \
--to=david.marchand@6wind.com \
--cc=dev@dpdk.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).