Staging: hv: Remove the vm_device structure
[cascardo/linux.git] / drivers / staging / hv / vmbus.h
index 2295fe2..73087f2 100644 (file)
 #include <linux/device.h>
 #include "vmbus_api.h"
 
-struct driver_context {
-       struct hv_guid class_id;
 
-       struct device_driver driver;
 
-};
 
-struct vm_device {
-       struct work_struct probe_failed_work_item;
-       struct hv_guid class_id;
-       struct hv_guid device_id;
-       int probe_error;
-       struct hv_device device_obj;
-       struct device device;
-};
-
-static inline struct vm_device *to_vm_device(struct hv_device *d)
-{
-       return container_of(d, struct vm_device, device_obj);
-}
-
-static inline struct vm_device *device_to_vm_device(struct device *d)
+static inline struct hv_device *device_to_hv_device(struct device *d)
 {
-       return container_of(d, struct vm_device, device);
+       return container_of(d, struct hv_device, device);
 }
 
-static inline struct driver_context *driver_to_driver_context(struct device_driver *d)
+static inline struct hv_driver *drv_to_hv_drv(struct device_driver *d)
 {
-       return container_of(d, struct driver_context, driver);
+       return container_of(d, struct hv_driver, driver);
 }
 
 
 /* Vmbus interface */
 int vmbus_child_driver_register(struct device_driver *drv);
-void vmbus_child_driver_unregister(struct driver_context *driver_ctx);
+void vmbus_child_driver_unregister(struct device_driver *drv);
 
 extern struct completion hv_channel_ready;