diff options
-rw-r--r-- | drivers/staging/hv/channel_interface.c | 14 | ||||
-rw-r--r-- | drivers/staging/hv/netvsc.c | 8 | ||||
-rw-r--r-- | drivers/staging/hv/vmbus.c | 4 | ||||
-rw-r--r-- | drivers/staging/hv/vmbus_api.h | 4 | ||||
-rw-r--r-- | drivers/staging/hv/vmbus_drv.c | 10 | ||||
-rw-r--r-- | drivers/staging/hv/vmbus_private.h | 2 |
6 files changed, 21 insertions, 21 deletions
diff --git a/drivers/staging/hv/channel_interface.c b/drivers/staging/hv/channel_interface.c index 5016668aea7b..35b700f8612b 100644 --- a/drivers/staging/hv/channel_interface.c +++ b/drivers/staging/hv/channel_interface.c | |||
@@ -31,21 +31,21 @@ static int ivmbus_open(struct hv_device *device, u32 sendbuffer_size, | |||
31 | void (*channel_callback)(void *context), | 31 | void (*channel_callback)(void *context), |
32 | void *context) | 32 | void *context) |
33 | { | 33 | { |
34 | return vmbus_open(device->context, sendbuffer_size, | 34 | return vmbus_open(device->channel, sendbuffer_size, |
35 | recv_ringbuffer_size, userdata, userdatalen, | 35 | recv_ringbuffer_size, userdata, userdatalen, |
36 | channel_callback, context); | 36 | channel_callback, context); |
37 | } | 37 | } |
38 | 38 | ||
39 | static void ivmbus_close(struct hv_device *device) | 39 | static void ivmbus_close(struct hv_device *device) |
40 | { | 40 | { |
41 | vmbus_close(device->context); | 41 | vmbus_close(device->channel); |
42 | } | 42 | } |
43 | 43 | ||
44 | static int ivmbus_sendpacket(struct hv_device *device, const void *buffer, | 44 | static int ivmbus_sendpacket(struct hv_device *device, const void *buffer, |
45 | u32 bufferlen, u64 requestid, u32 type, | 45 | u32 bufferlen, u64 requestid, u32 type, |
46 | u32 flags) | 46 | u32 flags) |
47 | { | 47 | { |
48 | return vmbus_sendpacket(device->context, buffer, bufferlen, | 48 | return vmbus_sendpacket(device->channel, buffer, bufferlen, |
49 | requestid, type, flags); | 49 | requestid, type, flags); |
50 | } | 50 | } |
51 | 51 | ||
@@ -54,7 +54,7 @@ static int ivmbus_sendpacket_pagebuffer(struct hv_device *device, | |||
54 | u32 pagecount, void *buffer, | 54 | u32 pagecount, void *buffer, |
55 | u32 bufferlen, u64 requestid) | 55 | u32 bufferlen, u64 requestid) |
56 | { | 56 | { |
57 | return vmbus_sendpacket_pagebuffer(device->context, pagebuffers, | 57 | return vmbus_sendpacket_pagebuffer(device->channel, pagebuffers, |
58 | pagecount, buffer, bufferlen, | 58 | pagecount, buffer, bufferlen, |
59 | requestid); | 59 | requestid); |
60 | } | 60 | } |
@@ -63,7 +63,7 @@ static int ivmbus_sendpacket_multipagebuffer(struct hv_device *device, | |||
63 | struct hv_multipage_buffer *multi_pagebuffer, | 63 | struct hv_multipage_buffer *multi_pagebuffer, |
64 | void *buffer, u32 bufferlen, u64 requestid) | 64 | void *buffer, u32 bufferlen, u64 requestid) |
65 | { | 65 | { |
66 | return vmbus_sendpacket_multipagebuffer(device->context, | 66 | return vmbus_sendpacket_multipagebuffer(device->channel, |
67 | multi_pagebuffer, buffer, | 67 | multi_pagebuffer, buffer, |
68 | bufferlen, requestid); | 68 | bufferlen, requestid); |
69 | } | 69 | } |
@@ -72,7 +72,7 @@ static int ivmbus_recvpacket(struct hv_device *device, void *buffer, | |||
72 | u32 bufferlen, u32 *buffer_actuallen, | 72 | u32 bufferlen, u32 *buffer_actuallen, |
73 | u64 *requestid) | 73 | u64 *requestid) |
74 | { | 74 | { |
75 | return vmbus_recvpacket(device->context, buffer, bufferlen, | 75 | return vmbus_recvpacket(device->channel, buffer, bufferlen, |
76 | buffer_actuallen, requestid); | 76 | buffer_actuallen, requestid); |
77 | } | 77 | } |
78 | 78 | ||
@@ -80,7 +80,7 @@ static int ivmbus_recvpacket_raw(struct hv_device *device, void *buffer, | |||
80 | u32 bufferlen, u32 *buffer_actuallen, | 80 | u32 bufferlen, u32 *buffer_actuallen, |
81 | u64 *requestid) | 81 | u64 *requestid) |
82 | { | 82 | { |
83 | return vmbus_recvpacket_raw(device->context, buffer, bufferlen, | 83 | return vmbus_recvpacket_raw(device->channel, buffer, bufferlen, |
84 | buffer_actuallen, requestid); | 84 | buffer_actuallen, requestid); |
85 | } | 85 | } |
86 | 86 | ||
diff --git a/drivers/staging/hv/netvsc.c b/drivers/staging/hv/netvsc.c index 4c29c31ad3a5..1c15f9a1a12b 100644 --- a/drivers/staging/hv/netvsc.c +++ b/drivers/staging/hv/netvsc.c | |||
@@ -240,7 +240,7 @@ static int NetVscInitializeReceiveBufferWithNetVsp(struct hv_device *Device) | |||
240 | * channel. Note: This call uses the vmbus connection rather | 240 | * channel. Note: This call uses the vmbus connection rather |
241 | * than the channel to establish the gpadl handle. | 241 | * than the channel to establish the gpadl handle. |
242 | */ | 242 | */ |
243 | ret = vmbus_establish_gpadl(Device->context, netDevice->ReceiveBuffer, | 243 | ret = vmbus_establish_gpadl(Device->channel, netDevice->ReceiveBuffer, |
244 | netDevice->ReceiveBufferSize, | 244 | netDevice->ReceiveBufferSize, |
245 | &netDevice->ReceiveBufferGpadlHandle); | 245 | &netDevice->ReceiveBufferGpadlHandle); |
246 | if (ret != 0) { | 246 | if (ret != 0) { |
@@ -368,7 +368,7 @@ static int NetVscInitializeSendBufferWithNetVsp(struct hv_device *Device) | |||
368 | * channel. Note: This call uses the vmbus connection rather | 368 | * channel. Note: This call uses the vmbus connection rather |
369 | * than the channel to establish the gpadl handle. | 369 | * than the channel to establish the gpadl handle. |
370 | */ | 370 | */ |
371 | ret = vmbus_establish_gpadl(Device->context, netDevice->SendBuffer, | 371 | ret = vmbus_establish_gpadl(Device->channel, netDevice->SendBuffer, |
372 | netDevice->SendBufferSize, | 372 | netDevice->SendBufferSize, |
373 | &netDevice->SendBufferGpadlHandle); | 373 | &netDevice->SendBufferGpadlHandle); |
374 | if (ret != 0) { | 374 | if (ret != 0) { |
@@ -467,7 +467,7 @@ static int NetVscDestroyReceiveBuffer(struct netvsc_device *NetDevice) | |||
467 | if (NetDevice->ReceiveBufferGpadlHandle) { | 467 | if (NetDevice->ReceiveBufferGpadlHandle) { |
468 | DPRINT_INFO(NETVSC, "Tearing down receive buffer's GPADL..."); | 468 | DPRINT_INFO(NETVSC, "Tearing down receive buffer's GPADL..."); |
469 | 469 | ||
470 | ret = vmbus_teardown_gpadl(NetDevice->Device->context, | 470 | ret = vmbus_teardown_gpadl(NetDevice->Device->channel, |
471 | NetDevice->ReceiveBufferGpadlHandle); | 471 | NetDevice->ReceiveBufferGpadlHandle); |
472 | 472 | ||
473 | /* If we failed here, we might as well return and have a leak rather than continue and a bugchk */ | 473 | /* If we failed here, we might as well return and have a leak rather than continue and a bugchk */ |
@@ -538,7 +538,7 @@ static int NetVscDestroySendBuffer(struct netvsc_device *NetDevice) | |||
538 | /* Teardown the gpadl on the vsp end */ | 538 | /* Teardown the gpadl on the vsp end */ |
539 | if (NetDevice->SendBufferGpadlHandle) { | 539 | if (NetDevice->SendBufferGpadlHandle) { |
540 | DPRINT_INFO(NETVSC, "Tearing down send buffer's GPADL..."); | 540 | DPRINT_INFO(NETVSC, "Tearing down send buffer's GPADL..."); |
541 | ret = vmbus_teardown_gpadl(NetDevice->Device->context, | 541 | ret = vmbus_teardown_gpadl(NetDevice->Device->channel, |
542 | NetDevice->SendBufferGpadlHandle); | 542 | NetDevice->SendBufferGpadlHandle); |
543 | 543 | ||
544 | /* | 544 | /* |
diff --git a/drivers/staging/hv/vmbus.c b/drivers/staging/hv/vmbus.c index ffdbd30e3ba5..d449daf81976 100644 --- a/drivers/staging/hv/vmbus.c +++ b/drivers/staging/hv/vmbus.c | |||
@@ -65,12 +65,12 @@ static void VmbusGetChannelOffers(void) | |||
65 | */ | 65 | */ |
66 | struct hv_device *VmbusChildDeviceCreate(struct hv_guid *DeviceType, | 66 | struct hv_device *VmbusChildDeviceCreate(struct hv_guid *DeviceType, |
67 | struct hv_guid *DeviceInstance, | 67 | struct hv_guid *DeviceInstance, |
68 | void *Context) | 68 | struct vmbus_channel *channel) |
69 | { | 69 | { |
70 | struct vmbus_driver *vmbusDriver = (struct vmbus_driver *)gDriver; | 70 | struct vmbus_driver *vmbusDriver = (struct vmbus_driver *)gDriver; |
71 | 71 | ||
72 | return vmbusDriver->OnChildDeviceCreate(DeviceType, DeviceInstance, | 72 | return vmbusDriver->OnChildDeviceCreate(DeviceType, DeviceInstance, |
73 | Context); | 73 | channel); |
74 | } | 74 | } |
75 | 75 | ||
76 | /* | 76 | /* |
diff --git a/drivers/staging/hv/vmbus_api.h b/drivers/staging/hv/vmbus_api.h index 55bd00ddb61b..17e3c9addc67 100644 --- a/drivers/staging/hv/vmbus_api.h +++ b/drivers/staging/hv/vmbus_api.h | |||
@@ -152,7 +152,7 @@ struct hv_device { | |||
152 | /* the device instance id of this device */ | 152 | /* the device instance id of this device */ |
153 | struct hv_guid deviceInstance; | 153 | struct hv_guid deviceInstance; |
154 | 154 | ||
155 | struct vmbus_channel *context; | 155 | struct vmbus_channel *channel; |
156 | 156 | ||
157 | /* Device extension; */ | 157 | /* Device extension; */ |
158 | void *Extension; | 158 | void *Extension; |
@@ -167,7 +167,7 @@ struct vmbus_driver { | |||
167 | /* Set by the caller */ | 167 | /* Set by the caller */ |
168 | struct hv_device * (*OnChildDeviceCreate)(struct hv_guid *DeviceType, | 168 | struct hv_device * (*OnChildDeviceCreate)(struct hv_guid *DeviceType, |
169 | struct hv_guid *DeviceInstance, | 169 | struct hv_guid *DeviceInstance, |
170 | void *Context); | 170 | struct vmbus_channel *channel); |
171 | void (*OnChildDeviceDestroy)(struct hv_device *device); | 171 | void (*OnChildDeviceDestroy)(struct hv_device *device); |
172 | int (*OnChildDeviceAdd)(struct hv_device *RootDevice, | 172 | int (*OnChildDeviceAdd)(struct hv_device *RootDevice, |
173 | struct hv_device *ChildDevice); | 173 | struct hv_device *ChildDevice); |
diff --git a/drivers/staging/hv/vmbus_drv.c b/drivers/staging/hv/vmbus_drv.c index 1e0a1de8261d..92ba95c7c6d6 100644 --- a/drivers/staging/hv/vmbus_drv.c +++ b/drivers/staging/hv/vmbus_drv.c | |||
@@ -71,7 +71,7 @@ static void vmbus_bus_release(struct device *device); | |||
71 | 71 | ||
72 | static struct hv_device *vmbus_child_device_create(struct hv_guid *type, | 72 | static struct hv_device *vmbus_child_device_create(struct hv_guid *type, |
73 | struct hv_guid *instance, | 73 | struct hv_guid *instance, |
74 | void *context); | 74 | struct vmbus_channel *channel); |
75 | static void vmbus_child_device_destroy(struct hv_device *device_obj); | 75 | static void vmbus_child_device_destroy(struct hv_device *device_obj); |
76 | static int vmbus_child_device_register(struct hv_device *root_device_obj, | 76 | static int vmbus_child_device_register(struct hv_device *root_device_obj, |
77 | struct hv_device *child_device_obj); | 77 | struct hv_device *child_device_obj); |
@@ -134,10 +134,10 @@ static void get_channel_info(struct hv_device *device, | |||
134 | { | 134 | { |
135 | struct vmbus_channel_debug_info debug_info; | 135 | struct vmbus_channel_debug_info debug_info; |
136 | 136 | ||
137 | if (!device->context) | 137 | if (!device->channel) |
138 | return; | 138 | return; |
139 | 139 | ||
140 | vmbus_get_debug_info(device->context, &debug_info); | 140 | vmbus_get_debug_info(device->channel, &debug_info); |
141 | 141 | ||
142 | info->ChannelId = debug_info.RelId; | 142 | info->ChannelId = debug_info.RelId; |
143 | info->ChannelState = debug_info.State; | 143 | info->ChannelState = debug_info.State; |
@@ -508,7 +508,7 @@ EXPORT_SYMBOL(vmbus_get_interface); | |||
508 | */ | 508 | */ |
509 | static struct hv_device *vmbus_child_device_create(struct hv_guid *type, | 509 | static struct hv_device *vmbus_child_device_create(struct hv_guid *type, |
510 | struct hv_guid *instance, | 510 | struct hv_guid *instance, |
511 | void *context) | 511 | struct vmbus_channel *channel) |
512 | { | 512 | { |
513 | struct vm_device *child_device_ctx; | 513 | struct vm_device *child_device_ctx; |
514 | struct hv_device *child_device_obj; | 514 | struct hv_device *child_device_obj; |
@@ -541,7 +541,7 @@ static struct hv_device *vmbus_child_device_create(struct hv_guid *type, | |||
541 | instance->data[14], instance->data[15]); | 541 | instance->data[14], instance->data[15]); |
542 | 542 | ||
543 | child_device_obj = &child_device_ctx->device_obj; | 543 | child_device_obj = &child_device_ctx->device_obj; |
544 | child_device_obj->context = context; | 544 | child_device_obj->channel = channel; |
545 | memcpy(&child_device_obj->deviceType, type, sizeof(struct hv_guid)); | 545 | memcpy(&child_device_obj->deviceType, type, sizeof(struct hv_guid)); |
546 | memcpy(&child_device_obj->deviceInstance, instance, | 546 | memcpy(&child_device_obj->deviceInstance, instance, |
547 | sizeof(struct hv_guid)); | 547 | sizeof(struct hv_guid)); |
diff --git a/drivers/staging/hv/vmbus_private.h b/drivers/staging/hv/vmbus_private.h index 7bdb29ac8952..09eaec964b30 100644 --- a/drivers/staging/hv/vmbus_private.h +++ b/drivers/staging/hv/vmbus_private.h | |||
@@ -104,7 +104,7 @@ extern struct VMBUS_CONNECTION gVmbusConnection; | |||
104 | 104 | ||
105 | struct hv_device *VmbusChildDeviceCreate(struct hv_guid *deviceType, | 105 | struct hv_device *VmbusChildDeviceCreate(struct hv_guid *deviceType, |
106 | struct hv_guid *deviceInstance, | 106 | struct hv_guid *deviceInstance, |
107 | void *context); | 107 | struct vmbus_channel *channel); |
108 | 108 | ||
109 | int VmbusChildDeviceAdd(struct hv_device *Device); | 109 | int VmbusChildDeviceAdd(struct hv_device *Device); |
110 | 110 | ||