aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/net/e1000/e1000_ethtool.c
diff options
context:
space:
mode:
authorMilind Arun Choudhary <milindchoudhary@gmail.com>2007-04-27 16:55:29 -0400
committerJeff Garzik <jeff@garzik.org>2007-04-28 11:01:07 -0400
commit9099cfb9170f352f08207dfa099717a904cff71f (patch)
tree6b2c08422851d5e36c866fc4397ce0bc43a4319f /drivers/net/e1000/e1000_ethtool.c
parentabf17ffda7b7b6c83a29d7ccea91d46065c6ca3e (diff)
e1000: ROUND_UP macro cleanup in drivers/net/e1000
E1000_ROUNDUP macro cleanup, use ALIGN Signed-off-by: Milind Arun Choudhary <milindchoudhary@gmail.com> Signed-off-by: Auke Kok <auke-jan.h.kok@intel.com> Signed-off-by: Jeff Garzik <jeff@garzik.org>
Diffstat (limited to 'drivers/net/e1000/e1000_ethtool.c')
-rw-r--r--drivers/net/e1000/e1000_ethtool.c6
1 files changed, 3 insertions, 3 deletions
diff --git a/drivers/net/e1000/e1000_ethtool.c b/drivers/net/e1000/e1000_ethtool.c
index 2881da1c6fe3..bb08375b5f13 100644
--- a/drivers/net/e1000/e1000_ethtool.c
+++ b/drivers/net/e1000/e1000_ethtool.c
@@ -683,12 +683,12 @@ e1000_set_ringparam(struct net_device *netdev,
683 rxdr->count = max(ring->rx_pending,(uint32_t)E1000_MIN_RXD); 683 rxdr->count = max(ring->rx_pending,(uint32_t)E1000_MIN_RXD);
684 rxdr->count = min(rxdr->count,(uint32_t)(mac_type < e1000_82544 ? 684 rxdr->count = min(rxdr->count,(uint32_t)(mac_type < e1000_82544 ?
685 E1000_MAX_RXD : E1000_MAX_82544_RXD)); 685 E1000_MAX_RXD : E1000_MAX_82544_RXD));
686 E1000_ROUNDUP(rxdr->count, REQ_RX_DESCRIPTOR_MULTIPLE); 686 rxdr->count = ALIGN(rxdr->count, REQ_RX_DESCRIPTOR_MULTIPLE);
687 687
688 txdr->count = max(ring->tx_pending,(uint32_t)E1000_MIN_TXD); 688 txdr->count = max(ring->tx_pending,(uint32_t)E1000_MIN_TXD);
689 txdr->count = min(txdr->count,(uint32_t)(mac_type < e1000_82544 ? 689 txdr->count = min(txdr->count,(uint32_t)(mac_type < e1000_82544 ?
690 E1000_MAX_TXD : E1000_MAX_82544_TXD)); 690 E1000_MAX_TXD : E1000_MAX_82544_TXD));
691 E1000_ROUNDUP(txdr->count, REQ_TX_DESCRIPTOR_MULTIPLE); 691 txdr->count = ALIGN(txdr->count, REQ_TX_DESCRIPTOR_MULTIPLE);
692 692
693 for (i = 0; i < adapter->num_tx_queues; i++) 693 for (i = 0; i < adapter->num_tx_queues; i++)
694 txdr[i].count = txdr->count; 694 txdr[i].count = txdr->count;
@@ -1065,7 +1065,7 @@ e1000_setup_desc_rings(struct e1000_adapter *adapter)
1065 } 1065 }
1066 1066
1067 txdr->size = txdr->count * sizeof(struct e1000_tx_desc); 1067 txdr->size = txdr->count * sizeof(struct e1000_tx_desc);
1068 E1000_ROUNDUP(txdr->size, 4096); 1068 txdr->size = ALIGN(txdr->size, 4096);
1069 if (!(txdr->desc = pci_alloc_consistent(pdev, txdr->size, 1069 if (!(txdr->desc = pci_alloc_consistent(pdev, txdr->size,
1070 &txdr->dma))) { 1070 &txdr->dma))) {
1071 ret_val = 2; 1071 ret_val = 2;