nvmecmd.opcode=OP_BAD_BLOCK;
nvmecmd.cdw10=DW10_BAD_BLOCK;
nvmecmd.cdw12=DW12_BAD_BLOCK;
- nvmecmd.addr =(__u64) data;
+ nvmecmd.addr = (__u64)(uintptr_t)data;
nvmecmd.data_len = 0x1;
result = nvme_submit_admin_passthru(fd,&nvmecmd);
if(!result) {
total_size = log_size;
if (offset >= total_size) {
- fprintf(stderr, "%s: INFO : WDC : Offset 0x%llx exceeds total size 0x%llx, no data retrieved\n",
- __func__, offset, total_size);
+ fprintf(stderr, "%s: INFO : WDC : Offset 0x%"PRIx64" exceeds total size 0x%"PRIx64", no data retrieved\n",
+ __func__, (uint64_t)offset, (uint64_t)total_size);
goto out;
}
log_size = min(total_size, file_size);
if (verbose)
- fprintf(stderr, "%s: INFO : WDC : Offset 0x%llx, file size 0x%llx, total size 0x%llx, log size 0x%llx\n",
- __func__, offset, file_size, total_size, log_size);
+ fprintf(stderr, "%s: INFO : WDC : Offset 0x%"PRIx64", file size 0x%"PRIx64", total size 0x%"PRIx64", log size 0x%"PRIx64"\n",
+ __func__, (uint64_t)offset, (uint64_t)file_size, (uint64_t)total_size, (uint64_t)log_size);
curr_data_offset = offset;