forked from luck/tmp_suning_uos_patched
samples: mpssd: fix the build errors when enable DEBUG in mpssd.c
If enable DEBUG, will meet the following errors when build mpssd, so fix them here. Only one error is listed here, other errors are similar. mpssd.c: In function ‘virtio_net’: mpssd.c:615:21: error: incompatible type for argument 2 of ‘disp_iovec’ disp_iovec(mic, copy, __func__, __LINE__); ^~~~ mpssd.c:361:1: note: expected ‘struct mic_copy_desc *’ but argument is of type ‘struct mic_copy_desc’ disp_iovec(struct mic_info *mic, struct mic_copy_desc *copy, ^~~~~~~~~~ Signed-off-by: Sherry Sun <sherry.sun@nxp.com> Link: https://lore.kernel.org/r/20200925071831.8025-2-sherry.sun@nxp.com Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
This commit is contained in:
parent
4292aa977f
commit
b31de43c60
|
@ -612,7 +612,7 @@ virtio_net(void *arg)
|
|||
copy.out_len, hdr->gso_type);
|
||||
#endif
|
||||
#ifdef DEBUG
|
||||
disp_iovec(mic, copy, __func__, __LINE__);
|
||||
disp_iovec(mic, ©, __func__, __LINE__);
|
||||
mpsslog("%s %s %d read from tap 0x%lx\n",
|
||||
mic->name, __func__, __LINE__,
|
||||
len);
|
||||
|
@ -632,7 +632,7 @@ virtio_net(void *arg)
|
|||
if (!err)
|
||||
verify_out_len(mic, ©);
|
||||
#ifdef DEBUG
|
||||
disp_iovec(mic, copy, __func__, __LINE__);
|
||||
disp_iovec(mic, ©, __func__, __LINE__);
|
||||
mpsslog("%s %s %d wrote to net 0x%lx\n",
|
||||
mic->name, __func__, __LINE__,
|
||||
sum_iovec_len(©));
|
||||
|
@ -681,12 +681,12 @@ virtio_net(void *arg)
|
|||
sizeof(struct virtio_net_hdr);
|
||||
verify_out_len(mic, ©);
|
||||
#ifdef DEBUG
|
||||
disp_iovec(mic, copy, __func__,
|
||||
disp_iovec(mic, ©, __func__,
|
||||
__LINE__);
|
||||
mpsslog("%s %s %d ",
|
||||
mic->name, __func__, __LINE__);
|
||||
mpsslog("read from net 0x%lx\n",
|
||||
sum_iovec_len(copy));
|
||||
sum_iovec_len(©));
|
||||
#endif
|
||||
len = writev(net_poll[NET_FD_TUN].fd,
|
||||
copy.iov, copy.iovcnt);
|
||||
|
@ -814,7 +814,7 @@ virtio_console(void *arg)
|
|||
len = readv(pty_fd, copy.iov, copy.iovcnt);
|
||||
if (len > 0) {
|
||||
#ifdef DEBUG
|
||||
disp_iovec(mic, copy, __func__, __LINE__);
|
||||
disp_iovec(mic, ©, __func__, __LINE__);
|
||||
mpsslog("%s %s %d read from tap 0x%lx\n",
|
||||
mic->name, __func__, __LINE__,
|
||||
len);
|
||||
|
@ -834,10 +834,10 @@ virtio_console(void *arg)
|
|||
if (!err)
|
||||
verify_out_len(mic, ©);
|
||||
#ifdef DEBUG
|
||||
disp_iovec(mic, copy, __func__, __LINE__);
|
||||
disp_iovec(mic, ©, __func__, __LINE__);
|
||||
mpsslog("%s %s %d wrote to net 0x%lx\n",
|
||||
mic->name, __func__, __LINE__,
|
||||
sum_iovec_len(copy));
|
||||
sum_iovec_len(©));
|
||||
#endif
|
||||
/* Reinitialize IOV for next run */
|
||||
iov0->iov_len = PAGE_SIZE;
|
||||
|
@ -866,12 +866,12 @@ virtio_console(void *arg)
|
|||
iov1->iov_len = copy.out_len;
|
||||
verify_out_len(mic, ©);
|
||||
#ifdef DEBUG
|
||||
disp_iovec(mic, copy, __func__,
|
||||
disp_iovec(mic, ©, __func__,
|
||||
__LINE__);
|
||||
mpsslog("%s %s %d ",
|
||||
mic->name, __func__, __LINE__);
|
||||
mpsslog("read from net 0x%lx\n",
|
||||
sum_iovec_len(copy));
|
||||
sum_iovec_len(©));
|
||||
#endif
|
||||
len = writev(pty_fd,
|
||||
copy.iov, copy.iovcnt);
|
||||
|
@ -883,7 +883,7 @@ virtio_console(void *arg)
|
|||
sum_iovec_len(©));
|
||||
} else {
|
||||
#ifdef DEBUG
|
||||
disp_iovec(mic, copy, __func__,
|
||||
disp_iovec(mic, ©, __func__,
|
||||
__LINE__);
|
||||
mpsslog("%s %s %d ",
|
||||
mic->name, __func__,
|
||||
|
|
Loading…
Reference in New Issue
Block a user