Displaying 20 results from an estimated 28 matches for "drv_obj".
2011 Feb 26
2
[PATCH 6/6] Staging: hv: Cleanup hyperv_driver variable names
.../blkvsc_drv.c
+++ b/drivers/staging/hv/blkvsc_drv.c
@@ -119,7 +119,7 @@ struct block_device_context {
struct blkvsc_hyperv_driver {
/* !! These must be the first 2 fields !! */
/* FIXME this is a bug! */
- struct hyperv_driver drv_ctx;
+ struct hyperv_driver drv;
struct storvsc_driver_object drv_obj;
};
@@ -174,7 +174,7 @@ static const struct block_device_operations block_ops = {
static int blkvsc_drv_init(int (*drv_init)(struct hyperv_driver *drv))
{
struct storvsc_driver_object *storvsc_drv_obj = &g_blkvsc_drv.drv_obj;
- struct hyperv_driver *drv_ctx = &g_blkvsc_drv.drv_ctx;
+...
2011 Feb 26
2
[PATCH 6/6] Staging: hv: Cleanup hyperv_driver variable names
.../blkvsc_drv.c
+++ b/drivers/staging/hv/blkvsc_drv.c
@@ -119,7 +119,7 @@ struct block_device_context {
struct blkvsc_hyperv_driver {
/* !! These must be the first 2 fields !! */
/* FIXME this is a bug! */
- struct hyperv_driver drv_ctx;
+ struct hyperv_driver drv;
struct storvsc_driver_object drv_obj;
};
@@ -174,7 +174,7 @@ static const struct block_device_operations block_ops = {
static int blkvsc_drv_init(int (*drv_init)(struct hyperv_driver *drv))
{
struct storvsc_driver_object *storvsc_drv_obj = &g_blkvsc_drv.drv_obj;
- struct hyperv_driver *drv_ctx = &g_blkvsc_drv.drv_ctx;
+...
2011 Feb 26
1
[PATCH 5/6] Staging: hv: Rename driver_context to hyperv_driver
...+116,10 @@ struct block_device_context {
};
/* Per driver */
-struct blkvsc_driver_context {
+struct blkvsc_hyperv_driver {
/* !! These must be the first 2 fields !! */
/* FIXME this is a bug! */
- struct driver_context drv_ctx;
+ struct hyperv_driver drv_ctx;
struct storvsc_driver_object drv_obj;
};
@@ -156,7 +156,7 @@ module_param(blkvsc_ringbuffer_size, int, S_IRUGO);
MODULE_PARM_DESC(ring_size, "Ring buffer size (in bytes)");
/* The one and only one */
-static struct blkvsc_driver_context g_blkvsc_drv;
+static struct blkvsc_hyperv_driver g_blkvsc_drv;
static const st...
2011 Feb 26
1
[PATCH 5/6] Staging: hv: Rename driver_context to hyperv_driver
...+116,10 @@ struct block_device_context {
};
/* Per driver */
-struct blkvsc_driver_context {
+struct blkvsc_hyperv_driver {
/* !! These must be the first 2 fields !! */
/* FIXME this is a bug! */
- struct driver_context drv_ctx;
+ struct hyperv_driver drv_ctx;
struct storvsc_driver_object drv_obj;
};
@@ -156,7 +156,7 @@ module_param(blkvsc_ringbuffer_size, int, S_IRUGO);
MODULE_PARM_DESC(ring_size, "Ring buffer size (in bytes)");
/* The one and only one */
-static struct blkvsc_driver_context g_blkvsc_drv;
+static struct blkvsc_hyperv_driver g_blkvsc_drv;
static const st...
2011 Feb 23
7
[PATCH 1/4] staging: hv: Fix the code depending on struct vmbus_driver_context data order
The patch fixed the code depending on the exact order of fields in the
struct vmbus_driver_context, so the unused field drv_ctx can be removed,
and drv_obj doesn't have to be the second field in this structure.
Signed-off-by: Haiyang Zhang <haiyangz at microsoft.com>
Signed-off-by: K. Y. Srinivasan <kys at microsoft.com>
Signed-off-by: Hank Janssen <hjanssen at microsoft.com>
---
drivers/staging/hv/blkvsc_drv.c | 2 ++
dri...
2011 Feb 23
7
[PATCH 1/4] staging: hv: Fix the code depending on struct vmbus_driver_context data order
The patch fixed the code depending on the exact order of fields in the
struct vmbus_driver_context, so the unused field drv_ctx can be removed,
and drv_obj doesn't have to be the second field in this structure.
Signed-off-by: Haiyang Zhang <haiyangz at microsoft.com>
Signed-off-by: K. Y. Srinivasan <kys at microsoft.com>
Signed-off-by: Hank Janssen <hjanssen at microsoft.com>
---
drivers/staging/hv/blkvsc_drv.c | 2 ++
dri...
2011 Mar 07
0
[PATCH 10/16] Staging: hv: Eliminate netvsc_driver_context
...ivers/staging/hv/netvsc_drv.c b/drivers/staging/hv/netvsc_drv.c
index fdcc8aa..f0d258c 100644
--- a/drivers/staging/hv/netvsc_drv.c
+++ b/drivers/staging/hv/netvsc_drv.c
@@ -48,9 +48,6 @@ struct net_device_context {
unsigned long avail;
};
-struct netvsc_driver_context {
- struct netvsc_driver drv_obj;
-};
#define PACKET_PAGES_LOWATER 8
/* Need this many pages to handle worst case fragmented packet */
@@ -61,7 +58,7 @@ module_param(ring_size, int, S_IRUGO);
MODULE_PARM_DESC(ring_size, "Ring buffer size (# of pages)");
/* The one and only one */
-static struct netvsc_driver_con...
2011 Mar 07
0
[PATCH 10/16] Staging: hv: Eliminate netvsc_driver_context
...ivers/staging/hv/netvsc_drv.c b/drivers/staging/hv/netvsc_drv.c
index fdcc8aa..f0d258c 100644
--- a/drivers/staging/hv/netvsc_drv.c
+++ b/drivers/staging/hv/netvsc_drv.c
@@ -48,9 +48,6 @@ struct net_device_context {
unsigned long avail;
};
-struct netvsc_driver_context {
- struct netvsc_driver drv_obj;
-};
#define PACKET_PAGES_LOWATER 8
/* Need this many pages to handle worst case fragmented packet */
@@ -61,7 +58,7 @@ module_param(ring_size, int, S_IRUGO);
MODULE_PARM_DESC(ring_size, "Ring buffer size (# of pages)");
/* The one and only one */
-static struct netvsc_driver_con...
2011 Feb 26
1
[PATCH 4/6] Staging: hv: Unify the hyperv driver abstractions
...ic const struct block_device_operations block_ops = {
/*
* blkvsc_drv_init - BlkVsc driver initialization.
*/
-static int blkvsc_drv_init(int (*drv_init)(struct hv_driver *drv))
+static int blkvsc_drv_init(int (*drv_init)(struct driver_context *drv))
{
struct storvsc_driver_object *storvsc_drv_obj = &g_blkvsc_drv.drv_obj;
struct driver_context *drv_ctx = &g_blkvsc_drv.drv_ctx;
diff --git a/drivers/staging/hv/netvsc.c b/drivers/staging/hv/netvsc.c
index 7cf6999..6d8d0a3 100644
--- a/drivers/staging/hv/netvsc.c
+++ b/drivers/staging/hv/netvsc.c
@@ -49,7 +49,7 @@ netvsc_device_add(str...
2011 Feb 26
1
[PATCH 4/6] Staging: hv: Unify the hyperv driver abstractions
...ic const struct block_device_operations block_ops = {
/*
* blkvsc_drv_init - BlkVsc driver initialization.
*/
-static int blkvsc_drv_init(int (*drv_init)(struct hv_driver *drv))
+static int blkvsc_drv_init(int (*drv_init)(struct driver_context *drv))
{
struct storvsc_driver_object *storvsc_drv_obj = &g_blkvsc_drv.drv_obj;
struct driver_context *drv_ctx = &g_blkvsc_drv.drv_ctx;
diff --git a/drivers/staging/hv/netvsc.c b/drivers/staging/hv/netvsc.c
index 7cf6999..6d8d0a3 100644
--- a/drivers/staging/hv/netvsc.c
+++ b/drivers/staging/hv/netvsc.c
@@ -49,7 +49,7 @@ netvsc_device_add(str...
2011 Feb 24
4
[PATCH ] Staging: hv: Hyper-V driver cleanup
...,10 +116,10 @@ struct block_device_context {
};
/* Per driver */
-struct blkvsc_driver_context {
+struct blkvsc_hyperv_driver {
/* !! These must be the first 2 fields !! */
/* FIXME this is a bug! */
- struct driver_context drv_ctx;
+ struct hyperv_driver drv;
struct storvsc_driver_object drv_obj;
};
@@ -156,7 +156,7 @@ module_param(blkvsc_ringbuffer_size, int, S_IRUGO);
MODULE_PARM_DESC(ring_size, "Ring buffer size (in bytes)");
/* The one and only one */
-static struct blkvsc_driver_context g_blkvsc_drv;
+static struct blkvsc_hyperv_driver g_blkvsc_drv;
static const st...
2011 Feb 24
4
[PATCH ] Staging: hv: Hyper-V driver cleanup
...,10 +116,10 @@ struct block_device_context {
};
/* Per driver */
-struct blkvsc_driver_context {
+struct blkvsc_hyperv_driver {
/* !! These must be the first 2 fields !! */
/* FIXME this is a bug! */
- struct driver_context drv_ctx;
+ struct hyperv_driver drv;
struct storvsc_driver_object drv_obj;
};
@@ -156,7 +156,7 @@ module_param(blkvsc_ringbuffer_size, int, S_IRUGO);
MODULE_PARM_DESC(ring_size, "Ring buffer size (in bytes)");
/* The one and only one */
-static struct blkvsc_driver_context g_blkvsc_drv;
+static struct blkvsc_hyperv_driver g_blkvsc_drv;
static const st...
2011 Feb 26
2
[PATCH 3/6] Staging: hv: Cleanup hyperv_device variable names
...obj;
struct driver_context *driver_ctx =
- driver_to_driver_context(device_ctx->device.driver);
+ driver_to_driver_context(device_obj->device.driver);
struct blkvsc_driver_context *blkvsc_drv_ctx =
(struct blkvsc_driver_context *)driver_ctx;
struct storvsc_driver_object *storvsc_drv_obj =
@@ -895,7 +895,7 @@ static int blkvsc_submit_request(struct blkvsc_request *blkvsc_req,
storvsc_req->sense_buffer = blkvsc_req->sense_buffer;
storvsc_req->sense_buffer_size = SCSI_SENSE_BUFFERSIZE;
- ret = storvsc_drv_obj->on_io_request(blkdev->device_ctx,
+ ret = storvsc_drv...
2011 Feb 26
2
[PATCH 3/6] Staging: hv: Cleanup hyperv_device variable names
...obj;
struct driver_context *driver_ctx =
- driver_to_driver_context(device_ctx->device.driver);
+ driver_to_driver_context(device_obj->device.driver);
struct blkvsc_driver_context *blkvsc_drv_ctx =
(struct blkvsc_driver_context *)driver_ctx;
struct storvsc_driver_object *storvsc_drv_obj =
@@ -895,7 +895,7 @@ static int blkvsc_submit_request(struct blkvsc_request *blkvsc_req,
storvsc_req->sense_buffer = blkvsc_req->sense_buffer;
storvsc_req->sense_buffer_size = SCSI_SENSE_BUFFERSIZE;
- ret = storvsc_drv_obj->on_io_request(blkdev->device_ctx,
+ ret = storvsc_drv...
2011 Feb 26
1
[PATCH 2/6] Staging: hv: Rename vm_device to hyperv_device
...- struct vm_device *device_ctx;
+ struct hyperv_device *device_ctx;
struct kmem_cache *request_pool;
spinlock_t lock;
struct gendisk *gd;
@@ -249,7 +249,7 @@ static int blkvsc_probe(struct device *device)
(struct blkvsc_driver_context *)driver_ctx;
struct storvsc_driver_object *storvsc_drv_obj =
&blkvsc_drv_ctx->drv_obj;
- struct vm_device *device_obj = device_to_vm_device(device);
+ struct hyperv_device *device_obj = device_to_hyperv_device(device);
struct block_device_context *blkdev = NULL;
struct storvsc_device_info device_info;
@@ -733,7 +733,7 @@ static int blkvsc...
2011 Feb 26
1
[PATCH 2/6] Staging: hv: Rename vm_device to hyperv_device
...- struct vm_device *device_ctx;
+ struct hyperv_device *device_ctx;
struct kmem_cache *request_pool;
spinlock_t lock;
struct gendisk *gd;
@@ -249,7 +249,7 @@ static int blkvsc_probe(struct device *device)
(struct blkvsc_driver_context *)driver_ctx;
struct storvsc_driver_object *storvsc_drv_obj =
&blkvsc_drv_ctx->drv_obj;
- struct vm_device *device_obj = device_to_vm_device(device);
+ struct hyperv_device *device_obj = device_to_hyperv_device(device);
struct block_device_context *blkdev = NULL;
struct storvsc_device_info device_info;
@@ -733,7 +733,7 @@ static int blkvsc...
2011 Feb 26
5
[PATCH 1/6] Staging: hv: Unify hyper-v device abstractions
...;
diff --git a/drivers/staging/hv/blkvsc_drv.c b/drivers/staging/hv/blkvsc_drv.c
index 36a0adb..6d1a783 100644
--- a/drivers/staging/hv/blkvsc_drv.c
+++ b/drivers/staging/hv/blkvsc_drv.c
@@ -183,7 +183,7 @@ static int blkvsc_drv_init(int (*drv_init)(struct hv_driver *drv))
drv_init(&storvsc_drv_obj->base);
drv_ctx->driver.name = storvsc_drv_obj->base.name;
- memcpy(&drv_ctx->class_id, &storvsc_drv_obj->base.dev_type,
+ memcpy(&drv_ctx->class_id, &storvsc_drv_obj->base.class_id,
sizeof(struct hv_guid));
drv_ctx->probe = blkvsc_probe;
@@...
2011 Feb 26
5
[PATCH 1/6] Staging: hv: Unify hyper-v device abstractions
...;
diff --git a/drivers/staging/hv/blkvsc_drv.c b/drivers/staging/hv/blkvsc_drv.c
index 36a0adb..6d1a783 100644
--- a/drivers/staging/hv/blkvsc_drv.c
+++ b/drivers/staging/hv/blkvsc_drv.c
@@ -183,7 +183,7 @@ static int blkvsc_drv_init(int (*drv_init)(struct hv_driver *drv))
drv_init(&storvsc_drv_obj->base);
drv_ctx->driver.name = storvsc_drv_obj->base.name;
- memcpy(&drv_ctx->class_id, &storvsc_drv_obj->base.dev_type,
+ memcpy(&drv_ctx->class_id, &storvsc_drv_obj->base.class_id,
sizeof(struct hv_guid));
drv_ctx->probe = blkvsc_probe;
@@...
2011 Feb 15
3
[PATCH ]:Staging: hv: Allocate the vmbus irq dynamically
...| DEBUG_LVL_ENTEREXIT); */
-static int vmbus_irq = VMBUS_IRQ;
/* Set up per device attributes in /sys/bus/vmbus/devices/<bus device> */
static struct device_attribute vmbus_device_attrs[] = {
@@ -466,7 +482,7 @@ static int vmbus_bus_init(void)
struct hv_driver *driver = &vmbus_drv.drv_obj;
struct vm_device *dev_ctx = &vmbus_drv.device_ctx;
int ret;
- unsigned int vector;
+ unsigned int vector, prev_irq = ~0;
DPRINT_INFO(VMBUS, "+++++++ HV Driver version = %s +++++++",
HV_DRV_VERSION);
@@ -518,19 +534,23 @@ static int vmbus_bus_init(void)
}
/* Get t...
2011 Feb 15
3
[PATCH ]:Staging: hv: Allocate the vmbus irq dynamically
...| DEBUG_LVL_ENTEREXIT); */
-static int vmbus_irq = VMBUS_IRQ;
/* Set up per device attributes in /sys/bus/vmbus/devices/<bus device> */
static struct device_attribute vmbus_device_attrs[] = {
@@ -466,7 +482,7 @@ static int vmbus_bus_init(void)
struct hv_driver *driver = &vmbus_drv.drv_obj;
struct vm_device *dev_ctx = &vmbus_drv.device_ctx;
int ret;
- unsigned int vector;
+ unsigned int vector, prev_irq = ~0;
DPRINT_INFO(VMBUS, "+++++++ HV Driver version = %s +++++++",
HV_DRV_VERSION);
@@ -518,19 +534,23 @@ static int vmbus_bus_init(void)
}
/* Get t...