mirror of
https://github.com/hardkernel/linux.git
synced 2026-06-11 13:27:06 +09:00
iwlwifi: pcie: rx: use rxq queue_size instead of constant
This is a little less efficient now as it's known to be a multiqueue device in this function, but a future patch will have to use a variable here anyway, so use rxq->queue_size now instead to make it clearer. Signed-off-by: Johannes Berg <johannes.berg@intel.com> Signed-off-by: Luca Coelho <luciano.coelho@intel.com>
This commit is contained in:
committed by
Luca Coelho
parent
924f838b6b
commit
5661925a9b
@@ -322,7 +322,7 @@ static void iwl_pcie_rxmq_restock(struct iwl_trans *trans,
|
||||
WARN_ON(rxb->page_dma & DMA_BIT_MASK(12));
|
||||
/* Point to Rx buffer via next RBD in circular buffer */
|
||||
iwl_pcie_restock_bd(trans, rxq, rxb);
|
||||
rxq->write = (rxq->write + 1) & MQ_RX_TABLE_MASK;
|
||||
rxq->write = (rxq->write + 1) & (rxq->queue_size - 1);
|
||||
rxq->free_count--;
|
||||
}
|
||||
spin_unlock(&rxq->lock);
|
||||
|
||||
Reference in New Issue
Block a user