aboutsummaryrefslogtreecommitdiff
path: root/include
diff options
context:
space:
mode:
authorDouglas Gilbert <dgilbert@interlog.com>2019-01-31 14:29:54 +0000
committerDouglas Gilbert <dgilbert@interlog.com>2019-01-31 14:29:54 +0000
commit04adb7f5027fb9f8b4368e4eaa561e14591bb1a7 (patch)
tree7f3af533e28c692c020eabd152b49762f340f106 /include
parenta918d1a30569c4d3f09cc87836ff19215db6d8b7 (diff)
downloadsg3_utils-04adb7f5027fb9f8b4368e4eaa561e14591bb1a7.tar.gz
linux: add nanosecond durations when SG3_UTILS_LINUX_NANO environment variable given
git-svn-id: https://svn.bingwo.ca/repos/sg3_utils/trunk@809 6180dd3e-e324-4e3e-922d-17de1ae2f315
Diffstat (limited to 'include')
-rw-r--r--include/sg_pt.h8
1 files changed, 6 insertions, 2 deletions
diff --git a/include/sg_pt.h b/include/sg_pt.h
index 00a43096..2be9cbf9 100644
--- a/include/sg_pt.h
+++ b/include/sg_pt.h
@@ -211,14 +211,18 @@ char * get_scsi_pt_transport_err_str(const struct sg_pt_base * objp,
* command. */
int get_scsi_pt_duration_ms(const struct sg_pt_base * objp);
+/* If not available return 0 otherwise return number of nanoseconds that the
+ * lower layers (and hardware) took to execute the command just completed. */
+uint64_t get_pt_duration_ns(const struct sg_pt_base * objp);
+
/* The two functions yield requested and actual data transfer lengths in
* bytes. The second argument is a pointer to the data-in length; the third
* argument is a pointer to the data-out length. The pointers may be NULL.
* The _actual_ values are related to resid (residual count from DMA) */
void get_pt_req_lengths(const struct sg_pt_base * objp, int * req_dinp,
- int * req_doutp);
+ int * req_doutp);
void get_pt_actual_lengths(const struct sg_pt_base * objp, int * act_dinp,
- int * act_doutp);
+ int * act_doutp);
/* Return true if device associated with 'objp' uses NVMe command set. To
* be useful (in modifying the type of command sent (SCSI or NVMe) then