History

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.

Andy King committed 13 years ago

Commit 347e0891 parent 61ec7e71 file · +3 −1Browse files

Unified · Split

drivers/misc/vmw_vmci/vmci_datagram.c+3−1
@@ -42,9 +42,11 @@ struct datagram_entry { · 41 unmodified lines
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 */