Skip to content

Commit

Permalink
Staging: hv: netvsc: call vmbus_close directly
Browse files Browse the repository at this point in the history
Don't do the interface indirection, it's not needed at all.

Cc: Haiyang Zhang <haiyangz@microsoft.com>
Cc: Hank Janssen <hjanssen@microsoft.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
  • Loading branch information
Greg Kroah-Hartman committed Oct 21, 2010
1 parent 1382e01 commit 1fb9dff
Showing 1 changed file with 4 additions and 4 deletions.
8 changes: 4 additions & 4 deletions drivers/staging/hv/netvsc.c
Original file line number Diff line number Diff line change
Expand Up @@ -738,17 +738,17 @@ static int NetVscOnDeviceAdd(struct hv_device *Device, void *AdditionalInfo)
if (ret != 0) {
DPRINT_ERR(NETVSC, "unable to connect to NetVSP - %d", ret);
ret = -1;
goto Close;
goto close;
}

DPRINT_INFO(NETVSC, "*** NetVSC channel handshake result - %d ***",
ret);

return ret;

Close:
close:
/* Now, we can close the channel safely */
Device->Driver->VmbusChannelInterface.Close(Device);
vmbus_close(Device->channel);

Cleanup:

Expand Down Expand Up @@ -810,7 +810,7 @@ static int NetVscOnDeviceRemove(struct hv_device *Device)
DPRINT_INFO(NETVSC, "net device (%p) safe to remove", netDevice);

/* Now, we can close the channel safely */
Device->Driver->VmbusChannelInterface.Close(Device);
vmbus_close(Device->channel);

/* Release all resources */
list_for_each_entry_safe(netvscPacket, pos,
Expand Down

0 comments on commit 1fb9dff

Please sign in to comment.