diff options
author | Daniel Baumann <daniel.baumann@progress-linux.org> | 2022-01-26 18:05:15 +0000 |
---|---|---|
committer | Daniel Baumann <daniel.baumann@progress-linux.org> | 2022-01-26 18:05:42 +0000 |
commit | 112b5b91647c3dea45cc1c9bc364df526c8012f1 (patch) | |
tree | 450af925135ec664c4310a1eb28b69481094ee2a /collectors/proc.plugin/sys_class_infiniband.c | |
parent | Releasing debian version 1.32.1-2. (diff) | |
download | netdata-112b5b91647c3dea45cc1c9bc364df526c8012f1.tar.xz netdata-112b5b91647c3dea45cc1c9bc364df526c8012f1.zip |
Merging upstream version 1.33.0.
Signed-off-by: Daniel Baumann <daniel.baumann@progress-linux.org>
Diffstat (limited to 'collectors/proc.plugin/sys_class_infiniband.c')
-rw-r--r-- | collectors/proc.plugin/sys_class_infiniband.c | 10 |
1 files changed, 7 insertions, 3 deletions
diff --git a/collectors/proc.plugin/sys_class_infiniband.c b/collectors/proc.plugin/sys_class_infiniband.c index 1a75ce13f..7e63bcbb4 100644 --- a/collectors/proc.plugin/sys_class_infiniband.c +++ b/collectors/proc.plugin/sys_class_infiniband.c @@ -481,8 +481,11 @@ int do_sys_class_infiniband(int update_every, usec_t dt) if (!p->discovered) info( - "Infiniband card %s port %s at speed %lu width %lu", dev_dent->d_name, port_dent->d_name, - p->speed, p->width); + "Infiniband card %s port %s at speed %" PRIu64 " width %" PRIu64 "", + dev_dent->d_name, + port_dent->d_name, + p->speed, + p->width); p->discovered = 1; } @@ -537,7 +540,8 @@ int do_sys_class_infiniband(int update_every, usec_t dt) rrdset_flag_set(port->st_bytes, RRDSET_FLAG_DETAIL); // On this chart, we want to have a KB/s so the dashboard will autoscale it // The reported values are also per-lane, so we must multiply it by the width - FOREACH_COUNTER_BYTES(GEN_RRD_DIM_ADD_CUSTOM, port, 8 * port->width, 1024, RRD_ALGORITHM_INCREMENTAL) + // x4 lanes multiplier as per Documentation/ABI/stable/sysfs-class-infiniband + FOREACH_COUNTER_BYTES(GEN_RRD_DIM_ADD_CUSTOM, port, 4 * 8 * port->width, 1024, RRD_ALGORITHM_INCREMENTAL) port->stv_speed = rrdsetvar_custom_chart_variable_create(port->st_bytes, "link_speed"); } else |