snprintf(str, len, " -o %s", mop->mo_mkfsopts);
if (mop->mo_device_kb)
snprintf(str, len, " -o quota=%llu",
- mop->mo_device_kb * 1024);
+ (unsigned long long)mop->mo_device_kb * 1024);
return str;
}
"component_start=%llu "
"component_end=%llu",
loa->loa_comp_id,
- loa->loa_comp_start,
- loa->loa_comp_end);
+ (unsigned long long)loa->loa_comp_start,
+ (unsigned long long)loa->loa_comp_end);
printf("\n");
continue;
}
"component_start=%llu "
"component_end=%llu",
__le32_to_cpu(ol->ol_comp_id),
+ (unsigned long long)
__le64_to_cpu(ol->ol_comp_start),
+ (unsigned long long)
__le64_to_cpu(ol->ol_comp_end));
}
if (size >= sizeof(struct filter_fid))
sz = larr->arr_hai.hai_len - sizeof(larr->arr_hai);
printf("lrh=[type=%X len=%d idx=%d] fid="DFID
- " compound/cookie=%#jx/%#jx"
- " status=%s action=%s archive#=%d flags=%#jx"
- " create=%ju change=%ju"
- " extent=%#jx-%#jx gid=%#jx datalen=%d"
+ " compound/cookie=%#llx/%#llx"
+ " status=%s action=%s archive#=%d flags=%#llx"
+ " create=%llu change=%llu"
+ " extent=%#llx-%#llx gid=%#llx datalen=%d"
" data=[%s]\n",
larr->arr_hdr.lrh_type,
larr->arr_hdr.lrh_len, larr->arr_hdr.lrh_index,
PFID(&larr->arr_hai.hai_fid),
- (uintmax_t)larr->arr_compound_id,
- (uintmax_t)larr->arr_hai.hai_cookie,
+ (unsigned long long)larr->arr_compound_id,
+ (unsigned long long)larr->arr_hai.hai_cookie,
agent_req_status2name(larr->arr_status),
hsm_copytool_action2name(larr->arr_hai.hai_action),
larr->arr_archive_id,
- (uintmax_t)larr->arr_flags,
- (uintmax_t)larr->arr_req_create,
- (uintmax_t)larr->arr_req_change,
- (uintmax_t)larr->arr_hai.hai_extent.offset,
- (uintmax_t)larr->arr_hai.hai_extent.length,
- (uintmax_t)larr->arr_hai.hai_gid, sz,
+ (unsigned long long)larr->arr_flags,
+ (unsigned long long)larr->arr_req_create,
+ (unsigned long long)larr->arr_req_change,
+ (unsigned long long)larr->arr_hai.hai_extent.offset,
+ (unsigned long long)larr->arr_hai.hai_extent.length,
+ (unsigned long long)larr->arr_hai.hai_gid, sz,
hai_dump_data_field(&larr->arr_hai, buf, sizeof(buf)));
}
printf("changelog record id:0x%x index:%llu cr_flags:0x%x "
"cr_type:%s(0x%x) date:'%02d:%02d:%02d.%09d %04d.%02d.%02d' "
"target:"DFID, __le32_to_cpu(rec->cr_hdr.lrh_id),
- __le64_to_cpu(rec->cr.cr_index),
+ (unsigned long long)__le64_to_cpu(rec->cr.cr_index),
__le32_to_cpu(rec->cr.cr_flags),
changelog_type2str(__le32_to_cpu(rec->cr.cr_type)),
__le32_to_cpu(rec->cr.cr_type),
changelog_rec_extra_flags(&rec->cr);
printf(" cr_extra_flags:0x%llx",
- __le64_to_cpu(ef->cr_extra_flags));
+ (unsigned long long)__le64_to_cpu(ef->cr_extra_flags));
if (ef->cr_extra_flags & CLFE_UIDGID) {
struct changelog_ext_uidgid *uidgid =
printf(" feature_compat: %#x\n", lsd.lsd_feature_compat);
printf(" feature_incompat: %#x\n", lsd.lsd_feature_incompat);
printf(" feature_rocompat: %#x\n", lsd.lsd_feature_rocompat);
- printf(" last_transaction: %llu\n", lsd.lsd_last_transno);
+ printf(" last_transaction: %llu\n",
+ (unsigned long long)lsd.lsd_last_transno);
printf(" target_index: %u\n", lsd.lsd_osd_index);
- printf(" mount_count: %llu\n", lsd.lsd_mount_count);
+ printf(" mount_count: %llu\n",
+ (unsigned long long)lsd.lsd_mount_count);
/* read client information */
if (opt_client) {
printf("\n %.40s:\n", lcd.lcd_uuid);
printf(" generation: %u\n", lcd.lcd_generation);
printf(" last_transaction: %llu\n",
- lcd.lcd_last_transno);
- printf(" last_xid: %llu\n", lcd.lcd_last_xid);
+ (unsigned long long)lcd.lcd_last_transno);
+ printf(" last_xid: %llu\n",
+ (unsigned long long)lcd.lcd_last_xid);
printf(" last_result: %u\n", lcd.lcd_last_result);
printf(" last_data: %u\n", lcd.lcd_last_data);
lcd.lcd_last_close_data =
__le32_to_cpu(lcd.lcd_last_close_data);
printf(" last_close_transation: %llu\n",
- lcd.lcd_last_close_transno);
+ (unsigned long long)lcd.lcd_last_close_transno);
printf(" last_close_xid: %llu\n",
- lcd.lcd_last_close_xid);
+ (unsigned long long)lcd.lcd_last_close_xid);
printf(" last_close_result: %u\n",
lcd.lcd_last_close_result);
printf(" last_close_data: %u\n",
printf(" %lld:\n", slot);
printf(" client_generation: %u\n",
lrd.lrd_client_gen);
- printf(" last_transaction: %llu\n", lrd.lrd_transno);
- printf(" last_xid: %llu\n", lrd.lrd_xid);
+ printf(" last_transaction: %lluu\n",
+ (unsigned long long)lrd.lrd_transno);
+ printf(" last_xid: %llu\n",
+ (unsigned long long)lrd.lrd_xid);
printf(" last_result: %u\n", lrd.lrd_result);
- printf(" last_data: %llu\n\n", lrd.lrd_data);
+ printf(" last_data: %llu\n\n",
+ (unsigned long long)lrd.lrd_data);
}
}
"-o lustre:ctime=%llu "
"-o lustre:mtime=%llu ",
PRSH(si, st), PZFS(st), fsname,
- SNAPSHOT_MAGIC, xtime, xtime);
+ SNAPSHOT_MAGIC,
+ (unsigned long long)xtime,
+ (unsigned long long)xtime);
if (len <= 0)
exit(-EOVERFLOW);
PRSH(si, st), PIMPORT(st), PZFS(st),
PSSNAME(si, st), PSS_NEW(si, st),
PZFS(st), si->si_comment,
- PSS_NEW(si, st), PZFS(st), xtime,
+ PSS_NEW(si, st), PZFS(st),
+ (unsigned long long)xtime,
PSS_NEW(si, st));
else if (si->si_new_ssname)
snprintf(cmd, sizeof(cmd) - 1,
" set lustre:mtime=%llu "DSSNAME"'",
PRSH(si, st), PIMPORT(st), PZFS(st),
PSSNAME(si, st), PSS_NEW(si, st),
- PZFS(st), xtime, PSS_NEW(si, st));
+ PZFS(st), (unsigned long long)xtime,
+ PSS_NEW(si, st));
else if (si->si_comment)
snprintf(cmd, sizeof(cmd) - 1,
DRSH" '"DIMPORT"; "DZFS
" set lustre:mtime=%llu "DSSNAME"'",
PRSH(si, st), PIMPORT(st), PZFS(st),
si->si_comment, PSSNAME(si, st),
- PZFS(st), xtime, PSSNAME(si, st));
+ PZFS(st), (unsigned long long)xtime,
+ PSSNAME(si, st));
else
exit(-EINVAL);
strlen("lustre:ctime")) == 0) {
ptr = snapshot_first_skip_blank(buf);
if (ptr) {
- sscanf(ptr, "%llu", &xtime);
+ xtime = (__u64)strtoull(ptr, NULL, 10);
printf("create_time: %s",
ctime((time_t *)&xtime));
}
strlen("lustre:mtime")) == 0) {
ptr = snapshot_first_skip_blank(buf);
if (ptr) {
- sscanf(ptr, "%llu", &xtime);
+ xtime = (__u64)strtoull(ptr, NULL, 10);
printf("modify_time: %s",
ctime((time_t *)&xtime));
}
printf("%s_osts_%s: %d\n", name,
lfsck_status2name(j), query.lu_osts_count[i][j]);
- printf("%s_repaired: %llu\n", name, query.lu_repaired[i]);
+ printf("%s_repaired: %llu\n", name,
+ (unsigned long long)query.lu_repaired[i]);
}
return 0;