fm10k: fix queue disabling
In Rx and Tx queue_disable functions, the index of queue should be qnum other than i which is the iteration of time expiration. Signed-off-by: Wang Xiao W <xiao.w.wang@intel.com> Acked-by: Jing Chen <jing.d.chen@intel.com>
This commit is contained in:
parent
4a5d5d5422
commit
aa86864085
@ -182,7 +182,7 @@ rx_queue_disable(struct fm10k_hw *hw, uint16_t qnum)
|
||||
/* Wait 100us at most */
|
||||
for (i = 0; i < FM10K_QUEUE_DISABLE_TIMEOUT; i++) {
|
||||
rte_delay_us(1);
|
||||
reg = FM10K_READ_REG(hw, FM10K_RXQCTL(i));
|
||||
reg = FM10K_READ_REG(hw, FM10K_RXQCTL(qnum));
|
||||
if (!(reg & FM10K_RXQCTL_ENABLE))
|
||||
break;
|
||||
}
|
||||
@ -271,7 +271,7 @@ tx_queue_disable(struct fm10k_hw *hw, uint16_t qnum)
|
||||
/* Wait 100us at most */
|
||||
for (i = 0; i < FM10K_QUEUE_DISABLE_TIMEOUT; i++) {
|
||||
rte_delay_us(1);
|
||||
reg = FM10K_READ_REG(hw, FM10K_TXDCTL(i));
|
||||
reg = FM10K_READ_REG(hw, FM10K_TXDCTL(qnum));
|
||||
if (!(reg & FM10K_TXDCTL_ENABLE))
|
||||
break;
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user