Skip to content

Commit 347e089

Browse files
Andy Kinggregkh
authored andcommitted
VMCI: Fix process-to-process DRGAMs.
When sending between processes, we always schedule a work item. Our work info struct has the message embedded in the middle, which means that we end up overwriting subsequent fields when we copy the (variable-length) message into it. Move it to the end of the struct. Acked-by: Dmitry Torokhov <dtor@vmware.com> Signed-off-by: Andy King <acking@vmware.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
1 parent 61ec7e7 commit 347e089

1 file changed

Lines changed: 3 additions & 1 deletion

File tree

‎drivers/misc/vmw_vmci/vmci_datagram.c‎

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -42,9 +42,11 @@ struct datagram_entry {
4242

4343
struct delayed_datagram_info {
4444
struct datagram_entry *entry;
45-
struct vmci_datagram msg;
4645
struct work_struct work;
4746
bool in_dg_host_queue;
47+
/* msg and msg_payload must be together. */
48+
struct vmci_datagram msg;
49+
u8 msg_payload[];
4850
};
4951

5052
/* Number of in-flight host->host datagrams */

0 commit comments

Comments
 (0)