Displaying 14 results from an estimated 14 matches for "vmbus_irq_vector".
2011 Feb 15
4
[PATCH]: Staging: hv: Allocate the vmbus irq dynamically
...b/drivers/staging/hv/vmbus_drv.c
index 459c707..441ce85 100644
--- a/drivers/staging/hv/vmbus_drv.c
+++ b/drivers/staging/hv/vmbus_drv.c
@@ -36,9 +36,7 @@
#include "vmbus_private.h"
-/* FIXME! We need to do this dynamically for PIC and APIC system */
-#define VMBUS_IRQ 0x5
-#define VMBUS_IRQ_VECTOR IRQ5_VECTOR
+static int vmbus_irq;
/* Main vmbus driver data structure */
struct vmbus_driver_context {
@@ -57,6 +55,27 @@ struct vmbus_driver_context {
struct vm_device device_ctx;
};
+/*
+ * Find an un-used IRQ that the VMBUS can use. If none is available;
+ * return -EBUSY.
+ */
+static...
2011 Feb 15
4
[PATCH]: Staging: hv: Allocate the vmbus irq dynamically
...b/drivers/staging/hv/vmbus_drv.c
index 459c707..441ce85 100644
--- a/drivers/staging/hv/vmbus_drv.c
+++ b/drivers/staging/hv/vmbus_drv.c
@@ -36,9 +36,7 @@
#include "vmbus_private.h"
-/* FIXME! We need to do this dynamically for PIC and APIC system */
-#define VMBUS_IRQ 0x5
-#define VMBUS_IRQ_VECTOR IRQ5_VECTOR
+static int vmbus_irq;
/* Main vmbus driver data structure */
struct vmbus_driver_context {
@@ -57,6 +55,27 @@ struct vmbus_driver_context {
struct vm_device device_ctx;
};
+/*
+ * Find an un-used IRQ that the VMBUS can use. If none is available;
+ * return -EBUSY.
+ */
+static...
2011 Feb 15
3
[PATCH ]:Staging: hv: Allocate the vmbus irq dynamically
...b/drivers/staging/hv/vmbus_drv.c
index 459c707..f279e6a 100644
--- a/drivers/staging/hv/vmbus_drv.c
+++ b/drivers/staging/hv/vmbus_drv.c
@@ -36,9 +36,7 @@
#include "vmbus_private.h"
-/* FIXME! We need to do this dynamically for PIC and APIC system */
-#define VMBUS_IRQ 0x5
-#define VMBUS_IRQ_VECTOR IRQ5_VECTOR
+static int vmbus_irq;
/* Main vmbus driver data structure */
struct vmbus_driver_context {
@@ -57,6 +55,25 @@ struct vmbus_driver_context {
struct vm_device device_ctx;
};
+/*
+ * Find an un-used IRQ that the VMBUS can use. If none is available; return -1.
+ */
+
+static int v...
2011 Feb 15
3
[PATCH ]:Staging: hv: Allocate the vmbus irq dynamically
...b/drivers/staging/hv/vmbus_drv.c
index 459c707..f279e6a 100644
--- a/drivers/staging/hv/vmbus_drv.c
+++ b/drivers/staging/hv/vmbus_drv.c
@@ -36,9 +36,7 @@
#include "vmbus_private.h"
-/* FIXME! We need to do this dynamically for PIC and APIC system */
-#define VMBUS_IRQ 0x5
-#define VMBUS_IRQ_VECTOR IRQ5_VECTOR
+static int vmbus_irq;
/* Main vmbus driver data structure */
struct vmbus_driver_context {
@@ -57,6 +55,25 @@ struct vmbus_driver_context {
struct vm_device device_ctx;
};
+/*
+ * Find an un-used IRQ that the VMBUS can use. If none is available; return -1.
+ */
+
+static int v...
2011 Mar 10
1
[PATCH 10/21] Staging: hv: Cleanup root device handling
...hv/vmbus_drv.c
@@ -19,6 +19,7 @@
* Hank Janssen <hjanssen at microsoft.com>
*/
#include <linux/init.h>
+#include <linux/err.h>
#include <linux/module.h>
#include <linux/device.h>
#include <linux/irq.h>
@@ -40,6 +41,8 @@
#define VMBUS_IRQ 0x5
#define VMBUS_IRQ_VECTOR IRQ5_VECTOR
+static struct device *root_dev; /* Root device */
+
/* Main vmbus driver data structure */
struct vmbus_driver_context {
@@ -47,8 +50,6 @@ struct vmbus_driver_context {
struct tasklet_struct msg_dpc;
struct tasklet_struct event_dpc;
- /* The bus root device */
- struct hv_d...
2011 Mar 10
1
[PATCH 10/21] Staging: hv: Cleanup root device handling
...hv/vmbus_drv.c
@@ -19,6 +19,7 @@
* Hank Janssen <hjanssen at microsoft.com>
*/
#include <linux/init.h>
+#include <linux/err.h>
#include <linux/module.h>
#include <linux/device.h>
#include <linux/irq.h>
@@ -40,6 +41,8 @@
#define VMBUS_IRQ 0x5
#define VMBUS_IRQ_VECTOR IRQ5_VECTOR
+static struct device *root_dev; /* Root device */
+
/* Main vmbus driver data structure */
struct vmbus_driver_context {
@@ -47,8 +50,6 @@ struct vmbus_driver_context {
struct tasklet_struct msg_dpc;
struct tasklet_struct event_dpc;
- /* The bus root device */
- struct hv_d...
2011 Mar 15
16
[PATCH 00/12] Staging: hv: Cleanup vmbus driver - Phase II
This patch-set fixes the following issues in the vmbus driver (vmbus_drv.c):
Make vmbus driver a platform pci device and cleanup
root device management and irq allocation
(patches 1/12 through 3/12):
1) Make vmbus driver a platform pci driver.
2) Cleanup root device management.
3) Leverage the pci model for allocating irq.
General cleanup of vmbus driver (patches 4/12 though 12/12):
1)
2011 Mar 15
16
[PATCH 00/12] Staging: hv: Cleanup vmbus driver - Phase II
This patch-set fixes the following issues in the vmbus driver (vmbus_drv.c):
Make vmbus driver a platform pci device and cleanup
root device management and irq allocation
(patches 1/12 through 3/12):
1) Make vmbus driver a platform pci driver.
2) Cleanup root device management.
3) Leverage the pci model for allocating irq.
General cleanup of vmbus driver (patches 4/12 though 12/12):
1)
2011 Feb 22
4
[PATCH 1/6] Staging: hv: vmbus_drv.c Replaced DPRINT with native pr_XXX
...ERR(VMBUS_DRV, "ERROR - Unable to request IRQ %d",
- vmbus_irq);
+ pr_err("%s: %s ERROR - Unable to request IRQ %d",
+ VMBUS_MOD, __func__, vmbus_irq);
bus_unregister(&vmbus_drv_ctx->bus);
@@ -532,15 +508,15 @@ static int vmbus_bus_init(void)
}
vector = VMBUS_IRQ_VECTOR;
- DPRINT_INFO(VMBUS_DRV, "irq 0x%x vector 0x%x", vmbus_irq, vector);
+ pr_info("%s: irq 0x%x vector 0x%x", VMBUS_MOD, vmbus_irq, vector);
/* Call to bus driver to add the root device */
memset(dev_ctx, 0, sizeof(struct vm_device));
ret = driver->dev_add(&dev_...
2011 Feb 22
4
[PATCH 1/6] Staging: hv: vmbus_drv.c Replaced DPRINT with native pr_XXX
...ERR(VMBUS_DRV, "ERROR - Unable to request IRQ %d",
- vmbus_irq);
+ pr_err("%s: %s ERROR - Unable to request IRQ %d",
+ VMBUS_MOD, __func__, vmbus_irq);
bus_unregister(&vmbus_drv_ctx->bus);
@@ -532,15 +508,15 @@ static int vmbus_bus_init(void)
}
vector = VMBUS_IRQ_VECTOR;
- DPRINT_INFO(VMBUS_DRV, "irq 0x%x vector 0x%x", vmbus_irq, vector);
+ pr_info("%s: irq 0x%x vector 0x%x", VMBUS_MOD, vmbus_irq, vector);
/* Call to bus driver to add the root device */
memset(dev_ctx, 0, sizeof(struct vm_device));
ret = driver->dev_add(&dev_...
2011 Feb 26
1
[PATCH 5/6] Staging: hv: Rename driver_context to hyperv_driver
...river_context;
+struct hyperv_driver;
struct hyperv_device;
struct hv_dev_port_info {
diff --git a/drivers/staging/hv/vmbus_drv.c b/drivers/staging/hv/vmbus_drv.c
index 3922a07..c7e8a36 100644
--- a/drivers/staging/hv/vmbus_drv.c
+++ b/drivers/staging/hv/vmbus_drv.c
@@ -41,13 +41,13 @@
#define VMBUS_IRQ_VECTOR IRQ5_VECTOR
/* Main vmbus driver data structure */
-struct vmbus_driver_context {
+struct vmbus_hyperv_driver {
/* !! These must be the first 2 fields !! */
/* FIXME, this is a bug */
/* The driver field is not used in here. Instead, the bus field is */
/* used to represent the driver */...
2011 Feb 26
1
[PATCH 5/6] Staging: hv: Rename driver_context to hyperv_driver
...river_context;
+struct hyperv_driver;
struct hyperv_device;
struct hv_dev_port_info {
diff --git a/drivers/staging/hv/vmbus_drv.c b/drivers/staging/hv/vmbus_drv.c
index 3922a07..c7e8a36 100644
--- a/drivers/staging/hv/vmbus_drv.c
+++ b/drivers/staging/hv/vmbus_drv.c
@@ -41,13 +41,13 @@
#define VMBUS_IRQ_VECTOR IRQ5_VECTOR
/* Main vmbus driver data structure */
-struct vmbus_driver_context {
+struct vmbus_hyperv_driver {
/* !! These must be the first 2 fields !! */
/* FIXME, this is a bug */
/* The driver field is not used in here. Instead, the bus field is */
/* used to represent the driver */...
2011 Feb 24
4
[PATCH ] Staging: hv: Hyper-V driver cleanup
...nnel *channel;
-
- /* Device extension; */
- void *ext;
-};
-
#endif /* _VMBUS_API_H_ */
diff --git a/drivers/staging/hv/vmbus_drv.c b/drivers/staging/hv/vmbus_drv.c
index 459c707..81e958a 100644
--- a/drivers/staging/hv/vmbus_drv.c
+++ b/drivers/staging/hv/vmbus_drv.c
@@ -41,20 +41,19 @@
#define VMBUS_IRQ_VECTOR IRQ5_VECTOR
/* Main vmbus driver data structure */
-struct vmbus_driver_context {
+struct vmbus_hyperv_driver {
/* !! These must be the first 2 fields !! */
/* FIXME, this is a bug */
/* The driver field is not used in here. Instead, the bus field is */
/* used to represent the driver */...
2011 Feb 24
4
[PATCH ] Staging: hv: Hyper-V driver cleanup
...nnel *channel;
-
- /* Device extension; */
- void *ext;
-};
-
#endif /* _VMBUS_API_H_ */
diff --git a/drivers/staging/hv/vmbus_drv.c b/drivers/staging/hv/vmbus_drv.c
index 459c707..81e958a 100644
--- a/drivers/staging/hv/vmbus_drv.c
+++ b/drivers/staging/hv/vmbus_drv.c
@@ -41,20 +41,19 @@
#define VMBUS_IRQ_VECTOR IRQ5_VECTOR
/* Main vmbus driver data structure */
-struct vmbus_driver_context {
+struct vmbus_hyperv_driver {
/* !! These must be the first 2 fields !! */
/* FIXME, this is a bug */
/* The driver field is not used in here. Instead, the bus field is */
/* used to represent the driver */...