aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/infiniband/hw/qib/qib_fs.c
diff options
context:
space:
mode:
authorMike Marciniszyn <mike.marciniszyn@intel.com>2014-03-07 08:40:49 -0500
committerRoland Dreier <roland@purestorage.com>2014-03-17 16:16:51 -0700
commit1ed88dd7d0b361e677b2690f573e5c274bb25c87 (patch)
treed78f5aa8f9983b92b7db9f876817199b136c3a2b /drivers/infiniband/hw/qib/qib_fs.c
parentIB/qib: Fix debugfs ordering issue with multiple HCAs (diff)
downloadlinux-dev-1ed88dd7d0b361e677b2690f573e5c274bb25c87.tar.xz
linux-dev-1ed88dd7d0b361e677b2690f573e5c274bb25c87.zip
IB/qib: Add percpu counter replacing qib_devdata int_counter
This patch replaces the dd->int_counter with a percpu counter. The maintanance of qib_stats.sps_ints and int_counter are combined into the new counter. There are two new functions added to read the counter: - qib_int_counter (for a particular qib_devdata) - qib_sps_ints (for all HCAs) A z_int_counter is added to allow the interrupt detection logic to determine if interrupts have occured since z_int_counter was "reset". Reviewed-by: Dennis Dalessandro <dennis.dalessandro@intel.com> Signed-off-by: Mike Marciniszyn <mike.marciniszyn@intel.com> Signed-off-by: Roland Dreier <roland@purestorage.com>
Diffstat (limited to 'drivers/infiniband/hw/qib/qib_fs.c')
-rw-r--r--drivers/infiniband/hw/qib/qib_fs.c1
1 files changed, 1 insertions, 0 deletions
diff --git a/drivers/infiniband/hw/qib/qib_fs.c b/drivers/infiniband/hw/qib/qib_fs.c
index c61e2a92b3c1..cab610ccd50e 100644
--- a/drivers/infiniband/hw/qib/qib_fs.c
+++ b/drivers/infiniband/hw/qib/qib_fs.c
@@ -105,6 +105,7 @@ static int create_file(const char *name, umode_t mode,
static ssize_t driver_stats_read(struct file *file, char __user *buf,
size_t count, loff_t *ppos)
{
+ qib_stats.sps_ints = qib_sps_ints();
return simple_read_from_buffer(buf, count, ppos, &qib_stats,
sizeof qib_stats);
}