hptiop: HighPoint RocketRAID 3xxx controller driver
Subsystems (3)
PATCH 31/31 hptiop: HighPoint RocketRAID 3xxx controller driver
From: HighPoint Linux Team <[email protected]>
This driver supports HighPoint RocketRAID 3220/3320 series 8 channel PCI-X SATA RAID Host Adapters. It works as a scsi low-level driver. Implementation details can be found in Documentation/scsi/hptiop.txt.
This driver has been tested on i386/x86_64 platforms.
Signed-off-by HighPoint Linux Team <[email protected]>
Signed-off-by Andrew Morton <[email protected]>
---
Documentation/scsi/hptiop.txt | 92 + MAINTAINERS | 6 drivers/scsi/Kconfig | 10 drivers/scsi/Makefile | 1 drivers/scsi/hptiop.c | 1501 ++++++++++++++++++++++++++++++++ drivers/scsi/hptiop.h | 465 +++++++++ 6 files changed, 2075 insertions(+)
Documentation/scsi/hptiop.txt new file +92 -0
@@ -0,0 +1,92 @@ +HIGHPOINT ROCKETRAID 3xxx RAID DRIVER (hptiop) + +Controller Register Map +------------------------- + +The controller IOP is accessed via PCI BAR0. + + BAR0 offset Register + 0x10 Inbound Message Register 0 + 0x14 Inbound Message Register 1 + 0x18 Outbound Message Register 0 + 0x1C Outbound Message Register 1 + 0x20 Inbound Doorbell Register + 0x24 Inbound Interrupt Status Register + 0x28 Inbound Interrupt Mask Register + 0x30 Outbound Interrupt Status Register + 0x34 Outbound Interrupt Mask Register + 0x40 Inbound Queue Port + 0x44 Outbound Queue Port + + +I/O Request Workflow +---------------------- + +All queued requests are handled via inbound/outbound queue port. +A request packet can be allocated in either IOP or host memory. + +To send a request to the controller: + + - Get a free request packet by reading the inbound queue port or + allocate a free request in host DMA coherent memory. + + The value returned from the inbound queue port is an offset + relative to the IOP BAR0. + + Requests allocated in host memory must be aligned on 32-bytes boundary. + + - Fill the packet. + + - Post the packet to IOP by writing it to inbound queue. For requests + allocated in IOP memory, write the offset to inbound queue port. For + requests allocated in host memory, write (0x80000000|(bus_addr>>5)) + to the inbound queue port. + + - The IOP process the request. When the request is completed, it + will be put into outbound queue. An outbound interrupt will be + generated. + + For requests allocated in IOP memory, the request offset is posted to + outbound queue. + + For requests allocated in host memory, (0x80000000|(bus_addr>>5)) + is posted to the outbound queue. If IOP_REQUEST_FLAG_OUTPUT_CONTEXT + flag is set in the request, the low 32-bit context value will be + posted instead. + + - The host read the outbound queue and complete the request. + + For requests allocated in IOP memory, the host driver free the request + by writing it to the outbound queue. + +Non-queued requests (reset/flush etc) can be sent via inbound message +register 0. An outbound message with the same value indicates the completion +of an inbound message. + + +User-level Interface +--------------------- + +The driver exposes following sysfs attributes: + + NAME R/W Description + driver-version R driver version string + firmware-version R firmware version string + +The driver registers char device "hptiop" to communicate with HighPoint RAID +management software. Its ioctl routine acts as a general binary interface +between the IOP firmware and HighPoint RAID management software. New management +functions can be implemented in application/firmware without modification +in driver code. + + +----------------------------------------------------------------------------- +Copyright (C) 2006 HighPoint Technologies, Inc. All Rights Reserved. + + This file is distributed in the hope that it will be useful, + but WITHOUT ANY WARRANTY; without even the implied warranty of + MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + GNU General Public License for more details. + + [email protected] + http://www.highpoint-tech.com
drivers/scsi/hptiop.c new file +1501 -0
1,501 lines not on this page · raw message
drivers/scsi/hptiop.h new file +465 -0
465 lines not on this page · raw message
drivers/scsi/Kconfig renamed from drivers/scsi/Kconfig~hptiop-highpoint-rocketraid-3xxx-controller-driver +10 -0
@@ -610,6 +610,16 @@ config SCSI_PDC_ADMA If unsure, say N. +config SCSI_HPTIOP + tristate "HighPoint RocketRAID 3xxx Controller support" + depends on SCSI && PCI + help + This option enables support for HighPoint RocketRAID 3xxx + controllers. + + To compile this driver as a module, choose M here; the module + will be called hptiop. If unsure, say N. + config SCSI_SATA_QSTOR tristate "Pacific Digital SATA QStor support" depends on SCSI_SATA && PCI
drivers/scsi/Makefile renamed from drivers/scsi/Makefile~hptiop-highpoint-rocketraid-3xxx-controller-driver +1 -0
@@ -151,6 +151,7 @@ obj-$(CONFIG_SCSI_SATA_NV) += libata.o s obj-$(CONFIG_SCSI_SATA_ULI) += libata.o sata_uli.o obj-$(CONFIG_SCSI_SATA_MV) += libata.o sata_mv.o obj-$(CONFIG_SCSI_PDC_ADMA) += libata.o pdc_adma.o +obj-$(CONFIG_SCSI_HPTIOP) += hptiop.o obj-$(CONFIG_ARM) += arm/
MAINTAINERS renamed from MAINTAINERS~hptiop-highpoint-rocketraid-3xxx-controller-driver +6 -0
@@ -1165,6 +1165,12 @@ L: [email protected] W: http://www.nt.tuwien.ac.at/~kkudielk/Linux/ S: Maintained +HIGHPOINT ROCKETRAID 3xxx RAID DRIVER +P: HighPoint Linux Team +M: [email protected] +W: http://www.highpoint-tech.com +S: Supported + HIPPI P: Jes Sorensen M: [email protected]
_