summaryrefslogtreecommitdiff
path: root/tools/perf/scripts/python/netdev-times.py
diff options
context:
space:
mode:
authorTina Ruchandani <ruchandani.tina@gmail.com>2014-10-30 17:45:22 -0700
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>2014-11-03 16:08:06 -0800
commit11dd2a979a5b81d69d6c877f94541987b19c54b5 (patch)
treed0ca050d2b2e98af65fdfd9946c99f264e54b38c /tools/perf/scripts/python/netdev-times.py
parentb7c12ca4df9dc69e4d8dd4468d3b5b780de1ae36 (diff)
Staging: lustre: lnet: Improve 'incarnation' stamp
ksock_net_t uses a __u64 quantity as an 'incarnation' timestamp. This is also passed on in hello messages and used to detect if a reboot has occurred. This 'incarnation' is obtained using do_gettimeofday.It is only used in equality checks, so the absolute value does not matter. This patch replaces do_gettimeofday with ktime_get_ns for the following reasons: 1. ktime_get_ns returns a __u64 which is safer than 'struct timeval' which will overflow on 32-bit systems in year 2038 and beyond. 2. Reduced compute: ktime_get_ns is faster than the multiply/add combination used in this function Signed-off-by: Tina Ruchandani <ruchandani.tina@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Diffstat (limited to 'tools/perf/scripts/python/netdev-times.py')
0 files changed, 0 insertions, 0 deletions