You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
gentoo-overlay/app-emulation/vmware-modules/files/279-3.19-04-iovec.patch

40 lines
1.5 KiB

diff -rupN vmci-only.old/linux/vmciKernelIf.c vmci-only/linux/vmciKernelIf.c
--- vmci-only.old/linux/vmciKernelIf.c 2015-04-28 18:05:56.000000000 +0000
+++ vmci-only/linux/vmciKernelIf.c 2015-07-06 08:02:08.314262258 +0000
@@ -40,6 +40,7 @@
#include <linux/socket.h> /* For memcpy_{to,from}iovec(). */
#include <linux/vmalloc.h>
#include <linux/wait.h>
+#include <linux/skbuff.h>
#include "compat_highmem.h"
#include "compat_interrupt.h"
@@ -1227,11 +1228,11 @@ __VMCIMemcpyToQueue(VMCIQueue *queue,
}
if (isIovec) {
- struct iovec *iov = (struct iovec *)src;
+ struct msghdr *msg = (struct msghdr *)src;
int err;
/* The iovec will track bytesCopied internally. */
- err = memcpy_fromiovec((uint8 *)va + pageOffset, iov, toCopy);
+ err = memcpy_from_msg((u8 *)va + pageOffset, msg, toCopy);
if (err != 0) {
if (!kernelIf->isDataMapped) {
kunmap(kernelIf->page[pageIndex]);
@@ -1302,11 +1303,11 @@ __VMCIMemcpyFromQueue(void *dest,
}
if (isIovec) {
- struct iovec *iov = (struct iovec *)dest;
+ struct msghdr *msg = (struct msghdr *)dest;
int err;
/* The iovec will track bytesCopied internally. */
- err = memcpy_toiovec(iov, (uint8 *)va + pageOffset, toCopy);
+ err = memcpy_to_msg(msg, (uint8 *)va + pageOffset, toCopy);
if (err != 0) {
if (!kernelIf->isDataMapped) {
kunmap(kernelIf->page[pageIndex]);