Skip to content

Commit

Permalink
VMCI: Fix process-to-process DRGAMs.
Browse files Browse the repository at this point in the history
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>
  • Loading branch information
Andy King authored and Greg Kroah-Hartman committed Mar 15, 2013
1 parent 61ec7e7 commit 347e089
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion drivers/misc/vmw_vmci/vmci_datagram.c
Original file line number Diff line number Diff line change
Expand Up @@ -42,9 +42,11 @@ struct datagram_entry {

struct delayed_datagram_info {
struct datagram_entry *entry;
struct vmci_datagram msg;
struct work_struct work;
bool in_dg_host_queue;
/* msg and msg_payload must be together. */
struct vmci_datagram msg;
u8 msg_payload[];
};

/* Number of in-flight host->host datagrams */
Expand Down

0 comments on commit 347e089

Please sign in to comment.