Skip to content

Commit

Permalink
Staging: hv: remove OnIsr vmbus_driver callback
Browse files Browse the repository at this point in the history
It's only ever set to one function, so just call that function instead.

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 Dec 2, 2010
1 parent 9d8bd71 commit 097e310
Show file tree
Hide file tree
Showing 3 changed files with 4 additions and 7 deletions.
5 changes: 2 additions & 3 deletions drivers/staging/hv/vmbus.c
Original file line number Diff line number Diff line change
Expand Up @@ -175,9 +175,9 @@ static void VmbusOnEventDPC(struct hv_driver *drv)
}

/*
* VmbusOnISR - ISR routine
* vmbus_on_isr - ISR routine
*/
static int VmbusOnISR(struct hv_driver *drv)
int vmbus_on_isr(struct hv_driver *drv)
{
int ret = 0;
int cpu = smp_processor_id();
Expand Down Expand Up @@ -235,7 +235,6 @@ int VmbusInitialize(struct hv_driver *drv)
driver->Base.OnDeviceAdd = VmbusOnDeviceAdd;
driver->Base.OnDeviceRemove = VmbusOnDeviceRemove;
driver->Base.OnCleanup = VmbusOnCleanup;
driver->OnIsr = VmbusOnISR;
driver->OnMsgDpc = VmbusOnMsgDPC;
driver->OnEventDpc = VmbusOnEventDPC;
driver->GetChannelOffers = VmbusGetChannelOffers;
Expand Down
2 changes: 1 addition & 1 deletion drivers/staging/hv/vmbus_api.h
Original file line number Diff line number Diff line change
Expand Up @@ -126,12 +126,12 @@ struct vmbus_driver {
struct hv_device *ChildDevice);

/* Set by the callee */
int (*OnIsr)(struct hv_driver *driver);
void (*OnMsgDpc)(struct hv_driver *driver);
void (*OnEventDpc)(struct hv_driver *driver);
void (*GetChannelOffers)(void);
};

int VmbusInitialize(struct hv_driver *drv);
int vmbus_on_isr(struct hv_driver *drv);

#endif /* _VMBUS_API_H_ */
4 changes: 1 addition & 3 deletions drivers/staging/hv/vmbus_drv.c
Original file line number Diff line number Diff line change
Expand Up @@ -873,10 +873,8 @@ static irqreturn_t vmbus_isr(int irq, void *dev_id)
struct vmbus_driver *vmbus_driver_obj = &g_vmbus_drv.drv_obj;
int ret;

/* ASSERT(vmbus_driver_obj->OnIsr != NULL); */

/* Call to bus driver to handle interrupt */
ret = vmbus_driver_obj->OnIsr(&vmbus_driver_obj->Base);
ret = vmbus_on_isr(&vmbus_driver_obj->Base);

/* Schedules a dpc if necessary */
if (ret > 0) {
Expand Down

0 comments on commit 097e310

Please sign in to comment.