struct mic_copy_desc *copy)
{
if (copy->out_len != sum_iovec_len(copy)) {
- mpsslog("%s %s %d BUG copy->out_len 0x%x len 0x%x\n",
+ mpsslog("%s %s %d BUG copy->out_len 0x%x len 0x%zx\n",
mic->name, __func__, __LINE__,
- copy->out_len, sum_iovec_len(copy));
+ copy->out_len, sum_iovec_len(copy));
assert(copy->out_len == sum_iovec_len(copy));
}
}
int i;
for (i = 0; i < copy->iovcnt; i++)
- mpsslog("%s %s %d copy->iov[%d] addr %p len 0x%lx\n",
+ mpsslog("%s %s %d copy->iov[%d] addr %p len 0x%zx\n",
mic->name, s, line, i,
copy->iov[i].iov_base, copy->iov[i].iov_len);
}
disp_iovec(mic, ©, __func__, __LINE__);
mpsslog("%s %s %d read failed %s ", mic->name,
__func__, __LINE__, strerror(errno));
- mpsslog("cnt %d sum %d\n",
+ mpsslog("cnt %d sum %zd\n",
copy.iovcnt, sum_iovec_len(©));
}
}
if (len != sum_iovec_len(©)) {
mpsslog("Tun write failed %s ",
strerror(errno));
- mpsslog("len 0x%x ", len);
- mpsslog("read_len 0x%x\n",
+ mpsslog("len 0x%zx ", len);
+ mpsslog("read_len 0x%zx\n",
sum_iovec_len(©));
} else {
#ifdef DEBUG
mpsslog("%s %s %d read failed %s ",
mic->name, __func__, __LINE__,
strerror(errno));
- mpsslog("cnt %d sum %d\n",
+ mpsslog("cnt %d sum %zd\n",
copy.iovcnt, sum_iovec_len(©));
}
}
if (len != sum_iovec_len(©)) {
mpsslog("Tun write failed %s ",
strerror(errno));
- mpsslog("len 0x%x ", len);
- mpsslog("read_len 0x%x\n",
+ mpsslog("len 0x%zx ", len);
+ mpsslog("read_len 0x%zx\n",
sum_iovec_len(©));
} else {
#ifdef DEBUG
return false;
mic->mic_virtblk.backend_file = malloc(strlen(evv) + 1);
if (mic->mic_virtblk.backend_file == NULL) {
- mpsslog("can't allocate memory\n", mic->name, mic->id);
+ mpsslog("%s %d can't allocate memory\n", mic->name, mic->id);
return false;
}
strcpy(mic->mic_virtblk.backend_file, evv + 1);
static bool
start_virtblk(struct mic_info *mic, struct mic_vring *vring)
{
- if (((__u64)&virtblk_dev_page.blk_config % 8) != 0) {
+ if (((unsigned long)&virtblk_dev_page.blk_config % 8) != 0) {
mpsslog("%s: blk_config is not 8 byte aligned.\n",
mic->name);
return false;