staging: unisys: Convert pending_msg_hdr to a pointer
authorDon Zickus <dzickus@redhat.com>
Mon, 1 Jun 2015 17:00:27 +0000 (13:00 -0400)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Tue, 2 Jun 2015 05:22:49 +0000 (14:22 +0900)
commit0274b5aec1b30f594e2e5975b3bbf672565a6dd7
tree8038baa331b21d346b2b2a6efc6e460903b8c20f
parentb32c4997c03d9d1fcfc1c6771f70d7526ffdbbe4
staging: unisys: Convert pending_msg_hdr to a pointer

In order for bus/dev_info structs to become public structs, one
element, pending_msg_hdr, needs to become opaque.  This is to keep
all the internals of the controlvm struct private to the bus layer.

So a simple conversion of embedding the pending_msg_hdr struct into
a pointer is done.  The rest of the patch is the fallout.

The rules are modified slightly.  Instead of relying on the 'id' to be
CONTROLVM_INVALID to indicate invalid, just use the pointer set to NULL.

In addition, because bus/dev_info can be NULL and we still need to send
a
response, pass pending_msg_hdr to all 'responders' instead of bus/

That change causes some fallout in the success case.  Instead of setting
state
bits and clearing info in the responders, do all that magic in the
responder
wrappers.

Signed-off-by: Don Zickus <dzickus@redhat.com>
Signed-off-by: Benjamin Romer <benjamin.romer@unisys.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
drivers/staging/unisys/visorbus/visorbus_private.h
drivers/staging/unisys/visorbus/visorchipset.c