aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/block/cciss.h
diff options
context:
space:
mode:
authorMike Miller <mike.miller@hp.com>2006-01-08 04:03:50 -0500
committerLinus Torvalds <torvalds@g5.osdl.org>2006-01-08 23:14:00 -0500
commitfb86a35b9ded8a7e53a432cbf28df603cdd4849c (patch)
tree6cfc9de386c26f5b1c9a126aee2bdc8f80bc8e2b /drivers/block/cciss.h
parentd09cf7d77f62f6fb2f6d63fe5980583805f2d559 (diff)
[PATCH] cciss: adds MSI and MSI-X support
This creates a new function, cciss_interrupt_mode called from cciss_pci_init. This function determines what type of interrupt vector to use, i.e., MSI, MSI-X, or IO-APIC. One noticeable difference is changing the interrupt field of the controller struct to an array of 4 unsigned ints. The Smart Array HW is capable of generating 4 distinct interrupts depending on the transport method in use during operation. These are: #define DOORBELL_INT 0 Used to notify the contoller of configuration updates. We only use this feature when in polling mode. #define PERF_MODE_INT 0 Used when the controller is in Performant Mode. #define SIMPLE_MODE_INT 2 Used when the controller is in Simple Mode (current Linux implementation). #define MEMQ_INT_MODE 3 Not used. When using IO-APIC interrupts these 4 lines are OR'ed together so when any one fires an interrupt an is generated. In MSI or MSI-X mode this hardware OR'ing is ignored. We must register for our interrupt depending on what mode the controller is running. For Linux we use SIMPLE_MODE_INT exclusively at this time. Please consider this for inclusion. Signed-off-by: Mike Miller <mike.miller@hp.com> Cc: Jens Axboe <axboe@suse.de> Signed-off-by: Andrew Morton <akpm@osdl.org> Signed-off-by: Linus Torvalds <torvalds@osdl.org>
Diffstat (limited to 'drivers/block/cciss.h')
-rw-r--r--drivers/block/cciss.h8
1 files changed, 7 insertions, 1 deletions
diff --git a/drivers/block/cciss.h b/drivers/block/cciss.h
index 3b0858c83897..ad45e581a91d 100644
--- a/drivers/block/cciss.h
+++ b/drivers/block/cciss.h
@@ -65,7 +65,6 @@ struct ctlr_info
65 unsigned long io_mem_addr; 65 unsigned long io_mem_addr;
66 unsigned long io_mem_length; 66 unsigned long io_mem_length;
67 CfgTable_struct __iomem *cfgtable; 67 CfgTable_struct __iomem *cfgtable;
68 unsigned int intr;
69 int interrupts_enabled; 68 int interrupts_enabled;
70 int major; 69 int major;
71 int max_commands; 70 int max_commands;
@@ -74,6 +73,13 @@ struct ctlr_info
74 int num_luns; 73 int num_luns;
75 int highest_lun; 74 int highest_lun;
76 int usage_count; /* number of opens all all minor devices */ 75 int usage_count; /* number of opens all all minor devices */
76# define DOORBELL_INT 0
77# define PERF_MODE_INT 1
78# define SIMPLE_MODE_INT 2
79# define MEMQ_MODE_INT 3
80 unsigned int intr[4];
81 unsigned int msix_vector;
82 unsigned int msi_vector;
77 83
78 // information about each logical volume 84 // information about each logical volume
79 drive_info_struct drv[CISS_MAX_LUN]; 85 drive_info_struct drv[CISS_MAX_LUN];