Staging: hv: cleanup coding style issues in ChannelMgmt.h
Cc: Hank Janssen <hjanssen@microsoft.com> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
This commit is contained in:
parent
e89ce628ba
commit
b239549ca6
@ -129,7 +129,7 @@ static VMBUS_CHANNEL_MESSAGE_TABLE_ENTRY gChannelMessageTable[ChannelMessageCoun
|
||||
Allocate and initialize a vmbus channel object
|
||||
|
||||
--*/
|
||||
static VMBUS_CHANNEL* AllocVmbusChannel(void)
|
||||
VMBUS_CHANNEL* AllocVmbusChannel(void)
|
||||
{
|
||||
VMBUS_CHANNEL* channel;
|
||||
|
||||
@ -189,7 +189,7 @@ static inline void ReleaseVmbusChannel(void* Context)
|
||||
Release the resources used by the vmbus channel object
|
||||
|
||||
--*/
|
||||
static void FreeVmbusChannel(VMBUS_CHANNEL* Channel)
|
||||
void FreeVmbusChannel(VMBUS_CHANNEL* Channel)
|
||||
{
|
||||
del_timer(&Channel->poll_timer);
|
||||
|
||||
@ -665,10 +665,7 @@ VmbusChannelOnVersionResponse(
|
||||
This is invoked in the vmbus worker thread context.
|
||||
|
||||
--*/
|
||||
static void
|
||||
VmbusOnChannelMessage(
|
||||
void *Context
|
||||
)
|
||||
void VmbusOnChannelMessage(void *Context)
|
||||
{
|
||||
HV_MESSAGE *msg=(HV_MESSAGE*)Context;
|
||||
VMBUS_CHANNEL_MESSAGE_HEADER* hdr;
|
||||
@ -714,10 +711,7 @@ VmbusOnChannelMessage(
|
||||
Send a request to get all our pending offers.
|
||||
|
||||
--*/
|
||||
static int
|
||||
VmbusChannelRequestOffers(
|
||||
void
|
||||
)
|
||||
int VmbusChannelRequestOffers(void)
|
||||
{
|
||||
int ret=0;
|
||||
VMBUS_CHANNEL_MESSAGE_HEADER* msg;
|
||||
@ -776,10 +770,7 @@ VmbusChannelRequestOffers(
|
||||
Release channels that are unattached/unconnected ie (no drivers associated)
|
||||
|
||||
--*/
|
||||
static void
|
||||
VmbusChannelReleaseUnattachedChannels(
|
||||
void
|
||||
)
|
||||
void VmbusChannelReleaseUnattachedChannels(void)
|
||||
{
|
||||
LIST_ENTRY *entry;
|
||||
VMBUS_CHANNEL *channel;
|
||||
|
@ -34,7 +34,7 @@
|
||||
|
||||
|
||||
|
||||
typedef void (*PFN_CHANNEL_CALLBACK)(void * context);
|
||||
typedef void (*PFN_CHANNEL_CALLBACK)(void *context);
|
||||
|
||||
typedef enum {
|
||||
CHANNEL_OFFER_STATE,
|
||||
@ -52,14 +52,17 @@ typedef struct _VMBUS_CHANNEL {
|
||||
VMBUS_CHANNEL_STATE State;
|
||||
|
||||
VMBUS_CHANNEL_OFFER_CHANNEL OfferMsg;
|
||||
/* These are based on the OfferMsg.MonitorId. Save it here for easy access. */
|
||||
/*
|
||||
* These are based on the OfferMsg.MonitorId.
|
||||
* Save it here for easy access.
|
||||
*/
|
||||
u8 MonitorGroup;
|
||||
u8 MonitorBit;
|
||||
|
||||
u32 RingBufferGpadlHandle;
|
||||
|
||||
/* Allocated memory for ring buffer */
|
||||
void * RingBufferPages;
|
||||
void *RingBufferPages;
|
||||
u32 RingBufferPageCount;
|
||||
RING_BUFFER_INFO Outbound; /* send to parent */
|
||||
RING_BUFFER_INFO Inbound; /* receive from parent */
|
||||
@ -70,8 +73,7 @@ typedef struct _VMBUS_CHANNEL {
|
||||
/* HANDLE dataWorkQueue; */
|
||||
|
||||
PFN_CHANNEL_CALLBACK OnChannelCallback;
|
||||
void * ChannelCallbackContext;
|
||||
|
||||
void *ChannelCallbackContext;
|
||||
} VMBUS_CHANNEL;
|
||||
|
||||
|
||||
@ -106,7 +108,6 @@ typedef union {
|
||||
* Represents each channel msg on the vmbus connection This is a
|
||||
* variable-size data structure depending on the msg type itself
|
||||
*/
|
||||
|
||||
typedef struct _VMBUS_CHANNEL_MSGINFO {
|
||||
/* Bookkeeping stuff */
|
||||
LIST_ENTRY MsgListEntry;
|
||||
@ -120,37 +121,22 @@ typedef struct _VMBUS_CHANNEL_MSGINFO {
|
||||
VMBUS_CHANNEL_MESSAGE_RESPONSE Response;
|
||||
|
||||
u32 MessageSize;
|
||||
/* The channel message that goes out on the "wire". */
|
||||
/* It will contain at minimum the VMBUS_CHANNEL_MESSAGE_HEADER header */
|
||||
/*
|
||||
* The channel message that goes out on the "wire".
|
||||
* It will contain at minimum the VMBUS_CHANNEL_MESSAGE_HEADER header
|
||||
*/
|
||||
unsigned char Msg[0];
|
||||
} VMBUS_CHANNEL_MSGINFO;
|
||||
|
||||
|
||||
/* Routines */
|
||||
VMBUS_CHANNEL *AllocVmbusChannel(void);
|
||||
|
||||
static VMBUS_CHANNEL*
|
||||
AllocVmbusChannel(
|
||||
void
|
||||
);
|
||||
void FreeVmbusChannel(VMBUS_CHANNEL *Channel);
|
||||
|
||||
static void
|
||||
FreeVmbusChannel(
|
||||
VMBUS_CHANNEL *Channel
|
||||
);
|
||||
void VmbusOnChannelMessage(void *Context);
|
||||
|
||||
static void
|
||||
VmbusOnChannelMessage(
|
||||
void *Context
|
||||
);
|
||||
int VmbusChannelRequestOffers(void);
|
||||
|
||||
static int
|
||||
VmbusChannelRequestOffers(
|
||||
void
|
||||
);
|
||||
|
||||
static void
|
||||
VmbusChannelReleaseUnattachedChannels(
|
||||
void
|
||||
);
|
||||
void VmbusChannelReleaseUnattachedChannels(void);
|
||||
|
||||
#endif /* _CHANNEL_MGMT_H_ */
|
||||
|
Loading…
Reference in New Issue
Block a user