summaryrefslogtreecommitdiffstats
path: root/drivers/net/enic/vnic_intr.c
diff options
context:
space:
mode:
authorScott Feldman <scofeldm@cisco.com>2009-12-23 13:27:54 +0000
committerDavid S. Miller <davem@davemloft.net>2009-12-23 21:03:41 -0800
commit7c8445991172cc17eaca9f7de0a300c02caaa49d (patch)
tree0518a514d0d3e5af0d6442a2ef72aa10bbce58ae /drivers/net/enic/vnic_intr.c
parentbd2496229e702b2eb50eab5589858a3cdb7847b2 (diff)
downloadblackbird-op-linux-7c8445991172cc17eaca9f7de0a300c02caaa49d.tar.gz
blackbird-op-linux-7c8445991172cc17eaca9f7de0a300c02caaa49d.zip
enic: feature add: add ethtool -c/C support
Only rx_usec and tx_usec options for ethtool -C are settable as those are the only settings that make sense to HW. Adds driver reporting of intr coalescing timer value in usec units rather than HW units. Signed-off-by: Vasanthy Kolluri <vkolluri@cisco.com> Signed-off-by: Scott Feldman <scofeldm@cisco.com> Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'drivers/net/enic/vnic_intr.c')
-rw-r--r--drivers/net/enic/vnic_intr.c8
1 files changed, 7 insertions, 1 deletions
diff --git a/drivers/net/enic/vnic_intr.c b/drivers/net/enic/vnic_intr.c
index 1f8786d7195e..3934309a9498 100644
--- a/drivers/net/enic/vnic_intr.c
+++ b/drivers/net/enic/vnic_intr.c
@@ -50,12 +50,18 @@ int vnic_intr_alloc(struct vnic_dev *vdev, struct vnic_intr *intr,
void vnic_intr_init(struct vnic_intr *intr, unsigned int coalescing_timer,
unsigned int coalescing_type, unsigned int mask_on_assertion)
{
- iowrite32(coalescing_timer, &intr->ctrl->coalescing_timer);
+ vnic_intr_coalescing_timer_set(intr, coalescing_timer);
iowrite32(coalescing_type, &intr->ctrl->coalescing_type);
iowrite32(mask_on_assertion, &intr->ctrl->mask_on_assertion);
iowrite32(0, &intr->ctrl->int_credits);
}
+void vnic_intr_coalescing_timer_set(struct vnic_intr *intr,
+ unsigned int coalescing_timer)
+{
+ iowrite32(coalescing_timer, &intr->ctrl->coalescing_timer);
+}
+
void vnic_intr_clean(struct vnic_intr *intr)
{
iowrite32(0, &intr->ctrl->int_credits);
OpenPOWER on IntegriCloud