summaryrefslogtreecommitdiffstats
path: root/drivers/infiniband/hw/hfi1/mad.c
diff options
context:
space:
mode:
authorJakub Pawlak2016-07-02 01:01:22 +0200
committerDoug Ledford2016-08-02 18:00:54 +0200
commit2b719046743d35b452f17956a5f19e1aa0fc3e8a (patch)
treef02b94e67f66ebcc5c0c6380d8fcfe57f9538c8d /drivers/infiniband/hw/hfi1/mad.c
parentIB/hfi1: Add VL XmitDiscards counters to the opapmaquery (diff)
downloadkernel-qcow2-linux-2b719046743d35b452f17956a5f19e1aa0fc3e8a.tar.gz
kernel-qcow2-linux-2b719046743d35b452f17956a5f19e1aa0fc3e8a.tar.xz
kernel-qcow2-linux-2b719046743d35b452f17956a5f19e1aa0fc3e8a.zip
IB/hfi1: Add counter to track unsupported packets drop
Add sw counter to track dropped unsupported packets. Report unsupported packets drop as the RcvError. Reviewed-by: Dennis Dalessandro <dennis.dalessandro@intel.com> Signed-off-by: Jakub Pawlak <jakub.pawlak@intel.com> Signed-off-by: Dennis Dalessandro <dennis.dalessandro@intel.com> Signed-off-by: Doug Ledford <dledford@redhat.com>
Diffstat (limited to 'drivers/infiniband/hw/hfi1/mad.c')
-rw-r--r--drivers/infiniband/hw/hfi1/mad.c3
1 files changed, 2 insertions, 1 deletions
diff --git a/drivers/infiniband/hw/hfi1/mad.c b/drivers/infiniband/hw/hfi1/mad.c
index 349a138cd2dc..962bb11074d9 100644
--- a/drivers/infiniband/hw/hfi1/mad.c
+++ b/drivers/infiniband/hw/hfi1/mad.c
@@ -2874,7 +2874,8 @@ static int pma_get_opa_porterrors(struct opa_pma_mad *pmp,
tmp = read_dev_cntr(dd, C_DC_UNC_ERR, CNTR_INVALID_VL);
rsp->uncorrectable_errors = tmp < 0x100 ? (tmp & 0xff) : 0xff;
-
+ rsp->port_rcv_errors =
+ cpu_to_be64(read_dev_cntr(dd, C_DC_RCV_ERR, CNTR_INVALID_VL));
vlinfo = &rsp->vls[0];
vfi = 0;
vl_select_mask = be32_to_cpu(req->vl_select_mask);