diff --git a/include/sigar.h b/include/sigar.h index ddc922ae..f6d6e90d 100644 --- a/include/sigar.h +++ b/include/sigar.h @@ -442,6 +442,8 @@ typedef struct { sigar_uint64_t rtime; sigar_uint64_t wtime; sigar_uint64_t time; + sigar_uint64_t snaptime; + double service_time; } sigar_disk_usage_t; /* XXX for sigar_file_system_usage_t compat */ @@ -450,6 +452,7 @@ typedef struct { #define disk_write_bytes disk.write_bytes #define disk_read_bytes disk.read_bytes #define disk_queue disk.queue +#define disk_service_time disk.service_time typedef struct { sigar_disk_usage_t disk; diff --git a/include/sigar_private.h b/include/sigar_private.h index 462cefd6..64841262 100644 --- a/include/sigar_private.h +++ b/include/sigar_private.h @@ -312,7 +312,9 @@ int sigar_group_name_get(sigar_t *sigar, int gid, char *buf, int buflen); #define SIGAR_DISK_STATS_INIT(disk) \ (disk)->reads = (disk)->writes = \ (disk)->read_bytes = (disk)->write_bytes = \ - (disk)->queue = (disk)->time = SIGAR_FIELD_NOTIMPL; + (disk)->queue = (disk)->time = \ + (disk)->service_time = SIGAR_FIELD_NOTIMPL; \ + (disk)->snaptime = 0 #define SIGAR_DISK_STATS_NOTIMPL(fsusage) \ SIGAR_DISK_STATS_INIT(&fsusage->disk)