diff options
author | David S. Miller <davem@davemloft.net> | 2009-10-28 06:38:54 -0400 |
---|---|---|
committer | David S. Miller <davem@davemloft.net> | 2009-10-28 06:38:54 -0400 |
commit | d6b9076f1b5dd22b63f0178923f420f4e0f81a8d (patch) | |
tree | 33a7054483e9d5cb6dff25126db11dc4d4ca4823 /drivers/net/igb | |
parent | 559e9c4987e90e278db347b0a2ba423e7e496fd3 (diff) |
igb: Fix warnings in igb_set_ringparam()
drivers/net/igb/igb_ethtool.c: In function ‘igb_set_ringparam’:
drivers/net/igb/igb_ethtool.c:744: warning: comparison of distinct pointer types lacks a cast
drivers/net/igb/igb_ethtool.c:748: warning: comparison of distinct pointer types lacks a cast
Casts were to u16 on the constant, but the type of new_{r,t}x_count is
u32. Cast to u32 instead.
Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'drivers/net/igb')
-rw-r--r-- | drivers/net/igb/igb_ethtool.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/drivers/net/igb/igb_ethtool.c b/drivers/net/igb/igb_ethtool.c index d24b902ba7de..90b89a81f669 100644 --- a/drivers/net/igb/igb_ethtool.c +++ b/drivers/net/igb/igb_ethtool.c | |||
@@ -741,11 +741,11 @@ static int igb_set_ringparam(struct net_device *netdev, | |||
741 | return -EINVAL; | 741 | return -EINVAL; |
742 | 742 | ||
743 | new_rx_count = min(ring->rx_pending, (u32)IGB_MAX_RXD); | 743 | new_rx_count = min(ring->rx_pending, (u32)IGB_MAX_RXD); |
744 | new_rx_count = max(new_rx_count, (u16)IGB_MIN_RXD); | 744 | new_rx_count = max(new_rx_count, (u32)IGB_MIN_RXD); |
745 | new_rx_count = ALIGN(new_rx_count, REQ_RX_DESCRIPTOR_MULTIPLE); | 745 | new_rx_count = ALIGN(new_rx_count, REQ_RX_DESCRIPTOR_MULTIPLE); |
746 | 746 | ||
747 | new_tx_count = min(ring->tx_pending, (u32)IGB_MAX_TXD); | 747 | new_tx_count = min(ring->tx_pending, (u32)IGB_MAX_TXD); |
748 | new_tx_count = max(new_tx_count, (u16)IGB_MIN_TXD); | 748 | new_tx_count = max(new_tx_count, (u32)IGB_MIN_TXD); |
749 | new_tx_count = ALIGN(new_tx_count, REQ_TX_DESCRIPTOR_MULTIPLE); | 749 | new_tx_count = ALIGN(new_tx_count, REQ_TX_DESCRIPTOR_MULTIPLE); |
750 | 750 | ||
751 | if ((new_tx_count == adapter->tx_ring_count) && | 751 | if ((new_tx_count == adapter->tx_ring_count) && |