100GbE Intel Wired LAN Driver Updates 2018-09-27
Subsystems (3)
This series contains fixes to the ice driver only.
Jake fixes a potential crash due to attempting to access the mutex which is already destroyed. Fix this by using rq.count and sq.count to determine if the queue was initialized. Fixed the current logic for checking the firmware version to properly handle situations when firmware major/minor versions differ and when the branch version differs.
Bruce replaces a memcpy() with a direct assignment, which is preferred. Also updated the branding strings and device ids supported by the driver. Fixed the "ethtool -G" command in the driver, which was always returning EINVAL when changing the descriptor ring size.
Brett update and clarified code comments.
Anirudh updates the driver to ensure we query the firmware for the transmit scheduler node information before adding it to the driver database, to ensure we have the current information. Also update the "get capabilities" command to get device and function capabilities.
The following are changes since commit 1042caa79e9351b81ed19dc8d2d7fd6ff51a4422:
net-ipv4: remove 2 always zero parameters from ipv4_redirect()
and are available in the git repository at:
git://git.kernel.org/pub/scm/linux/kernel/git/jkirsher/next-queue 100GbE
Anirudh Venkataramanan (2):
ice: Query the Tx scheduler node before adding it
ice: Update to capabilities admin queue command
Brett Creeley (1):
ice: Update comment for ice_fltr_mgmt_list_entry
Bruce Allan (3):
ice: replace unnecessary memcpy with direct assignment
ice: update branding strings and supported device ids
ice: fix changing of ring descriptor size (ethtool -G)
Jacob Keller (2):
ice: use [sr]q.count when checking if queue is initialized
ice: update fw version check logic
drivers/net/ethernet/intel/ice/ice.h | 4 +- .../net/ethernet/intel/ice/ice_adminq_cmd.h | 5 ++ drivers/net/ethernet/intel/ice/ice_common.c | 50 +++++++++----- drivers/net/ethernet/intel/ice/ice_controlq.c | 40 ++++++----- drivers/net/ethernet/intel/ice/ice_devids.h | 10 +-- drivers/net/ethernet/intel/ice/ice_ethtool.c | 17 ++++- drivers/net/ethernet/intel/ice/ice_main.c | 2 - drivers/net/ethernet/intel/ice/ice_sched.c | 67 ++++++++++++++++++- drivers/net/ethernet/intel/ice/ice_switch.h | 3 +- 9 files changed, 150 insertions(+), 48 deletions(-)
Signature · 1 line
2.17.1
PATCH 1/8 ice: use [sr]q.count when checking if queue is initialized
From: Jacob Keller <[email protected]>
When shutting down the controlqs, we check if they are initialized before we shut them down and destroy the lock. This is important, as it prevents attempts to access the lock of an already shutdown queue.
Unfortunately, we checked rq.head and sq.head as the value to determine if the queue was initialized. This doesn't work, because head is not reset when the queue is shutdown. In some flows, the adminq will have already been shut down prior to calling ice_shutdown_all_ctrlqs. This can result in a crash due to attempting to access the already destroyed mutex.
Fix this by using rq.count and sq.count instead. Indeed, ice_shutdown_sq and ice_shutdown_rq already indicate that this is the value we should be using to determine of the queue was initialized.
--- drivers/net/ethernet/intel/ice/ice_controlq.c | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-)
drivers/net/ethernet/intel/ice/ice_controlq.c +4 -4
@@ -597,11 +597,11 @@ static enum ice_status ice_init_check_adminq(struct ice_hw *hw)return 0 ; init_ctrlq_free_rq: -if (cq->rq.head) { +if (cq->rq.count) {ice_shutdown_rq (hw, cq);mutex_destroy (&cq->rq_lock); } -if (cq->sq.head) { +if (cq->sq.count) {ice_shutdown_sq (hw, cq);mutex_destroy (&cq->sq_lock); }
@@ -710,11 +710,11 @@ static void ice_shutdown_ctrlq(struct ice_hw *hw, enum ice_ctl_q q_type)return ; } -if (cq->sq.head) { +if (cq->sq.count) {ice_shutdown_sq (hw, cq);mutex_destroy (&cq->sq_lock); } -if (cq->rq.head) { +if (cq->rq.count) {ice_shutdown_rq (hw, cq);mutex_destroy (&cq->rq_lock); }
Signature · 1 line
2.17.1
Re: [net-next 1/8] ice: use [sr]q.count when checking if queue is initialized
Hello!
Quoted 13 lines · Jeff Kirsher
From: Jacob Keller <[email protected]>
When shutting down the controlqs, we check if they are initialized before we shut them down and destroy the lock. This is important, as it prevents attempts to access the lock of an already shutdown queue.
Unfortunately, we checked rq.head and sq.head as the value to determine if the queue was initialized. This doesn't work, because head is not reset when the queue is shutdown. In some flows, the adminq will have already been shut down prior to calling
ice_shutdown_all_ctrlqs. This can result in a crash due to attempting to access the already destroyed mutex.
Quoted 3 lines
Fix this by using rq.count and sq.count instead. Indeed,
ice_shutdown_sqandice_shutdown_rqalready indicate that this is the value we should be using to determine of the queue was initialized.
s/of/if/?
Quoted 4 lines
Signed-off-by Jacob Keller <[email protected]>Signed-off-by Anirudh Venkataramanan <[email protected]>Tested-by Andrew Bowers <[email protected]>Signed-off-by Jeff Kirsher <[email protected]>
[...]
MBR, Sergei
RE: [net-next 1/8] ice: use [sr]q.count when checking if queue is initialized
Quoted 30 lines
-----Original Message-----
From: [email protected] [mailto:[email protected]] On Behalf Of Sergei Shtylyov
Sent: Friday, September 28, 2018 2:02 AM
To: Kirsher, Jeffrey T <[email protected]>; [email protected]
Cc: Keller, Jacob E <[email protected]>; [email protected]; [email protected]; [email protected]; [email protected]; Venkataramanan, Anirudh <[email protected]>
Subject: Re: [net-next 1/8] ice: use [sr]q.count when checking if queue is initializedHello!
Quoted 13 lines · Jeff Kirsher
From: Jacob Keller <[email protected]>
When shutting down the controlqs, we check if they are initialized before we shut them down and destroy the lock. This is important, as it prevents attempts to access the lock of an already shutdown queue.
Unfortunately, we checked rq.head and sq.head as the value to determine if the queue was initialized. This doesn't work, because head is not reset when the queue is shutdown. In some flows, the adminq will have already been shut down prior to calling
ice_shutdown_all_ctrlqs. This can result in a crash due to attempting to access the already destroyed mutex.
Quoted 5 lines
Quoted 3 lines
Fix this by using rq.count and sq.count instead. Indeed,
ice_shutdown_sqandice_shutdown_rqalready indicate that this is the value we should be using to determine of the queue was initialized.s/of/if/?
Yes. However, unless there's a functional change required as well, I don't think it's worth fixing this.
Thanks,
Jake
Quoted 9 lines
Quoted 3 lines
Signed-off-by Jacob Keller <[email protected]>Signed-off-by Anirudh VenkataramananQuoted 2 lines
Tested-by Andrew Bowers <[email protected]>Signed-off-by Jeff Kirsher <[email protected]>[...]
MBR, Sergei
PATCH 2/8 ice: replace unnecessary memcpy with direct assignment
In reply to Jeff KirsherFrom: Bruce Allan <[email protected]>
Direct assignment is preferred over a memcpy()
--- drivers/net/ethernet/intel/ice/ice_controlq.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-)
drivers/net/ethernet/intel/ice/ice_controlq.c +1 -1
@@ -850,7 +850,7 @@ ice_sq_send_cmd(struct ice_hw *hw, struct ice_ctl_q_info *cq, details =ICE_CTL_Q_DETAILS (cq->sq, cq->sq.next_to_use);if (cd) -memcpy (details, cd,sizeof (*details)); + *details = *cd;else memset (details,0 ,sizeof (*details));
Signature · 1 line
2.17.1
PATCH 3/8 ice: update branding strings and supported device ids
In reply to Jeff KirsherFrom: Bruce Allan <[email protected]>
Update branding strings and remove device ids 0x1594 and 0x1595.
--- drivers/net/ethernet/intel/ice/ice_devids.h | 10 +++------- drivers/net/ethernet/intel/ice/ice_main.c | 2 -- 2 files changed, 3 insertions(+), 9 deletions(-)
drivers/net/ethernet/intel/ice/ice_devids.h +3 -7
@@ -5,15 +5,11 @@#define _ICE_DEVIDS_H_/* Device IDs */ -/* Intel(R) Ethernet Controller C810 for backplane */ +/* Intel(R) Ethernet Controller E810-C for backplane */ #define ICE_DEV_ID_C810_BACKPLANE 0x1591 -/* Intel(R) Ethernet Controller C810 for QSFP */ +/* Intel(R) Ethernet Controller E810-C for QSFP */ #define ICE_DEV_ID_C810_QSFP 0x1592 -/* Intel(R) Ethernet Controller C810 for SFP */ +/* Intel(R) Ethernet Controller E810-C for SFP */ #define ICE_DEV_ID_C810_SFP 0x1593 -/* Intel(R) Ethernet Controller C810/X557-AT 10GBASE-T */ -#define ICE_DEV_ID_C810_10G_BASE_T 0x1594 -/* Intel(R) Ethernet Controller C810 1GbE */ -#define ICE_DEV_ID_C810_SGMII 0x1595#endif /* _ICE_DEVIDS_H_ */
drivers/net/ethernet/intel/ice/ice_main.c +0 -2
@@ -3777,8 +3777,6 @@ static const struct pci_device_id ice_pci_tbl[] = { { PCI_VDEVICE(INTEL, ICE_DEV_ID_C810_BACKPLANE), 0 }, { PCI_VDEVICE(INTEL, ICE_DEV_ID_C810_QSFP), 0 }, { PCI_VDEVICE(INTEL, ICE_DEV_ID_C810_SFP), 0 }, - { PCI_VDEVICE(INTEL, ICE_DEV_ID_C810_10G_BASE_T), 0 }, - { PCI_VDEVICE(INTEL, ICE_DEV_ID_C810_SGMII), 0 },/* required last entry */ { 0, } };
Signature · 1 line
2.17.1
PATCH 4/8 ice: update fw version check logic
In reply to Jeff KirsherFrom: Jacob Keller <[email protected]>
We have MAX_FW_API_VER_BRANCH, MAX_FW_API_VER_MAJOR, and MAX_FW_API_VER_MINOR that we use in ice_controlq.h to test when a firmware version is newer than expected. This is currently tested by comparing each field separately. Thus, we compare the branch field against the MAX_FW_API_VER_BRANCH, and so forth.
This means that currently, if we suppose that the max firmware version is defined as 0.2.1, i.e.
Then firmware 0.1.3 will fail to load. This is because the minor version 3 is greater than the max minor version 1.
This is not intuitive, because of the notion that increasing the major firmware version to 2 should mean any firmware version with a major version is less than 2 should be considered older than 2...
In order to allow both 0.2.1 and 0.1.3 to load, you would have to define the "max" firmware version as 0.2.3.. It is possible that such a firmware version doesn't even exist yet!
Fix this by replacing the current logic with an updated check that behaves as follows:
First, we check the major version. If it is greater than the expected version, then we prevent driver load. Additionally, a warning message is logged to indicate to the system administrator that they need to update their driver. This is now the only case where the driver will refuse to load.
Second, if the major version is less than the expected version, we log an information message indicating the NVM should be updated.
Third, if the major version is exact, we'll then check the minor version. If the minor version is more than two versions less than expected, we log an information message indicating the NVM should be updated. If it is more than two versions greater than the expected version, we log an information message that the driver should be updated.
To support this, the ice_aq_ver_check function needs its signature updated to pass the HW structure. Since we now pass this structure, there is no need to pass the firmware API versions separately.
--- drivers/net/ethernet/intel/ice/ice_controlq.c | 30 ++++++++++++------- 1 file changed, 19 insertions(+), 11 deletions(-)
drivers/net/ethernet/intel/ice/ice_controlq.c +19 -11
@@ -518,22 +518,31 @@ ice_shutdown_sq(struct ice_hw *hw, struct ice_ctl_q_info *cq)/** * ice_aq_ver_check - Check the reported AQ API version. -* @fw_branch: The "branch" of FW, typically describes the device type -* @fw_major: The major version of the FW API -* @fw_minor: The minor version increment of the FW API +* @hw: pointer to the hardware structure * * Checks if the driver should load on a given AQ API version. * * Return: 'true' iff the driver should attempt to load. 'false' otherwise. */ -static bool ice_aq_ver_check (u8 fw_branch,u8 fw_major,u8 fw_minor) +static bool ice_aq_ver_check (struct ice_hw *hw) { -if (fw_branch !=EXP_FW_API_VER_BRANCH ) -return false; -if (fw_major !=EXP_FW_API_VER_MAJOR ) -return false; -if (fw_minor !=EXP_FW_API_VER_MINOR ) +if (hw->api_maj_ver >EXP_FW_API_VER_MAJOR ) { +/* Major API version is newer than expected, don't load */ +dev_warn (ice_hw_to_dev (hw), +"The driver for the device stopped because the NVM image is newer than expected. You must install the most recent version of the network driver.\n" );return false; + }else if (hw->api_maj_ver ==EXP_FW_API_VER_MAJOR ) { +if (hw->api_min_ver > (EXP_FW_API_VER_MINOR +2 )) +dev_info (ice_hw_to_dev (hw), +"The driver for the device detected a newer version of the NVM image than expected. Please install the most recent version of the network driver.\n" ); +else if ((hw->api_min_ver +2 ) <EXP_FW_API_VER_MINOR ) +dev_info (ice_hw_to_dev (hw), +"The driver for the device detected an older version of the NVM image than expected. Please update the NVM image.\n" ); + }else { +/* Major API version is older than expected, log a warning */ +dev_info (ice_hw_to_dev (hw), +"The driver for the device detected an older version of the NVM image than expected. Please update the NVM image.\n" ); + }return true; }
@@ -588,8 +597,7 @@ static enum ice_status ice_init_check_adminq(struct ice_hw *hw)if (status) goto init_ctrlq_free_rq; -if (!ice_aq_ver_check (hw->api_branch, hw->api_maj_ver, - hw->api_min_ver)) { +if (!ice_aq_ver_check (hw)) { status =ICE_ERR_FW_API_VER ; goto init_ctrlq_free_rq; }
Signature · 1 line
2.17.1
PATCH 5/8 ice: Update comment for ice_fltr_mgmt_list_entry
In reply to Jeff KirsherFrom: Brett Creeley <[email protected]>
Previously the comment stated that VSI lists should be used when a second VSI becomes a subscriber to the "VLAN address". VSI lists are always used for VLAN membership, so replace "VLAN address" with "MAC address". Also note that VLAN(s) always use VSI list rules.
--- drivers/net/ethernet/intel/ice/ice_switch.h | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-)
drivers/net/ethernet/intel/ice/ice_switch.h +2 -1
@@ -140,7 +140,8 @@ struct ice_fltr_list_entry {/* This defines an entry in the list that maintains MAC or VLAN membership * to HW list mapping, since multiple VSIs can subscribe to the same MAC or * VLAN. As an optimization the VSI list should be created only when a -* second VSI becomes a subscriber to the VLAN address. +* second VSI becomes a subscriber to the same MAC address. VSI lists are always +* used for VLAN membership. */ struct ice_fltr_mgmt_list_entry {/* back pointer to VSI list id to VSI list mapping */
Signature · 1 line
2.17.1
PATCH 6/8 ice: Query the Tx scheduler node before adding it
In reply to Jeff KirsherFrom: Anirudh Venkataramanan <[email protected]>
Query the Tx scheduler tree node information from FW before adding it to the driver's software database. This will keep the node information current in driver.
--- .../net/ethernet/intel/ice/ice_adminq_cmd.h | 5 ++ drivers/net/ethernet/intel/ice/ice_sched.c | 67 ++++++++++++++++++- 2 files changed, 71 insertions(+), 1 deletion(-)
drivers/net/ethernet/intel/ice/ice_adminq_cmd.h +5 -0
@@ -736,6 +736,10 @@ struct ice_aqc_add_elem {struct ice_aqc_txsched_elem_data generic[1 ]; }; +struct ice_aqc_get_elem { +struct ice_aqc_txsched_elem_data generic[1 ]; +}; +struct ice_aqc_get_topo_elem {struct ice_aqc_txsched_topo_grp_info_hdr hdr;struct ice_aqc_txsched_elem_data
@@ -1409,6 +1413,7 @@ enum ice_adminq_opc {/* transmit scheduler commands */ ice_aqc_opc_get_dflt_topo =0x0400 , ice_aqc_opc_add_sched_elems =0x0401 , + ice_aqc_opc_get_sched_elems =0x0404 , ice_aqc_opc_suspend_sched_elems =0x0409 , ice_aqc_opc_resume_sched_elems =0x040A , ice_aqc_opc_delete_sched_elems = 0x040F,
drivers/net/ethernet/intel/ice/ice_sched.c +66 -1
92 lines not on this page · raw message
Signature · 1 line
2.17.1
PATCH 7/8 ice: Update to capabilities admin queue command
In reply to Jeff KirsherFrom: Anirudh Venkataramanan <[email protected]>
This patch makes a couple of changes in the way the driver uses the "get capabilities" command.
1. Get device capabilities in addition to function capabilities
2. Align to latest spec by using cap_count to determine size of the buffer in case of length error.
--- drivers/net/ethernet/intel/ice/ice_common.c | 50 ++++++++++++++------- 1 file changed, 34 insertions(+), 16 deletions(-)
drivers/net/ethernet/intel/ice/ice_common.c +34 -16
@@ -1451,7 +1451,7 @@ ice_parse_caps(struct ice_hw *hw, void *buf, u32 cap_count,* @hw: pointer to the hw struct * @buf: a virtual buffer to hold the capabilities * @buf_size: Size of the virtual buffer -* @data_size: Size of the returned data, or buf size needed if AQ err==ENOMEM +* @cap_count: cap count needed if AQ err==ENOMEM * @opc: capabilities type to discover - pass in the command opcode * @cd: pointer to command details structure or NULL *
@@ -1459,7 +1459,7 @@ ice_parse_caps(struct ice_hw *hw, void *buf, u32 cap_count,* the firmware. */ static enum ice_status -ice_aq_discover_caps (struct ice_hw *hw,void *buf,u16 buf_size,u16 *data_size, +ice_aq_discover_caps (struct ice_hw *hw,void *buf,u16 buf_size,u32 *cap_count,enum ice_adminq_opc opc,struct ice_sq_cd *cd) {struct ice_aqc_list_caps *cmd;
@@ -1477,58 +1477,76 @@ ice_aq_discover_caps(struct ice_hw *hw, void *buf, u16 buf_size, u16 *data_size, status =ice_aq_send_cmd (hw, &desc, buf, buf_size, cd);if (!status)ice_parse_caps (hw, buf,le32_to_cpu (cmd->count), opc); - *data_size =le16_to_cpu (desc.datalen); - +else if (hw->adminq.sq_last_status ==ICE_AQ_RC_ENOMEM ) + *cap_count = +DIV_ROUND_UP (le16_to_cpu (desc.datalen), +sizeof (struct ice_aqc_list_caps_elem ));return status; }/** -* ice_get_caps - get info about the HW +* ice_discover_caps - get info about the HW * @hw: pointer to the hardware structure +* @opc: capabilities type to discover - pass in the command opcode */ -enum ice_status ice_get_caps (struct ice_hw *hw) +static enum ice_status ice_discover_caps (struct ice_hw *hw, +enum ice_adminq_opc opc) {enum ice_status status; -u16 data_size =0 ; +u32 cap_count;u16 cbuf_len;u8 retries;/* The driver doesn't know how many capabilities the device will return * so the buffer size required isn't known ahead of time. The driver * starts with cbuf_len and if this turns out to be insufficient, the -* device returns ICE_AQ_RC_ENOMEM and also the buffer size it needs. -* The driver then allocates the buffer of this size and retries the -* operation. So it follows that the retry count is 2. +* device returns ICE_AQ_RC_ENOMEM and also the cap_count it needs. +* The driver then allocates the buffer based on the count and retries +* the operation. So it follows that the retry count is 2. */ #define ICE_GET_CAP_BUF_COUNT 40#define ICE_GET_CAP_RETRY_COUNT 2 - cbuf_len =ICE_GET_CAP_BUF_COUNT * -sizeof (struct ice_aqc_list_caps_elem ); - + cap_count =ICE_GET_CAP_BUF_COUNT ; retries =ICE_GET_CAP_RETRY_COUNT ;do {void *cbuf; + cbuf_len = (u16)(cap_count * +sizeof (struct ice_aqc_list_caps_elem )); cbuf =devm_kzalloc (ice_hw_to_dev (hw), cbuf_len,GFP_KERNEL );if (!cbuf)return ICE_ERR_NO_MEMORY ; - status =ice_aq_discover_caps (hw, cbuf, cbuf_len, &data_size, - ice_aqc_opc_list_func_caps,NULL ); + status =ice_aq_discover_caps (hw, cbuf, cbuf_len, &cap_count, + opc,NULL );devm_kfree (ice_hw_to_dev (hw), cbuf);if (!status || hw->adminq.sq_last_status !=ICE_AQ_RC_ENOMEM )break ;/* If ENOMEM is returned, try again with bigger buffer */ - cbuf_len = data_size; }while (--retries);return status; } +/** +* ice_get_caps - get info about the HW +* @hw: pointer to the hardware structure +*/ +enum ice_status ice_get_caps (struct ice_hw *hw) +{ +enum ice_status status; + + status =ice_discover_caps (hw, ice_aqc_opc_list_dev_caps); +if (!status) + status =ice_discover_caps (hw, ice_aqc_opc_list_func_caps); + +return status; +} +/** * ice_aq_manage_mac_write - manage MAC address write command * @hw: pointer to the hw struct
Signature · 1 line
2.17.1
PATCH 8/8 ice: fix changing of ring descriptor size (ethtool -G)
In reply to Jeff KirsherFrom: Bruce Allan <[email protected]>
rx_mini_pending was set to an incorrect value. This was causing EINVAL to always be returned to 'ethtool -G'. The driver does not support mini or jumbo rings so the respective settings should be zero.
Also, change the valid range of the number of descriptors in the rings to make the code simpler and easier for users to understand (this removes the valid settings of 8 and 16). Add a system log message indicating when the number is rounded-up from what the user specifies with the 'ethtool -G' command (i.e. when it is not a multiple of 32), and update the log message when a user-provided value is out of range to also indicate the stride.
--- drivers/net/ethernet/intel/ice/ice.h | 4 ++-- drivers/net/ethernet/intel/ice/ice_ethtool.c | 17 ++++++++++++++--- 2 files changed, 16 insertions(+), 5 deletions(-)
drivers/net/ethernet/intel/ice/ice.h +2 -2
@@ -39,9 +39,9 @@extern const char ice_drv_ver[];#define ICE_BAR0 0#define ICE_DFLT_NUM_DESC 128 -#define ICE_MIN_NUM_DESC 8 -#define ICE_MAX_NUM_DESC 8160#define ICE_REQ_DESC_MULTIPLE 32 +#define ICE_MIN_NUM_DESC ICE_REQ_DESC_MULTIPLE +#define ICE_MAX_NUM_DESC 8160#define ICE_DFLT_TRAFFIC_CLASS BIT(0)#define ICE_INT_NAME_STR_LEN (IFNAMSIZ + 16)#define ICE_ETHTOOL_FWVER_LEN 32
drivers/net/ethernet/intel/ice/ice_ethtool.c +14 -3
@@ -1198,9 +1198,11 @@ ice_get_ringparam(struct net_device *netdev, struct ethtool_ringparam *ring) ring->tx_max_pending =ICE_MAX_NUM_DESC ; ring->rx_pending = vsi->rx_rings[0 ]->count; ring->tx_pending = vsi->tx_rings[0 ]->count; - ring->rx_mini_pending =ICE_MIN_NUM_DESC ; + +/* Rx mini and jumbo rings are not supported */ ring->rx_mini_max_pending =0 ; ring->rx_jumbo_max_pending =0 ; + ring->rx_mini_pending =0 ; ring->rx_jumbo_pending =0 ; }
@@ -1218,14 +1220,23 @@ ice_set_ringparam(struct net_device *netdev, struct ethtool_ringparam *ring) ring->tx_pending < ICE_MIN_NUM_DESC || ring->rx_pending > ICE_MAX_NUM_DESC || ring->rx_pending < ICE_MIN_NUM_DESC) { -netdev_err (netdev,"Descriptors requested (Tx: %d / Rx: %d) out of range [%d-%d]\n" , +netdev_err (netdev,"Descriptors requested (Tx: %d / Rx: %d) out of range [%d-%d] (increment %d)\n" , ring->tx_pending, ring->rx_pending, -ICE_MIN_NUM_DESC ,ICE_MAX_NUM_DESC ); +ICE_MIN_NUM_DESC ,ICE_MAX_NUM_DESC , +ICE_REQ_DESC_MULTIPLE );return -EINVAL ; } new_tx_cnt =ALIGN (ring->tx_pending,ICE_REQ_DESC_MULTIPLE ); +if (new_tx_cnt != ring->tx_pending) +netdev_info (netdev, +"Requested Tx descriptor count rounded up to %d\n" , + new_tx_cnt); new_rx_cnt =ALIGN (ring->rx_pending,ICE_REQ_DESC_MULTIPLE ); +if (new_rx_cnt != ring->rx_pending) +netdev_info (netdev, +"Requested Rx descriptor count rounded up to %d\n" , + new_rx_cnt);/* if nothing to do return success */ if (new_tx_cnt == vsi->tx_rings[0]->count &&
Signature · 1 line
2.17.1
David Miller
maintainerFrom: Jeff Kirsher <[email protected]>
Date: Thu, 27 Sep 2018 09:21:53 -0700
Quoted 1 line
This series contains fixes to the ice driver only.
...
Quoted 4 lines
The following are changes since commit
1042caa79e9351b81ed19dc8d2d7fd6ff51a4422:
net-ipv4: remove 2 always zero parameters fromipv4_redirect()
and are available in the git repository at:
git://git.kernel.org/pub/scm/linux/kernel/git/jkirsher/next-queue100GbE
Pulled, thanks Jeff.