diff options
author | brenohl@br.ibm.com <brenohl@br.ibm.com> | 2011-09-26 10:11:03 +0000 |
---|---|---|
committer | David S. Miller <davem@davemloft.net> | 2011-09-27 00:47:00 -0400 |
commit | 2aefcad8666e0c7c1aff51c0dacc164a1b681895 (patch) | |
tree | cbe017867792c34285bbf0e1bd9cb0687e985936 /drivers/net/ethernet/ibm/ehea/ehea.h | |
parent | dccaa9e091d2fd658634de31a1ab272072759cda (diff) | |
download | lwn-2aefcad8666e0c7c1aff51c0dacc164a1b681895.tar.gz lwn-2aefcad8666e0c7c1aff51c0dacc164a1b681895.zip |
ehea: Remove sleep at .ndo_get_stats
Currently ehea ndo_get_stats can sleep in two places, in a hcall
and in a GFP_KERNEL alloc, which is not correct.
This patch creates a delayed workqueue that grabs the information each 1
sec from the hardware, and place it into the device structure, so that,
.ndo_get_stats quickly returns the device structure statistics block.
Signed-off-by: Breno Leitao <brenohl@br.ibm.com>
Acked-by: Eric Dumazet <eric.dumazet@gmail.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'drivers/net/ethernet/ibm/ehea/ehea.h')
-rw-r--r-- | drivers/net/ethernet/ibm/ehea/ehea.h | 1 |
1 files changed, 1 insertions, 0 deletions
diff --git a/drivers/net/ethernet/ibm/ehea/ehea.h b/drivers/net/ethernet/ibm/ehea/ehea.h index 7dd5e6a0d998..0b8e6a97a980 100644 --- a/drivers/net/ethernet/ibm/ehea/ehea.h +++ b/drivers/net/ethernet/ibm/ehea/ehea.h @@ -459,6 +459,7 @@ struct ehea_port { struct ehea_mc_list *mc_list; /* Multicast MAC addresses */ struct ehea_eq *qp_eq; struct work_struct reset_task; + struct delayed_work stats_work; struct mutex port_lock; char int_aff_name[EHEA_IRQ_NAME_SIZE]; int allmulti; /* Indicates IFF_ALLMULTI state */ |