summaryrefslogtreecommitdiffstats
path: root/xlators/debug/trace
diff options
context:
space:
mode:
authorRavishankar N <ravishankar@redhat.com>2017-12-25 19:19:53 +0530
committerAmar Tumballi <amarts@redhat.com>2017-12-29 17:13:25 +0000
commit9fd17c1c3c44944ea280c4c15bad0d49b298b8a9 (patch)
tree26620d09b2e7fd55aff5a302d8bd15f547352e2b /xlators/debug/trace
parentcc425b0de57d574f6e68b6ef5edfdf99cd8353af (diff)
posix: Introduce flags for validity of iatt members
v1 of the patch started off as adding new fields to iatt that can be filled up using statx but the discussions were more around introducing masks to check the validity of different fields from a RIO perspective. To that extent, I have dropped the statx call in this version and introduced a 64 bit mask for existing fields. The masks I have defined are similar with the statx() flags' masks. I have *not* changed iatt_to_stat() to use the macros IATT_TYPE_VALID, IATT_GFID_VALID etc before blindly copying from struct iatt to struct. Also fixed warnings in xlators because of atime/mtime/ctime seconds field change from uint32_t to int64_t. Change-Id: I4ac614f1e8d5c8246fc99d5bc2d2a23e7941512b Signed-off-by: Ravishankar N <ravishankar@redhat.com>
Diffstat (limited to 'xlators/debug/trace')
-rw-r--r--xlators/debug/trace/src/trace.c6
1 files changed, 3 insertions, 3 deletions
diff --git a/xlators/debug/trace/src/trace.c b/xlators/debug/trace/src/trace.c
index c85f2a7..be2f84d 100644
--- a/xlators/debug/trace/src/trace.c
+++ b/xlators/debug/trace/src/trace.c
@@ -41,9 +41,9 @@ trace_stat_to_str(struct iatt *buf, char *str, size_t len)
snprintf (str, len, "gfid=%s ino=%"PRIu64", mode=%o, "
"nlink=%"GF_PRI_NLINK", uid=%u, gid=%u, size=%"PRIu64", "
"blocks=%"PRIu64", atime=%s mtime=%s ctime=%s "
- "atime_sec=%"PRIu32", atime_nsec=%"PRIu32","
- " mtime_sec=%"PRIu32", mtime_nsec=%"PRIu32", "
- "ctime_sec=%"PRIu32", ctime_nsec=%"PRIu32"",
+ "atime_sec=%"PRId64", atime_nsec=%"PRIu32","
+ " mtime_sec=%"PRId64", mtime_nsec=%"PRIu32", "
+ "ctime_sec=%"PRId64", ctime_nsec=%"PRIu32"",
uuid_utoa (buf->ia_gfid), buf->ia_ino,
st_mode_from_ia (buf->ia_prot, buf->ia_type), buf->ia_nlink,
buf->ia_uid, buf->ia_gid, buf->ia_size, buf->ia_blocks,