* [net-next-2.6 PATCH] ixgbevf: Removed unneeded HW struct members
@ 2010-09-08 7:36 Jeff Kirsher
2010-09-09 4:42 ` David Miller
2010-09-09 8:48 ` [PATCH net-next-2.6] ixgbevf: remove private net_device_stats Eric Dumazet
0 siblings, 2 replies; 3+ messages in thread
From: Jeff Kirsher @ 2010-09-08 7:36 UTC (permalink / raw)
To: davem; +Cc: netdev, gospo, bphilips, Greg Rose, Jeff Kirsher
From: Greg Rose <gregory.v.rose@intel.com>
The VF has no flash and can only do memory mapped I/O.
Signed-off-by: Greg Rose <gregory.v.rose@intel.com>
Signed-off-by: Jeff Kirsher <jeffrey.t.kirsher@intel.com>
---
drivers/net/ixgbevf/vf.h | 2 --
1 files changed, 0 insertions(+), 2 deletions(-)
diff --git a/drivers/net/ixgbevf/vf.h b/drivers/net/ixgbevf/vf.h
index 94b750b..61f9dc8 100644
--- a/drivers/net/ixgbevf/vf.h
+++ b/drivers/net/ixgbevf/vf.h
@@ -124,8 +124,6 @@ struct ixgbe_hw {
void *back;
u8 __iomem *hw_addr;
- u8 *flash_address;
- unsigned long io_base;
struct ixgbe_mac_info mac;
struct ixgbe_mbx_info mbx;
^ permalink raw reply related [flat|nested] 3+ messages in thread
* Re: [net-next-2.6 PATCH] ixgbevf: Removed unneeded HW struct members
2010-09-08 7:36 [net-next-2.6 PATCH] ixgbevf: Removed unneeded HW struct members Jeff Kirsher
@ 2010-09-09 4:42 ` David Miller
2010-09-09 8:48 ` [PATCH net-next-2.6] ixgbevf: remove private net_device_stats Eric Dumazet
1 sibling, 0 replies; 3+ messages in thread
From: David Miller @ 2010-09-09 4:42 UTC (permalink / raw)
To: jeffrey.t.kirsher; +Cc: netdev, gospo, bphilips, gregory.v.rose
From: Jeff Kirsher <jeffrey.t.kirsher@intel.com>
Date: Wed, 08 Sep 2010 00:36:04 -0700
> From: Greg Rose <gregory.v.rose@intel.com>
>
> The VF has no flash and can only do memory mapped I/O.
>
> Signed-off-by: Greg Rose <gregory.v.rose@intel.com>
> Signed-off-by: Jeff Kirsher <jeffrey.t.kirsher@intel.com>
Applied.
^ permalink raw reply [flat|nested] 3+ messages in thread
* [PATCH net-next-2.6] ixgbevf: remove private net_device_stats
2010-09-08 7:36 [net-next-2.6 PATCH] ixgbevf: Removed unneeded HW struct members Jeff Kirsher
2010-09-09 4:42 ` David Miller
@ 2010-09-09 8:48 ` Eric Dumazet
1 sibling, 0 replies; 3+ messages in thread
From: Eric Dumazet @ 2010-09-09 8:48 UTC (permalink / raw)
To: Jeff Kirsher, David Miller; +Cc: netdev
Use the net_device provided net_device_stats structure.
Remove ixgbevf_get_stats() now its not needed.
Signed-off-by: Eric Dumazet <eric.dumazet@gmail.com>
---
drivers/net/ixgbevf/ixgbevf.h | 1 -
drivers/net/ixgbevf/ixgbevf_main.c | 26 +++++---------------------
2 files changed, 5 insertions(+), 22 deletions(-)
diff --git a/drivers/net/ixgbevf/ixgbevf.h b/drivers/net/ixgbevf/ixgbevf.h
index f7015ef..da4033c 100644
--- a/drivers/net/ixgbevf/ixgbevf.h
+++ b/drivers/net/ixgbevf/ixgbevf.h
@@ -243,7 +243,6 @@ struct ixgbevf_adapter {
/* OS defined structs */
struct net_device *netdev;
struct pci_dev *pdev;
- struct net_device_stats net_stats;
/* structs defined in ixgbe_vf.h */
struct ixgbe_hw hw;
diff --git a/drivers/net/ixgbevf/ixgbevf_main.c b/drivers/net/ixgbevf/ixgbevf_main.c
index bdbd26c..3eda1bd 100644
--- a/drivers/net/ixgbevf/ixgbevf_main.c
+++ b/drivers/net/ixgbevf/ixgbevf_main.c
@@ -308,8 +308,8 @@ static bool ixgbevf_clean_tx_irq(struct ixgbevf_adapter *adapter,
tx_ring->total_bytes += total_bytes;
tx_ring->total_packets += total_packets;
- adapter->net_stats.tx_bytes += total_bytes;
- adapter->net_stats.tx_packets += total_packets;
+ netdev->stats.tx_bytes += total_bytes;
+ netdev->stats.tx_packets += total_packets;
return (count < tx_ring->work_limit);
}
@@ -639,8 +639,8 @@ next_desc:
rx_ring->total_packets += total_rx_packets;
rx_ring->total_bytes += total_rx_bytes;
- adapter->net_stats.rx_bytes += total_rx_bytes;
- adapter->net_stats.rx_packets += total_rx_packets;
+ adapter->netdev->stats.rx_bytes += total_rx_bytes;
+ adapter->netdev->stats.rx_packets += total_rx_packets;
return cleaned;
}
@@ -2297,7 +2297,7 @@ void ixgbevf_update_stats(struct ixgbevf_adapter *adapter)
adapter->stats.vfmprc);
/* Fill out the OS statistics structure */
- adapter->net_stats.multicast = adapter->stats.vfmprc -
+ adapter->netdev->stats.multicast = adapter->stats.vfmprc -
adapter->stats.base_vfmprc;
}
@@ -3181,21 +3181,6 @@ static int ixgbevf_xmit_frame(struct sk_buff *skb, struct net_device *netdev)
}
/**
- * ixgbevf_get_stats - Get System Network Statistics
- * @netdev: network interface device structure
- *
- * Returns the address of the device statistics structure.
- * The statistics are actually updated from the timer callback.
- **/
-static struct net_device_stats *ixgbevf_get_stats(struct net_device *netdev)
-{
- struct ixgbevf_adapter *adapter = netdev_priv(netdev);
-
- /* only return the current stats */
- return &adapter->net_stats;
-}
-
-/**
* ixgbevf_set_mac - Change the Ethernet Address of the NIC
* @netdev: network interface device structure
* @p: pointer to an address structure
@@ -3272,7 +3257,6 @@ static const struct net_device_ops ixgbe_netdev_ops = {
.ndo_open = &ixgbevf_open,
.ndo_stop = &ixgbevf_close,
.ndo_start_xmit = &ixgbevf_xmit_frame,
- .ndo_get_stats = &ixgbevf_get_stats,
.ndo_set_rx_mode = &ixgbevf_set_rx_mode,
.ndo_set_multicast_list = &ixgbevf_set_rx_mode,
.ndo_validate_addr = eth_validate_addr,
^ permalink raw reply related [flat|nested] 3+ messages in thread
end of thread, other threads:[~2010-09-09 8:48 UTC | newest]
Thread overview: 3+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2010-09-08 7:36 [net-next-2.6 PATCH] ixgbevf: Removed unneeded HW struct members Jeff Kirsher
2010-09-09 4:42 ` David Miller
2010-09-09 8:48 ` [PATCH net-next-2.6] ixgbevf: remove private net_device_stats Eric Dumazet
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).