From d38d9c9e5ec4c6387ee8a555753ecbd64ea35c13 Mon Sep 17 00:00:00 2001 From: Scott Long Date: Wed, 2 Mar 2005 05:14:28 +0000 Subject: [PATCH] Move all of the hptmv files to /sys/dev/hptmv so that they won't be mistaken for being on a CVS vendor branch. The files were moved via a repo-copy. --- sys/conf/files.i386 | 10 +- sys/contrib/dev/hptmv/access601.h | 41 - sys/contrib/dev/hptmv/array.h | 265 ----- sys/contrib/dev/hptmv/atapi.h | 556 --------- sys/contrib/dev/hptmv/command.h | 265 ----- sys/contrib/dev/hptmv/gui_lib.c | 1384 ---------------------- sys/contrib/dev/hptmv/hptproc.c | 600 ---------- sys/contrib/dev/hptmv/i386-elf.raid.o.uu | 1346 --------------------- sys/contrib/dev/hptmv/ioctl.c | 928 --------------- sys/contrib/dev/hptmv/mvSata.h | 429 ------- sys/contrib/dev/hptmv/mvStorageDev.h | 210 ---- sys/contrib/dev/hptmv/raid5n.h | 120 -- sys/contrib/dev/hptmv/readme.txt | 96 -- sys/contrib/dev/hptmv/vdevice.h | 280 ----- sys/dev/hptmv/access601.h | 2 + sys/dev/hptmv/array.h | 2 + sys/dev/hptmv/atapi.h | 2 + sys/dev/hptmv/command.h | 2 + sys/dev/hptmv/gui_lib.c | 2 + sys/dev/hptmv/hptproc.c | 2 + sys/dev/hptmv/ioctl.c | 2 + sys/dev/hptmv/mvSata.h | 2 + sys/dev/hptmv/mvStorageDev.h | 4 +- sys/dev/hptmv/raid5n.h | 2 + sys/dev/hptmv/readme.txt | 1 + sys/dev/hptmv/vdevice.h | 2 + sys/modules/hptmv/Makefile | 4 +- 27 files changed, 31 insertions(+), 6528 deletions(-) delete mode 100644 sys/contrib/dev/hptmv/access601.h delete mode 100644 sys/contrib/dev/hptmv/array.h delete mode 100644 sys/contrib/dev/hptmv/atapi.h delete mode 100644 sys/contrib/dev/hptmv/command.h delete mode 100644 sys/contrib/dev/hptmv/gui_lib.c delete mode 100644 sys/contrib/dev/hptmv/hptproc.c delete mode 100644 sys/contrib/dev/hptmv/i386-elf.raid.o.uu delete mode 100644 sys/contrib/dev/hptmv/ioctl.c delete mode 100644 sys/contrib/dev/hptmv/mvSata.h delete mode 100644 sys/contrib/dev/hptmv/mvStorageDev.h delete mode 100644 sys/contrib/dev/hptmv/raid5n.h delete mode 100644 sys/contrib/dev/hptmv/readme.txt delete mode 100644 sys/contrib/dev/hptmv/vdevice.h diff --git a/sys/conf/files.i386 b/sys/conf/files.i386 index 18680feebfc6..edaaba8f7e2a 100644 --- a/sys/conf/files.i386 +++ b/sys/conf/files.i386 @@ -62,8 +62,8 @@ opt_ah.h optional ath_hal \ clean "opt_ah.h" # hptmvraid.o optional hptmv \ - dependency "$S/contrib/dev/hptmv/i386-elf.raid.o.uu" \ - compile-with "uudecode < $S/contrib/dev/hptmv/i386-elf.raid.o.uu" \ + dependency "$S/dev/hptmv/i386-elf.raid.o.uu" \ + compile-with "uudecode < $S/dev/hptmv/i386-elf.raid.o.uu" \ no-implicit-rule # # @@ -104,9 +104,6 @@ compat/svr4/svr4_sysent.c optional compat_svr4 compat/svr4/svr4_sysvec.c optional compat_svr4 compat/svr4/svr4_termios.c optional compat_svr4 compat/svr4/svr4_ttold.c optional compat_svr4 -contrib/dev/hptmv/gui_lib.c optional hptmv -contrib/dev/hptmv/hptproc.c optional hptmv -contrib/dev/hptmv/ioctl.c optional hptmv contrib/dev/oltr/if_oltr.c optional oltr contrib/dev/oltr/if_oltr_isa.c optional oltr isa contrib/dev/oltr/if_oltr_pci.c optional oltr pci @@ -160,6 +157,9 @@ dev/fdc/fdc_pccard.c optional fdc pccard dev/fe/if_fe_isa.c optional fe isa dev/hptmv/entry.c optional hptmv dev/hptmv/mv.c optional hptmv +dev/hptmv/gui_lib.c optional hptmv +dev/hptmv/hptproc.c optional hptmv +dev/hptmv/ioctl.c optional hptmv dev/ichwd/ichwd.c optional ichwd dev/if_ndis/if_ndis.c optional ndis dev/if_ndis/if_ndis_pccard.c optional ndis pccard diff --git a/sys/contrib/dev/hptmv/access601.h b/sys/contrib/dev/hptmv/access601.h deleted file mode 100644 index 54e1902b687d..000000000000 --- a/sys/contrib/dev/hptmv/access601.h +++ /dev/null @@ -1,41 +0,0 @@ -/* - * Copyright (c) 2003-2004 HighPoint Technologies, Inc. - * All rights reserved. - * - * Redistribution and use in source and binary forms, with or without - * modification, are permitted provided that the following conditions - * are met: - * 1. Redistributions of source code must retain the above copyright - * notice, this list of conditions and the following disclaimer. - * 2. Redistributions in binary form must reproduce the above copyright - * notice, this list of conditions and the following disclaimer in the - * documentation and/or other materials provided with the distribution. - * - * THIS SOFTWARE IS PROVIDED BY THE AUTHOR AND CONTRIBUTORS ``AS IS'' AND - * ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE - * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE - * ARE DISCLAIMED. IN NO EVENT SHALL THE AUTHOR OR CONTRIBUTORS BE LIABLE - * FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL - * DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS - * OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) - * HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT - * LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY - * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF - * SUCH DAMAGE. - */ -#ifndef _ACCESS601_H_ -#define _ACCESS601_H_ - -void HPTLIBAPI BeepOn(MV_BUS_ADDR_T BaseAddr); -void HPTLIBAPI BeepOff(MV_BUS_ADDR_T BaseAddr); -UCHAR HPTLIBAPI check_protect_circuit(MV_BUS_ADDR_T BaseAddr); - -#ifdef SUPPORT_FAIL_LED -void HPTLIBAPI set_fail_led(MV_SATA_ADAPTER *pAdapter, UCHAR channel, UCHAR state); -void HPTLIBAPI set_fail_leds(MV_SATA_ADAPTER *pAdapter, UCHAR mask); -#else -#define set_fail_led(pAdapter, channel, state) -#define set_fail_leds(pAdapter, mask) -#endif - -#endif diff --git a/sys/contrib/dev/hptmv/array.h b/sys/contrib/dev/hptmv/array.h deleted file mode 100644 index 29e0a9bbd3f2..000000000000 --- a/sys/contrib/dev/hptmv/array.h +++ /dev/null @@ -1,265 +0,0 @@ -/* - * Copyright (c) 2003-2004 HighPoint Technologies, Inc. - * All rights reserved. - * - * Redistribution and use in source and binary forms, with or without - * modification, are permitted provided that the following conditions - * are met: - * 1. Redistributions of source code must retain the above copyright - * notice, this list of conditions and the following disclaimer. - * 2. Redistributions in binary form must reproduce the above copyright - * notice, this list of conditions and the following disclaimer in the - * documentation and/or other materials provided with the distribution. - * - * THIS SOFTWARE IS PROVIDED BY THE AUTHOR AND CONTRIBUTORS ``AS IS'' AND - * ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE - * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE - * ARE DISCLAIMED. IN NO EVENT SHALL THE AUTHOR OR CONTRIBUTORS BE LIABLE - * FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL - * DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS - * OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) - * HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT - * LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY - * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF - * SUCH DAMAGE. - */ - -#ifndef _ARRAY_H_ -#define _ARRAY_H_ - -/* - * time represented in DWORD format - */ -#pragma pack(1) -#ifdef __BIG_ENDIAN_BITFIELD -typedef DWORD TIME_RECORD; -#else -typedef struct _TIME_RECORD { - UINT seconds:6; /* 0 - 59 */ - UINT minutes:6; /* 0 - 59 */ - UINT month:4; /* 1 - 12 */ - UINT hours:6; /* 0 - 59 */ - UINT day:5; /* 1 - 31 */ - UINT year:5; /* 0=2000, 31=2031 */ -} TIME_RECORD; -#endif -#pragma pack() - -/*************************************************************************** - * Description: Virtual Device Table - ***************************************************************************/ - -typedef struct _RaidArray -{ - /* - * basic information - */ - UCHAR bArnMember; /* the number of members in array */ - UCHAR bArRealnMember; /* real member count */ - UCHAR bArBlockSizeShift; /* the number of shift bit for a block */ - UCHAR reserve1; - - ULONG dArStamp; /* array ID. all disks in a array has same ID */ - USHORT bStripeWitch; /* = (1 << BlockSizeShift) */ - - USHORT rf_broken: 1; - USHORT rf_need_rebuild: 1; /* one member's data are incorrect. - for R5, if CriticalMembers==0, it means - parity needs to be constructed */ - USHORT rf_need_sync: 1; /* need write array info to disk */ - /* ioctl flags */ - USHORT rf_auto_rebuild: 1; - USHORT rf_newly_created: 1; - USHORT rf_rebuilding: 1; - USHORT rf_verifying: 1; - USHORT rf_initializing: 1; - USHORT rf_abort_rebuild: 1; - USHORT rf_duplicate_and_create: 1; - USHORT rf_duplicate_and_created: 1; - USHORT rf_duplicate_must_done: 1; - USHORT rf_raid15: 1; - - USHORT CriticalMembers; /* tell which member is critial */ - UCHAR last_read; /* for RAID 1 load banlancing */ - UCHAR pad1; - - LBA_T RebuildSectors; /* how many sectors is OK (LBA on member disk) */ - - PVDevice pMember[MAX_MEMBERS]; - /* - * utility working data - */ - UCHAR ArrayName[MAX_ARRAY_NAME]; /* The Name of the array */ - TIME_RECORD CreateTime; /* when created it */ - UCHAR Description[64]; /* array description */ - UCHAR CreateManager[16]; /* who created it */ -} RaidArray; - -/*************************************************************************** - * Array Descripton on disk - ***************************************************************************/ -#pragma pack(1) -typedef struct _ArrayDescript -{ - ULONG Signature; /* This block is vaild array info block */ - ULONG dArStamp; /* array ID. all disks in a array has same ID */ - - UCHAR bCheckSum; /* check sum of ArrayDescript_3_0_size bytes */ - -#ifdef __BIG_ENDIAN_BITFIELD - UCHAR df_reservedbits: 6; /* put more flags here */ - UCHAR df_user_mode_set: 1;/* user select device mode */ - UCHAR df_bootmark:1; /* user set boot mark on the disk */ -#else - UCHAR df_bootmark:1; /* user set boot mark on the disk */ - UCHAR df_user_mode_set: 1;/* user select device mode */ - UCHAR df_reservedbits: 6; /* put more flags here */ -#endif - - UCHAR bUserDeviceMode; /* see device.h */ - UCHAR ArrayLevel; /* how many level[] is valid */ - - struct { - ULONG Capacity; /* capacity for the array */ - - UCHAR VDeviceType; /* see above & arrayType in array.h */ - UCHAR bMemberCount; /* all disk in the array */ - UCHAR bSerialNumber; /* Serial Number */ - UCHAR bArBlockSizeShift; /* the number of shift bit for a block */ - -#ifdef __BIG_ENDIAN_BITFIELD - USHORT rf_reserved: 14; - USHORT rf_raid15: 1; /* don't remove even you don't use it */ - USHORT rf_need_rebuild:1; /* array is critical */ -#else - USHORT rf_need_rebuild:1; /* array is critical */ - USHORT rf_raid15: 1; /* don't remove even you don't use it */ - USHORT rf_reserved: 14; -#endif - USHORT CriticalMembers; /* record critical members */ - ULONG RebuildSectors; /* how many sectors is OK (LBA on member disk) */ - } level[2]; - - UCHAR ArrayName[MAX_ARRAY_NAME]; /* The Name of the array */ - TIME_RECORD CreateTime; /* when created it */ - UCHAR Description[64]; /* array description */ - UCHAR CreateManager[16]; /* who created it */ - -#define ArrayDescript_3_0_size ((unsigned)(ULONG_PTR)&((struct _ArrayDescript *)0)->bCheckSum31) -#define ArrayDescript_3_1_size 512 - - UCHAR bCheckSum31; /* new check sum */ - UCHAR reserve2[2]; -#ifdef __BIG_ENDIAN_BITFIELD - UCHAR df_read_ahead: 1; /* enable read ahead */ - UCHAR df_read_ahead_set: 1; - UCHAR df_write_cache: 1; /* enable write cache */ - UCHAR df_write_cache_set: 1; - UCHAR df_ncq: 1; /* enable NCQ */ - UCHAR df_ncq_set: 1; - UCHAR df_tcq: 1; /* enable TCQ */ - UCHAR df_tcq_set: 1; -#else - UCHAR df_tcq_set: 1; - UCHAR df_tcq: 1; /* enable TCQ */ - UCHAR df_ncq_set: 1; - UCHAR df_ncq: 1; /* enable NCQ */ - UCHAR df_write_cache_set: 1; - UCHAR df_write_cache: 1; /* enable write cache */ - UCHAR df_read_ahead_set: 1; - UCHAR df_read_ahead: 1; /* enable read ahead */ -#endif - - struct { - ULONG CapacityHi32; - ULONG RebuildSectorsHi32; - } - levelex[2]; - -} ArrayDescript; - -#pragma pack() - -/* Signature */ -#define HPT_ARRAY_V3 0x5a7816f3 -#ifdef ARRAY_V2_ONLY -#define SAVE_FOR_RAID_INFO 0 -#else -#define SAVE_FOR_RAID_INFO 10 -#endif - -/*************************************************************************** - * Function protocol for array layer - ***************************************************************************/ - -/* - * array.c - */ -ULONG FASTCALL GetStamp(void); -void HPTLIBAPI SyncArrayInfo(PVDevice pVDev); -void HPTLIBAPI fDeleteArray(_VBUS_ARG PVDevice pVArray, BOOLEAN del_block0); - -/* - * iArray.c - */ -void HPTLIBAPI fCheckArray(PDevice pDevice); -void HPTLIBAPI CheckArrayCritical(_VBUS_ARG0); -PVDevice HPTLIBAPI GetSpareDisk(_VBUS_ARG PVDevice pArray); -#ifdef SUPPORT_OLD_ARRAY -void HPTLIBAPI fFixRAID01Stripe(_VBUS_ARG PVDevice pStripe); -#endif - -/*************************************************************************** - * Macro defination - ***************************************************************************/ -#ifndef MAX_ARRAY_PER_VBUS -#define MAX_ARRAY_PER_VBUS (MAX_VDEVICE_PER_VBUS*2) /* worst case */ -#endif - - -#if defined(MAX_ARRAY_DEVICE) -#if MAX_ARRAY_DEVICE!=MAX_ARRAY_PER_VBUS -#error "remove MAX_ARRAY_DEVICE and use MAX_ARRAY_PER_VBUS instead" -#endif -#endif - -#define _SET_ARRAY_BUS_(pArray) pArray->pVBus = _vbus_p; - -#ifdef ARRAY_V2_ONLY -#define _SET_ARRAY_VER_(pArray) pArray->vf_format_v2 = 1; -#else -#define _SET_ARRAY_VER_(pArray) -#endif - -#define mArGetArrayTable(pVArray) \ - if((pVArray = _vbus_(pFreeArrayLink)) != 0) { \ - _vbus_(pFreeArrayLink) = (PVDevice)_vbus_(pFreeArrayLink)->pVBus; \ - ZeroMemory(pVArray, ARRAY_VDEV_SIZE); \ - _SET_ARRAY_BUS_(pVArray) \ - _SET_ARRAY_VER_(pVArray) \ - } else - -#define mArFreeArrayTable(pVArray) \ - do { \ - pVArray->pVBus = (PVBus)_vbus_(pFreeArrayLink);\ - _vbus_(pFreeArrayLink) = pVArray; \ - pVArray->u.array.dArStamp = 0; \ - } while(0) - -UCHAR CheckSum(UCHAR *p, int size); - -void HPTLIBAPI fRAID0SendCommand(_VBUS_ARG PCommand pCmd); -void HPTLIBAPI fRAID1SendCommand(_VBUS_ARG PCommand pCmd); -void HPTLIBAPI fJBODSendCommand(_VBUS_ARG PCommand pCmd); -void HPTLIBAPI fRAID0MemberFailed(_VBUS_ARG PVDevice pVDev); -void HPTLIBAPI fRAID1MemberFailed(_VBUS_ARG PVDevice pVDev); -void HPTLIBAPI fJBODMemberFailed(_VBUS_ARG PVDevice pVDev); -#if SUPPORT_RAID5 -void HPTLIBAPI fRAID5SendCommand(_VBUS_ARG PCommand pCmd); -void HPTLIBAPI fRAID5MemberFailed(_VBUS_ARG PVDevice pVDev); -#else -#define fRAID5SendCommand 0 -#define fRAID5MemberFailed 0 -#endif - -#endif diff --git a/sys/contrib/dev/hptmv/atapi.h b/sys/contrib/dev/hptmv/atapi.h deleted file mode 100644 index a46c1148c9ce..000000000000 --- a/sys/contrib/dev/hptmv/atapi.h +++ /dev/null @@ -1,556 +0,0 @@ -/* - * Copyright (c) 2003-2004 HighPoint Technologies, Inc. - * All rights reserved. - * - * Redistribution and use in source and binary forms, with or without - * modification, are permitted provided that the following conditions - * are met: - * 1. Redistributions of source code must retain the above copyright - * notice, this list of conditions and the following disclaimer. - * 2. Redistributions in binary form must reproduce the above copyright - * notice, this list of conditions and the following disclaimer in the - * documentation and/or other materials provided with the distribution. - * - * THIS SOFTWARE IS PROVIDED BY THE AUTHOR AND CONTRIBUTORS ``AS IS'' AND - * ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE - * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE - * ARE DISCLAIMED. IN NO EVENT SHALL THE AUTHOR OR CONTRIBUTORS BE LIABLE - * FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL - * DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS - * OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) - * HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT - * LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY - * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF - * SUCH DAMAGE. - */ - -#ifndef _ATAPI_H_ -#define _ATAPI_H_ - -#pragma pack(1) - -/*************************************************************************** - * IDE IO Register File - ***************************************************************************/ - -/* - * IDE IO Port definition - */ -typedef struct _IDE_REGISTERS_1 { - USHORT Data; /* RW: Data port feature register */ - UCHAR BlockCount; /* RW: Sector count */ - UCHAR BlockNumber; /* RW: Sector number & LBA 0-7 */ - UCHAR CylinderLow; /* RW: Cylinder low & LBA 8-15 */ - UCHAR CylinderHigh; /* RW: Cylinder hign & LBA 16-23 */ - UCHAR DriveSelect; /* RW: Drive/head & LBA 24-27 */ - UCHAR Command; /* RO: Status WR:Command */ -} IDE_REGISTERS_1, *PIDE_REGISTERS_1; - - -/* - * IDE status definitions - */ -#define IDE_STATUS_ERROR 0x01 /* Error Occurred in Execution */ -#define IDE_STATUS_INDEX 0x02 /* is vendor specific */ -#define IDE_STATUS_CORRECTED_ERROR 0x04 /* Corrected Data */ -#define IDE_STATUS_DRQ 0x08 /* Ready to transfer data */ -#define IDE_STATUS_DSC 0x10 /* not defined in ATA-2 */ -#define IDE_STATUS_DWF 0x20 /* Device Fault has been detected */ -#define IDE_STATUS_DRDY 0x40 /* Device Ready to accept command */ -#define IDE_STATUS_IDLE 0x50 /* Device is OK */ -#define IDE_STATUS_BUSY 0x80 /* Device Busy, must wait */ - - -#define IDE_ERROR_BAD_BLOCK 0x80 /* Reserved now */ -#define IDE_ERROR_DATA_ERROR 0x40 /* Uncorreectable Data Error */ -#define IDE_ERROR_MEDIA_CHANGE 0x20 /* Media Changed */ -#define IDE_ERROR_ID_NOT_FOUND 0x10 /* ID Not Found */ -#define IDE_ERROR_MEDIA_CHANGE_REQ 0x08 /* Media Change Requested */ -#define IDE_ERROR_COMMAND_ABORTED 0x04 /* Aborted Command */ -#define IDE_ERROR_TRACK0_NOT_FOUND 0x02 /* Track 0 Not Found */ -#define IDE_ERROR_ADDRESS_NOT_FOUND 0x01 /* Address Mark Not Found */ - - -#define LBA_MODE 0x40 - -/* - * IDE command definitions - */ - -#define IDE_COMMAND_RECALIBRATE 0x10 /* Recalibrate */ -#define IDE_COMMAND_READ 0x20 /* Read Sectors with retry */ -#define IDE_COMMAND_WRITE 0x30 /* Write Sectors with retry */ -#define IDE_COMMAND_VERIFY 0x40 /* Read Verify Sectors with Retry */ -#define IDE_COMMAND_SEEK 0x70 /* Seek */ -#define IDE_COMMAND_SET_DRIVE_PARAMETER 0x91 /* Initialize Device Parmeters */ -#define IDE_COMMAND_GET_MEDIA_STATUS 0xDA -#define IDE_COMMAND_DOOR_LOCK 0xDE /* Door Lock */ -#define IDE_COMMAND_DOOR_UNLOCK 0xDF /* Door Unlock */ -#define IDE_COMMAND_ENABLE_MEDIA_STATUS 0xEF /* Set Features */ -#define IDE_COMMAND_IDENTIFY 0xEC /* Identify Device */ -#define IDE_COMMAND_MEDIA_EJECT 0xED -#define IDE_COMMAND_SET_FEATURES 0xEF /* IDE set features command */ - -#define IDE_COMMAND_FLUSH_CACHE 0xE7 -#define IDE_COMMAND_STANDBY_IMMEDIATE 0xE0 - -#ifndef NOT_SUPPORT_MULTIPLE -#define IDE_COMMAND_READ_MULTIPLE 0xC4 /* Read Multiple */ -#define IDE_COMMAND_WRITE_MULTIPLE 0xC5 /* Write Multiple */ -#define IDE_COMMAND_SET_MULTIPLE 0xC6 /* Set Multiple Mode */ -#endif - -#ifndef NOT_SUPPORT_DMA -#define IDE_COMMAND_DMA_READ 0xc8 /* IDE DMA read command */ -#define IDE_COMMAND_DMA_WRITE 0xca /* IDE DMA write command */ -#endif - -#define IDE_COMMAND_READ_DMA_QUEUE 0xc7 /* IDE read DMA queue command */ -#define IDE_COMMAND_WRITE_DMA_QUEUE 0xcc /* IDE write DMA queue command */ -#define IDE_COMMAND_SERVICE 0xA2 /* IDE service command command */ -#define IDE_COMMAND_NOP 0x00 /* IDE NOP command */ -#define IDE_STATUS_SRV 0x10 -#define IDE_RELEASE_BUS 4 - -/*#define IDE_COMMAND_FLUSH_CACHE_EXT */ -#define IDE_COMMAND_READ_DMA_EXT 0x25 -#define IDE_COMMAND_READ_QUEUE_EXT 0x26 -#define IDE_COMMAND_READ_MULTIPLE_EXT 0x29 -#define IDE_COMMAND_READ_MAX_ADDR 0x27 -#define IDE_COMMAND_READ_EXT 0x24 -#define IDE_COMMAND_VERIFY_EXT 0x42 -#define IDE_COMMAND_SET_MULTIPLE_EXT 0x37 -#define IDE_COMMAND_WRITE_DMA_EXT 0x35 -#define IDE_COMMAND_WRITE_QUEUE_EXT 0x36 -#define IDE_COMMAND_WRITE_EXT 0x34 -#define IDE_COMMAND_WRITE_MULTIPLE_EXT 0x39 - -/* - * IDE_COMMAND_SET_FEATURES - */ -#define FT_USE_ULTRA 0x40 /* Set feature for Ultra DMA */ -#define FT_USE_MWDMA 0x20 /* Set feature for MW DMA */ -#define FT_USE_SWDMA 0x10 /* Set feature for SW DMA */ -#define FT_USE_PIO 0x8 /* Set feature for PIO */ -#define FT_DISABLE_IORDY 0x10 /* Set feature for disabling IORDY */ - -/* - * S.M.A.R.T. commands - */ -#define IDE_COMMAND_SMART 0xB0 -#define SMART_READ_VALUES 0xd0 -#define SMART_READ_THRESHOLDS 0xd1 -#define SMART_AUTOSAVE 0xd2 -#define SMART_SAVE 0xd3 -#define SMART_IMMEDIATE_OFFLINE 0xd4 -#define SMART_READ_LOG_SECTOR 0xd5 -#define SMART_WRITE_LOG_SECTOR 0xd6 -#define SMART_ENABLE 0xd8 -#define SMART_DISABLE 0xd9 -#define SMART_STATUS 0xda -#define SMART_AUTO_OFFLINE 0xdb - - /*************************************************************************** - * IDE Control Register File - ***************************************************************************/ - -typedef struct _IDE_REGISTERS_2 { - UCHAR AlternateStatus; /* RW: device control port */ -} IDE_REGISTERS_2, *PIDE_REGISTERS_2; - - -/* - * IDE drive control definitions - */ -#define IDE_DC_DISABLE_INTERRUPTS 0x02 -#define IDE_DC_RESET_CONTROLLER 0x04 -#define IDE_DC_REENABLE_CONTROLLER 0x00 - -/*************************************************************************** - * MSNS: Removable device - ***************************************************************************/ -/* - * Media syatus - */ -#define MSNS_NO_MEDIA 2 -#define MSNS_MEDIA_CHANGE_REQUEST 8 -#define MSNS_MIDIA_CHANGE 0x20 -#define MSNS_WRITE_PROTECT 0x40 -#define MSNS_READ_PROTECT 0x80 - -/*************************************************************************** - * ATAPI IO Register File - ***************************************************************************/ - -/* - * ATAPI register definition - */ - -typedef struct _ATAPI_REGISTERS_1 { - USHORT Data; - UCHAR InterruptReason; /* Atapi Phase Port */ - UCHAR Unused1; - UCHAR ByteCountLow; /* Byte Count LSB */ - UCHAR ByteCountHigh; /* Byte Count MSB */ - UCHAR DriveSelect; - UCHAR Command; -} ATAPI_REGISTERS_1, *PATAPI_REGISTERS_1; - -/* - * Atapi Error Status - */ -#define IDE_ERROR_END_OF_MEDIA IDE_ERROR_TRACK0_NOT_FOUND -#define IDE_ERROR_ILLEGAL_LENGTH IDE_ERROR_ADDRESS_NOT_FOUND - -/* - * ATAPI interrupt reasons - */ -#define ATAPI_IR_COD 0x01 -#define ATAPI_IR_IO 0x02 - -/* sense key */ -#define ATAPI_SENSE_NO_SENSE 0x00 -#define ATAPI_SENSE_RECOVERED_ERROR 0x01 -#define ATAPI_SENSE_NOT_READY 0x02 -#define ATAPI_SENSE_MEDIUM_ERROR 0x03 -#define ATAPI_SENSE_HARDWARE_ERROR 0x04 -#define ATAPI_SENSE_ILLEGAL_REQUEST 0x05 -#define ATAPI_SENSE_UNIT_ATTENTION 0x06 -#define ATAPI_SENSE_DATA_PROTECT 0x07 -#define ATAPI_SENSE_BLANK_CHECK 0x08 -#define ATAPI_SENSE_UNIQUE 0x09 -#define ATAPI_SENSE_COPY_ABORTED 0x0A -#define ATAPI_SENSE_ABORTED_COMMAND 0x0B -#define ATAPI_SENSE_EQUAL 0x0C -#define ATAPI_SENSE_VOL_OVERFLOW 0x0D -#define ATAPI_SENSE_MISCOMPARE 0x0E -#define ATAPI_SENSE_RESERVED 0x0F - -/* Additional Sense codes */ -#define ATAPI_ASC_NO_SENSE 0x00 -#define ATAPI_ASC_LUN_NOT_READY 0x04 -#define ATAPI_ASC_TRACK_ERROR 0x14 -#define ATAPI_ASC_SEEK_ERROR 0x15 -#define ATAPI_ASC_REC_DATA_NOECC 0x17 -#define ATAPI_ASC_REC_DATA_ECC 0x18 -#define ATAPI_ASC_ILLEGAL_COMMAND 0x20 -#define ATAPI_ASC_ILLEGAL_BLOCK 0x21 -#define ATAPI_ASC_INVALID_CDB 0x24 -#define ATAPI_ASC_INVALID_LUN 0x25 -#define ATAPI_ASC_PROTECT 0x27 -#define ATAPI_ASC_MEDIUM_CHANGED 0x28 -#define ATAPI_ASC_BUS_RESET 0x29 -#define ATAPI_ASC_NO_MEDIA_IN_DEVICE 0x3a -#define ATAPI_ASC_MUSIC_AREA 0xA0 -#define ATAPI_ASC_DATA_AREA 0xA1 -#define ATAPI_ASC_VOLUME_OVERFLOW 0xA7 - -/* - * IDE command definitions ( for ATAPI ) - */ - -#define IDE_COMMAND_ATAPI_RESET 0x08 /* Atapi Software Reset command */ -#define IDE_COMMAND_ATAPI_PACKET 0xA0 /* Atapi Identify command */ -#define IDE_COMMAND_ATAPI_IDENTIFY 0xA1 /* Atapi Packet Command */ - - -/* - * ATAPI command definitions - */ - -#define ATAPI_TEST_UNIT_READY 0x00 -#define ATAPI_REZERO_UNIT 0x01 -#define ATAPI_REQUEST_SENSE 0x03 -#define ATAPI_FORMAT_UNIT6 0x04 -#define ATAPI_FORMAT_UNIT 0x24 -#define ATAPI_INQUIRY 0x12 -#define ATAPI_MODE_SELECT 0x15 -#define ATAPI_MODE_SENSE 0x1A -#define ATAPI_START_STOP_UNIT 0x1B -#define ATAPI_LOAD_UNLOAD 0x1B -#define ATAPI_MEDIUM_REMOVAL 0x1E -#define ATAPI_READ_CAPACITY 0x25 -#define ATAPI_READ 0x28 -#define ATAPI_WRITE 0x2A -#define ATAPI_SEEK 0x2B -#define ATAPI_VERIFY 0x2F -#define ATAPI_READ_DATA_BUFF 0x3C -#define ATAPI_READ_SUB_CHANNEL 0x42 -#define ATAPI_READ_TOC 0x43 -#define ATAPI_READ_HEADER 0x44 -#define ATAPI_GET_CONFIGURATION 0x46 -#define ATAPI_PLAY_AUDIO_MSF 0x47 -#define ATAPI_GET_EVENT_STATUS_NOTIFICATION 0x4A -#define ATAPI_PAUSE_RESUME 0x4B -#define ATAPI_STOP_PLAY_SCAN 0x4E -#define ATAPI_READ_DISK_INFORMATION 0x51 -#define ATAPI_READ_TRACK_INFORMATION 0x52 -#define ATAPI_MODE_SELECT10 0x55 -#define ATAPI_MODE_SENSE10 0x5A -#define ATAPI_CLOSE_TRACK_SESSION 0x5B -#define ATAPI_READ_BUFFER_CAPACITY 0x5C -#define ATAPI_BLANK_COMMAND 0xA1 /*Provide the ability to erase any part of a CD-RW disc.*/ -#define ATAPI_REPORT_KEY 0xA4 -#define ATAPI_PLAY_AUDIO 0xA5 -#define ATAPI_READ12 0xA8 -#define ATAPI_READ_DVD_STRUCTURE 0xAD -#define ATAPI_READ_CD_MSF 0xB9 -#define ATAPI_SET_CD_SPEED 0xBB -#define ATAPI_MECHANISM_STATUS 0xBD -#define ATAPI_READ_CD 0xBE -#define ATAPI_SET_CDRW_SPEED 0xDA /*WindowsXP need*/ - -#define MODE_DSP_WRITE_PROTECT 0x80 - - -/*************************************************************************** - * ATAPI IO Register File - ***************************************************************************/ - - -typedef struct _ATAPI_REGISTERS_2 { - UCHAR AlternateStatus; -} ATAPI_REGISTERS_2, *PATAPI_REGISTERS_2; - - -/*************************************************************************** - * ATAPI packets - ***************************************************************************/ -typedef struct _ATAPI_SENSE_DATA { -#ifdef __BIG_ENDIAN_BITFIELD - UCHAR Valid:1; - UCHAR ErrorCode:7; - UCHAR SegmentNumber; - UCHAR FileMark:1; - UCHAR EndOfMedia:1; - UCHAR IncorrectLength:1; - UCHAR Reserved:1; - UCHAR SenseKey:4; -#else - UCHAR ErrorCode:7; - UCHAR Valid:1; - UCHAR SegmentNumber; - UCHAR SenseKey:4; - UCHAR Reserved:1; - UCHAR IncorrectLength:1; - UCHAR EndOfMedia:1; - UCHAR FileMark:1; -#endif - UCHAR Information[4]; - UCHAR AdditionalSenseLength; - UCHAR CommandSpecificInformation[4]; - UCHAR AdditionalSenseCode; - UCHAR AdditionalSenseCodeQualifier; - UCHAR FieldReplaceableUnitCode; - UCHAR SenseKeySpecific[3]; -} ATAPI_SENSE_DATA, *PATAPI_SENSE_DATA; - -/* - * IDENTIFY data - */ -typedef struct _IDENTIFY_DATA { - USHORT GeneralConfiguration; /* 00 00 */ - USHORT NumberOfCylinders; /* 02 1 */ - USHORT Reserved1; /* 04 2 */ - USHORT NumberOfHeads; /* 06 3 */ - USHORT UnformattedBytesPerTrack; /* 08 4 */ - USHORT UnformattedBytesPerSector; /* 0A 5 */ - USHORT SectorsPerTrack; /* 0C 6 */ - USHORT VendorUnique1[3]; /* 0E 7-9 */ - USHORT SerialNumber[10]; /* 14 10-19 */ - USHORT BufferType; /* 28 20 */ - USHORT BufferSectorSize; /* 2A 21 */ - USHORT NumberOfEccBytes; /* 2C 22 */ - USHORT FirmwareRevision[4]; /* 2E 23-26 */ - USHORT ModelNumber[20]; /* 36 27-46 */ - UCHAR MaximumBlockTransfer; /* 5E 47 */ - UCHAR VendorUnique2; /* 5F */ - USHORT DoubleWordIo; /* 60 48 */ - USHORT Capabilities; /* 62 49 */ - USHORT Reserved2; /* 64 50 */ - UCHAR VendorUnique3; /* 66 51 */ - UCHAR PioCycleTimingMode; /* 67 */ - UCHAR VendorUnique4; /* 68 52 */ - UCHAR DmaCycleTimingMode; /* 69 */ - USHORT TranslationFieldsValid; /* 6A 53 */ - USHORT NumberOfCurrentCylinders; /* 6C 54 */ - USHORT NumberOfCurrentHeads; /* 6E 55 */ - USHORT CurrentSectorsPerTrack; /* 70 56 */ - ULONG CurrentSectorCapacity; /* 72 57-58 */ - USHORT CurrentMultiSectorSetting; /* 76 59 */ - ULONG UserAddressableSectors; /* 78 60-61 */ - UCHAR SingleWordDMASupport; /* 7C 62 */ - UCHAR SingleWordDMAActive; /* 7D */ - UCHAR MultiWordDMASupport; /* 7E 63 */ - UCHAR MultiWordDMAActive; /* 7F */ - UCHAR AdvancedPIOModes; /* 80 64 */ - UCHAR Reserved4; /* 81 */ - USHORT MinimumMWXferCycleTime; /* 82 65 */ - USHORT RecommendedMWXferCycleTime; /* 84 66 */ - USHORT MinimumPIOCycleTime; /* 86 67 */ - USHORT MinimumPIOCycleTimeIORDY; /* 88 68 */ - USHORT Reserved5[2]; /* 8A 69-70 */ - USHORT ReleaseTimeOverlapped; /* 8E 71 */ - USHORT ReleaseTimeServiceCommand; /* 90 72 */ - USHORT MajorRevision; /* 92 73 */ - USHORT MinorRevision; /* 94 74 */ - USHORT MaxQueueDepth; /* 96 75 */ - USHORT SataCapability; /* 76 */ - USHORT Reserved6[9]; /* 98 77-85 */ - USHORT CommandSupport; /* 86 */ - USHORT CommandEnable; /* 87 */ - USHORT UtralDmaMode; /* 88 */ - USHORT Reserved7[11]; /* 89-99 */ - ULONG Lba48BitLow; /* 101-100 */ - ULONG Lba48BitHigh; /* 103-102 */ - USHORT Reserved8[23]; /* 104-126 */ - USHORT SpecialFunctionsEnabled; /* 127 */ - USHORT Reserved9[128]; /* 128-255 */ - -} IDENTIFY_DATA, *PIDENTIFY_DATA; - -typedef struct _CONFIGURATION_IDENTIFY_DATA { - USHORT Revision; - USHORT MWDMAModeSupported; - USHORT UDMAModeSupported; - ULONG MaximumLbaLow; - ULONG MaximumLbaHigh; - USHORT CommandSupport; - USHORT Reserved[247]; - UCHAR Signature; /* 0xA5 */ - UCHAR CheckSum; -} -CONFIGURATION_IDENTIFY_DATA, *PCONFIGURATION_IDENTIFY_DATA; - -/* */ -/* Identify data without the Reserved4. */ -/* */ -typedef struct _IDENTIFY_DATA2 { - USHORT GeneralConfiguration; /* 00 00 */ - USHORT NumberOfCylinders; /* 02 1 */ - USHORT Reserved1; /* 04 2 */ - USHORT NumberOfHeads; /* 06 3 */ - USHORT UnformattedBytesPerTrack; /* 08 4 */ - USHORT UnformattedBytesPerSector; /* 0A 5 */ - USHORT SectorsPerTrack; /* 0C 6 */ - USHORT VendorUnique1[3]; /* 0E 7-9 */ - USHORT SerialNumber[10]; /* 14 10-19 */ - USHORT BufferType; /* 28 20 */ - USHORT BufferSectorSize; /* 2A 21 */ - USHORT NumberOfEccBytes; /* 2C 22 */ - USHORT FirmwareRevision[4]; /* 2E 23-26 */ - USHORT ModelNumber[20]; /* 36 27-46 */ - UCHAR MaximumBlockTransfer; /* 5E 47 */ - UCHAR VendorUnique2; /* 5F */ - USHORT DoubleWordIo; /* 60 48 */ - USHORT Capabilities; /* 62 49 */ - USHORT Reserved2; /* 64 50 */ - UCHAR VendorUnique3; /* 66 51 */ - UCHAR PioCycleTimingMode; /* 67 */ - UCHAR VendorUnique4; /* 68 52 */ - UCHAR DmaCycleTimingMode; /* 69 */ - USHORT TranslationFieldsValid; /* 6A 53 */ - USHORT NumberOfCurrentCylinders; /* 6C 54 */ - USHORT NumberOfCurrentHeads; /* 6E 55 */ - USHORT CurrentSectorsPerTrack; /* 70 56 */ - ULONG CurrentSectorCapacity; /* 72 57-58 */ - USHORT CurrentMultiSectorSetting; /* 59 */ - ULONG UserAddressableSectors; /* 60-61 */ - UCHAR SingleWordDMASupport; /* 62 */ - UCHAR SingleWordDMAActive; - UCHAR MultiWordDMASupport; /* 63 */ - UCHAR MultiWordDMAActive; - UCHAR AdvancedPIOModes; /* 64 */ - UCHAR Reserved4; - USHORT MinimumMWXferCycleTime; /* 65 */ - USHORT RecommendedMWXferCycleTime; /* 66 */ - USHORT MinimumPIOCycleTime; /* 67 */ - USHORT MinimumPIOCycleTimeIORDY; /* 68 */ - USHORT Reserved5[2]; /* 69-70 */ - USHORT ReleaseTimeOverlapped; /* 71 */ - USHORT ReleaseTimeServiceCommand; /* 72 */ - USHORT MajorRevision; /* 73 */ - USHORT MinorRevision; /* 74 */ -/* USHORT Reserved6[14]; // 75-88 */ -} IDENTIFY_DATA2, *PIDENTIFY_DATA2; - -#define IDENTIFY_DATA_SIZE sizeof(IDENTIFY_DATA2) - -/* */ -/* IDENTIFY DMA timing cycle modes. */ -/* */ - -#define IDENTIFY_DMA_CYCLES_MODE_0 0x00 -#define IDENTIFY_DMA_CYCLES_MODE_1 0x01 -#define IDENTIFY_DMA_CYCLES_MODE_2 0x02 - -/* - * Mode definitions - */ -typedef enum _DISK_MODE -{ - IDE_PIO_0 = 0, - IDE_PIO_1, - IDE_PIO_2, - IDE_PIO_3, - IDE_PIO_4, - IDE_MWDMA_0, - IDE_MWDMA_1, - IDE_MWDMA_2, - IDE_UDMA_0, - IDE_UDMA_1, - IDE_UDMA_2, - IDE_UDMA_3, - IDE_UDMA_4, - IDE_UDMA_5, - IDE_UDMA_6, - IDE_UDMA_7, -} DISK_MODE; - -/*************************************************************************** - * IDE Macro - ***************************************************************************/ -#ifndef MAX_LBA_T -#define MAX_LBA_T ((LBA_T)-1) -#endif - -#define SECTOR_TO_BYTE_SHIFT 9 -#define SECTOR_TO_BYTE(x) ((ULONG)(x) << SECTOR_TO_BYTE_SHIFT) - -#define mGetStatus(IOPort2) (UCHAR)InPort(&IOPort2->AlternateStatus) -#define mUnitControl(IOPort2, Value) OutPort(&IOPort2->AlternateStatus,(UCHAR)(Value)) - -#define mGetErrorCode(IOPort) (UCHAR)InPort((PUCHAR)&IOPort->Data+1) -#define mSetFeaturePort(IOPort,x) OutPort((PUCHAR)&IOPort->Data+1, x) -#define mSetBlockCount(IOPort,x) OutPort(&IOPort->BlockCount, x) -#define mGetBlockCount(IOPort) (UCHAR)InPort(&IOPort->BlockCount) -#define mGetInterruptReason(IOPort) (UCHAR)InPort(&IOPort->BlockCount) -#define mSetBlockNumber(IOPort,x) OutPort(&IOPort->BlockNumber, x) -#define mGetBlockNumber(IOPort) (UCHAR)InPort((PUCHAR)&IOPort->BlockNumber) -#define mGetByteLow(IOPort) (UCHAR)InPort(&IOPort->CylinderLow) -#define mSetCylinderLow(IOPort,x) OutPort(&IOPort->CylinderLow, x) -#define mGetByteHigh(IOPort) (UCHAR)InPort(&IOPort->CylinderHigh) -#define mSetCylinderHigh(IOPort,x) OutPort(&IOPort->CylinderHigh, x) -#define mGetBaseStatus(IOPort) (UCHAR)InPort(&IOPort->Command) -#ifdef SUPPORT_HPT601 -#define mSelectUnit(IOPort,UnitId) do {\ - OutPort(&IOPort->DriveSelect, (UCHAR)(UnitId));\ - OutPort(&IOPort->DriveSelect, (UCHAR)(UnitId));\ - } while (0) -#else -#define mSelectUnit(IOPort,UnitId) OutPort(&IOPort->DriveSelect, (UCHAR)(UnitId)) -#endif -#define mGetUnitNumber(IOPort) InPort(&IOPort->DriveSelect) -#define mIssueCommand(IOPort,Cmd) OutPort(&IOPort->Command, (UCHAR)(Cmd)) - -/* - * WDC old disk, don't care right now - */ -#define WDC_MW1_FIX_FLAG_OFFSET 129 -#define WDC_MW1_FIX_FLAG_VALUE 0x00005555 - -#pragma pack() -#endif - - - diff --git a/sys/contrib/dev/hptmv/command.h b/sys/contrib/dev/hptmv/command.h deleted file mode 100644 index 0b03e155dc19..000000000000 --- a/sys/contrib/dev/hptmv/command.h +++ /dev/null @@ -1,265 +0,0 @@ -/* - * Copyright (c) 2003-2004 HighPoint Technologies, Inc. - * All rights reserved. - * - * Redistribution and use in source and binary forms, with or without - * modification, are permitted provided that the following conditions - * are met: - * 1. Redistributions of source code must retain the above copyright - * notice, this list of conditions and the following disclaimer. - * 2. Redistributions in binary form must reproduce the above copyright - * notice, this list of conditions and the following disclaimer in the - * documentation and/or other materials provided with the distribution. - * - * THIS SOFTWARE IS PROVIDED BY THE AUTHOR AND CONTRIBUTORS ``AS IS'' AND - * ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE - * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE - * ARE DISCLAIMED. IN NO EVENT SHALL THE AUTHOR OR CONTRIBUTORS BE LIABLE - * FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL - * DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS - * OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) - * HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT - * LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY - * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF - * SUCH DAMAGE. - */ -#ifndef _COMMAND_H_ -#define _COMMAND_H_ - -/*************************************************************************** - * Description: Command - ***************************************************************************/ -typedef struct _AtaCommand -{ - LBA_T Lba; /* Current Logic Disk command: LBA */ - USHORT nSectors; /* sector count. May great than 0x80 */ - UCHAR Command; /* IDE_COMMAND_READ, _WRITE, _VERIFY */ - UCHAR QueueTag; -} AtaComm, *PAtaComm; - -typedef struct _PassthroughCmd { - BYTE bFeaturesReg; /* feature register */ - BYTE bSectorCountReg; /* IDE sector count register. */ - BYTE bSectorNumberReg; /* IDE sector number register. */ - BYTE bCylLowReg; /* IDE low order cylinder value. */ - BYTE bCylHighReg; /* IDE high order cylinder value. */ - BYTE bDriveHeadReg; /* IDE drive/head register. */ - BYTE bCommandReg; /* Actual IDE command. Checked for validity by driver. */ - BYTE nSectors; /* data transfer */ - ADDRESS pDataBuffer; /* data buffer */ -} -PassthroughCmd; - -/* control commands */ -#define CTRL_CMD_REBUILD 1 -#define CTRL_CMD_VERIFY 2 -#define CTRL_CMD_INIT 3 - -/* - * RAID5 rebuild/verify - * Rebuild/verify one stripe line. - * The caller needn't supply a buffer for rebuild. - * RebuildSectors member will be updated if its previous location is the - * begin of this stripe line. - */ -typedef struct _R5ControlCmd { - LBA_T StripeLine; /* _physical_ stripe line on array */ - USHORT Offset; /* internal use, don't set */ - UCHAR Command; /* CTRL_CMD_XXX */ - UCHAR reserve1; -} -R5ControlCmd, *PR5ControlCmd; - -/* - * RAID1 rebuild/verify - * Rebuild/verify specified sectors. - * The caller must supply a valid buffer and a physical SG table (or a - * pfnBuildSgl routine). - * For rebuild/initialize, the buffer size should be nSectors<<9; - * For verify, the buffer size should be (nSectors*2)<<9. - * RebuildSectors member will be updated if its previous value equals Lba. - */ -typedef struct _R1ControlCmd { - LBA_T Lba; - USHORT nSectors; - UCHAR Command; /* CTRL_CMD_XXX */ - UCHAR reserve1; - ADDRESS Buffer; /* buffer logical address */ -#ifdef _MACOSX_ - ADDRESS PhysicalAddress; -#endif -} -R1ControlCmd, *PR1ControlCmd; - -typedef struct _Command -{ - PVDevice pVDevice; - union{ - /* Ide Command */ - AtaComm Ide; - PassthroughCmd Passthrough; - /* Atapi Command */ - UCHAR Atapi[12]; - /* Control command */ - R5ControlCmd R5Control; - R1ControlCmd R1Control; - } uCmd; - - USHORT cf_physical_sg: 1; - USHORT cf_data_in: 1; - USHORT cf_data_out: 1; - USHORT cf_atapi: 1; - USHORT cf_ide_passthrough: 1; - USHORT cf_control: 1; - - /* return status */ - UCHAR Result; - /* retry count */ - UCHAR RetryCount; - - /* S/G table address, if already prepared */ - FPSCAT_GATH pSgTable; - - /* called if pSgTable is invalid. */ - int (* HPTLIBAPI pfnBuildSgl)(_VBUS_ARG PCommand pCmd, FPSCAT_GATH pSgTable, int logical); - - /* called when this command is finished */ - void (* HPTLIBAPI pfnCompletion)(_VBUS_ARG PCommand pCmd); - - /* pointer to origional command */ - void *pOrgCommand; - - - /* scratch data area */ - union { - struct { - LBA_T StartLBA; - UCHAR FirstMember; /* the sequence number of the first member */ - UCHAR LastMember; /* the sequence number of the last member */ - USHORT LastSectors; /* the number of sectors for the last member */ - USHORT FirstSectors; /* the number of sectors for the first member */ - USHORT FirstOffset; /* the offset from the StartLBA for the first member */ - USHORT AllMemberBlocks;/* the number of sectors for all member */ - USHORT WaitInterrupt; /* bit map the members who wait interrupt */ - UCHAR InSameLine; /* if the start and end on the same line */ - UCHAR pad1; - } array; - struct { - LBA_T StartLBA; - USHORT FirstSectors; /* the number of sectors for the first member */ - USHORT FirstOffset; /* the offset from the StartLBA for the first member */ - USHORT WaitInterrupt; /* bit map the members who wait interrupt */ - USHORT r5_gap; /* see raid5.c */ - UCHAR ParDiskNo; /* parity for startLba */ - UCHAR BadDiskNo; - UCHAR FirstMember; - UCHAR pad1; - } r5; - struct { - PCommand pCmd1; - PCommand pCmd2; - } r5split; -#ifdef _RAID5N_ - struct { - ULONG dummy[2]; /* uScratch.wait shall be moved out uScratch. - now just fix it thisway */ - struct range_lock *range_lock; - struct stripe *stripes[5]; - UCHAR nstripes; - UCHAR finished_stripes; - USHORT pad2; - /* for direct-read: */ - struct { - UCHAR cmds; - UCHAR finished; - UCHAR first; - UCHAR parity; - LBA_T base; - USHORT firstoffset; - USHORT firstsectors; - } dr; - } r5n2; -#endif - struct { - ULONG WordsLeft; - FPSCAT_GATH pPIOSg; - void (* HPTLIBAPI pfnOrgDone)(_VBUS_ARG PCommand pCmd); -#ifdef SUPPORT_HPT584 - UCHAR cmd; -#endif - } disk; - struct { - PCommand pNext; - void (* HPTLIBAPI WaitEntry)(_VBUS_ARG PCommand pCmd); - } wait; - - struct { - PVOID prdAddr; - ULONG cmd_priv; - USHORT responseFlags; - UCHAR bIdeStatus; - UCHAR errorRegister; - } sata_param; - } uScratch; -} Command; - -/*************************************************************************** - * command return value - ***************************************************************************/ -#define RETURN_PENDING 0 -#define RETURN_SUCCESS 1 -#define RETURN_BAD_DEVICE 2 -#define RETURN_BAD_PARAMETER 3 -#define RETURN_WRITE_NO_DRQ 4 -#define RETURN_DEVICE_BUSY 5 -#define RETURN_INVALID_REQUEST 6 -#define RETURN_SELECTION_TIMEOUT 7 -#define RETURN_IDE_ERROR 8 -#define RETURN_NEED_LOGICAL_SG 9 -#define RETURN_NEED_PHYSICAL_SG 10 -#define RETURN_RETRY 11 -#define RETURN_DATA_ERROR 12 -#define RETURN_BUS_RESET 13 -#define RETURN_BAD_TRANSFER_LENGTH 14 - -typedef void (* HPTLIBAPI DPC_PROC)(_VBUS_ARG void *); -typedef struct _dpc_routine { - DPC_PROC proc; - void *arg; -} -DPC_ROUTINE; - -/* - * MAX_QUEUE_COMM is defined in platform related compiler.h - * to specify the maximum requests allowed (for each VBus) from system. - * - * Maximum command blocks needed for each VBus: - * Each OS command requests 1+MAX_MEMBERS*2 command blocks (RAID1/0 case) - * This space is allocated by platform dependent part, either static or - * dynamic, continuous or non-continous. - * The code only needs _vbus_(pFreeCommands) to be set. - * - * PendingRoutines[] size: - * Each command may invoke CallAfterReturn once. - * - * IdleRoutines[] size: - * Each command may invoke CallWhenIdle once. - */ -#define MAX_COMMAND_BLOCKS_FOR_EACH_VBUS (MAX_QUEUE_COMM * (1+MAX_MEMBERS*2)) -#define MAX_PENDING_ROUTINES (MAX_COMMAND_BLOCKS_FOR_EACH_VBUS+1) -#define MAX_IDLE_ROUTINES (MAX_COMMAND_BLOCKS_FOR_EACH_VBUS+1) - -#define mWaitingForIdle(pVBus) ((pVBus)->IdleRoutinesFirst!=(pVBus)->IdleRoutinesLast) - -PCommand HPTLIBAPI AllocateCommand(_VBUS_ARG0); -void FASTCALL FreeCommand(_VBUS_ARG PCommand pCmd); - -void FASTCALL CallAfterReturn(_VBUS_ARG DPC_PROC proc, void *arg); -void HPTLIBAPI CheckPendingCall(_VBUS_ARG0); -void FASTCALL CallWhenIdle(_VBUS_ARG DPC_PROC proc, void *arg); -void HPTLIBAPI CheckIdleCall(_VBUS_ARG0); - -void HPTLIBAPI AddToWaitingList(PCommand *ppList, PCommand pCmd); -void HPTLIBAPI DoWaitingList(_VBUS_ARG PCommand *ppList); - -#endif diff --git a/sys/contrib/dev/hptmv/gui_lib.c b/sys/contrib/dev/hptmv/gui_lib.c deleted file mode 100644 index e20ef55d8daa..000000000000 --- a/sys/contrib/dev/hptmv/gui_lib.c +++ /dev/null @@ -1,1384 +0,0 @@ -/* - * Copyright (c) 2003-2004 HighPoint Technologies, Inc. - * All rights reserved. - * - * Redistribution and use in source and binary forms, with or without - * modification, are permitted provided that the following conditions - * are met: - * 1. Redistributions of source code must retain the above copyright - * notice, this list of conditions and the following disclaimer. - * 2. Redistributions in binary form must reproduce the above copyright - * notice, this list of conditions and the following disclaimer in the - * documentation and/or other materials provided with the distribution. - * - * THIS SOFTWARE IS PROVIDED BY THE AUTHOR AND CONTRIBUTORS ``AS IS'' AND - * ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE - * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE - * ARE DISCLAIMED. IN NO EVENT SHALL THE AUTHOR OR CONTRIBUTORS BE LIABLE - * FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL - * DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS - * OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) - * HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT - * LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY - * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF - * SUCH DAMAGE. - */ -/* - * gui_lib.c - * Copyright (c) 2002-2004 HighPoint Technologies, Inc. All rights reserved. - * - * Platform independent ioctl interface implementation. - * The platform dependent part may reuse this function and/or use it own - * implementation for each ioctl function. - * - * This implementation doesn't use any synchronization; the caller must - * assure the proper context when calling these functions. - */ - -#include -#include -#include -#include - -#include -#include -#include -#include - -static int hpt_get_driver_capabilities(PDRIVER_CAPABILITIES cap); -static int hpt_get_controller_count(void); -static int hpt_get_controller_info(int id, PCONTROLLER_INFO pInfo); -static int hpt_get_channel_info(int id, int bus, PCHANNEL_INFO pInfo); -static int hpt_get_logical_devices(DEVICEID * pIds, int nMaxCount); -static int hpt_get_device_info(DEVICEID id, PLOGICAL_DEVICE_INFO pInfo); -static DEVICEID hpt_create_array(_VBUS_ARG PCREATE_ARRAY_PARAMS pParam); -static int hpt_add_spare_disk(_VBUS_ARG DEVICEID idDisk); -static int hpt_remove_spare_disk(_VBUS_ARG DEVICEID idDisk); -static int hpt_set_array_info(_VBUS_ARG DEVICEID idArray, PALTERABLE_ARRAY_INFO pInfo); -static int hpt_set_device_info(_VBUS_ARG DEVICEID idDisk, PALTERABLE_DEVICE_INFO pInfo); - -int check_VDevice_valid(PVDevice p) -{ - int i; - PVDevice pVDevice; - PVBus _vbus_p; - IAL_ADAPTER_T *pAdapter = gIal_Adapter; - - while(pAdapter != 0) - { - for (i = 0; i < MV_SATA_CHANNELS_NUM; i++) - if(&(pAdapter->VDevices[i]) == p) return 0; - pAdapter = pAdapter->next; - } - -#ifdef SUPPORT_ARRAY - pAdapter = gIal_Adapter; - while(pAdapter != 0) - { - _vbus_p = &pAdapter->VBus; - for (i=0;iu.array.dArStamp != 0) && (pVDevice == p)) - return 0; - } - pAdapter = pAdapter->next; - } -#endif - - return -1; -} - -#ifdef SUPPORT_ARRAY -static void get_array_info(PVDevice pVDevice, PLOGICAL_DEVICE_INFO pInfo) -{ - int i; - - pInfo->Type = LDT_ARRAY; - pInfo->Capacity = pVDevice->VDeviceCapacity; - pInfo->ParentArray = VDEV_TO_ID(pVDevice->pParent); - - memcpy(pInfo->u.array.Name, pVDevice->u.array.ArrayName, MAX_ARRAY_NAME); - - switch( pVDevice->VDeviceType ) - { - case VD_RAID_0: - pInfo->u.array.ArrayType = AT_RAID0; - break; - case VD_RAID_1: - pInfo->u.array.ArrayType = AT_RAID1; - break; - case VD_JBOD: - pInfo->u.array.ArrayType = AT_JBOD; - break; - case VD_RAID_5: - pInfo->u.array.ArrayType = AT_RAID5; - break; - default: - pInfo->u.array.ArrayType = AT_UNKNOWN; - } - - pInfo->u.array.BlockSizeShift = pVDevice->u.array.bArBlockSizeShift; - - pInfo->u.array.RebuiltSectors = pVDevice->u.array.RebuildSectors; - - /* The array is disabled */ - if(!pVDevice->vf_online) { - pInfo->u.array.Flags |= ARRAY_FLAG_DISABLED; - goto ignore_info; - } - - /* array need synchronizing */ - if(pVDevice->u.array.rf_need_rebuild && !pVDevice->u.array.rf_duplicate_and_create) - pInfo->u.array.Flags |= ARRAY_FLAG_NEEDBUILDING; - - pInfo->u.array.RebuildingProgress = ((pVDevice->u.array.RebuildSectors>>11)*1000 / - (pVDevice->VDeviceCapacity>>11) * (pVDevice->u.array.bArnMember-1)) * 10; - - /* array is in rebuilding process */ - if(pVDevice->u.array.rf_rebuilding) - pInfo->u.array.Flags |= ARRAY_FLAG_REBUILDING; - - /* array is being verified */ - if(pVDevice->u.array.rf_verifying) - pInfo->u.array.Flags |= ARRAY_FLAG_VERIFYING; - - /* array is being initialized */ - if(pVDevice->u.array.rf_initializing) - pInfo->u.array.Flags |= ARRAY_FLAG_INITIALIZING; - - /* broken but may still working */ - if(pVDevice->u.array.rf_broken) - pInfo->u.array.Flags |= ARRAY_FLAG_BROKEN; - - /* array has a active partition */ - if(pVDevice->vf_bootable) - pInfo->u.array.Flags |= ARRAY_FLAG_BOOTDISK; - - /* a newly created array */ - if(pVDevice->u.array.rf_newly_created) - pInfo->u.array.Flags |= ARRAY_FLAG_NEWLY_CREATED; - - /* array has boot mark set */ - if(pVDevice->vf_bootmark) - pInfo->u.array.Flags |= ARRAY_FLAG_BOOTMARK; - - /* auto-rebuild should start */ - if(pVDevice->u.array.rf_auto_rebuild) - pInfo->u.array.Flags |= ARRAY_FLAG_NEED_AUTOREBUILD; - - for(i = 0; i < pVDevice->u.array.bArnMember; i++) - { - PVDevice pMember = pVDevice->u.array.pMember[i]; - if (!pMember || !pMember->vf_online || (pMember->VDeviceType==VD_SINGLE_DISK)) - continue; - - /* array need synchronizing */ - if(pMember->u.array.rf_need_rebuild && - !pMember->u.array.rf_duplicate_and_create) - pInfo->u.array.Flags |= ARRAY_FLAG_NEEDBUILDING; - - /* array is in rebuilding process */ - if(pMember->u.array.rf_rebuilding) - pInfo->u.array.Flags |= ARRAY_FLAG_REBUILDING; - - /* array is being verified */ - if(pMember->u.array.rf_verifying) - pInfo->u.array.Flags |= ARRAY_FLAG_VERIFYING; - - /* array is being initialized */ - if(pMember->u.array.rf_initializing) - pInfo->u.array.Flags |= ARRAY_FLAG_INITIALIZING; - - /* broken but may still working */ - if(pMember->u.array.rf_broken) - pInfo->u.array.Flags |= ARRAY_FLAG_BROKEN; - - /* a newly created array */ - if(pMember->u.array.rf_newly_created) - pInfo->u.array.Flags |= ARRAY_FLAG_NEWLY_CREATED; - - /* auto-rebuild should start */ - if(pMember->u.array.rf_auto_rebuild) - pInfo->u.array.Flags |= ARRAY_FLAG_NEED_AUTOREBUILD; - - /* for RAID1/0 case */ - if (pMember->u.array.rf_rebuilding || - pMember->u.array.rf_verifying || - pMember->u.array.rf_initializing) - { - DWORD percent = ((pMember->u.array.RebuildSectors>>11)*1000 / - (pMember->VDeviceCapacity>>11) * (pMember->u.array.bArnMember-1)) * 10; - if (pInfo->u.array.RebuildingProgress==0 || - pInfo->u.array.RebuildingProgress>percent) - pInfo->u.array.RebuildingProgress = percent; - } - } - - if (pInfo->u.array.RebuildingProgress>10000) - pInfo->u.array.RebuildingProgress = 10000; - -ignore_info: - - pInfo->u.array.nDisk = 0; - for(i=0; iu.array.Members[i] = INVALID_DEVICEID; - - for(i = 0; i < pVDevice->u.array.bArnMember; i++) - { - if(pVDevice->u.array.pMember[i] != NULL) - { - pInfo->u.array.Members[pInfo->u.array.nDisk] = VDEV_TO_ID(pVDevice->u.array.pMember[i]); - pInfo->u.array.nDisk++; - } - } -} -#endif - -static int get_disk_info(PVDevice pVDevice, PLOGICAL_DEVICE_INFO pInfo) -{ - MV_SATA_ADAPTER *pSataAdapter; - MV_SATA_CHANNEL *pSataChannel; - IAL_ADAPTER_T *pAdapter; - char *p; - int i; - - pInfo->Type = LDT_DEVICE; - - if (pVDevice->pParent) - pInfo->ParentArray = VDEV_TO_ID(pVDevice->pParent); - else - pInfo->ParentArray = INVALID_DEVICEID; - - /* report real capacity to be compatible with old arrays */ - pInfo->Capacity = pVDevice->u.disk.dDeRealCapacity; - - /* device location */ - pSataChannel = pVDevice->u.disk.mv; - if(pSataChannel == NULL) return -1; - pInfo->u.device.TargetId = 0; - pSataAdapter = pSataChannel->mvSataAdapter; - if(pSataAdapter == NULL) return -1; - - pAdapter = pSataAdapter->IALData; - - pInfo->u.device.PathId = pSataChannel->channelNumber; - pInfo->u.device.ControllerId = (UCHAR)pSataAdapter->adapterId; - -/*GUI uses DeviceModeSetting to display to users -(1) if users select a mode, GUI/BIOS should display that mode. -(2) if SATA/150, GUI/BIOS should display 150 if case (1) isn't satisfied. -(3) display real mode if case (1)&&(2) not satisfied. -*/ - if (pVDevice->u.disk.df_user_mode_set) - pInfo->u.device.DeviceModeSetting = pVDevice->u.disk.bDeUserSelectMode; - else if ((((PIDENTIFY_DATA)pVDevice->u.disk.mv->identifyDevice)->SataCapability & 3)==2) - pInfo->u.device.DeviceModeSetting = 15; - else { - p = (char *)&((PIDENTIFY_DATA)pVDevice->u.disk.mv->identifyDevice)->ModelNumber; - if (*(WORD*)p==0x5354 /*'ST'*/ && - (*(WORD*)(p+8)==0x4153/*'AS'*/ || (p[8]=='A' && p[11]=='S'))) - pInfo->u.device.DeviceModeSetting = 15; - else - pInfo->u.device.DeviceModeSetting = pVDevice->u.disk.bDeModeSetting; - } - - pInfo->u.device.UsableMode = pVDevice->u.disk.bDeUsable_Mode; - - pInfo->u.device.DeviceType = PDT_HARDDISK; - - pInfo->u.device.Flags = 0x0; - - /* device is disabled */ - if(!pVDevice->u.disk.df_on_line) - pInfo->u.device.Flags |= DEVICE_FLAG_DISABLED; - - /* disk has a active partition */ - if(pVDevice->vf_bootable) - pInfo->u.device.Flags |= DEVICE_FLAG_BOOTDISK; - - /* disk has boot mark set */ - if(pVDevice->vf_bootmark) - pInfo->u.device.Flags |= DEVICE_FLAG_BOOTMARK; - - pInfo->u.device.Flags |= DEVICE_FLAG_SATA; - - /* is a spare disk */ - if(pVDevice->VDeviceType == VD_SPARE) - pInfo->u.device.Flags |= DEVICE_FLAG_IS_SPARE; - - memcpy(&(pInfo->u.device.IdentifyData), (pSataChannel->identifyDevice), sizeof(IDENTIFY_DATA2)); - p = (char *)&pInfo->u.device.IdentifyData.ModelNumber; - for (i = 0; i < 20; i++) - ((WORD*)p)[i] = shortswap(pSataChannel->identifyDevice[IDEN_MODEL_OFFSET+i]); - p[39] = '\0'; - - return 0; -} - -static int hpt_get_driver_capabilities(PDRIVER_CAPABILITIES cap) -{ - ZeroMemory(cap, sizeof(DRIVER_CAPABILITIES)); - cap->dwSize = sizeof(DRIVER_CAPABILITIES); - cap->MaximumControllers = MAX_VBUS; - - /* cap->SupportCrossControllerRAID = 0; */ - /* take care for various OSes! */ - cap->SupportCrossControllerRAID = 0; - - - cap->MinimumBlockSizeShift = MinBlockSizeShift; - cap->MaximumBlockSizeShift = MaxBlockSizeShift; - cap->SupportDiskModeSetting = 0; - cap->SupportSparePool = 1; - cap->MaximumArrayNameLength = MAX_ARRAY_NAME - 1; - cap->SupportDedicatedSpare = 0; - -#ifdef SUPPORT_HOTSWAP - cap->SupportHotSwap = 1; -#endif - -#ifdef SUPPORT_ARRAY - /* Stripe */ - cap->SupportedRAIDTypes[0] = AT_RAID0; - cap->MaximumArrayMembers[0] = MAX_MEMBERS; - /* Mirror */ - cap->SupportedRAIDTypes[1] = AT_RAID1; - cap->MaximumArrayMembers[1] = 2; - /* Mirror + Stripe */ -#ifdef ARRAY_V2_ONLY - cap->SupportedRAIDTypes[2] = (AT_RAID1<<4)|AT_RAID0; /* RAID0/1 */ -#else - cap->SupportedRAIDTypes[2] = (AT_RAID0<<4)|AT_RAID1; /* RAID1/0 */ -#endif - cap->MaximumArrayMembers[2] = MAX_MEMBERS; - /* Jbod */ - cap->SupportedRAIDTypes[3] = AT_JBOD; - cap->MaximumArrayMembers[3] = MAX_MEMBERS; - /* RAID5 */ -#if SUPPORT_RAID5 - cap->SupportedRAIDTypes[4] = AT_RAID5; - cap->MaximumArrayMembers[4] = MAX_MEMBERS; -#endif -#if 0 /* don't let GUI create RAID 0/1. */ - /* Stripe + Mirror */ - cap->SupportedRAIDTypes[5] = (AT_RAID1<<4)|AT_RAID0; - cap->MaximumArrayMembers[5] = 4; -#endif -#endif /* SUPPORT_ARRAY */ - return 0; -} - -static int hpt_get_controller_count(void) -{ - IAL_ADAPTER_T *pAdapTemp = gIal_Adapter; - int iControllerCount = 0; - - while(pAdapTemp != 0) - { - iControllerCount++; - pAdapTemp = pAdapTemp->next; - } - - return iControllerCount; -} - -static int hpt_get_controller_info(int id, PCONTROLLER_INFO pInfo) -{ - IAL_ADAPTER_T *pAdapTemp; - int iControllerCount = 0; - - for (pAdapTemp = gIal_Adapter; pAdapTemp; pAdapTemp = pAdapTemp->next) { - if (iControllerCount++==id) { - pInfo->InterruptLevel = 0; - pInfo->ChipType = 0; - pInfo->ChipFlags = CHIP_SUPPORT_ULTRA_100; - strcpy( pInfo->szVendorID, "HighPoint Technologies, Inc."); -#ifdef GUI_CONTROLLER_NAME -#ifdef FORCE_ATA150_DISPLAY - /* show "Bus Type: ATA/150" in GUI for SATA controllers */ - pInfo->ChipFlags = CHIP_SUPPORT_ULTRA_150; -#endif - strcpy(pInfo->szProductID, GUI_CONTROLLER_NAME); -#define _set_product_id(x) -#else -#define _set_product_id(x) strcpy(pInfo->szProductID, x) -#endif - _set_product_id("RocketRAID 182x SATA Controller"); - pInfo->NumBuses = 8; - pInfo->ChipFlags |= CHIP_SUPPORT_ULTRA_133|CHIP_SUPPORT_ULTRA_150; - return 0; - } - } - return -1; -} - - -static int hpt_get_channel_info(int id, int bus, PCHANNEL_INFO pInfo) -{ - IAL_ADAPTER_T *pAdapTemp = gIal_Adapter; - int i,iControllerCount = 0; - - while(pAdapTemp != 0) - { - if (iControllerCount++==id) - goto found; - pAdapTemp = pAdapTemp->next; - } - return -1; - -found: - - pInfo->IoPort = 0; - pInfo->ControlPort = 0; - - for (i=0; i<2 ;i++) - { - pInfo->Devices[i] = (DEVICEID)INVALID_DEVICEID; - } - - if (pAdapTemp->mvChannel[bus].online == MV_TRUE) - pInfo->Devices[0] = VDEV_TO_ID(&pAdapTemp->VDevices[bus]); - else - pInfo->Devices[0] = (DEVICEID)INVALID_DEVICEID; - - return 0; - - -} - -static int hpt_get_logical_devices(DEVICEID * pIds, int nMaxCount) -{ - int count = 0; - int i,j; - PVDevice pPhysical, pLogical; - IAL_ADAPTER_T *pAdapTemp; - - for(i = 0; i < nMaxCount; i++) - pIds[i] = INVALID_DEVICEID; - - /* append the arrays not registered on VBus */ - for (pAdapTemp = gIal_Adapter; pAdapTemp; pAdapTemp = pAdapTemp->next) { - for(i = 0; i < MV_SATA_CHANNELS_NUM; i++) - { - pPhysical = &pAdapTemp->VDevices[i]; - pLogical = pPhysical; - - while (pLogical->pParent) pLogical = pLogical->pParent; - if (pLogical->VDeviceType==VD_SPARE) - continue; - - for (j=0; j=nMaxCount) goto done; - next:; - } - } - -done: - return count; -} - -static int hpt_get_device_info(DEVICEID id, PLOGICAL_DEVICE_INFO pInfo) -{ - PVDevice pVDevice = ID_TO_VDEV(id); - - if((id == HPT_NULL_ID) || check_VDevice_valid(pVDevice)) - return -1; - -#ifdef SUPPORT_ARRAY - if (mIsArray(pVDevice)) - get_array_info(pVDevice, pInfo); - else -#endif - return get_disk_info(pVDevice, pInfo); - - return 0; -} - -#ifdef SUPPORT_ARRAY -static DEVICEID hpt_create_array(_VBUS_ARG PCREATE_ARRAY_PARAMS pParam) -{ - ULONG Stamp = GetStamp(); - int i,j; - ULONG capacity = MAX_LBA_T; - PVDevice pArray,pChild; -#if MAX_VBUS==1 - PVBus _vbus_p = NULL; -#endif - int Loca = -1; - - for(i = 0; i < pParam->nDisk; i++) - { - PVDevice pVDev = ID_TO_VDEV(pParam->Members[i]); - if (check_VDevice_valid(pVDev)) return INVALID_DEVICEID; - if (mIsArray(pVDev)) return INVALID_DEVICEID; - if (!pVDev->vf_online) return INVALID_DEVICEID; - if (!_vbus_p) - _vbus_p = pVDev->u.disk.pVBus; - else if (_vbus_p != pVDev->u.disk.pVBus) - return INVALID_DEVICEID; - } - if (!_vbus_p) return INVALID_DEVICEID; - - mArGetArrayTable(pArray); - if(!pArray) return INVALID_DEVICEID; - - switch (pParam->ArrayType) - { - case AT_JBOD: - pArray->VDeviceType = VD_JBOD; - goto simple; - - case AT_RAID0: - if((pParam->BlockSizeShift < MinBlockSizeShift) || (pParam->BlockSizeShift > MaxBlockSizeShift)) - goto error; - pArray->VDeviceType = VD_RAID_0; - goto simple; - - case AT_RAID5: - if((pParam->BlockSizeShift < MinBlockSizeShift) || (pParam->BlockSizeShift > MaxBlockSizeShift)) - goto error; - pArray->VDeviceType = VD_RAID_5; - /* only "no build" R5 is not critical after creation. */ - if ((pParam->CreateFlags & CAF_CREATE_R5_NO_BUILD)==0) - pArray->u.array.rf_need_rebuild = 1; - goto simple; - - case AT_RAID1: - if(pParam->nDisk <= 2) - { - pArray->VDeviceType = VD_RAID_1; -simple: - pArray->u.array.bArnMember = pParam->nDisk; - pArray->u.array.bArRealnMember = pParam->nDisk; - pArray->u.array.bArBlockSizeShift = pParam->BlockSizeShift; - pArray->u.array.bStripeWitch = (1 << pParam->BlockSizeShift); - pArray->u.array.dArStamp = Stamp; - - pArray->u.array.rf_need_sync = 1; - pArray->u.array.rf_newly_created = 1; - - if ((pParam->CreateFlags & CAF_CREATE_AND_DUPLICATE) && - (pArray->VDeviceType == VD_RAID_1)) - { - pArray->u.array.rf_newly_created = 0; /* R1 shall still be accessible */ - pArray->u.array.rf_need_rebuild = 1; - pArray->u.array.rf_auto_rebuild = 1; - pArray->u.array.rf_duplicate_and_create = 1; - - for(i = 0; i < MAX_VDEVICE_PER_VBUS; i++) - if (_vbus_p->pVDevice[i] == ID_TO_VDEV(pParam->Members[0])) - Loca = i; - } - - pArray->u.array.RebuildSectors = pArray->u.array.rf_need_rebuild? 0 : MAX_LBA_T; - - memcpy(pArray->u.array.ArrayName, pParam->ArrayName, MAX_ARRAY_NAME); - - for(i = 0; i < pParam->nDisk; i++) - { - pArray->u.array.pMember[i] = ID_TO_VDEV(pParam->Members[i]); - pArray->u.array.pMember[i]->bSerialNumber = i; - pArray->u.array.pMember[i]->pParent = pArray; - - /* don't unregister source disk for duplicate RAID1 */ - if (i || - pArray->VDeviceType!=VD_RAID_1 || - (pParam->CreateFlags & CAF_CREATE_AND_DUPLICATE)==0) - UnregisterVDevice(pArray->u.array.pMember[i]); - - if(pArray->VDeviceType == VD_RAID_5) - pArray->u.array.pMember[i]->vf_cache_disk = 1; - } - } - else - { - for(i = 0; i < (pParam->nDisk / 2); i++) - { - mArGetArrayTable(pChild); - pChild->VDeviceType = VD_RAID_1; - - pChild->u.array.bArnMember = 2; - pChild->u.array.bArRealnMember = 2; - pChild->u.array.bArBlockSizeShift = pParam->BlockSizeShift; - pChild->u.array.bStripeWitch = (1 << pParam->BlockSizeShift); - pChild->u.array.dArStamp = Stamp; - - pChild->u.array.rf_need_sync = 1; - pChild->u.array.rf_newly_created = 1; - - pChild->u.array.RebuildSectors = MAX_LBA_T; - - memcpy(pChild->u.array.ArrayName, pParam->ArrayName, MAX_ARRAY_NAME); - - for(j = 0; j < 2; j++) - { - pChild->u.array.pMember[j] = ID_TO_VDEV(pParam->Members[i*2 + j]); - pChild->u.array.pMember[j]->bSerialNumber = j; - pChild->u.array.pMember[j]->pParent = pChild; - pChild->u.array.pMember[j]->pfnDeviceFailed = pfnDeviceFailed[pChild->VDeviceType]; - UnregisterVDevice(pChild->u.array.pMember[j]); - } - - pArray->u.array.pMember[i] = pChild; - - pChild->vf_online = 1; - pChild->bSerialNumber = i; - pChild->pParent = pArray; - pChild->VDeviceCapacity = MIN(pChild->u.array.pMember[0]->VDeviceCapacity, - pChild->u.array.pMember[1]->VDeviceCapacity); - - pChild->pfnSendCommand = pfnSendCommand[pChild->VDeviceType]; - pChild->pfnDeviceFailed = pfnDeviceFailed[VD_RAID_0]; - } - - pArray->VDeviceType = VD_RAID_0; - - pArray->u.array.bArnMember = pParam->nDisk / 2; - pArray->u.array.bArRealnMember = pParam->nDisk / 2; - pArray->u.array.bArBlockSizeShift = pParam->BlockSizeShift; - pArray->u.array.bStripeWitch = (1 << pParam->BlockSizeShift); - pArray->u.array.dArStamp = Stamp; - - pArray->u.array.rf_need_sync = 1; - pArray->u.array.rf_newly_created = 1; - - memcpy(pArray->u.array.ArrayName, pParam->ArrayName, MAX_ARRAY_NAME); - } - break; - - default: - goto error; - } - - for(i = 0; i < pArray->u.array.bArnMember; i++) - pArray->u.array.pMember[i]->pfnDeviceFailed = pfnDeviceFailed[pArray->VDeviceType]; - - if ((pParam->CreateFlags & CAF_CREATE_AND_DUPLICATE) && - (pArray->VDeviceType == VD_RAID_1)) - { - pArray->vf_bootmark = pArray->u.array.pMember[0]->vf_bootmark; - pArray->vf_bootable = pArray->u.array.pMember[0]->vf_bootable; - pArray->u.array.pMember[0]->vf_bootable = 0; - pArray->u.array.pMember[0]->vf_bootmark = 0; - if (Loca>=0) { - _vbus_p->pVDevice[Loca] = pArray; - /* to comfort OS */ - pArray->u.array.rf_duplicate_and_created = 1; - pArray->pVBus = _vbus_p; - } - } - else { - UCHAR TempBuffer[512]; - ZeroMemory(TempBuffer, 512); - for(i = 0; i < pParam->nDisk; i++) - { - PVDevice pDisk = ID_TO_VDEV(pParam->Members[i]); - pDisk->vf_bootmark = pDisk->vf_bootable = 0; - fDeReadWrite(&pDisk->u.disk, 0, IDE_COMMAND_WRITE, TempBuffer); - } - } - - pArray->vf_online = 1; - pArray->pParent = NULL; - - switch(pArray->VDeviceType) - { - case VD_RAID_0: - for(i = 0; i < pArray->u.array.bArnMember; i++) - if(pArray->u.array.pMember[i]->VDeviceCapacity < capacity) - capacity = pArray->u.array.pMember[i]->VDeviceCapacity; -#ifdef ARRAY_V2_ONLY - capacity -= 10; -#endif - capacity &= ~(pArray->u.array.bStripeWitch - 1); - /* shrink member capacity for RAID 1/0 */ - for(i = 0; i < pArray->u.array.bArnMember; i++) - if (mIsArray(pArray->u.array.pMember[i])) - pArray->u.array.pMember[i]->VDeviceCapacity = capacity; - pArray->VDeviceCapacity = capacity * pArray->u.array.bArnMember; - break; - - case VD_RAID_1: - pArray->VDeviceCapacity = MIN(pArray->u.array.pMember[0]->VDeviceCapacity, - pArray->u.array.pMember[1]->VDeviceCapacity); - break; - - case VD_JBOD: - for(i = 0; i < pArray->u.array.bArnMember; i++) - pArray->VDeviceCapacity += pArray->u.array.pMember[i]->VDeviceCapacity -#ifdef ARRAY_V2_ONLY - -10 -#endif - ; - break; - - case VD_RAID_5: - for(i = 0; i < pArray->u.array.bArnMember; i++) - if(pArray->u.array.pMember[i]->VDeviceCapacity < capacity) - capacity = pArray->u.array.pMember[i]->VDeviceCapacity; - pArray->VDeviceCapacity = (capacity & ~(pArray->u.array.bStripeWitch - 1)) - * (pArray->u.array.bArnMember - 1); - break; - - default: - goto error; - } - - pArray->pfnSendCommand = pfnSendCommand[pArray->VDeviceType]; - pArray->pfnDeviceFailed = fOsDiskFailed; - SyncArrayInfo(pArray); - - if (!pArray->u.array.rf_duplicate_and_created) - RegisterVDevice(pArray); - return VDEV_TO_ID(pArray); - -error: - for(i = 0; i < pArray->u.array.bArnMember; i++) - { - pChild = pArray->u.array.pMember[i]; - if((pChild != NULL) && (pChild->VDeviceType != VD_SINGLE_DISK)) - mArFreeArrayTable(pChild); - } - mArFreeArrayTable(pArray); - return INVALID_DEVICEID; -} - -#ifdef SUPPORT_OLD_ARRAY -/* this is only for old RAID 0/1 */ -int old_add_disk_to_raid01(_VBUS_ARG DEVICEID idArray, DEVICEID idDisk) -{ - PVDevice pArray1 = ID_TO_VDEV(idArray); - PVDevice pArray2 = 0; - PVDevice pDisk = ID_TO_VDEV(idDisk); - int i; - IAL_ADAPTER_T *pAdapter = gIal_Adapter; - -#if MAX_VBUS>1 - if (pArray1->pVBus!=_vbus_p) { HPT_ASSERT(0); return -1;} -#endif - - if(pDisk->u.disk.dDeRealCapacity < (pArray1->VDeviceCapacity / 2)) - return -1; - - pArray2 = pArray1->u.array.pMember[1]; - if(pArray2 == NULL) { - /* create a Stripe */ - mArGetArrayTable(pArray2); - pArray2->VDeviceType = VD_RAID_0; - pArray2->u.array.dArStamp = GetStamp(); - pArray2->vf_format_v2 = 1; - pArray2->u.array.rf_broken = 1; - pArray2->u.array.bArBlockSizeShift = pArray1->u.array.bArBlockSizeShift; - pArray2->u.array.bStripeWitch = (1 << pArray2->u.array.bArBlockSizeShift); - pArray2->u.array.bArnMember = 2; - pArray2->VDeviceCapacity = pArray1->VDeviceCapacity; - pArray2->pfnSendCommand = pfnSendCommand[pArray2->VDeviceType]; - pArray2->pfnDeviceFailed = pfnDeviceFailed[pArray1->VDeviceType]; - memcpy(pArray2->u.array.ArrayName, pArray1->u.array.ArrayName, MAX_ARRAY_NAME); - pArray2->pParent = pArray1; - pArray2->bSerialNumber = 1; - pArray1->u.array.pMember[1] = pArray2; - pArray1->u.array.bArRealnMember++; - } - - for(i = 0; i < pArray2->u.array.bArnMember; i++) - if((pArray2->u.array.pMember[i] == NULL) || !pArray2->u.array.pMember[i]->vf_online) - { - if(pArray2->u.array.pMember[i] != NULL) - pArray2->u.array.pMember[i]->pParent = NULL; - pArray2->u.array.pMember[i] = pDisk; - goto find; - } - return -1; - -find: - UnregisterVDevice(pDisk); - pDisk->VDeviceType = VD_SINGLE_DISK; - pDisk->bSerialNumber = i; - pDisk->pParent = pArray2; - pDisk->vf_format_v2 = 1; - pDisk->u.disk.dDeHiddenLba = i? 10 : 0; - pDisk->VDeviceCapacity = pDisk->u.disk.dDeRealCapacity; - pDisk->pfnDeviceFailed = pfnDeviceFailed[pArray2->VDeviceType]; - - pArray2->u.array.bArRealnMember++; - if(pArray2->u.array.bArnMember == pArray2->u.array.bArRealnMember){ - pArray2->vf_online = 1; - pArray2->u.array.rf_broken = 0; - } - - if(pArray1->u.array.pMember[0]->vf_online && pArray1->u.array.pMember[1]->vf_online){ - pArray1->u.array.bArRealnMember = pArray1->u.array.bArnMember; - pArray1->u.array.rf_broken = 0; - pArray1->u.array.rf_need_rebuild = 1; - pArray1->u.array.rf_auto_rebuild = 1; - - } - pArray1->u.array.RebuildSectors = 0; - pArray1->u.array.dArStamp = GetStamp(); - SyncArrayInfo(pArray1); - return 1; -} -#endif - -int hpt_add_disk_to_array(_VBUS_ARG DEVICEID idArray, DEVICEID idDisk) -{ - int i; - - ULONG Capacity; - PVDevice pArray = ID_TO_VDEV(idArray); - PVDevice pDisk = ID_TO_VDEV(idDisk); - - if((idArray == HPT_NULL_ID) || (idDisk == HPT_NULL_ID)) return -1; - if(check_VDevice_valid(pArray) || check_VDevice_valid(pDisk)) return -1; - if(!pArray->u.array.rf_broken) return -1; - - if(pArray->VDeviceType != VD_RAID_1 && pArray->VDeviceType != VD_RAID_5) - return -1; - if((pDisk->VDeviceType != VD_SINGLE_DISK) && (pDisk->VDeviceType != VD_SPARE)) - return -1; - -#ifdef SUPPORT_OLD_ARRAY - /* RAID 0 + 1 */ - if (pArray->vf_format_v2 && pArray->VDeviceType==VD_RAID_1 && - pArray->u.array.pMember[0] && - mIsArray(pArray->u.array.pMember[0])) - { - if(old_add_disk_to_raid01(_VBUS_P idArray, idDisk)) - return 0; - else - return -1; - } -#endif - - Capacity = pArray->VDeviceCapacity / (pArray->u.array.bArnMember - 1); - - if (pArray->vf_format_v2) { - if(pDisk->u.disk.dDeRealCapacity < Capacity) return -1; - } - else - if(pDisk->VDeviceCapacity < Capacity) return -1; - -#if MAX_VBUS>1 - if (pArray->pVBus!=_vbus_p) { HPT_ASSERT(0); return -1;} -#endif - - for(i = 0; i < pArray->u.array.bArnMember; i++) - if((pArray->u.array.pMember[i] == NULL) || !pArray->u.array.pMember[i]->vf_online) - { - if(pArray->u.array.pMember[i] != NULL) - pArray->u.array.pMember[i]->pParent = NULL; - pArray->u.array.pMember[i] = pDisk; - goto find; - } - return -1; - -find: - UnregisterVDevice(pDisk); - pDisk->VDeviceType = VD_SINGLE_DISK; - pDisk->bSerialNumber = i; - pDisk->pParent = pArray; - if (pArray->VDeviceType==VD_RAID_5) pDisk->vf_cache_disk = 1; - pDisk->pfnDeviceFailed = pfnDeviceFailed[pArray->VDeviceType]; - if (pArray->vf_format_v2) { - pDisk->vf_format_v2 = 1; - pDisk->VDeviceCapacity = pDisk->u.disk.dDeRealCapacity; - } - - pArray->u.array.bArRealnMember++; - if(pArray->u.array.bArnMember == pArray->u.array.bArRealnMember) - { - pArray->u.array.rf_need_rebuild = 1; - pArray->u.array.RebuildSectors = 0; - pArray->u.array.rf_auto_rebuild = 1; - pArray->u.array.rf_broken = 0; - } - pArray->u.array.RebuildSectors = 0; - - /* sync the whole array */ - while (pArray->pParent) pArray = pArray->pParent; - pArray->u.array.dArStamp = GetStamp(); - SyncArrayInfo(pArray); - return 0; -} - -static int hpt_add_spare_disk(_VBUS_ARG DEVICEID idDisk) -{ - PVDevice pVDevice = ID_TO_VDEV(idDisk); - DECLARE_BUFFER(PUCHAR, pbuffer); - - if(idDisk == HPT_NULL_ID || check_VDevice_valid(pVDevice)) - return -1; - if (pVDevice->VDeviceType != VD_SINGLE_DISK || pVDevice->pParent) - return -1; - -#if MAX_VBUS>1 - if (pVDevice->u.disk.pVBus!=_vbus_p) return -1; -#endif - - UnregisterVDevice(pVDevice); - pVDevice->VDeviceType = VD_SPARE; - pVDevice->vf_bootmark = 0; - - ZeroMemory((char *)pbuffer, 512); - fDeReadWrite(&pVDevice->u.disk, 0, IDE_COMMAND_WRITE, pbuffer); - SyncArrayInfo(pVDevice); - return 0; -} - -static int hpt_remove_spare_disk(_VBUS_ARG DEVICEID idDisk) -{ - PVDevice pVDevice = ID_TO_VDEV(idDisk); - - if(idDisk == 0 || check_VDevice_valid(pVDevice)) return -1; - -#if MAX_VBUS>1 - if (pVDevice->u.disk.pVBus!=_vbus_p) return -1; -#endif - - pVDevice->VDeviceType = VD_SINGLE_DISK; - - SyncArrayInfo(pVDevice); - RegisterVDevice(pVDevice); - return 0; -} - -static int hpt_set_array_info(_VBUS_ARG DEVICEID idArray, PALTERABLE_ARRAY_INFO pInfo) -{ - PVDevice pVDevice = ID_TO_VDEV(idArray); - - if(idArray == HPT_NULL_ID || check_VDevice_valid(pVDevice)) return -1; - if (!mIsArray(pVDevice)) return -1; - - /* if the pVDevice isn't a top level, return -1; */ - if(pVDevice->pParent != NULL) return -1; - -#if MAX_VBUS>1 - if (pVDevice->pVBus!=_vbus_p) { HPT_ASSERT(0); return -1;} -#endif - - if (pInfo->ValidFields & AAIF_NAME) { - memset(pVDevice->u.array.ArrayName, 0, MAX_ARRAY_NAME); - memcpy(pVDevice->u.array.ArrayName, pInfo->Name, sizeof(pInfo->Name)); - pVDevice->u.array.rf_need_sync = 1; - } - - if (pInfo->ValidFields & AAIF_DESCRIPTION) { - memcpy(pVDevice->u.array.Description, pInfo->Description, sizeof(pInfo->Description)); - pVDevice->u.array.rf_need_sync = 1; - } - - if (pVDevice->u.array.rf_need_sync) - SyncArrayInfo(pVDevice); - return 0; -} - -static int hpt_set_device_info(_VBUS_ARG DEVICEID idDisk, PALTERABLE_DEVICE_INFO pInfo) -{ - PVDevice pVDevice = ID_TO_VDEV(idDisk); - - /* stop buzzer. */ - if(idDisk == HPT_NULL_ID) { -#ifndef FOR_DEMO - IAL_ADAPTER_T *pAdapter; - for (pAdapter=gIal_Adapter; pAdapter; pAdapter=pAdapter->next) { - if (pAdapter->beeping) { - pAdapter->beeping = 0; - BeepOff(pAdapter->mvSataAdapter.adapterIoBaseAddress); - } - } -#endif - return 0; - } - - if (check_VDevice_valid(pVDevice)) return -1; - if (mIsArray(pVDevice)) - return -1; - -#if MAX_VBUS>1 - if (pVDevice->u.disk.pVBus!=_vbus_p) return -1; -#endif - -/* if (pInfo->ValidFields & ADIF_MODE) { - pVDevice->u.disk.bDeModeSetting = pInfo->DeviceModeSetting; - pVDevice->u.disk.bDeUserSelectMode = pInfo->DeviceModeSetting; - pVDevice->u.disk.df_user_mode_set = 1; - fDeSelectMode((PDevice)&(pVDevice->u.disk), (UCHAR)pInfo->DeviceModeSetting); - SyncArrayInfo(pVDevice); - }*/ - return 0; -} -#endif /* SUPPORT_ARRAY */ - -#ifdef SUPPORT_HPT601 -int hpt_get_601_info(DEVICEID idDisk, PHPT601_INFO pInfo) -{ - PVDevice pVDevice = ID_TO_VDEV(idDisk); - PChannel pChan = pVDevice->u.disk.pChannel; - PIDE_REGISTERS_1 IoPort = pChan->BaseIoAddress1; - - if(!pVDevice->u.disk.df_with_601) return -1; - - mSelectUnit(IoPort, pVDevice->u.disk.bDeUnitId); - pChan->pChipInstance->ftbl.pfnWaitOnBusy(pChan, pVDevice->u.disk.bDeUnitId, 1); - - BeginAccess601(IoPort); - - mSetBlockCount(IoPort, 0); - pInfo->DeviceId = InWord(&IoPort->Data); - - mSetBlockCount(IoPort, 0x14); - pInfo->Temperature = InWord(&IoPort->Data); - - mSetBlockCount(IoPort, 0xA); - pInfo->FanStatus = InWord(&IoPort->Data); - - mSetBlockCount(IoPort, 7); - pInfo->BeeperControl = InWord(&IoPort->Data); - - mSetBlockCount(IoPort, 3); - pInfo->LED1Control = InWord(&IoPort->Data); - - mSetBlockCount(IoPort, 5); - pInfo->LED2Control = InWord(&IoPort->Data); - - mSetBlockCount(IoPort, 0x18); - pInfo->PowerStatus = InWord(&IoPort->Data); - - EndAccess601(IoPort); - pInfo->ValidFields = 0x7F; - /*DEVICEID|TEMPERATURE|FANSTATUS|BEEPERCONTROL|LED1CONTROL|LED2CONTROL|POWERSTATUS*/ - return 0; -} - -int hpt_set_601_info(DEVICEID idDisk, PHPT601_INFO pInfo) -{ - PVDevice pVDevice = ID_TO_VDEV(idDisk); - PChannel pChan = pVDevice->u.disk.pChannel; - PIDE_REGISTERS_1 IoPort = pChan->BaseIoAddress1; - - if(!pVDevice->u.disk.df_with_601) return -1; - - mSelectUnit(IoPort, pVDevice->u.disk.bDeUnitId); - pChan->pChipInstance->ftbl.pfnWaitOnBusy(pChan, pVDevice->u.disk.bDeUnitId, 1); - - BeginAccess601(IoPort); - - if (pInfo->ValidFields & HPT601_INFO_TEMPERATURE) { - mSetBlockCount(IoPort, 1); - OutWord(&IoPort->Data, pInfo->Temperature); - } - - if (pInfo->ValidFields & HPT601_INFO_FANSTATUS) { - mSetBlockCount(IoPort, 0xA); - OutWord(&IoPort->Data, pInfo->FanStatus); - } - - if (pInfo->ValidFields & HPT601_INFO_BEEPERCONTROL) { - mSetBlockCount(IoPort, 7); - OutWord(&IoPort->Data, pInfo->BeeperControl); - } - - if (pInfo->ValidFields & HPT601_INFO_LED1CONTROL) { - mSetBlockCount(IoPort, 3); - OutWord(&IoPort->Data, pInfo->LED1Control); - } - - if (pInfo->ValidFields & HPT601_INFO_LED2CONTROL) { - mSetBlockCount(IoPort, 5); - OutWord(&IoPort->Data, pInfo->LED2Control); - } - - EndAccess601(IoPort); - - return 0; -} -#endif - -/* hpt_default_ioctl() - * This is a default implementation. The platform dependent part - * may reuse this function and/or use it own implementation for - * each ioctl function. - */ -int hpt_default_ioctl(_VBUS_ARG - DWORD dwIoControlCode, /* operation control code */ - PVOID lpInBuffer, /* input data buffer */ - DWORD nInBufferSize, /* size of input data buffer */ - PVOID lpOutBuffer, /* output data buffer */ - DWORD nOutBufferSize, /* size of output data buffer */ - PDWORD lpBytesReturned /* byte count */ - ) -{ - switch(dwIoControlCode) { - - case HPT_IOCTL_GET_VERSION: - - if (nInBufferSize != 0) return -1; - if (nOutBufferSize != sizeof(DWORD)) return -1; - *((DWORD*)lpOutBuffer) = HPT_INTERFACE_VERSION; - break; - - case HPT_IOCTL_GET_CONTROLLER_COUNT: - - if (nOutBufferSize!=sizeof(DWORD)) return -1; - *(PDWORD)lpOutBuffer = hpt_get_controller_count(); - break; - - case HPT_IOCTL_GET_CONTROLLER_INFO: - { - int id; - PCONTROLLER_INFO pInfo; - - if (nInBufferSize!=sizeof(DWORD)) return -1; - if (nOutBufferSize!=sizeof(CONTROLLER_INFO)) return -1; - - id = *(DWORD *)lpInBuffer; - pInfo = (PCONTROLLER_INFO)lpOutBuffer; - if (hpt_get_controller_info(id, pInfo)!=0) - return -1; - } - break; - - case HPT_IOCTL_GET_CHANNEL_INFO: - { - int id, bus; - PCHANNEL_INFO pInfo; - - if (nInBufferSize!=8) return -1; - if (nOutBufferSize!=sizeof(CHANNEL_INFO)) return -1; - - id = *(DWORD *)lpInBuffer; - bus = ((DWORD *)lpInBuffer)[1]; - pInfo = (PCHANNEL_INFO)lpOutBuffer; - - if (hpt_get_channel_info(id, bus, pInfo)!=0) - return -1; - } - break; - - case HPT_IOCTL_GET_LOGICAL_DEVICES: - { - DWORD nMax; - DEVICEID *pIds; - - if (nInBufferSize!=sizeof(DWORD)) return -1; - nMax = *(DWORD *)lpInBuffer; - if (nOutBufferSize < sizeof(DWORD)+sizeof(DWORD)*nMax) return -1; - - pIds = ((DEVICEID *)lpOutBuffer)+1; - *(DWORD*)lpOutBuffer = hpt_get_logical_devices(pIds, nMax); - } - break; - - case HPT_IOCTL_GET_DEVICE_INFO: - { - DEVICEID id; - PLOGICAL_DEVICE_INFO pInfo; - - if (nInBufferSize!=sizeof(DEVICEID)) return -1; - if (nOutBufferSize!=sizeof(LOGICAL_DEVICE_INFO)) return -1; - - id = *(DWORD *)lpInBuffer; - if (id == INVALID_DEVICEID) return -1; - - pInfo = (PLOGICAL_DEVICE_INFO)lpOutBuffer; - memset(pInfo, 0, sizeof(LOGICAL_DEVICE_INFO)); - - if (hpt_get_device_info(id, pInfo)!=0) - return -1; - } - break; - -#ifdef SUPPORT_ARRAY - case HPT_IOCTL_CREATE_ARRAY: - { - CREATE_ARRAY_PARAMS *pParam; - DEVICEID id; - - if (nInBufferSize!=sizeof(CREATE_ARRAY_PARAMS)) return -1; - if (nOutBufferSize!=sizeof(DEVICEID)) return -1; - - pParam = (PCREATE_ARRAY_PARAMS)lpInBuffer; - - id = hpt_create_array(_VBUS_P pParam); - *(DEVICEID *)lpOutBuffer = id; - - if(id == (DEVICEID)INVALID_DEVICEID) - return -1; - } - break; - - case HPT_IOCTL_SET_ARRAY_INFO: - { - DEVICEID idArray; - PALTERABLE_ARRAY_INFO pInfo; - - if (nInBufferSize!=sizeof(HPT_SET_ARRAY_INFO)) return -1; - if (nOutBufferSize!=0) return -1; - - idArray = ((PHPT_SET_ARRAY_INFO)lpInBuffer)->idArray; - pInfo = &((PHPT_SET_ARRAY_INFO)lpInBuffer)->Info; - - if(hpt_set_array_info(_VBUS_P idArray, pInfo)) - return -1; - } - break; - - case HPT_IOCTL_SET_DEVICE_INFO: - { - DEVICEID idDisk; - PALTERABLE_DEVICE_INFO pInfo; - - if (nInBufferSize!=sizeof(HPT_SET_DEVICE_INFO)) return -1; - if (nOutBufferSize!=0) return -1; - - idDisk = ((PHPT_SET_DEVICE_INFO)lpInBuffer)->idDisk; - pInfo = &((PHPT_SET_DEVICE_INFO)lpInBuffer)->Info; - if(hpt_set_device_info(_VBUS_P idDisk, pInfo) != 0) - return -1; - } - break; - - case HPT_IOCTL_SET_BOOT_MARK: - { - DEVICEID id; - PVDevice pTop; - int i; - IAL_ADAPTER_T *pAdapter = gIal_Adapter; - PVBus pVBus; - - if (nInBufferSize!=sizeof(DEVICEID)) return -1; - id = *(DEVICEID *)lpInBuffer; - while(pAdapter != 0) - { - pVBus = &pAdapter->VBus; - for(i = 0; i < MAX_ARRAY_PER_VBUS; i++) - { - if(!(pTop = pVBus->pVDevice[i])) continue; -#if MAX_VBUS>1 - if (pTop->pVBus!=_vbus_p) return -1; -#endif - while (pTop->pParent) pTop = pTop->pParent; - if (id==0 && pTop->vf_bootmark) - pTop->vf_bootmark = 0; - else if (pTop==ID_TO_VDEV(id) && !pTop->vf_bootmark) - pTop->vf_bootmark = 1; - else - continue; - SyncArrayInfo(pTop); - break; - } - pAdapter = pAdapter->next; - } - } - break; -#endif /* SUPPORT_ARRAY */ - case HPT_IOCTL_RESCAN_DEVICES: - { - fRescanAllDevice(_VBUS_P0); - if (nInBufferSize!=0) return -1; - if (nOutBufferSize!=0) return -1; - fRescanAllDevice(_VBUS_P0); - } - break; - -#ifdef SUPPORT_ARRAY - case HPT_IOCTL_ADD_SPARE_DISK: - { - DEVICEID id; - - if (nInBufferSize!=sizeof(DEVICEID)) return -1; - if (nOutBufferSize!=0) return -1; - - id = *(DEVICEID *)lpInBuffer; - - if(hpt_add_spare_disk(_VBUS_P id)) - return -1; - } - break; - - case HPT_IOCTL_REMOVE_SPARE_DISK: - { - DEVICEID id; - - if (nInBufferSize!=sizeof(DEVICEID)) return -1; - if (nOutBufferSize!=0) return -1; - - id = *(DEVICEID *)lpInBuffer; - - if(hpt_remove_spare_disk(_VBUS_P id)) - return -1; - } - break; - - case HPT_IOCTL_ADD_DISK_TO_ARRAY: - { - DEVICEID id1,id2; - id1 = ((PHPT_ADD_DISK_TO_ARRAY)lpInBuffer)->idArray; - id2 = ((PHPT_ADD_DISK_TO_ARRAY)lpInBuffer)->idDisk; - - if (nInBufferSize != sizeof(HPT_ADD_DISK_TO_ARRAY)) return -1; - if (nOutBufferSize != 0) return -1; - - if(hpt_add_disk_to_array(_VBUS_P id1, id2)) - return -1; - } - break; -#endif - case HPT_IOCTL_GET_DRIVER_CAPABILITIES: - { - PDRIVER_CAPABILITIES cap; - if (nOutBufferSizeidDisk; - pInfo = &((PHPT_SET_601_INFO)lpInBuffer)->Info; - if(hpt_set_601_info(id, pInfo) != 0) - return -1; - } - break; -#endif - default: - return -1; - } - - if (lpBytesReturned) - *lpBytesReturned = nOutBufferSize; - return 0; -} diff --git a/sys/contrib/dev/hptmv/hptproc.c b/sys/contrib/dev/hptmv/hptproc.c deleted file mode 100644 index e05798f1eb74..000000000000 --- a/sys/contrib/dev/hptmv/hptproc.c +++ /dev/null @@ -1,600 +0,0 @@ -/* - * Copyright (c) 2003-2004 HighPoint Technologies, Inc. - * All rights reserved. - * - * Redistribution and use in source and binary forms, with or without - * modification, are permitted provided that the following conditions - * are met: - * 1. Redistributions of source code must retain the above copyright - * notice, this list of conditions and the following disclaimer. - * 2. Redistributions in binary form must reproduce the above copyright - * notice, this list of conditions and the following disclaimer in the - * documentation and/or other materials provided with the distribution. - * - * THIS SOFTWARE IS PROVIDED BY THE AUTHOR AND CONTRIBUTORS ``AS IS'' AND - * ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE - * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE - * ARE DISCLAIMED. IN NO EVENT SHALL THE AUTHOR OR CONTRIBUTORS BE LIABLE - * FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL - * DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS - * OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) - * HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT - * LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY - * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF - * SUCH DAMAGE. - */ -/* - * hptproc.c sysctl support - */ -#include -#include -#include -#include -#include -#include - -#include -#include -#include -#include - -int hpt_rescan_all(void); - -/***************************************************************************/ - -static char hptproc_buffer[256]; - -#define FORMAL_HANDLER_ARGS struct sysctl_oid *oidp, void *arg1, int arg2, \ - struct sysctl_req *req -#define REAL_HANDLER_ARGS oidp, arg1, arg2, req -typedef struct sysctl_req HPT_GET_INFO; - -static int hpt_set_asc_info(IAL_ADAPTER_T *pAdapter, char *buffer,int length) -{ - int orig_length = length+4; - PVBus _vbus_p = &pAdapter->VBus; - PVDevice pArray; - PVDevice pSubArray, pVDev; - UINT i, iarray, ichan; - struct cam_periph *periph = NULL; - intrmask_t oldspl; - -#ifdef SUPPORT_ARRAY - if (length>=8 && strncmp(buffer, "rebuild ", 8)==0) - { - buffer+=8; - length-=8; - if (length>=5 && strncmp(buffer, "start", 5)==0) - { - oldspl = lock_driver(); - for(i = 0; i < MAX_ARRAY_PER_VBUS; i++) - if ((pArray=ArrayTables(i))->u.array.dArStamp==0) - continue; - else{ - if (pArray->u.array.rf_need_rebuild && !pArray->u.array.rf_rebuilding) - hpt_queue_dpc((HPT_DPC)hpt_rebuild_data_block, pAdapter, pArray, - (UCHAR)((pArray->u.array.CriticalMembers || pArray->VDeviceType == VD_RAID_1)? DUPLICATE : REBUILD_PARITY)); - } - unlock_driver(oldspl); - return orig_length; - } - else if (length>=4 && strncmp(buffer, "stop", 4)==0) - { - oldspl = lock_driver(); - for(i = 0; i < MAX_ARRAY_PER_VBUS; i++) - if ((pArray=ArrayTables(i))->u.array.dArStamp==0) - continue; - else{ - if (pArray->u.array.rf_rebuilding) - pArray->u.array.rf_abort_rebuild = 1; - } - unlock_driver(oldspl); - return orig_length; - } - else if (length>=3 && buffer[1]==','&& buffer[0]>='1'&& buffer[2]>='1') - { - iarray = buffer[0]-'1'; - ichan = buffer[2]-'1'; - - if(iarray >= MAX_VDEVICE_PER_VBUS || ichan >= MV_SATA_CHANNELS_NUM) return -EINVAL; - - pArray = _vbus_p->pVDevice[iarray]; - if (!pArray || (pArray->vf_online == 0)) return -EINVAL; - - for (i=0;iVDevices[ichan]; - if(!pVDev->u.disk.df_on_line || pVDev->pParent) return -EINVAL; - - /* Not allow to use a mounted disk ??? test*/ - for(i = 0; i < MAX_VDEVICE_PER_VBUS; i++) - if(pVDev == _vbus_p->pVDevice[i]) - { - periph = hpt_get_periph(pAdapter->mvSataAdapter.adapterId,i); - if (periph != NULL && periph->refcount == 1) - { - hpt_printk(("Can not use disk used by OS!\n")); - return -EINVAL; - } - /* the Mounted Disk isn't delete */ - } - - switch(pArray->VDeviceType) - { - case VD_RAID_1: - case VD_RAID_5: - { - pSubArray = pArray; -loop: - oldspl = lock_driver(); - if(hpt_add_disk_to_array(_VBUS_P VDEV_TO_ID(pSubArray), VDEV_TO_ID(pVDev)) == -1) { - unlock_driver(oldspl); - return -EINVAL; - } - pArray->u.array.rf_auto_rebuild = 0; - pArray->u.array.rf_abort_rebuild = 0; - hpt_queue_dpc((HPT_DPC)hpt_rebuild_data_block, pAdapter, pArray, DUPLICATE); - unlock_driver(oldspl); - break; - } - case VD_RAID_0: - for (i = 0; (UCHAR)i < pArray->u.array.bArnMember; i++) - if(pArray->u.array.pMember[i] && mIsArray(pArray->u.array.pMember[i]) && - (pArray->u.array.pMember[i]->u.array.rf_broken == 1)) - { - pSubArray = pArray->u.array.pMember[i]; - goto loop; - } - default: - return -EINVAL; - } - return orig_length; - } - } - else if (length>=7 && strncmp(buffer, "verify ", 7)==0) - { - buffer+=7; - length-=7; - if (length>=6 && strncmp(buffer, "start ", 6)==0) - { - buffer+=6; - length-=6; - if (length>=1 && *buffer>='1') - { - iarray = *buffer-'1'; - if(iarray >= MAX_VDEVICE_PER_VBUS) return -EINVAL; - - pArray = _vbus_p->pVDevice[iarray]; - if (!pArray || (pArray->vf_online == 0)) return -EINVAL; - - if(pArray->VDeviceType != VD_RAID_1 && pArray->VDeviceType != VD_RAID_5) - return -EINVAL; - - if (!(pArray->u.array.rf_need_rebuild || - pArray->u.array.rf_rebuilding || - pArray->u.array.rf_verifying || - pArray->u.array.rf_initializing)) - { - oldspl = lock_driver(); - pArray->u.array.RebuildSectors = 0; - hpt_queue_dpc((HPT_DPC)hpt_rebuild_data_block, pAdapter, pArray, VERIFY); - unlock_driver(oldspl); - } - return orig_length; - } - } - else if (length>=5 && strncmp(buffer, "stop ", 5)==0) - { - buffer+=5; - length-=5; - if (length>=1 && *buffer>='1') - { - iarray = *buffer-'1'; - if(iarray >= MAX_VDEVICE_PER_VBUS) return -EINVAL; - - pArray = _vbus_p->pVDevice[iarray]; - if (!pArray || (pArray->vf_online == 0)) return -EINVAL; - if(pArray->u.array.rf_verifying) - { - oldspl = lock_driver(); - pArray->u.array.rf_abort_rebuild = 1; - unlock_driver(oldspl); - } - return orig_length; - } - } - } - else -#ifdef _RAID5N_ - if (length>=10 && strncmp(buffer, "writeback ", 10)==0) { - buffer+=10; - length-=10; - if (length>=1 && *buffer>='0' && *buffer<='1') { - _vbus_(r5.enable_write_back) = *buffer-'0'; - if (_vbus_(r5.enable_write_back)) - hpt_printk(("RAID5 write back enabled")); - return orig_length; - } - } - else -#endif -#endif /* SUPPORT_ARRAY */ - if (0) {} /* just to compile */ -#if DBGUG - else if (length>=9 && strncmp(buffer, "dbglevel ", 9)==0) { - buffer+=9; - length-=9; - if (length>=1 && *buffer>='0' && *buffer<='3') { - hpt_dbg_level = *buffer-'0'; - return orig_length; - } - } - else if (length>=8 && strncmp(buffer, "disable ", 8)==0) { - /* TO DO */ - } -#endif - - return -EINVAL; -} - -/* - * Since we have only one sysctl node, add adapter ID in the command - * line string: e.g. "hpt 0 rebuild start" - */ -static int hpt_set_info(int length) -{ - int retval; - -#ifdef SUPPORT_IOCTL - PUCHAR ke_area; - int err; - DWORD dwRet; - PHPT_IOCTL_PARAM32 piop; -#endif - char *buffer = hptproc_buffer; - if (length >= 6) { - if (strncmp(buffer,"hpt ",4) == 0) { - IAL_ADAPTER_T *pAdapter; - retval = buffer[4]-'0'; - for (pAdapter=gIal_Adapter; pAdapter; pAdapter=pAdapter->next) { - if (pAdapter->mvSataAdapter.adapterId==retval) - return (retval = hpt_set_asc_info(pAdapter, buffer+6, length-6)) >= 0? retval : -EINVAL; - } - return -EINVAL; - } -#ifdef SUPPORT_IOCTL - piop = (PHPT_IOCTL_PARAM32)buffer; - if (piop->Magic == HPT_IOCTL_MAGIC) { - KdPrintE(("ioctl=%d in=%x len=%d out=%x len=%ld\n", - piop->dwIoControlCode, - piop->lpInBuffer, - piop->nInBufferSize, - piop->lpOutBuffer, - (u_long)piop->nOutBufferSize)); - - /* - * map buffer to kernel. - */ - if (piop->nInBufferSize+piop->nOutBufferSize > PAGE_SIZE) { - KdPrintE(("User buffer too large\n")); - return -EINVAL; - } - - ke_area = malloc(piop->nInBufferSize+piop->nOutBufferSize, M_DEVBUF, M_NOWAIT); - if (ke_area == NULL) { - KdPrintE(("Couldn't allocate kernel mem.\n")); - return -EINVAL; - } - - if (piop->nInBufferSize) - copyin((void*)(ULONG_PTR)piop->lpInBuffer, ke_area, piop->nInBufferSize); - - /* - * call kernel handler. - */ - err = Kernel_DeviceIoControl(&gIal_Adapter->VBus, - piop->dwIoControlCode, ke_area, piop->nInBufferSize, - ke_area + piop->nInBufferSize, piop->nOutBufferSize, &dwRet); - - if (err==0) { - if (piop->nOutBufferSize) - copyout(ke_area + piop->nInBufferSize, (void*)(ULONG_PTR)piop->lpOutBuffer, piop->nOutBufferSize); - - if (piop->lpBytesReturned) - copyout(&dwRet, (void*)(ULONG_PTR)piop->lpBytesReturned, sizeof(DWORD)); - - free(ke_area, M_DEVBUF); - return length; - } - else KdPrintW(("Kernel_ioctl(): return %d\n", err)); - - free(ke_area, M_DEVBUF); - return -EINVAL; - } else { - KdPrintW(("Wrong signature: %x\n", piop->Magic)); - return -EINVAL; - } -#endif - } - - return -EINVAL; -} - -#define shortswap(w) ((WORD)((w)>>8 | ((w) & 0xFF)<<8)) - -static void get_disk_name(char *name, PDevice pDev) -{ - int i; - MV_SATA_CHANNEL *pMvSataChannel = pDev->mv; - IDENTIFY_DATA2 *pIdentifyData = (IDENTIFY_DATA2 *)pMvSataChannel->identifyDevice; - - for (i = 0; i < 10; i++) - ((WORD*)name)[i] = shortswap(pIdentifyData->ModelNumber[i]); - name[20] = '\0'; -} - -static int hpt_copy_info(HPT_GET_INFO *pinfo, char *fmt, ...) -{ - int printfretval; - va_list ap; - - if(fmt == NULL) { - *hptproc_buffer = 0; - return (SYSCTL_OUT(pinfo, hptproc_buffer, 1)); - } - else - { - va_start(ap, fmt); - printfretval = vsnprintf(hptproc_buffer, sizeof(hptproc_buffer), fmt, ap); - va_end(ap); - return(SYSCTL_OUT(pinfo, hptproc_buffer, strlen(hptproc_buffer))); - } -} - -static void hpt_copy_disk_info(HPT_GET_INFO *pinfo, PVDevice pVDev, UINT iChan) -{ - char name[32], arrayname[16]; - - get_disk_name(name, &pVDev->u.disk); - -#ifdef SUPPORT_ARRAY - if(pVDev->pParent) - memcpy(arrayname, pVDev->pParent->u.array.ArrayName, MAX_ARRAY_NAME); - else -#endif - arrayname[0]=0; - - hpt_copy_info(pinfo, "Channel %d %s %5dMB %s %s\n", - iChan+1, - name, pVDev->VDeviceCapacity>>11, - ((!pVDev->u.disk.df_on_line)? "Disabled" : - ((pVDev->VDeviceType != VD_SPARE)?"Normal ":"Spare ")), arrayname); -} - -#ifdef SUPPORT_ARRAY -static void hpt_copy_array_info(HPT_GET_INFO *pinfo, int nld, PVDevice pArray) -{ - int i; - char *sType=0, *sStatus=0; - char buf[32]; - PVDevice pTmpArray; - - switch (pArray->VDeviceType) { - case VD_RAID_0: - for (i = 0; (UCHAR)i < pArray->u.array.bArnMember; i++) - if(pArray->u.array.pMember[i]) { - if(mIsArray(pArray->u.array.pMember[i])) - sType = "RAID 1/0 "; - /* TO DO */ - else - sType = "RAID 0 "; - break; - } - break; - - case VD_RAID_1: - sType = "RAID 1 "; - break; - - case VD_JBOD: - sType = "JBOD "; - break; - - case VD_RAID_5: - sType = "RAID 5 "; - break; - - default: - sType = "N/A "; - break; - } - - if (pArray->vf_online == 0) - sStatus = "Disabled"; - else if (pArray->u.array.rf_broken) - sStatus = "Critical"; - for (i = 0; (UCHAR)i < pArray->u.array.bArnMember; i++) - { - if (!sStatus) - { - if(mIsArray(pArray->u.array.pMember[i])) - pTmpArray = pArray->u.array.pMember[i]; - else - pTmpArray = pArray; - - if (pTmpArray->u.array.rf_rebuilding) { -#ifdef DEBUG - sprintf(buf, "Rebuilding %dMB", (pTmpArray->u.array.RebuildSectors>>11)); -#else - sprintf(buf, "Rebuilding %d%%", (pTmpArray->u.array.RebuildSectors>>11)*100/((pTmpArray->VDeviceCapacity/(pTmpArray->u.array.bArnMember-1))>>11)); -#endif - sStatus = buf; - } - else if (pTmpArray->u.array.rf_verifying) { - sprintf(buf, "Verifying %d%%", (pTmpArray->u.array.RebuildSectors>>11)*100/((pTmpArray->VDeviceCapacity/(pTmpArray->u.array.bArnMember-1))>>11)); - sStatus = buf; - } - else if (pTmpArray->u.array.rf_need_rebuild) - sStatus = "Critical"; - else if (pTmpArray->u.array.rf_broken) - sStatus = "Critical"; - - if(pTmpArray == pArray) goto out; - } - else - goto out; - } -out: - if (!sStatus) sStatus = "Normal"; - hpt_copy_info(pinfo, "%2d %11s %-20s %5dMB %-16s", nld, sType, pArray->u.array.ArrayName, pArray->VDeviceCapacity>>11, sStatus); -} -#endif - -static int hpt_get_info(IAL_ADAPTER_T *pAdapter, HPT_GET_INFO *pinfo) -{ - PVBus _vbus_p = &pAdapter->VBus; - struct cam_periph *periph = NULL; - UINT channel,j,i; - PVDevice pVDev; - -#ifndef FOR_DEMO - if (pAdapter->beeping) { - intrmask_t oldspl = lock_driver(); - pAdapter->beeping = 0; - BeepOff(pAdapter->mvSataAdapter.adapterIoBaseAddress); - unlock_driver(oldspl); - } -#endif - - hpt_copy_info(pinfo, "Controller #%d:\n\n", pAdapter->mvSataAdapter.adapterId); - - hpt_copy_info(pinfo, "Physical device list\n"); - hpt_copy_info(pinfo, "Channel Model Capacity Status Array\n"); - hpt_copy_info(pinfo, "-------------------------------------------------------------------\n"); - - for (channel = 0; channel < MV_SATA_CHANNELS_NUM; channel++) - { - pVDev = &(pAdapter->VDevices[channel]); - if(pVDev->u.disk.df_on_line) - hpt_copy_disk_info(pinfo, pVDev, channel); - } - - hpt_copy_info(pinfo, "\nLogical device list\n"); - hpt_copy_info(pinfo, "No. Type Name Capacity Status OsDisk\n"); - hpt_copy_info(pinfo, "--------------------------------------------------------------------------\n"); - - j=1; - for(i = 0; i < MAX_VDEVICE_PER_VBUS; i++){ - pVDev = _vbus_p->pVDevice[i]; - if(pVDev){ - j=i+1; -#ifdef SUPPORT_ARRAY - if (mIsArray(pVDev)) - { - is_array: - hpt_copy_array_info(pinfo, j, pVDev); - } - else -#endif - { - char name[32]; - /* it may be add to an array after driver loaded, check it */ -#ifdef SUPPORT_ARRAY - if (pVDev->pParent) - /* in this case, pVDev can only be a RAID 1 source disk. */ - if (pVDev->pParent->VDeviceType==VD_RAID_1 && pVDev==pVDev->pParent->u.array.pMember[0]) - goto is_array; -#endif - get_disk_name(name, &pVDev->u.disk); - - hpt_copy_info(pinfo, "%2d %s %s %5dMB %-16s", - j, "Single disk", name, pVDev->VDeviceCapacity>>11, - /* gmm 2001-6-19: Check if pDev has been added to an array. */ - ((pVDev->pParent) ? "Unavailable" : "Normal")); - } - periph = hpt_get_periph(pAdapter->mvSataAdapter.adapterId, i); - if (periph == NULL) - hpt_copy_info(pinfo," %s\n","not registered"); - else - hpt_copy_info(pinfo," %s%d\n", periph->periph_name, periph->unit_number); - } - } - return 0; -} - -static inline int hpt_proc_in(FORMAL_HANDLER_ARGS, int *len) -{ - int i, error=0; - - *len = 0; - if ((req->newlen - req->newidx) >= sizeof(hptproc_buffer)) { - error = EINVAL; - } else { - i = (req->newlen - req->newidx); - error = SYSCTL_IN(req, hptproc_buffer, i); - if (!error) - *len = i; - (hptproc_buffer)[i] = '\0'; - } - return (error); -} - -static int hpt_status(FORMAL_HANDLER_ARGS) -{ - int length, error=0, retval=0; - IAL_ADAPTER_T *pAdapter; - - error = hpt_proc_in(REAL_HANDLER_ARGS, &length); - - if (req->newptr != NULL) - { - if (error || length == 0) - { - KdPrint(("error!\n")); - retval = EINVAL; - goto out; - } - - if (hpt_set_info(length) >= 0) - retval = 0; - else - retval = EINVAL; - goto out; - } - - hpt_copy_info(req, "%s Version %s\n", DRIVER_NAME, DRIVER_VERSION); - for (pAdapter=gIal_Adapter; pAdapter; pAdapter=pAdapter->next) { - if (hpt_get_info(pAdapter, req) < 0) { - retval = EINVAL; - break; - } - } - - hpt_copy_info(req, NULL); - goto out; - -out: - return (retval); -} - - -#define xhptregister_node(name) hptregister_node(name) - -#if (__FreeBSD_version < 500043) -#define hptregister_node(name) \ - SYSCTL_NODE(, OID_AUTO, name, CTLFLAG_RW, 0, "Get/Set " #name " state root node") \ - SYSCTL_OID(_ ## name, OID_AUTO, status, CTLTYPE_STRING|CTLFLAG_RW, \ - NULL, 0, hpt_status, "A", "Get/Set " #name " state") -#else -#define hptregister_node(name) \ - SYSCTL_NODE(, OID_AUTO, name, CTLFLAG_RW, 0, "Get/Set " #name " state root node"); \ - SYSCTL_OID(_ ## name, OID_AUTO, status, CTLTYPE_STRING|CTLFLAG_RW, \ - NULL, 0, hpt_status, "A", "Get/Set " #name " state"); -#endif - -xhptregister_node(PROC_DIR_NAME); diff --git a/sys/contrib/dev/hptmv/i386-elf.raid.o.uu b/sys/contrib/dev/hptmv/i386-elf.raid.o.uu deleted file mode 100644 index f8d041348847..000000000000 --- a/sys/contrib/dev/hptmv/i386-elf.raid.o.uu +++ /dev/null @@ -1,1346 +0,0 @@ -/* - * Copyright (c) 2003-2004 HighPoint Technologies, Inc. - * All rights reserved. - * - * Redistribution and use in source and binary forms, with or without - * modification, are permitted provided that the following conditions - * are met: - * 1. Redistributions of source code must retain the above copyright - * notice, this list of conditions and the following disclaimer. - * 2. Redistributions in binary form must reproduce the above copyright - * notice, this list of conditions and the following disclaimer in the - * documentation and/or other materials provided with the distribution. - * - * THIS SOFTWARE IS PROVIDED BY THE AUTHOR AND CONTRIBUTORS ``AS IS'' AND - * ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE - * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE - * ARE DISCLAIMED. IN NO EVENT SHALL THE AUTHOR OR CONTRIBUTORS BE LIABLE - * FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL - * DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS - * OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) - * HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT - * LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY - * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF - * SUCH DAMAGE. - * - * $FreeBSD$ - */ -begin 664 hptmvraid.o -M?T5,1@$!`0D```````````$``P`!``````````````#0N````````#0````` -M`"@`#``)`%6)Y5=64X'L%`(``(M]"(M'#(F%\/W__X!_`0"-=\0/A5<%``"` -M?P(`#X1%!0``L0&`3@$$B`Z+1PR)1@@/ML&+5Q"+!(4`````@/D#QT8$```` -M`(E6#(E&-'0<#[8&BP2%`````(!.`02)1CB-9?1;7E_)PXUV`(U"]HV5]/W_ -M_XE&#%)J((M'$(/H"E!7Z/S___^#Q!"!O?3]___S%GA:=;EHD````(V%]/W_ -M_U#H_/___X3`6EEUHHJ%_?W__X/@`H3`=!;&1P@!BH7^_?__.D<)B$<+#X*# -M!```:``"``"-E?3]__]2Z/S___^$P%I9#X5(!```BI6'_O__BD<$B-.#XP&# -MX/R(T8/A`@G8"3]__\/A,S^ -M__\QT@^VG?_]__\YVGTMC8WT_?__@\$0B@$\"`^'K/[__P^VP(L$A0````"% -MP`^$FO[__T*#P1`YVGSC]__^)5TR*A17^__^(1SR*E13^__^(%XN%$/[__XE'#(E? -M!(J-%_[__[@!````T^"(3SYFB4=$#[;2BP25`````(E'-`^V`XL$A0````") -M1SB*A>_]__^(1P.+E>#]__^-A?3]__^)?)-0_D,]@\`L:A!0C4=P4.C\____ -MC87T_?__:@2#P#Q0C8>`````4.C\____C87T_?__:A"#Z(!0C8?$````4.C\ -M____@\0DC87T_?__:D"#P$!0C8>$````4.C\____@\0,Z6;^__\/MH7O_?__ -MBU2#4(72#X5/^___B72#4/Y#/8J5[_W__XA6`P^V`XE>!(L$A0````#I-/S_ -M_VAP`0``C87T_?__:@`%D````%#H_/___X/$#.F8^___#[;`4%?H_/___UM8 -MZ6S[__^-=@"Q`^FV^O__D+$"Z:[Z__^058GE5E.+=0PQVP^V1CPYPWT/B?:+ -M5)Y0A=)T#$,YPWSSC67X6U[)PXC9N`$```#3X&8)1DA6_W4(Z/S___^)PH72 -M6%ETV\8"`X`^"`^4P(I*`<'@`X/A]PG!B$H!B%H#H0P```")0C0/M@:+!(4` -M````B7($B4(XBD8!@^`0A,!T#(/)$(M"3(A*`8E"#(E4GE"*1D:#X/Z#R`J( -M1D;'1DP`````_D8]4FH'Z/S___^`3D8$6U[I9O___Y!5B>575E-7BT4(B47P -MBUT,#[8#@_@�X`0``@_@&#X^+````@_@$?`J*4SPX4SUT-8GVBTL$AG\____ -M@$L!!(!C1OXQ_X32=+^-=@"+=+M0A?9T!8`^`W<*1P^VPCG'?.OKI5;_=?#H -M_/___XI&1H/@!%F$P%YT!(!+1@2*4SSKV(UV`(/X"`^%>____XI#/8I3/#C0 -M='(/ML!`#[;2.=!T#@^W0T3WV"%#3.E8____9HM#2&:%P'1"#[?0,7^O=BE-&B-"#X`*$P'71Z]N*0T:#X/Z`2P$$9H-[2`"(0T9T -MA8/(`HA#1NEZ____@$L!!(![/0)T/HM#4(!C1OV%P'41BT-4QD`#`(E#4,=# -M5`````"`.`-T$(!+1@3'0TP`````Z:7^__]3_W7PZ/S___]86NOC@&-&_NF/ -M_O__C78`58GE5U:+?0A3O@\```"-GV`B``"+0T"%P'0'BT,$A7\G#D%-7Z/S___^*0P&#X`1:A,!9=-O'0S@`````Z])5B>57 -M5E.![`0"``"+=0R*11!6B(7S_?__Z/S___^`/@A9#X3I````BD8\,?\\`'9_ -MC78`BUR^4(7;=&V`.P,/A[,```"*4P&#XO[&0P,`QT-0`````(A3`8"]\_W_ -M_P#'0P0`````QT,X`````'4%@#X&=&QH``(``&H`C97T_?__4NC\____C87T -M_?__4&HP:@"-0SQ0Z/S___^#Q!Q3Z/S___]8BD8\1XGZ.-!WA&C4````:@!6 -MZ/S___^+50B+@EPB``")1@B)LEPB``"#Q`S'1D``````C67T6UY?R<.+1@2% -MP'6-BD8!@^`!"<*(4P'KJHUV``^VA?/]__]0_W2^4/]U".C\____@\0,ZY56 -M_W4(Z/S___]86ND'____C78`58GE5U93@>P,`@``BU4,BP*+6`2)G?#]__^+ -M6B"+4Q2)E>S]__^+M>S]__\/MD`#A?:+?1"+312)A>C]__^-E?3]__\/A+,` -M``!F#[9#$(/@`0^WP#G(#X2@````#[=3+,'B"0^V6RB+C>S]__]FBT$$9H7` -MBS$/M\AU"+D```$`C78`.C]__]T6"G!`<8IPG4=BY7P_?__ -M#[9"/$,YPP^4P`^VP$@/MU)$(S]___KDF;'1_X`@+@!````C67T6UY?R<.-=@!FB4<$9L='!@``B3>#QPCK -MEXM#&(7`B97L_?__=00QP.O345)3_W4(_]"#Q!"%P`^%//___^OGD%6)Y5=6 -M4X/L"(M%"(M0!(E5\(M=#(I0`XI+*#C*BWLD9HMS,'1B.,IS"8M%\`^W0$0! -MQSC*=$F*0RDXPG0Z@'LT`'0D.,IV"SC"

+1?!F`W!$BU409HER"(EZ!(/$ -M"%M>7\G#C78`.,IVW(M-\&8#<43KTXUV`&8#S(`6G47@'L1`'4$QD,1`5/_7\G#_W4(Z/S___^)PXM%\(M$L%") -M1>R)`XE[((I7$(I#$(/B`H/@_0G0B$,0BE<0@^($@^#["="(0Q"*1PJ(0PI3 -M5_]U[.A\_?__QT,<`````,=#&`````!3_W4(BU7L_U(TBTWP@\08BE$\Z7K_ -M__^)]L9'$0)7_W<<_W4(Z/S____I<____XUV`%6)Y8M5#(M*!(I!`<#H`H!B -M`?OWT(M1.(/@`8!A`?O^23V`248!A=)T!(7`=`+)PU'_=0C_TEA:Z_2)]E6) -MY593BT4,BU`@BTH4AR<,QP.OUD(I&`<#H`H/@`0^VP.OFB?95B>575E.#[`B+?0R+7R"+`XLW -MB47PB77LBD\1@/D!=$^*4Q"(T(/@`H3`#X3/````@'L2`'4YBU7PBD)&@^`" -MA,!U+,9#$@$QP(!^`P`/E,"+=()0A?9T$U;H2?___X7`6G5UBP>)1>R*3Q&+ -M=>R0B$L15_]U".C\____#[9.`[C^____T\!F(T,R9HE#,E]FAQ$` -M=03&0Q$!4_]S'/]U".C\____BU7P9HM"%DB#Q`QFA7\G#:C"-1R1J`%#H_/___P^V3@.X`0```-/@9HE# -M,HDW5_]U"/]6-.O1@^($A-(/A&7___]6Z)?^__^%P%EU*8![$0$/A%/___\/ -MMDX#N`$````/MU,RT^`YP@^%//___XI/$>DQ____:C!J`(U')%#H_/___^NI -MB?95B>56BW444XM5#(7VBUT0BTH@=".+00R)`V:+0@C!X`EFB4,$9L=#!@"` -MN`$```"-9?A;7LG#D(M1%(72="V*01"#X`&$P'0CB=&0BP&+402)4P2)`V:+ -M008E`(#__X/#"(/!"&:%P'3BZ[^+01B%P'4$,<#KN5934?]U"/_0ZZ^-=@!5 -MB>575E.+=0R+!@^V2`.X_O___]/`BUX@BWT(9B%#,HI&$3P!=`.(0Q%65^C\ -M____66:#>S(`6'4X@'L1`'4.QD,1`8L+BU%,.U8$="Q3_W,<5^C\____BP-F -MQT`4``"#P!A0:`````!7Z/S___^#Q!B-9?1;7E_)PP^W1@B-!!")04SKR(GV -M58GE5U93BW4,BD81/`&+?0B+7B!T-HA#$597Z/S___]3_W,<5^C\____BP-F -MQT`4``"#P!A0:`````!7Z/S___^-9?1;7E_)PXUV`(!^"B!T&L9#$0&+"XM1 -M3#M6!'6Y#[=&"(T$$(E!3.NMBP/&1A$`BT!4B09J,&H`C48D4.C\____BD80 -M@^#]@\@$B$80QD82`,9&"C"+!E97_U`TZZ"-=@!5B>575HM5%%.+10R%THM] -M$(M(('1"BTD,B0]FBU`(P>()9HE7!&;'1P8`@(L`@'@#`'0-9H72=!@'L#``^$;?___SG/#X1E____BP&+402)5P2)!V:+008E`(#__X/' -M"(/!"&:%P'3BZ4+___^)T&8I\`$Q9HE!!.N^.?)RLV:)<01FQT$&`(#KKHM! -M&(7`=0?___\9#$0&+"XM13#M6!`^%9____P^W1@B- -M!!")04SI6/___XUV`%6)Y5=64XM=#(LSBD9&@^`!A,#'1AP`````=14/MD,* -M@_@"#X3_````@_@"?WY(="S&0Q$&4_]S'/]U".C\____@\0,C4884&@````` -M_W4(Z/S___^-9?1;7E_)PXM#!(E&$&:+0PAFB484_W4(Z/S____&0`H@B<*+ -M0P2)0@1FBT,(@$H0`F:)0@B)6B#'0AP`````QT(8`````(M&4(D"4O]U"/]0 -M-.N7B?:#^`-U@(M#!(E&$&:+0PAFB484#[=#",'@"5!J`/]S#.C\____,?]F -MQT,R`P"#Q`S_=0CH_/___\9`"C")PHM#!(E"!&:+0PAFB4((@$H0!(E:(,=" -M'`````#'0A@`````BT2^4(D"4O]U"$?_4#2#Q`R#_P%^N>D<____BT,$B480 -M9HM#"&:)1A3_=0CH_/___\9`"B")PHM#!(E"!&:+0PAFB4((@$H0`HE:(,=" -M'`````#'0A@`````Z3#___]5B>575E.#[!"+10B+?0R)1?"+-XI&`8/@!(3` -M#X32`0``BD<0@^`@A,!T-&:#?A8`QT8<7!,``(E^('0+C67T6UY?R<.-=@"+ -M5?")?0R)50B-9?1;7E_)Z3?^__^-=@"+1AR%P`^%;0$``&:+1A1FA0`````BTWDBT2.4(7`=!^*0`&#X`2$P'05BD<0@^`$ -MA,!U'(I%[SA%[G04C78`_D7O_T7D@'WO`7;*Z2#_____=?#H_/___VHD5U") -MP^C\____BDWDN`$```#3X&8)1S*)>R#'0QP`````QT,8`````(M5Y(M$EE") -M`U/_=?#_4#2#Q!CKJ(`Y`P^%5O___XM?!(M"6"M95(E%Z(M'!"M"5(M)6'A! -MA=MX.3G8?1^%R<9%[@`/A3G___^#?>@%#X8O____QD7N`>DF____BUWHA=O& -M1>X`=>R#^04/AQ+____KX??;Z\/WV.N[C78`QD7N`.G\_O__C78`C488QT7\GI_/___\9'$0)7_W<<_W7PZ/S____I-/[__XUV -M`%6)Y5=64XMU#(M>!(M]"(!F`?N*0SV*4T9(@\H!A,`/MDX#QT-,`````(A3 -M1HA#/703B-"#X`*$P'0.@^+5AC\____B4-`B5T(C67T6UY?R>G\____ -M4U?_T%A:Z\R%R744BU-0BT-4QD(#`8E#4,9``P")4U2+4P2%TG0*BD(!@^`$ -MA,!TIHM#4(`X`W6>4U?H_/___X7`68G"7W2,Q@`#QD`#`8E8!*$,````B4(T -MH1@```")0CB*0P&#X!"$P'0*BT),@$H!$(E"#,=&!`````"*0T:#X/Z#R`J) -M4U2(0T;^0SU2:@?H_/___^EH____B?95B>575E.![!`"``"+10R+$(M`((MP -M%(7VB97P_?__BTT4B87D_?__QX7L_?__$0```(V5]/W__P^$5@$``&8/MD`0 -M@^`!#[?`.<@/A$,!``"+O>3]__^`?RG_#X2E````9HM&!`^W7RS!XPEFA<`/ -MM\AU!;D```$`.O]__^+O>3]__^*5RB-=@`X -ME>O]__\/A)P```"#Q@AFBT8$*.`#4%;_=1#H_/___[@!````C67T6UY? -MR<-FQT<&`(#KZXM5$(L&B0)FB5H$9L="!@"`Z]B-=@"+?1"+!HM6!(E7!(D' -MBX7P_?__@\<(BD`#B7T0B(7K_?__B[WD_?__BEO]__^+O>3]__^*5RCI-____XUV`(N=Y/W__XM#&(7`B=9U!S'`Z73___]1 -M4E/_=0C_T(/$$(7`#X64_O__Z^2058GEBTT,4XI1*(M%"#A0`XM=$'079HM! -M*F:)0PC'0P0`````BQPDR<.-=@!FBT$L9HE#"(M!)(E#!.OH58GE5U93@^P, -MBWT,9HM'"(M?!(MU"&:)1?**1CPQR83`B$7KQT7L`````'09C78`BU2.4(M" -M##G#7\G#N`$```#3X&:+=S()QHE?)(A/ -M*&:)=S(/MT7RC008.T(,=C*-00''1>P!````B$S(` -M6G47@'L1`'4$QD,1`5/_ -M7\G#_W4(Z/S___^)PXM%\(M$L%")1>R)`XE[((I7$(I#$(/B`H/@_0G0B$,0 -MBE<0@^($@^#["="(0Q"*1PJ(0PI35_]U[.@(_O__QT,<`````,=#&`````!3 -M_W4(BU7L_U(TBTWP@\08BE$\Z7K___^)]L9'$0)7_W<<_W4(Z/S____I<___ -M_XUV`%6)Y8M%#(!@`?N+4`2+0CB`8@'[_DH]@$I&`87`=07)PXUV`%+_=0C_ -MT%A:Z_&)]E6)Y8M-#%.+70B+E(N\+P``A=)T"8L"B82+O"\``(G0BQPDR<.- -M=@!5B>6+51!3BUT(BX23O"\``(M-#(D!B8R3O"\``(L<),G#B?95B>575E.# -M[`B+10P]``@``(M5$+X`$```=T0]``0``+X`"```=S@]``(``+X`!```=RP] -M``$``+X``@``=R`]@````+X``0``=Q2#^$`/A]P```"#^"$9]H/FX(/&0`^O -MUH'"_P\``(E5\,%M\`S_3?"#??#_QT7L``````^$FP```)#_=0CH_/___XG# -M,=*X`!```#'_]_;_1>PYQUES<(UV`('^``@``+@'````=T.!_@`$``"X!@`` -M`'>)GN`O``!J`E=6Z/S]__^-9?1;7E_)PU6)Y593BW4(BQY+@_O_ -M=!EH`!```&H`_W2>!$OH_/___X/$#(/[_W7GC67X6U[)PU6)Y5.+70B+"TF# -M^?]T((M$BP0QTHUV`(,X`'4:0H/`!('Z_P,``';O28/Y_W7@N`$```!;R<,Q -MP.OYD%6)Y6H0:@#_=0CH_/___\G#C78`58GEBTT,BU$,A=)T!HM!"(E""(M! -M"(D0QT$(`````&H`4?]U".A*_?__R<-5B>564XM="(M#,(M-#(7`C7,PB4$, -M=`F+4S"-00R)0@B)<0B)2S!;7LG#D%6)Y5=64XM%#(M8,(7;BWT0BW44=!*) -M]CDSP1W*XM;#(7;=?!J`/]U".C"_/__B3B)<`10B575E.+=0P/ME8FC4+]T?@QVP'" -M.=.+?0A\$VH'5E?H;OS__XUE]%M>7\G#B?;_M)Z<"```5^@7_O__6%H/ME8F -MC4+]T?A#`<(YTWSAZ\R-=@!5B>575E.#[!2*10R+512(1?-FB57PBT4(BY#@ -M+P``#[9-\P^W1?")1>2-0?W1^(T$",'B`P^O1>0YP@^#@P```(M5"('"I"\` -M`(E5X(G/D(M%"(N8I"\``#M=X`^$+`$``(L#BU,$B5`$B0*+0Q")WH7`B1Z) -M7@1T%HM3%(72=`.)0A"+1A")$,=&$`````"+5?!F.5,D#X3W````4_]U".@& -M____6(M%"%J+D.`O``"-1_W1^(T$.,'B`P^O1>0YPG*,:@?_=0CH2OO__XG& -M7U@QP(7V#X2"````BU40B58@BE7SBT7PB%8F#[95\V:)1B2-0OW1^#'_C000 -M.<>)-HEV!,=&&`````!]3V;!;?`##[=5\(E5Z(E%[/]UZ/]U".AY_/__B82^ -MG`@``%F%P%MT,HG[P>,$C1PSC8/$"```4('#1`D``.AJ_?__1U/H8_W__UD[ -M?>Q;?,")\(UE]%M>7\G#3X/__W07_[2^G`@``/]U"$_HA/S__UB#__]:=>EJ -M!U;_=0CHLOK__S'`Z\R)]HI%\SA#)@^%_?[__P^VP(M5$(7`B1N)6P2)4R!T -M%8VS1`D``(G'5NCX_/__@\803UEU\XG8ZY.058GE5U93@^P(BT449HE%\HM5 -M#(M]$`^V2CZ)^-/H)?\#``"+4BR-'(*+,X7V=`V0.7X@=&N+=A2%]G7T#[=% -M\E!7BU4,#[9"/%#_=0CHXOW__X/$$(7`B<9T.XM-#(E('(L#A<")1A1T"(L3 -MC484B4(0BT4,B3.)7A"*6#R(7B8/MD@^T^\QT@^V2#R)^/?Q*--+B%XGC67T -M6XGP7E_)PXM6!(L&B5`$B0*)=@2)-NOEC78`58GE5U93@>RT````BT4,BE`0 -MB-#0Z(G!]]�&)C6#___^+30R+012%P'0+@^(!A-(/A%0"``!J`8V%9/__ -M_U#_=0S_=0B)A5S___^+50S_4AB#Q!"+C5S___]FBT$$#[?09H7`B95$____ -M=0K'A43___\```$`QX5,____`````(M-#(I11(32QX58____``````^$C0$` -M`(M-#(N%6/___XM$@3")A5#___^*B!P*``"(C5?___^*@!T*```XA5?___\/ -MAT8)`=>-=@"+A43___\YA4S_ -M__\/A-(```"+G43___\KG4S___\Y\W8"B?.+A6#___^%P`^$F@```%.+A4S_ -M__^+E5S___\#`E!7Z/S___^#Q`P!G4S___\IWG0$`=_KIXN%2/___V8IA4K_ -M__]T%O^%0/___S'29L>%2/___P@`Z3[___^+E5#___^*@AT*``#^A5?___\X -MA5?___\/AK_^__^+30R*443_A5C___\/ML(YA5C___\/C'/^__]J`/]U#/]U -M"/]5$(UE]%M>7\G#B?935XN%3/___XN-7/___P,!4.EA____B?:#A5S___\( -MBY5<____9HM"!`^WR&:%P(F-1/___W4*QX5$____```!`,>%3/___P````#I -M]O[__XF%7/___^F__?__D%6)Y5=64X/L%(M%"(E%\(M%$(7`BWT,=`3&1Q$+ -MQT7L`````(!_1``/A)\```"+5?"+1?"!PJPO```%I"\``(E5Z(E%Y(UV`(M5 -M[(M,ES"*028QVSC#QX'T"0```````(A%XW-"C78`#[;#P>`$C00(C9#$"``` -MBX#$"```,?:%P'45BT($A+0@R%P'0%O@$```"%]G5(0SI= -MXW+!,<"%P'0WBU7HBT($B1&)2@3_1>R)002)"`^V1T0Y1>P/C'O___^+1?") -M?0R)10B#Q!1;7E_)Z59```")]HM5Y.O'N`$```#KN56)Y5=64X/L&(M=#(M% -M"/^(Y"\``(E%\(NS]`D``(U#"(M(!(M3"(7VB4H$B1&)0`2)0P@/A)8"``"* -M5A"(T(/@((3`#X3R````#[=3)(M%\`6D+P``B57D`U,@B57HBU`$B0.)6`2) -M&HJ#'@H``#P!BS['@_0)````````B5,$=0J`?@H"='<\`708B$81BT7PB74, -MB44(C67T6UY?R>FD/P``BT8$0`^W5T0/K\(Y1>AR&P-73#M5Z'0+BU7PB74, -MB54(Z]&+1>B)1TSK[?]UY/]UZ%?_=?#HYOK__XFP]`D``(E&,(M5\(E%#(E5 -M"(/$$(UE]%M>7\GI50X```^V0R?_M(.<"```Z&7W__^%P%IU',:#'@H```P/ -MMT=$@$]&"O?8(T,@.4=,=@.)1TR*@QX*``#I3?___Y"*1D5`BDY$.,B(1D4/ -MA(H```"+5?"+@N@O``"%P'0)@+L>"@```70(C67T6UY?R<.+4QR+2B2%R746 -MA7\GI_/___U+H(CT``(7`6G0+BU7PBX+H+P``Z]2+ -M0QS_<"B+0QS_<"3_=?#H_/___XM#'(M5\,=`)`````"+@N@O``!(@\0,B8+H -M+P``ZZ&-=@"#X@2$T@^$F0```,9%[P`X3>]S4HM%\(M5\`6D+P``@<*L+P`` -MB47@B57^+7(8PBH,>"@``/`''@_0)````````="Z(1A&+5=R+0@3^ -M1>^)6@2)$XE#!(D8BD7O.D9$7^D`____,?^)^#I#)G(% -MBU7@Z\J)^@^VPL'@!(V$&,0(``!01^@^]O__6(GX.D,F]S -M((UV``^V1>^+7(8PBH,>"@``/`%T`XA&$?Y%[SA-[W+C@'X1`'46:"`E``!6 -M_W7PZ+_Y__^#Q`SIC?[__VH`5O]U\.A$_/__Z^N)]H"['@H```$/A)\```"+ -M1?`%K"\``(M0!(D#B5@$B1J)4P2+D_@)``"%TG55_W,8_W7PZ+WU__^+0QS' -M0Q@`````BW@86H7_674IBU7PB[+L+P``A?8/A"/^__^)T`7L+P``4&@````` -M4NC\____Z7;___^#P!A0:`````#_=?#KZ(J#'@H``(A"$?^S^`D``&A89@`` -M_W7PZ/S____'@_@)````````Z>C]__\Q]HGR.E,F6+ -M10R+`(!X*@!U`LG#QD`J`%!H2#,``/]U".C\____@\0,Z^>058GE5U93@^P( -MBU4,BT(@BP@/MD`)BX2!G`@``(E%\(M"!"M!(,'@"0^W6@B)PL'H#(M]$,'C -M"8'B_P\``(E%[+X`$```*=8YWG8"B=Z+112%P'0\BT7LBTWP`U2!!#G>B1=F -MB7<$=!)FQT<&``#_1>R#QP@I\S'2Z\9FQT<&`("-9?1;7K@!````7\G#C78` -MBTWPBT7L`U2!!%+H_/___XG"6>NYC78`58GE5U93BUT(BD,+`$,*C7,,B?:* -M4PH/MLJ#^1\/AZ4```"X`0```-/@A4,,#Y7`#[;`A7\G##[;ZQD,+`8GVBE,+#[;"C0PX@_D?=R:X`0```-/@A4,,#Y7` -M#[;`AB$8&4E?H_/___UF`?@8!6'06QD8%`HEU#(E]"(UE]%M>7\GI -MW/W__U;HIO[__X7`6G5"@'X$`779BD8(.D,G=-$Z1@EUS`^VP,'@!(T$&(M6 -M#`F01`D``(U>#(V(1`D``(M#!`E!!(M#"`E!"(M##`E!#.N=QD8&`(EU#(E] -M"(UE]%M>7\GK*%6)Y593BUT,BW4(QD,+`,9#"@!3Z#/^__]8B5T,B74(C67X -M6U[)ZP!5B>575E.+70R+,XM6'`^V0PB+?()0_W4(Z/S___^).(![!`&)PEAT -M.X!*$`3&0@HP#[9#"@-&((E"!&8/MD,+9HE""(E:(,="&"`J``#'0AS@*P`` -M4O]U"/]7-(UE]%M>7\G#@$H0`L9""B#KPXGV58GE5U93@^P(,?\QVXUV`(/[ -M'P^'\P```+@!````B-G3X(M5"(4"#Y7`#[;`A<"^`0```'42@_M_=P-#Z]*# -MQ`A;7HGX7\G#C10>@_H?=VB(T;@!````T^"+30B%`0^5P`^VP(7`=`-&Z]V) -M7>R)TXM%[(M-#,'H`X@$N8I%[(/@!XA$N0&Q""C!BT4,B$RX`@^VP3GP#^G\/AEW____KB8UV`(/Z/W<3C4K@N`$```#3 -MX(M-"(5!!.N/D(/Z7W<5C4K`N`$```#3X(M-"(5!".ET____@_I_=Q6-2J"X -M`0```-/@BTT(A4$,Z5K___\QP.E9____D(/[/W<7C4O@N`$```#3X(M-"(5! -M!.D!____B?:#^U]W%XU+P+@!````T^"+50B%0@CIY?[__XGV@_M_=Q6-2Z"X -M`0```-/@BTT(A4$,ZP8`0``BT4,BU@( -M@'L5`(LP#X0"`0``BWL0A?]U"XE#$(UE]%M>7\G#C87T_O__QD,5`%!3Z%?^ -M__^)A>#^__\/MD,4BX2&G`@``(F%Z/[__XM#$`^V0`R+A(:<"```B87<_O__ -MBU4,#[9"#(N$AIP(```Q]ED[M>#^__^)A>3^__];?7`/MH2U]/[__P^VG+7U -M_O__B[W<_O__BU2'!,'C"0':#[:,M?;^__^)E>S^__^+E>3^__^+?(($`=^) -MO?#^__^+E>C^__\#7(($BX7L_O__P>$).=AT+E'_M?#^__]04^C\____@\00 -M1CNUX/[__WR0:@#_=0S_=0CHYP(``.D:____B?915U#H_/___X/$#.O6C78` -MC87T_O__4%/H:_W__XF%X/[__P^V0Q2+A(:<"```B87H_O__BWT,#[9'#(N$ -MAIP(```Q]HF%W/[__SNUX/[__UA:?9@/MI2U]/[__P^VG+7U_O__B[WH_O__ -MBT27!,'C"0^VC+7V_O__`=B)A>S^___!X0F+A=S^__\#7)`$45/_M>S^__]& -MB9WP_O__Z/S___^#Q`P[M>#^__]\I^DZ____B?95B>575E.![!0!``"+10R+ -M&(V%]/[__U"+10R#P`A0Z+#\__^)A>3^__^+50P/MD(8BX2#G`@``(F%Z/[_ -M_P^V0AF+A(.<"```,?:)A>#^__\[M>3^__]86GU5D`^VE+7T_O__#[:$M?7^ -M__^+O>C^__^+7)<$P>`)#[:,M?;^__\!P\'A"8F=[/[__XN]X/[__P-$EP11 -M4%-&B87P_O__Z/S___^#Q`P[M>3^__]\K&H`_W4,_W4(Z&\!``"-9?1;7E_) -MPXUV`%6)Y5=64X'L5`$``(M%#(M8"(LPC87T_O__4%/HZ_O__XF%I/[__P^V -M0Q2+A(:<"```B86P_O__BU4,BE(4,,)P><) -MBH2%]/[__SJ-H_[__XB%K_[__W,C#[;P#[;!BY2%U/[__XM4L@1!`=HZC:/^ -M__^)E(6T_O__P0#6G0+ -MC67T6UY?R<.-=@"+4PB+0A"%P'3KA?;'0A``````QD`%`K(,=0*R`8A0!HE% -M#(E]"(UE]%M>7\GI(O?__XGV58GE5E-3BT4(C5`LBD`I,=N$P(MU#(A%]W0M -MD(/['W\_N`$```"(V=/@A48@=`V`>@4"=22*0@8\`7460P^V1?>#PB0YPWS4 -MN`$```!96U[)P\9&!0*(1@8QP.OPC78`C4O@N`$```#3X(5&'.N^D%6)Y5=6 -M4X/L$(M%"(E%\(MU#("^'PH```#&1BH`=':-1BR)1>2*5BDQ_X32BUWD=!2- -M=@"`>P4!="!'#[;"@\,D.<=\[XM%\(EU#(E%"(UE]%M>7\GI;O+__X![!`-U -M*8M#"(!X%0!T((M0$(72=!G'0!``````QD,%`HJ&'@H``(A#!HI6*>NQQD8J -M`8UE]%M>7\G#C48LB47DBE8IB?8Q_X32QT7H`0```(M=Y,=%[`````!T)Y"* -M0P6$P`^$W0```#P"=#''1>@`````BD8I1XC"#[;`@\,D.<=\VHM%[(7`=;N+ -M?>B%_W2=QH8>"@```>E-____BD,&/`%TSX!^*P`/A(0```"+5AP/MD,(BT2" -M4(I``8/@!(3`=&;'1>@`````#[9#!(/X!L9#!0'&0P8`=YC_)(4`````4_]U -M\.CN]___6%KKA,9#!0+&0P8!4_]U\.A5]?__Z^E3_W7PZ,[Y___KWE/_=?#H -MA_O__^O34_]U\.A$_/__Z\C&1BL!Z\;&0P8!Z4'___^(AAX*``#&AA\*```! -MZ8;^__^04U;HZ?W__X7`6EET'P^V0P2#^`;&0P4!=Q+_)(4<````4_]U\.AJ -M]___65B*0P4\`@^%\/[___]%[.GD_O__QD,%`L9#!@%3_W7PZ,#T___KV%/_ -M=?#H.?G__^O-4_]U\.CR^O__Z\)3_W7PZ*_[___KM\9&*P'KQHUV`%6)Y5=6 -M4X'LB`$``(M%#(NP]`D``(7VBU@"@```,:''PH```#'A_@)```````` -M#X2U````BE80B-"#X""$P`^$+2(```^V1@J#^`(/A$8>``"#^`(/CQ\=``!( -M=!?_=0S_=0CH\?S__S'2C67T6UZ)T%_)PXM%#(I`)C').,&(A7?^__]S1@^V -MP<'@!`-%#(V0Q`@``(N`Q`@``#';A3^__]0 -MZ+WG__]9_W4,Z'#H__^)A8S^__]:QD`$!HM%#,:%S_[__P"*0"8XA<_^__^( -MA73^__\/@S`*``"+50R*6B`$`T4,C9#$ -M"```BX#$"```,+<@R%]G0%N0$```"%R0^$ -MTP````^VA<_^___!X`2+?0P!QXN'Q`@```F%Y/[__XVWQ`@``(M&!`F%Z/[_ -M_XM&"`F%[/[__XM&#`F%\/[__XJ-S_[__XM%##I(*`^$A0```%#HG^?__UG& -M0`0"BI7/_O__B%`(B%`)BY?$"```B5`,BU8$B5`0BU8(B5`4BU8,B5`8BXV, -M_O__*PB#Z2S!^0*)QHT$S0`````IR(T$P<'@`RG(C03!B<+!X@\IPHT,T8/Y -M'P^/!0D``+@!````T^`)1B"+30R*62>*02:(A73^__^-=@#^A<_^__^*A73^ -M__\XA<_^__\/@LC^____=0SH`.?__UK&0`0"B%@(B%@)B<:+A>3^__^)1@R+ -MA>C^__^)1A"+A>S^__^)1A2+A?#^__^)1AB+C8S^__\K#H/I+,'Y`HT$S0`` -M```IR(T$P<'@`RG(C03!B<+!X@\IPHT,T8/Y'P^/40@``+@!````T^`)1B"+ -M30R*22@/MM'!X@0#50R-@D0)``"+6`2+<`B(C7/^__^+0`R+BD0)``")G8C^ -M__^)A8#^__^)Q_?1BX7D_O__]],AP2.=Z/[__XFUA/[__XF-U/[__XF=V/[_ -M_XN-\/[__XN=[/[___?6]]`$C97T -M_O__`<(!\(NX1`D``/?7B3J-L$0)``"+7@3WTXE:!(M."/?1B4H(BT8,]]") -M0@PCO>3^__^).B.=Z/[__XE:!".-[/[__XE*"".%\/[__XE"#(M=#/]U#.C* -MY/__@(/*<*-#-&#^1\/CY\%``"X`0```-/@ -MBXV,_O__"4$@#[:%S_[__\'@!(V]]/[__XT$.(L8,=*%VW47BT@$A"(A>"8N%U/[__XE&#(N%V/[_ -M_XE&$(N%W/[__XE&%(N%X/[__XE&&,:%S_[__P#'A=#^__\`````BT4,BD`F -M.(7/_O__B(5T_O__#X,C^O__C78`BU4,BE(H.)7/_O__B)5[_O__='&*C<_^ -M__^+70PZ2R=T8P^VP<'@!(V-]/[__P'!`=B-D,0(``"+@,0(```CA=3^__^) -M`8M:!".=V/[__XE9!(MR"".UW/[__XEQ"(M2#".5X/[__XE1##')A_[__\'C!(VU -M]/[__XA7"8T<,XL#B4<,BT,$B4<0BT,(B4<4BT,,B4<8BX70_O__A(#*<*-%-")T<'A#RG1 -MC0S(@_D?#X^*`@``N`$```#3X`E'((M=#(I;)XB=>O[__XM%#`^VG<_^__^* -M0"B-E?3^___!XP3_=0R-'!.(A7G^___HX>'__U[&0`0$BHUZ_O__B$@8B<:* -MA7G^__^(1AF+`XE&"(M#!(E&#(M#"(E&$(M##(E&%(N-?/[__RL.@^DLP?D" -MC03-`````"G(C03!P>`#*(#*<*-%-")T<'A#RG1 -MC0S(@_D?#X^%`0``N`$```#3X`E&((N5C/[__RLRC4;4P?@"C13%`````"G" -MC130P>(#*<*-%-")T<'A#RG1C0S(@_D?#X\N`0``N`$```#3X(N-C/[__PE! -M((M%#`^VG<_^__^*0">-E?3^___!XP3_=0R-'!.(A7C^___HQ^#__UG&0`0$ -MBHUX_O__B$@8B<:*A<_^__^(1AF+`XE&"(M#!(E&#(M#"(E&$(M##(E&%(N- -M?/[__RL.@^DLP?D"C03-`````"G(C03!P>`#*(# -M*<*-%-")T<'A#RG1C0S(@_D??R&X`0```-/@BXV,_O__"4$@BUT,BELFB)UT -M_O__Z3O]__^#Z2"X`0```-/@B[6,_O__"48,$C87T_O___W4,C1P#Z&??__]9QD`$`8J5S_[__XA0 -M"(A0"8L3B5`,BU,$B5`0BU,(B5`4BU,,B5`8*P:#Z"S!^`*-%,4`````*<*- -M%-#!X@,IPHT4T(G1P>$/*=&-#,B#^1]_&[@!````T^`)1B"+30R*22:(C73^ -M___IVOK__X/I(+@!````T^`)1AR+70R*6R:(G73^___IO/K__X/I(+@!```` -MT^"+G8S^__\)0QSI6?K__XM=#/]U#.BXWO__@`$`T4,C9#$"```BX#$"```,+0@R%P'0%N0$```"%R74C_H7/_O__BIUT_O__.)W/ -M_O__#X-?]/__BW4,BEXGZYN-=@`/MIW/_O___W4,P>,$`UT,Z&_=__]?QD`$ -M`HJ5S_[__XA0"(A0"8N3Q`@``(E0#(VSQ`@``(M6!(E0$(M6"(E0%(M6#(E0 -M&(M-#(I))HB-=/[__^N(C87D_O__4.AGW/__QH7/_O__`,:%SO[__P!8BT4, -MBD`F.(7/_O__B(5U_O__#X/##```BU4,BEHGB?8XG<_^__]T?0^VA<_^___! -MX`0#10R-D,0(``"+@,0(```QR87`=16+0@2%P'4.BWH(A?]U!XMR#(7V=`6Y -M`0```(7)=$`/MH7/_O__P>`$`T4,C9#$"```BX#$"```"87D_O__BT($"87H -M_O__BT(("87L_O__BT(,"87P_O___H7._O___H7/_O__BHUU_O__.(W/_O__ -M#X)C____#[:%=?[__X/H`P^VE<[^___1^#G"#X[]!@``BWT,B)_8"0``BX7D -M_O__B8?$"0``BX7H_O__B8?("0``BX7L_O__B8?,"0``BX7P_O__B8?0"0`` -MQH?9"0```<>'U`D```````!7Z.S;__^(6`B(6`G&0`0"BY7D_O__B5`,BY7H -M_O__B5`0BY7L_O__B5`4BY7P_O__B5`8B<:)/"3HM-O__XF%J/[__UO&0`0& -MBXVH_O__*PZ#Z2S!^0*-!,T`````*(/*<*-#-&# -M^1\/CR,&``"X`0```-/@"48@BT4,BD`F/`*(A73^__\/AOX"``#&A<_^__\` -M.(7/_O__#X,3\O__C78`BIW/_O__BW4,.EXG#X1E`0``#[;3P>($B?`!T(N8 -M1`D``/?3B9W4_O__C8A$"0``BT$$]]")A=C^__^+00CWT(F%W/[__XM!#(V] -M]/[__R.=Y/[__XT4.O?0B87@_O__B1J+A=C^__\CA>C^__^)0@2+A=S^__\C -MA>S^__^)0@B+A>#^__\CA?#^__^)0@R)\U;HJ=K__X'#Q`D``%[&0`0#B5@( -MB<:*A<_^__^(1@R+E:C^__^)\2L*@^DLP?D"C03-`````"G(C03!P>`#*`$`T4,C9#$"```BX#$"```,+6@R%VW0%N0$```"%R74IBU4,BE(FB)5T_O___H7/_O__BHUT_O__.(W/ -M_O__#X)Q_O__Z7SP__\/MIW/_O__P>,$_W4,`UT,Z)?9__]9QD`$`HJ-S_[_ -M_XA("(A("8N3Q`@``(E0#(VSQ`@``(M6!(E0$(M6"(E0%(M6#(E0&(N-J/[_ -M_RL(@^DLP?D"B<:-!,T`````*(/*<*-#-&#^1]_ -M&[@!````T^`)1B"+70R*6R:(G73^___I3O___X/I(+@!````T^`)1AR+10R* -M0":(A73^___I,/____]U#`^VG<_^___HZMC__UK&0`0!BI7/_O__P>,$B%`( -MB%`)C1P[BQ.)4`R+4P2)4!"+4PB)4!2+4PR)4!@K!H/H+,'X`HT4Q0`````I -MPHT4T,'B`RG"C130B='!X0\IT8T,R(/Y'W\/N`$```#3X`E&(.EP_O__@^D@ -MN`$```#3X`E&'.E>_O__@^D@N`$```#3X(N=J/[__PE#'.D/_O__BUT,_W4, -MZ$W8__^!P\0)``!9QD`$!8E8",9`%`")P8N5J/[__RL*@^DLP?D"B<>-!,T` -M````*(/*<*-#-&#^1\/CYD"``"X`0```-/@BXVH -M_O__"4$@QH7/_O__`(M%#(I`)CB%S_[__XB%=/[__P^#H^[__XJ5S_[__XM- -M##I1)P^$^0```(I'%(J=S_[__P^VT(A<.@Q`#[;3B$<4P>($B<@!T(N(1`D` -M`/?1B8W4_O__C9A$"0``BT,$]]")A=C^__^+0PCWT(F%W/[__XM##(VU]/[_ -M_XT4,B.-Y/[___?0B87@_O__B0J+G=C^__\CG>C^__^)6@2+M=S^__\CM>S^ -M__^)<@B+A>#^__\CA?#^__^)0@PQTH7)=0R%VW4(A?9U!(7`=`6Z`0```(72 -M#X49`0``#[:%S_[__\'@!`-%#(V0Q`@``(N`Q`@``#')A`#*,$C87T_O___W4,C1P#Z-W5__]: -MQD`$`8J5S_[__XA0"(A0"8L3B5`,BU,$B5`0BU,(B5`4BU,,B5`8*P>#Z"S! -M^`*-%,4`````*<*-%-#!X@,IPHT4T(G1P>$/*=&-#,B#^1]_#[@!````T^`) -M1R#I:O[__X/I(+@!````T^`)1QSI6/[__X/I(+@!````T^"+G:C^__\)0QSI -M7_W__X/I(+@!````T^`)1ASIU?G___]U#.@WU?__B86D_O__QD`$`8NUI/[_ -M_XA>"(A>"8N%Y/[__XE&#(N%Z/[__XE&$(N%[/[__XE&%(N%\/[__XE&&(M] -M#(I?)XD\).COU/__QD`$`HA8"(A8"8N5Y/[__XE0#(N5Z/[__XE0$(N5[/[_ -M_XE0%(N5\/[__XE0&(G&B3PDZ+?4__^)A:#^__]:QD`$!HN-H/[__RL.@^DL -MP?D"C03-`````"G(C03!P>`#*`$`@2%_W41BW(( -MA?9U"HM:#(7;=`B-=@"Y`0```(7)=1G^A<_^__^*A73^__\XA<_^__]RH^FZ -MZO___HW._O__BIUT_O__BH7._O__C3P8#[:=S_[__\'C!/]U#`-=#.C`T___ -MB86<_O__6<9`!`&*E<_^__^+C9S^__^)^(A1"(A!"8N#Q`@``(E!#(VSQ`@` -M`(M&!(E!$(M&"(E!%(M&#(E!&(M5#(I2)_]U#(B5F_[__^ALT___B864_O__ -M6L9`!`2*C9O^__^+A93^__^)^HA0&8A(&(N#Q`@``(N-E/[__XE!"(M&!(E! -M#(M&"(E!$(M&#(E!%(G+BXVD_O__*PN#Z2S!^0*-!,T`````*(/*<*-#-&#^1\/CY@"``"X`0```-/@"4,@BYV4_O__BQLIG9S^ -M__^+A9S^__^#Z"S!^`*-%,4`````*<*-%-#!X@,IPHT4T(G1P>$/*=&-#,B# -M^1\/CS4"``"X`0```-/@B[64_O__"48@BX6@_O__BP`IA93^__^+A93^__^# -MZ"S!^`*-%,4`````*<*-%-#!X@,IPHT4T(G1P>$/*=&-#,B#^1\/C\P!``"X -M`0```-/@BY6@_O__"4(@BUT,BELGB)V3_O__#[:=S_[__\'C!/]U#`-=#.@H -MTO__6<9`!`2)QXJ%D_[__XA'&(J5S_[__XA7&8N#Q`@``(E'"(VSQ`@``(M& -M!(E'#(M&"(E'$(M&#(E'%(N-I/[__RL/@^DLP?D"C03-`````"G(C03!P>`# -M*(#*<*-%-")T<'A#RG1C0S(@_D?#X_#````N`$` -M``#3X(N=H/[__PE#(`^VG<_^___!XP3_=0P#70SH5='__UK&0`0"BI7/_O__ -MB%`(B%`)BY/$"```B5`,C;/$"```BU8$B5`0BU8(B5`4BU8,B5`8BXV@_O__ -M*PB#Z2S!^0*)QHT$S0`````IR(T$P<'@`RG(C03!B<+!X@\IPHT,T8/Y'W\; -MN`$```#3X`E&((M-#(I))HB-=/[__^G2_/__@^D@N`$```#3X`E&'(M=#(I; -M)HB==/[__^FT_/__@^D@N`$```#3X(NUH/[__PE&'.DU____@^D@N`$```#3 -MX`E''.G>_O__@^D@N`$```#3X(N-H/[__PE!'.DL_O__@^D@N`$```#3X(N] -ME/[__PE''.G#_?__@^D@N`$```#3X`E#'.E@_?__@^D@N`$```#3X`E&'.G, -M^___BW4,BEXGZ=?S__^-G>3^__]3Z&;/__]9BTT,,?8/MU$D,?^#_A\/A^<# -M``"Y(````"GQ.=%V`HG1@_D@#X3&`P``N`$```#3X$B)\=/@"0.X(````"GP -M.<)V$(U4%N`Q]D>)^(/#!#P#=KB+50R*4BB`^@B(E7/^__\/A'0#``"+=0R* -MG7/^__^(GM@)``#&AMD)```!BX7D_O__B8;$"0``BX7H_O__B8;("0``BX7L -M_O__B8;,"0``BX7P_O__B8;0"0``QX;4"0```````%;H8\___XF%R/[__UK& -M0`0"B[W(_O__B%\(B%\)BX7D_O__B4<,BX7H_O__B4<0BX7L_O__B4<4BX7P -M_O__B4<8BT4,BD`F/`*)_HB%=/[__P^&:`$``,:%S_[__P`XA<_^__\/@\_E -M__^+70R!P\0)``")G<3^__^*A<_^__^+50PZ0B@/A.0```!2Z-C.__]9QD`$ -M`8J-S_[__XA("(A("8N5Y/[__XE0#(N5Z/[__XE0$(N5[/[__XE0%(N5\/[_ -M_XE0&/]U#(G&Z)G.__^)QUK&0`0#BYW$_O__*S>)6`B-3M3!^0**A<_^__^( -M1PR-!,T`````*(/*<*-#-&#^1\/CY4```"X`0`` -M`-/@"4<@BY7(_O__*SJ-1]3!^`*-%,4`````*<*-%-#!X@,IPHT4T(G1P>$/ -M*=&-#,B#^1]_.;@!````T^"+C3__X/I(+@!````T^"+M`#*$/*=&-#,B#^1]_,[@!````T^`)1R"+10R*0":(A73^___^A<_^ -M__^*C73^__\XC<_^__\/@D;____I0N/__X/I(+@!````T^`)1QR+50R*4B:( -ME73^___KR(/I(+@!````T^`)1ASI]?[__XM-#(I!)XA!*(B%<_[__^EX_/__ -MQP/_____Z3W\__^#[B#I1OS__[@!````Z57C__^#^`,/A=OB__^-G>3^__]3 -MZ$/+__^+10Q?,?8/MU`D,?^#_A\/A^P```"Y(````"GQ.=%V`HG1@_D@#X3+ -M````N`$```#3X$B)\=/@"0.X(````"GP.<)V$(U4%N`Q]D>)^(/#!#P#=KB+ -M50S_LIP(``#H=,$ -M`UT,C8/$"```4('#1`D``.BLRO__4^BFRO__65O_=0SH6,O__UK&0`0"BI7/ -M_O__B%`(QD`)`(N5Y/[__XE0#(N5Z/[__XE0$(N5[/[__XE0%(N5\/[__XE0 -M&/Z%S_[__XJ-S_[__XM=##I+)G*'Z=GA___'`______I./___X/N(.E!____ -MBUT,BELF,`$`T4,C9#$"```BX#$"```,=N%P'45 -MBT($A+>@R%_W0%NP$```"%VP^%?P,``$$ZC7;^__]RNC'` -MA']`D```````#IW.'__XV=Y/[__U/HN,G__XM%#%DQ -M]@^W4"0Q_X/^'P^'+P,``+D@````*?$YT78"B=&#^2`/A`X#``"X`0```-/@ -M2(GQT^`)`[@@````*?`YPG80C506X#'V1XGX@\,$/`-VN(M5#(I:)XB:V`D` -M`,:"V0D```"+A>3^__^)@L0)``"+A>C^__^)@L@)``"+A>S^__^)@LP)``"+ -MA?#^__^`>B8"B8+0"0``QX+4"0````````^'XP```%*)T^C!R?__@(# -M*<*-%-"(7#$,B='!X0\IT8T,R(/Y'W\GN`$```#3X`E&(/Z%S_[__XJ%S_[_ -M_XM5##I")@^"8O___^G%W___@^D@N`$```#3X`E&'.O4_W4,Z-[(__^)A<#^ -M__]>QD`$`8N-P/[__XA9"(A9"8N%Y/[__XE!#(N%Z/[__XE!$(N%[/[__XE! -M%(N%\/[__XE!&(M=#,:%S_[__P"*6R8XG<_^__^(G73^__\/@U3?__^+=0R! -MQL0)``")M;S^__^*A<_^__^+50PZ0B)6`B-3M3!^0**A<_^__^(1PR-!,T` -M````*(/*<*-#-&#^1\/CXD```"X`0```-/@"4<@ -MBX7`_O__*P>#Z"S!^`*-%,4`````*<*-%-#!X@,IPHT4T(G1P>$/*=&-#,B# -M^1]_,[@!````T^`)1R"+50R*4B:(E73^___^A<_^__^*G73^__\XG<_^__\/ -M@OC^___I.-[__X/I(+@!````T^`)1QR+30R*22:(C73^___KR(/I(+@!```` -MT^`)1QSI;____\<#_____^GU_/__@^X@Z?[\__^X`0```.F"_/__B?:%]@^$ -M<-[__X/B`H32#X1EWO__BT4,BH`<"@``B(7/_O__BTT,BI$="@``.-`/AUT! -M``"0BIW/_O__BW4,.EXG#X0X`0``#[;SB?.-O73____!XP2-'#M3Z`/&__^+ -M10P/MX2P_`D``(M5#%^)A6S^__\/M[2R_@D``#'_@[UL_O__'P^'^PD``+H@ -M````*Y5L_O__.?)V`HGR@_H@#X35"0``B-&X`0```-/@2(J-;/[__]/@"0.X -M(````"N%;/[__SG&=A^+A6S^__^-=##@QX5L_O__`````$>)^H/#!(#Z`W:7 -M#[:5S_[__\'B!(M%#`'0BYA$"0``]].)G>3^__^-B$0)``"+003WT(F%Z/[_ -M_XM!"/?0B87L_O__BT$,]]"-C73___^)A?#^__^-A"KT_O__C10*BSHAWXDX -MB[7H_O__(W($B7`$BYWL_O__(UH(B5@(BXWP_O__(TH,B4@,BU4,BH7/_O__ -M.D(H#X3%"```BUT,BI,="@``_H7/_O__.)7/_O__#X:D_O__@+W-_O__``^% -MMP```(M=#(J;'`H``#C3B)W/_O__#X`B%_W4)BU@,A=MT!XGVN0$` -M``"%R743_H7/_O__.)7/_O__=JWIX-O___]U#`^VG<_^___H`<7__UK&0`0! -MBI7/_O__P>,$B%`(B%`)C1PSBQ.)4`R+4P2)4!"+4PB)4!2+4PR)4!B+30R* -MD1T*``#KI8V%Y/[__U#H`,3__\:%S_[__P"+10R*0"8XA<_^__];B,$/@ZT' -M``"+50R*4BB(E7/^__^*G7/^__\XG<_^__]T0XJ%S_[__XM5##I")W0U#[;` -MP>`$`="-D,0(``"+@,0(```)A>3^__^+0@0)A>C^__^+0@@)A>S^__^+0@P) -MA?#^___^A<_^__\XC<_^__]RH0^VC7/^___!X02-G?3^__^-#!F+,2.UY/[_ -M_XFUU/[__XM9!".=Z/[__XF=V/[__XM1"".5[/[__XF5W/[__XM!#".%\/[_ -M_XF%X/[___?6]]/WTO?0B;7D_O__B9WH_O__B97L_O__B87P_O__(S&)M>3^ -M__\C602)G>C^__\C40B)E>S^__\C00S_=0R)A?#^___HG,/__XF%N/[__UG& -M0`0`BY7D_O__,<"%TG4>B[WH_O__A?]U%(NU[/[__X7V=0J+G?#^__^%VW0% -MN`$```"%P`^$A@4``(M%#(M5#(I`*(B%<_[__XB"V`D``(N%Y/[__XF"Q`D` -M`(N%Z/[__XF"R`D``(N%[/[__XF"S`D``(N%\/[__\:"V0D```'&A<_^__\` -MBDHF.(W/_O__B8+0"0``QX+4"0```````(B-=/[__P^#1`$``(J%<_[__SB% -MS_[__P^$#0$``(J5S_[__XM-##J1'`H```^"K@0``#J1'0H```^'H@0``#I1 -M)P^$F00```^VG<_^___!XP2-M?3^__^-'#.+A>3^__\)`XN%Z/[__PE#!(N% -M[/[__PE#"(N%\/[__PE##/]U#.ANPO__6L9`!`&*E<_^__^(4`B(4`F+$XE0 -M#(M3!(E0$(M3"(E0%(M3#(E0&(M=#/]U#(G&@-!,T`````*(/ -M*<*-#-&#^1\/C\P#``"X`0```-/@"4<@BIW/_O__BW4,.EXG#X0]`P``BU4, -MBE(FB)5T_O___H7/_O__BHUT_O__.(W/_O__#^__^*6B>)@N@)``#&@O$)```` -MQX+L"0```````%+H#L'__XF%L/[__U_&0`0!BXVP_O__B%D(BIVW_O__B%D) -MBX74_O__B4$,BX78_O__B4$0BX7<_O__B4$4BX7@_O__B4$8QH7/_O__`,>% -MT/[__P````"+10R*0"8XA<_^__^(A73^__\/@W37__^*E<_^__^+30PZ42@/ -MA(P!``"*62*A<_^__^(1PB(7PF+A=3^ -M__^)1PR+A=C^__^)1Q"+A=S^__^)1Q2+A>#^__^)1QB+C;C^__\K#X/I+,'Y -M`HT$S0`````IR(T$P<'@`RG(C03!B<+!X@\IPHT,T8/Y'P^/:P$``+@!```` -MT^`)1R"+C=#^__^%R71%BQ$/*=&-#,B#^1\/CPH!``"X`0```-/@"4<@BTT,BDDG -M_W4,BUT,B(VO_O__Z*6___^!P]P)```K.%J-3]3&0`0#B5@(P?D"BIVO_O__ -MB%@,B<:)A=#^__^-!,T`````*(/*<*-#-&#^1\/ -MCXD```"X`0```-/@"48@BX6P_O__*P:#Z"S!^`*-%,4`````*<*-%-#!X@,I -MPHT4T(G1P>$/*=&-#,B#^1]_,[@!````T^`)1B"+10R*0":(A73^___^A<_^ -M__^*C73^__\XC<_^__\/@DK^___IN=7__X/I(+@!````T^`)1AR+50R*4B:( -ME73^___KR(/I(+@!````T^`)1ASI;____X/I(+@!````T^`)1QSI[O[__X/I -M(+@!````T^`)1QSIC?[__XN%N/[__RLXC4?4P?@"C13%`````"G"C130P>(# -M*<*-%-")T<'A#RG1C0S(@_D??QZX`0```-/@BY6X_O__"4(@BDXFB(UT_O__ -MZ8#\__^#Z2"X`0```-/@BYVX_O__"4,`$C808Q`@``%!&Z):Z__^) -M\3I+)EARXHM3'.N(D%/_=0CH(]'__X7`6EETGHM-"(N!K"\``(E8!(D#BT7P -MB4,$B9FL+P``Z7K___^)]E6)Y593BT4(BU@(BX/D+P``A -MR<.-LZPO```YLZPO``!TZ>O`58GE5U93@^P,BT4(BT`(B<>+D*PO``"!QZPO -M```Y^HE%\'02BTT(.4H<#X2D````BQ(Y^G7NBTWPBY&T+P``@<&T+P``.AT$HU:^(M%"#E#''01BQ([5>AU[C'`@\0,6UY?R<,Q]HI#)HGQ.,%S2HA% -M[XGVB?$/ML'!X`2-!!B-B,0(``"+@,0(```Q_X7`=1>+002%P'40BT$(A)]K\!````A?]U%4:)\#I%[W*[,)]E6)Y5=64U.+70B+2R2+10R%R8E%\(M]$(MS -M"'4+4^BA_O__A7\G#C78`BT7PB4,DB7LH_X;H+P`` -MB74(C67T6UY?R>G\____B?95B>564XM=#(I#$83`BW4(=0;&0Q$!L`$\`706 -M/`9T$CP#=`Z*0Q"#X""$P'4$QD,1"_]S+%;H0;C__U/_R<.)=0B-9?A;7LGI_/___XV&["\``%!H```` -M`%;H_/___X/$#.O4D(/`&.OIC78`58GE5U93@>R\````BT4,BU`@BPJ)C4#_ -M__\/MD$\2(F%5/___V:+0@AFB85B____BTI,B8U<____#[9"2HF%4/___P^V -M2DN)C4S___]FBT)2BTH49HF%8/___X7)BW409HM:4`^$;@(``&8/MD(0@^`! -M#[?`.T44#X1:`@``B8U$____BU4,BP(/MD`#,?^)A4C___\QR9`/M\,#A5S_ -M__^)A5C___^+A4C___\YA5#___\/A`8!```/MYU@____P>,)D(N%1/___P^W -M4`2%TG4%N@```0")T"GX.=AW#2G#@X5$____"#'_Z]@!WXN58/___V8IE6+_ -M__\/A*D```#_A5#___^+A4S___\QVSF%4/___P^$A````(N50/___P^V0CPY -MA5#___]T+8N%0/___V:+4$1FBX5B____9CG09HF%8/___P^&2O___V:)E6#_ -M___I/O___XN%3/___X7`="W_C4S___\QP(.]3/___P`/E,")A5#___^+A4#_ -M__]FBU!$#[?"`85<____ZZ:+A53___^)A4S____KR_^%4/___^EQ____9L=& -M_@"`N0$```"-9?1;7HG(7\G#A58/___XG3B94\____P>,)C78`BXU$____#[=1!(72=06Z```!`(G0*?@Y -MV(F%./___W,OBX5$____BPB)T`'Y9BGXB0YFB48$9L=&!@``*YTX____@\8( -M@X5$____"#'_Z["+C43___^+`0'X`=^)!F:)7@1FQT8&``"#Q@@YUW0CBU4, -MBXU8____#[=""`.-//___P-"!#G!#X5%_O__Z?S^__^#P0@Q_XF-1/___^O0 -M9HE>!(/&".E`_____S4$````Z/S___]:Z0K___^+0A@QR87`#X30_O___W44 -MC8UD____45*)C43_____=0C_T(/$$#')A<`/A*W^___I=_W__XUV`%6)Y593 -MBU4,BD(1/`&+=0B+6B!T`XA#$5)6Z/S___^*0TE`B$-)6CI#2%ET!XUE^%M> -MR<.*0Q&$P'4&QD,1`;`!/`%T##P&=`@\`W0$QD,1"U-6_U,<6U[KTXGV58GE -M5U93@^Q(BT4,BE`0BSB(T(/@!(3`#X1#`@``BU4,BEI$A-O'1<``````#X1F -M`0``BT4,BTW`BTR(,(E-O(J!'`H``(A%NXJ!'0H``#A%NP^',@$``(I5NXM- -MO#I1)P^$$0$```^VP@^WE('\"0``#[>T@?X)``#!X`2)5:PQ_XV<",0(``"# -M?:P?#X?%`0``NB`````K5:PY\G8"B?*#^B`/A*,!``"(T;@!````T^!(BDVL -MT^`)`[@@````*T6L.<9V&8M%K(UT,.#'1:P`````1XGZ@\,$@/H#=JD/MD6[ -MB<*+3;S!X@2-E`I$"0``B56T#[>4@?P)``")5:P/M[2!_@D``#'_D(-]K!\/ -MARX!``")^8M5M`^VP8T<@KH@````*U6L.?)V`HGR@_H@#X0``0``B-&X`0`` -M`-/@2(I-K-/@"0.X(````"M%K#G&#X;1````BT6LC70PX,=%K`````!'B?J` -M^@-VG8M-O(J!'0H``/Y%NSA%NP^&U/[__XM-#(I91/]%P`^VPSE%P`^,FO[_ -M_XM%"(N0H"\``(72=%2$V\=%P`````!T-HV0K"\``(M%#(M-P(M,B#"+0@2) -M$8E*!(D(B4$$_T7`QX'T"0```````(M-#`^V040Y1(04L/MH(< -M"@``9HN$@OP)``!FB4%0#[:"'`H``&:+A(+^"0``9HE!4L9!2`#&04D`BT,$ -MBU6\B5,$B1K_1<")0@2)$(M-#`^V040Y1575E.#["B+10R+ -M`(E%\&:+6$0QR6:!^X``9HE=[G8&9L=%[H``BU4,BD(0@^`@A,`/A>T"``"+ -M11"*0!(/MM"+=1"(1=>+!HG6,=+W]HA5ZXM%\`^V4#R+=1"+1@2)UC'2]_:* -M1=Y((?AFBUWN -M9BG#9CM=['8#BUWLBW78]]Z+1>0A_H7`#X2$````QT7D`````&:+5>Z+1?!F -M.U!$MT/'0QBW7P9HM>1&8Y7>YS!\=%Y`$```"+11!F -MBT`09CG89HE%[`^&H?[__V:)7>SIF/[__X!]Z@!T)?Y-ZH!]Z@`/E$7KBUWP -M#[=#1(MU$`%&",=%Y`$```!FBUM$Z[B+11"*0!*(1>KKT_Y%Z^N),<"-9?1; -M7E_)PXM-#(I!1$B(043^P`^$GP```(M="('#K"\``(M]"(E=X(''I"\``(MU -M#`^V1D2+3(8PBD$F,=LXP\>!]`D```````"(1=]S08GV#[;#P>`$C00(C9#$ -M"```BX#$"```,?:%P'45BT($A+0@R%P'0%O@$```"%]G5" -M0SI=WW+!,<"%P'0LBU7@BT($B1&)2@2)"(E!!(M-#(I!1$B(043^P`^%=O__ -M_[C_____Z3W___^+1P2).8E/!.O5N`$```#KOP^W1>Y0BTT0_W$(_W7P_W4( -MZ."N__^)P8/$$(7)N/____\/A`3___^+70S&0T0!B4LPB9GT"0``Z>W^__^0 -M58GEBTT0AG\____D(E%#(E5 -M",GI+/?__U6)Y5=64X/L,(M%#(LXBD"+50P/ -MMUH(9HE=Y(I7/$J(5>8/MD\^#[;2B57(T^@QTHE%U/=UR(E%V`^V3S[3X(E% -MW`^W=T0/KT7(BTW(`UW,#Z_.*<.-1!G_,=+W\8G!#Z_.BT7C78`58GE4XM=#(M# -M+(7`=06+7?S)PU/H_/___S'26(M#+(L$D(7`=!")]L=`$`````"+0!2%P'7R -M0H'Z_P,``';=:@?_+?0A6C8>D -M+P``4XF'I"\``(F'J"\``(V'K"\``(F'K"\``(F'L"\``(V'M"\``(F'M"\` -M`(F'N"\``*$`````P>`,NJNJJJKWXHG3P>L/QX>@+P```````%-H(`H``%># -MPR#H3*;__U-J$%>)QNA!IO__`<:A`````,'@#,'H#E!J1%?H*Z;__X/$)&H( -M:``0``!7`<;H&:;__P'&5T;H_/___X/$$#LU`````*,$````<@B-9?1;7E_) -MPU?H_/___XG"A=)8=.M&BX?<+P``_X?@+P``.S4`````B0*)E]PO``!RUNO, -M58GE5U9348M%"(E%\(MU#(!F`?N+7@0/MDX#N`$```#3X(I31HG!B-"#X`*$ -MP,=#3`````")UP^$YP```&:+0TAFA7\G#4_]U\/_06%H/MGM&Z^*)]HC0@\@%_DL]A,!F -MB4M(QT-,`````(A#1GD&@^!_Z\:0@^"?B$-&4_]U\.C\____B<%?A* -M5@.(40.`20$(Q@$#H0P```")030/MM*A(````(E9!(E,DU")03C'1@0````` -MBD-&@^#^@\@*B$-&_D,]46H'Z/S___]86HM#!(7`=`R-=@")PXM`!(7`=??H -M_/___XE#0(E="(UE]%M>7\GI_/___V:+0TAFA<`/A$O____I$/___XGV58GE -MBU4,2E,QVX/Z_XM-"'0.B?8/M@%*`<-!@_K_=?0/ML-;R<.)]E6)Y593BUT( -M@#L#=D>*4SPQ]H32=!*)]HM,LU"%R7441@^VPCG&?/"`8T;[C67X6U[)PY"* -M4P&*00&#X@&#X/X)T(A!`?]TLU#H_/___UB*4SSKS(E="(UE^%M>R>L!D%6) -MY5=64X'L!`(``(M%",>%\/W__P````"`>#P`C;7T_?__#X0L`@``BW@$A?]T -M#XM'!(7`=`B)O?#]__^)QV@``@``:@!6Z/S___^#Q`PQP(7_QP;S%GA:=`.+ -M1T")1@2+50B`>D0`=`J`3@D"BD)'B$8*BT4(BE!`B-.*AI,```"#XP&#X/R( -MT8/A`@G8"&F`````````#H_/__ -M_VH$C8>`````4(U&/%#H_/___VH0C8?$````4(V&@````%#H_/___X/$)&I` -MC8>$````4(U&0%#H_/___X/$#(N%\/W__X7`=&*+E?#]__^+0@R)1AS'AIP` -M````````B@*(1B"*0CR(1B&+50B*0@.(1B*+E?#]__^*0CZ(1B.*0D:#X`*$ -MP'0$@$XD`8N5\/W__V:+0DAFB48FBT),B48HQX:@`````````(7_=$-HD``` -M`%;H_/___V@``@``5O?8B$8(Z/S____WV%:(AI````!J,(M5"(M"3(/H"E") -MT(/`/%#H_/___XUE]%M>7\G#BU4(B@*(1A#KLXM5".F[_O__,=+I>O[__XGV -M58GEBT4(4X`X`W8;,4(7`=1!##[;".<-\\(UE -M^%M>R<.04.C\____6(I6/.OD@&8!_NOFB?95B>6+30B+40@QP#D,@G0(0(/X -M!W;UR6+10R`8`'[B44(R>G\____D%6)Y5=64X'L -M!`0``(M]"(I7`8C0@^`$A,"-G?3]__^)_G0%@#\"=PB-9?1;7E_)PX/B_8A7 -M`6@``@``:@!3Z/S___^*!X/$##P#=!`\"(MV4`^$@0```(`^`W7P4VH@:@"- -M1CQ0Z/S___^#Q!!F@;O^`0``5:IUL(N+R@$``(7)=!6!>P9,24Q/=$&!NW8! -M``!'4E5"=#6)V,>%\/O__P,```"`N+X!``"`=!"#P!#_C?#[__]Y[.EL____ -MBY#*`0``A=)TYH!/`0+KX(!/`0+I4____XUV`(7V=`MF@W](`0^%% -M\/O__P$````/MD<\.87P^___C;7T^___#XUF____5FH@:@"+E?#[__^+1)=0 -M@\`\4.C\____,=*#Q!"+!)8Q!)-"@_I_?O3_A?#[__\/MD<\.87P^___?,7I -M)O___Y!5B>564XM="(N+2!$``(U!`;HA`@``B=:9]_Z+10R)1,L\BT40B43+ -M0(F32!$``%M>R<.058GE5U93BW4(BX9$$0``.X9($0``="N_(0(``(M6+30B+`87`BU4,=!&+0"2)0B2+`8E0)(D1R<.)]HE2).OUC78` -M58GE5U93BW4,BQ:%THG7="6-=@"+6B0YVG0EBT,DB4(D4_]U"/]3*%@Y^UIT -M"(L&A<")PG7>C67T6UY?R<.)]L<&`````.O958GEBT4(@#@(=`7)PXUV`,GI -M_/___XGV58GE4XM%"(`X"(M=#(M-$(M0"'0+45+_TXM=_,G#B?:+7?S)Z?S_ -M__^-=@!5B>575E-1BE40B%7SBT4(BW@HB@`/MMA35XA%\NC\____:@!35^C\ -M____:@!J`&H`:@!J`U-7Z/S___^#Q#`QTH7`#X2'````,=OW10P```#P#Y7# -MA=L/A(\````QP(!]\R`/E/___XUV`%6)Y8I%"(G"@^(#@^`$P>(- -MA,!T"XV"`"`#`,G#C78`C8(`(`(`Z_-5B>564U"*10QH(*$'`(A%]XMU"+L@ -MH0<`Z/S___]8D`^V1?=0Z*[___\%'`$``(D$)/]V#.C\____A,!:6;H!```` -M>1MH$"<``('#$"<``.C\____@?L_2TP`6';",=*-9?A;B=!>R<.-=@!5B>56 -M4VH`#[9%#%#H6____XG&C4`(B00DBUT(_W,,Z/S___]H&`$``(U&#%#_R<.058GE#[9%#&H`4.@=____@\`,B00DBT4(_W`,Z/S_ -M___)PXGV58GE9H-]%`"+10QU$_=%$````/!U"JD`_P``=`N-=@"X`0```,G# -MD&:%P'4+@WT(`;@!````=.TQP.OI58GE5U934(M=%(M#$(M-"(D!BT,4B4$$ -MBP,QTH7`BWT0B47P=06Z`0````^V1P31X`G"BT4,B[`X`@``A?9FB5$(#X0@ -M`0``@_X"#X07`0``@WL$`71Y9@^V0PX-`!(``&:)00IF#[9#"`T`$P``BU,( -M9HE!#(G09L'H"`T`%```9HE!#HG0)0``_P"!X@````_!Z!#!ZA@-`!4``('* -M0!8``&:)01!FB5$2C5$4BTWPA#"-AP0!``"+<@Q05HM=%.C\____B`.-AP@! -M``!05HE%\.C\____9@^VP&:)0P*-APP!``!05HE%[.C\____9@^VP&:)0P2- -MAQ`!``!05HE%Z.C\____9@^VP(/$(&:)0P:-AQ0!``!05HE%Y.C\____9@^V -MP&:)0PA8@WT0`5IT*8V'&`$``%!6Z/S___^(0PJ-AQP!``!05NC\____B$,+ -MC67T6UY?R<.0C8<@`0``4%:)1=SH_/___XA%XX/(@`^VP%#_==Q6Z/S_____ -M=?!6Z/S____!X`AF"4,"_W7L5NC\____P>`(@\0D9@E#!/]UZ%;H_/___\'@ -M"&8)0P;_=>16Z/S____!X`AF"4,(#[9%XU#_==Q6Z/S___^#Q!SI6____U6) -MY5=64X/L&(M5"`^V=0R+?+(DBT409HE%XHM',(/`,%#_<@SH_/___X/@'XT4 -MQ0`````IPHT$UXV01`(``%F#N$0"```!B57<6W0_C9A8`@``C47D4/]S!%;_ -M=0CH8?[__XU5Y/Z/40D``%)J``^W1>)0_W,<:@%6_W575E.#["B+51`/MD4,BTT(BW2!)(E%T&:+`F:)1=QF -MBT("9HE%WHM"!(E%X&:+1=R#X!^-%,4`````*<*-'-:-@T0"``")1=AFBT7> -MA,#'1=0`````9L=%S@``="YFBT7>)?\```!FB47.QT74`0```&:!3& -M3`D```````#'AC0"````````9HM%WH/@!&:%P(V[6`(```^%D````(.[1`(` -M``%T2_Z.40D``(U%Y%"+1>!0#[=%SE#_=QS_==3_==#_=BC_5QC_==A6Z`@/ -M``"+ODP)``"#Q"2%_W03BX9$"0``A7\G#_W70 -M_W4(Z*40``#_MD0)``!6Z)D1``"#Q!"%P'7::@#_MD0)``!6Z*0%``"#Q`SK -MQXUV`(U%Y%#_=P3_==#_=0CHZOS__X/$$.E6____B?95B>575E-0BUT(BW4, -MBWT0:"P-``#_G\____C78` -M58GE5U93@^PDBT4(BT@,B47PBU4<#[9%#,'@`HE5[(I5$`G"B4WDBT7P#[;* -MBW2()(M%&(7`BWT4QT7@`````(A5ZXE-W'1LA?8/A,X```"-!/T`````"T8D -MBY[<"0``4(M&,(/`)%#_=>3H_/___X/$##G[=":+5=R)5=B-=@"+1A2-!-A0 -M_W780_]U\(/C'^B&_?__@\0,.?MUXXN&3`D``(7`=0?'1>`!````B9[<"0`` -MBT7LAF@!#X3/````BT7P@WA@ -M`0^$K@```(-X9`$/A*0```"#>&@!#X2:````BU7P@WI<`70R#[9=ZU/H]_;_ -M_P4<`0``B00D_W7DZ/S___]97E-J`&H!_W7PBTWP_U$@C67T6UY?R<-J!`^V -M7>M3Z,/V__^-<"B)-"3_=>3H_/___U;_=>3H_/___VH9Z/S___]J`%;_=>3H -M_/___X/$)%;_=>3H_/___VC0!P``Z/S___]3_W7PZ'<&``"#Q!3IM0_W7PZ'<'``!?6.E;____BDWKN``!``#3X%!0_W7PZ%3]__^#Q`SI -M%?___XG8@^`09H7`=5N!XP`!``!FA=L/A%#___^#OC0"```!=!R#/0`````! -M#X4Z____B74(C67T6UY?R>DF#@``QX9,"0```````,>&-`(```````#_==#_ -M==3_=?#H"/O__X/$#.N]_W74_W7PZ,P%``!8BT7P@WAD`5IT'8-X:`%T%P^V -M1>M0:@%J`?]U\(M5\/]2(.G1_O__:@"*3=2X``$``-/@4/]U\.B?_/__@\0, -MZ\^)]E6)Y5,/MD4,P>`""T40BUT(#[;`BTR#)(7)=#"+D40)``"%TG0+@SH! -M=`:#>A`!=`^)10R)70B+'"3)Z>P+``")50R)30B+'"3)ZPB)10SKYHUV`%6) -MY5=64U&+50B*&HM"*(MX#(C8BW(P@^`#B$7SC88@`0``4%>!QAP!``#H_/__ -M_U97@^,$Z/S____`ZP*)Q@^V3?.#XP&X``$``-/@2_?0@>,``/__4('#%``# -M`%-7Z/S___^)\H/$'(32>".)\(/@`83`#X62````BU4,BT(4@_@!=%N#^`%R -M3X/X`G0)D(UE]%M>7\G#@^9@B?`\0'7OBU4,BUH@A=MU$FH`4HGV_W4(Z`P! -M``"#Q`SKTXM%#(/`%%#_=0CH5````(7`6EEUOFH!_W4,Z]=J`.OWC78`@^9` -MB?"$P'0CBT4,@\`44/]U".@H````2%]:==6+50R+O(C78` -M58GE5U93@^P4BUT,C7WD5X/#%/]S!(MU",=%X``````/M@90_W8HZ#3W__^# -MQ!"#?1`!#X3W````5VH`:@#_`/M@90_W8H_U,<_W4,5NBY"```@\0D -M@WT0`0^$L````(N&1`D``(7`="^#>!`!='Z+CC@"``"%R71*#[8&4/]V*.BZ -M"0``BYY$"0``6(7;6G0'BWL0A?]T"XUE]%M>7\G#C78`C4,44%-6Z'T*``"+ -M6PB#Q`R%VW3@BTL0AC\____@\04ZXQ05NCG"@``A:@#_MD0)``!6Z//^__^# -MQ`SKBXGV@ST``````0^%0____U;H<0H``%CI-____XUV`,=%X`$```#'ADP) -M````````Z?/^__^)]E6)Y5=64U.+70B+0RB+>`R+0S")QH/&*%97B47PZ/S_ -M__^#X`1:60^$2`$``&H"5E?H_/___U97Z/S___]HT`<``.C\____#[8#4/]S -M*.C5`0``@\0@QH,\`@```,:#4`D```#&@U$)````QX/8"0```````,>#W`D` -M``````#'@S0"````````QX/4"0``(````#'`C78`B82#5`D``$"#^!]^\XV3 -M1`(``+@?````QP(!````@\(X2'GTBT7PQX-$"0```````,>#2`D```````#' -M@TP)````````@\`(:@!05^C\____BT7P:!@!``"#P`Q05^C\____@\08BT7P -M_W,8@\`04%?H_/___XM#'"4`_/__4(M%\(/`%%!7Z/S___^+1?!J`(/`&%!7 -MZ/S___^#Q"2+1?#_N`$```!?R<-J`E97Z/S___^#Q`SIT/[__XGV -M58GE5U93@^P8BT449HE%XHM%#(7`=6J+70B^'P```)"+NT0"``"%_W51@[M4 -M`@```719BX-<`@``B[MT`@``BY-P`@``B5710:@`/MT7B4%?_=1"+50@/M@)0_W(H_U7<@\0L@\,X3GF?C67T6UY? -MR<.-=@"+@UP"``"+NW@"``"+DW0"``#KI56)Y5=64U`/MG4,B?"#X`2+70B_ -M`P```,#H`B'W@WM<`8A%\P^$D@```(-[8`$/A(@```")^@^VPL'@"(!]\P!T -M<@5T`0,`4/]S#.C\____B<&)\`^VT`^V1!-ZP>`%)>````"!X1____\)P0^V -MA!."````P>`+@>'_Y___)0`8```)R(GZ4`^VPL'@"(!]\P!T&05T`0,`4/]S -M#.C\____@\04C67T6UY?R<,%=`$"`.OED`5T`0(`ZXR0B?H/ML+!X`B`??,` -M=$8%#`$#`%#_575E,/MG4, -MBUT(5NC9[O__B30D4XUX*.BA[___:@17_W,,Z/S___]7_W,,Z/S___]J&>C\ -M____@\0@:@!7_W,,Z/S___]7_W,,Z/S___]64^B0_O__B74,B5T(@\0D3[___C78`58GE5U934,9%\@"0QD7S`(I5\XI%\HTT@H'F_P```%;H -M5^[__XU8*(G'QP0D`@```(M%"%/_<`SH_/___U.+50C_<@SH_/___U;_=0CH -M/O___VH`BT4(4_]P#.C\____@\0H:!\!``!7BU4(_W(,Z/S___]J`(U'!%"+ -M10C_<`SH_/___VH`C4<(4(M5"/]R#.C\____@\0D:@"-1PQ0BT4(_W`,Z/S_ -M__]J`(U'$%"+50C_<@SH_/___VH`C4<44(M%"/]P#.C\____@\0D:@"-1QA0 -MBU4(_W(,Z/S___]J`(U''%"+10C_<`SH_/___VH`C4 -M7\G#B?95B>5H___/#VAL!`$`BT4(_W`,Z/S____)PXGV58GE4XM="(M#!##` -M/0``@%!T(6@L#0``_W,,Z/S___^#R`%0:"P-``#_6+30R+50C' -M00@`````BX)("0``B4$,BX)("0``A-=@"+00R)0@SKQ%6)Y5=64XM=$(L#A<"+?0B+=0QU,VH@C4,$ -M4(U&%%#H_/___XL#@\0,B4805E?H*?___\<&`````/Z'/`(``(UE]%M>7\G# -MD&HDC4,$4(U&%%#H_/____Z'4`D``.O%D%6)Y593BW4,BT80A<"+70AT!OZ+ -M4`D``%93Z!W___^+@]0)```/ME8$B92#5`D``,<&`0```$")@]0)``#^BSP" -M``"-9?A;7LG#B?95B>6*10@\`W82#[;(C4P)`K@!````T^#)PXGV#[;(C4P) -M`>OLC78`58GE5U93#[9]#(GX#[;PBUT(5NC`____"4-4B30DZ,WI__\%'`$` -M`(D$)/]S#.C\____B?F#X0.X``$``-/@@^<$]]!0B?B$P`^5P`^VP$@E``#_ -M_P44``,`4/]S#.C\_____W-4:&0=``#_#-`(```$```!0,<"$T@^5P$@E``#__P44 -M``,`4%?H_/___VH`BT,P@\`(4%?H_/____]U\/]U".AD____@\0@C88<`0`` -M4%?H_/___X/&*,>#0`(```$```!J`597Z/S___^-9?1;7E_)PXGV58GE5U93 -M48MU"`^V10R)1?"+1(8DBU@PBWX,QX`T`@```````(/#*&H"4U?H_/___U-7 -MZ/S___^+5?")50R)=0B#Q!2-9?1;7E_)Z53^__]5B>564XM="(M#*(MP#/]U -M$/]U#%.+@]@)``#!X`4#0Q!0Z%'I__^+D]@)``!"BT,<@^(?B9/8"0``)0#\ -M___!X@4)T/Z#40D``(E%$(M#,(/`%(E%#(EU"(/$$(UE^%M>R>G\____D%6) -MY5-J`&H":@"+70A3Z"7W__]3Z)?U__]3Z/S___^#Q!A(=`>+7?S)PXGV#[8# -MQX-,"0```0```%#_B=!?R<.# -M?@0!#X1&`0``]T80`/\`_W41]T84`/\`_W4(9O=&&`#_=`0QTNO.C8<$`0`` -MB47HC8<(`0``B47DC8<,`0``B47@C8<0`0``B47A3Z/S___\/MD824/]UY%/H_/___P^V1A10_W7@4^C\____@\0D#[9&%E#_ -M==Q3Z/S___\/MD884/]UV%/H_/___P^V1AI0C8<8`0``4%/H_/___X/$)`^V -M1AM0_W7L4^C\____@\0,@SX"=`JZ`0```.DC____C8<@`0``4%/H_/___VID -M:@I74^C\____@\08,=*%P`^$_O[___]U[%/H_/___X/@B5HQTCP(60^%YO[_ -M_\=%\`````"!QP`!``"-=@"+1@@/MQ!2@\`"B48(5U/H_/____]%\(/$#(%] -M\/\```!VW8%N#``!``#I>O___Y`/MD814(V'!`$``%!3B47HZ/S___\/MD83 -M4(V'"`$``%!3B47DZ/S___\/MD854(V'#`$``%!3B47@Z/S___^#Q"0/MD87 -M4(V'$`$``%!3B47((A,`/A!,"``"-@G0!`P!0_W,,Z/S___^)PH'BX````"4`&```P>@+ -MP>H%B%0[>HB$.X(```!&65B)\$<\!W:T4^@6]O__4^CX]___4^@.^/__:@!H -M\`0!`/]S#.C\____:"P-``#_#YS!86@^$<@$``(M#1*G@`P"`=`@E'_S_ -M?XE#1(-[7`$/A#T!``"#>V`!#X0S`0``@WMD`0^$*0$``(-[:`$/A!\!```Q -M]C'_D%=31NCL\___68GQ1X#Y!UAV[O]S1&@`#```_W,,Z/S_____=!"#>V@!=`JZ`0```.D+_O__,?\Q]L=% -M\`````")]O]U\%/H_/___X7`6EEU#+@``0``BDWPT^`)QT:)\/]%\#P'=MM7 -M:`#_``!3Z._I__^#Q`SKLXM#1*D0````#X33_O__@^#OB4-$Z7'!0`````!```` -MR<.058GEQP4``````````,G#D%6)Y593BW4(#[9%#(M#3`D```````#'@S0"````````B5T(C67X6U[)Z>7O__^0C67X -M6S'`7LG#C78`58GEBT4(#[95#(M4D"0QP(72=`PQP(.Z3`D```$/E<#)PXGV -M58GEBD4,B<*#X@.#X`16P>((A,!3BW4(C9H``0,`=0:-F@`!`@!3_W8,Z/S_ -M__^#X`]9@_@!6G0;@_@!<@6#^`-T"3'`C67X6U[)P[@!````Z_*04_]V#.C\ -M____:$`-`P#H_/___U/_=@SH_/___X/@#X/$%.O&58GE5U93@^P4BD4,B$7S -M@^`#B$7GBD7S@^`$P.@"BW4(#[9]\XA%YHM4OB2+1@R)1>PQP(72#X1$`0`` -MBT(P@[I,"0```8E%Z`^$+P$``%=6Z.;A__^+7>AJ!(/#*%/_=>SH_/___U/_ -M=>SH_/___VH9Z/S___^#Q"!J`%/_=>SH_/___U/_=>SH_/___U=6Z,_P__\/ -MMD7GP>`(,?^#Q!R)1>"`?>8`#X0N`0``BT7@!0@!`P!0_W8,Z/S___^)PX/C -M\`^V1>>#RP'!X`B`?>8`4P^$]P````4(`0,`4/]V#.C\____#[9%Y\'@"(/$ -M%(!]Y@`/A,D````%"`$#`%#_=@SH_/___VH9Z/S___\/MD7G@^/PP>`(@'WF -M`%,/A),````%"`$#`%#_=@SH_/___P^V1>?!X`B#Q!B`?>8`=&T%"`$#`%#_ -M=@SH_/___VC0!P``Z/S___\/MEWS4U;H_/___X/$%(7`=1M'@_\##X4M____ -M4U;H?N#__S'`C67T6UY?R<.+1>@%'`$``%#_=>SH_/___X/@P%D\0%]UU5-6 -MZ%/@__^X`0```.O0!0@!`@#KD9`%"`$"`.EH____B?8%"`$"`.DR____B?8% -M"`$"`.D$____B?:+1>`%"`$"`.G-_O__C78`58GE5U934XM5"`^V10R+7((D -M,S!T>E?_=?#H_/___XG"6(M%$(7` -M6752C4;_,+__O__4E?_=?#H_/___[D!````C67T6UZ)R%_)PX'*``$``.O?D,>#.`(` -M``$```"!XL#]___KP(GV,"3`D```$```!14^AQ]?__N`$```"+7?S)PXUV`#'`Z_15B>4/MDT, -M4XM="(M4BR0QP(72=0>+7?S)PXGVQX),"0```````%%3Z,_U__^X`0```.OA -M58GEBT4(4P^V50R+7)`D,<"%VW0A@[M,"0```70>:@!J`O]U$%/HC>W__U/H -M_^O__[@!````BUW\R<.0,<#K]E6)Y8M%"`^V50R+5)`DA=*X_P```'0'#[:" -M/`(``,G#58GE5E.+50@/MD4,BW(,BU2")#')A=)T'(M:,(/#+%-6Z/S___]: -M@WT0`5ET)C')@^`"=0N-9?A;BR<.)]FH`4U;H_/___X/$#+D!````Z^*0 -M,7\G#C78`#[;2P>((A,!T:H'"=`$#`(E5 -M\/]U\(M%"/]P#.C\____B?+!X@6!XN`````E'____PG0B?K!X@LE_^?__X'B -M`!@```G"4O]U\(M5"/]R#.C\____#[;#B?F+50B(C`*"````B?&(3`)Z@\04 -MN`$```#K@I"!PG0!`@#KE%6)Y5=64[\#````BET,(=^#XP3`ZP(/E<`/ML!( -M)0``__\%&``#`%"+=0C_=@SH_/___XGY#[;1C4H8N@$```#3X@G"B=B#X`%( -M)0``__^#XP%2!1@``P!+4('C``#___]V#('#&``#`.C\____4_]V#.C\____ -M@\0575E-6BD4,B$7SBE7S@^`#B$7R@^($#[9% -M\U"+?0C`Z@)7B=;H+.S__XGP@^`!2"4``/__!1@``P!0_W<,Z/S___\/MEWR -MC4L8NO[____3PB'"B?"#X`%()0``__]2!1@``P!0_W<,Z/S___^)\(/@`4@E -M``#__P48``,`4/]W#.C\____B=B)\L'@"(/$)(32=%8%"`$#`%#_=PSH_/__ -M_X/@\(/(`5")\@^V1?+!X`B$TG0L!0@!`P!0_W<,Z/S___\/MD7S4%?HA^O_ -M_X/$'(UE]%M>N`$```!?R<.-=@`%"`$"`.O2D`4(`0(`ZZB058GE5U93@^P( -M#[9]#(M%"(M`#(GZB47P#[;"BU4(BUR")(GZB?B#X@.#X`3!X@B$P(MU$`^$ -M$`$``(V"=`$#`%"+10C_<`SH_/___XE&6%F%VU@/A.D```"+4S")5>R)^@^V -MPE#_=0CH_/___XD&7X7`6@^$O````(N#3`D``(E&+(N#.`(``(E&,(J#/`(` -M`(A&-#'2B?:*1!IJB$0R!$*#^B=V\O]U[/]U\.C\____B48XBT7L@\`04/]U -M\.C\____B48\BT7L@\`44/]U\.C\____B49`BT7L@\`84/]U\.C\____B49$ -MBT7L@\0@@\`<4/]U\.C\____B49(BT7L@\`@4/]U\.C\____B49,BT7L@\`D -M4/]U\.C\____B490BT7L@\`H4/]U\.C\____B494C67T6UZX`0```%_)P\<& -M`````.OKC8)T`0(`Z>O^__^-=@!5B>6#[#"+11")1=2+112)1=R+11AFB47@ -MBT4<9HE%XHM%((E%Y(M%)(E%Z(M%*(U5T(E%[(M%+%*)1?`/MD4,4/]U",=% -MT`````#H_/___\G#B?95B>575E.#[`B*10P/MOB(1?.+10B+=+@DA?:X!``` -M``^$L````(N.3`D``(7)#X1$`0``@+X\`@``'P^$3P$``(N&U`D``$B+G(94 -M"0``B8;4"0``C03=`````"G8C83&1`(``(E%[(A8!(M%$(L0A=(/A<````") -MQX/'!(.^.`(```(/A*(````/MT<,#[=7#E#_=PA2_W8(Z!7:__^)1P2#Q!!( -M=&*`OE`)````=4B+AC0"``"%P'0C_W40_W7L5N@Q[O__5_]U[%;HI_#__X/$ -M&#'`C67T6UY?R<,/MEWS4_]U".AQ[___4_]U".B8[___@\00Z\+_=1#_=>Q6 -MZ//M__^#Q`SKRHM&"(7`=9>+AM0)``")G(94"0``0(F&U`D``+@#````ZZK' -M1P0!````Z7#_____=1#_=>Q6Z+3M__^#Q`R`OCP"```!=82#OC0"```!="G_ -M=>Q6Z,;P__^%P%I9#X5H_____W7L5NCC[?__C78`N`$```#I5/___U?_=0CH -MG>___UM?Z\J0N`(```#I//___XGV58GE5U93@^P4BT4(BT`,:&`=``!0B47D -MZ/S___^+50B)QHM25%DQP(76B57P6W0U]\8```0`#X4=`0``QD7K`,=%X``` -M``#WQO\!``!U(<'N"/Y%Z]'N_T7@@'WK`7;GN`$```"-9?1;7E_)PXUV`#'; -M@'WK``^5PTN!XP``__]J[X'#%``#`%/_=>3H_/___U/_=>3H_/___XE%[/?0 -M@\@04%/_=>3H_/___X/$(#'`@'WK``^5P$@E``#__P4(``,`4/]UY.C\____ -MB<=8QD7J`%H/MDWJNP`!``"X`0```-/CT^")\B-=[(/B`2-%['4$A=)T&O]U -M[%)0B?B#X!]04?]UX/]U".BRWO__@\0S_ -M_X5%\%MU%_Y%ZL'N`L'O"(!]Z@-VF.D1____C78`#[9%ZE#_=>#_=0CH0.'_ -M_X/$#.O4:%@=``#_=>3H_/___XG#]]!0:%@=``#_=>3H_/___VH`4VH`_W4( -MBU4(_U(@@\0DZ:[^__^)]E6)Y6H`BT4(:&0=``#_<`SH_/___[@!````R<-5 -MB>6+10C_<%1H9!T``/]P#.C\____N`$```#)PXUV`%6)Y5=64XM]$#';.?MS -M)HM%#(VP'`$``%;_=0CH_/___X3`6EEY&/]U%$/H_/___SG[6'+C,<"-9?1; -M7E_)PX/@`8/P`0^VP.OMB?95B>53:@"+70B+0S`%(`$``%"+0RC_<`SH_/__ -M_XM#,`4@`0``4(M#*/]P#.C\____BUW\R<.)]E6)Y5-J`HM="(M#,`4@`0`` -M4(M#*/]P#.C\____BT,P!1P!``!0BT,H_W`,Z/S___^+7?S)PXGV58GE5U93 -M4XM5"(M"*(MP##';BT(P@[HT`@```8E%\'1#BWWP@<<@`0``5U;H_/___ZF! -M````6EEU8(GV5U;H_/___ZF!````6EET(HG80V8]MPMW#VCH`P``Z/S___]8 -MZ]J)]C'`C67T6UY?R<-J9&H*_W7P5NC\____BT7P!1P!``!05NC\____@^#! -M@\08/$`/E,`/ML#KS&HRZ[R)]E6)Y5=6BT4(4P^V50R+7)`D,<"%VW1'BT,H -M@[M,"0```8MX#(MS,'0S4^C\____:.$```"-AAP!``!05^C\____:F1H$"<` -M`%97Z/S___^#Q""%P'424^C\____,<"-9?1;7E_)PXGV4^C\____N`$```#K -MZ8UV`%6)Y593BTT(#[95#(M$D20Q]H7`=$=H[````&H`:@!J`&H`:@!J`&@` -M`0``C5@T4VH`:@%24>C\____,?:#Q#2%P'09]H.@````X'0+,G\____,<#)PU6)Y6CO```` -M:@`/MD4@4`^V11Q0#[9%&%`/MD444`^V11!0:@!J`&H`:@`/MD4,4/]U".C\ -M____R<.)]E6)Y5=64X/L'(M%"(E%\(M%$(E%[(M%%(E%Z(M%&(E%Y(M%'(E% -MX(M%(&:)1=Z+121FB47)12@/ -MMT77\GI_/___U6)Y5=64X/L<(M5(&:)5>2+ -M52AFB57$BU4P9HE5I(I5.(M%"(M-)(A5H@^V50R+7)`D9HE-U(M-+&:)3;2+ -M<`R*332+>S!3B$VCZ!G]__]:,=*%P'4*C67T6UZ)T%_)PU/H_/___X-]%`%8 -M#X3'`0``]T7D`/\```^%^@```/=%U`#_```/A>T```#W1<0`_P``#X7@```` -M]T6T`/\```^%TP```(V'!`$``(V7"`$``(E%E(E5D(V/#`$``(V'$`$``(V7 -M%`$``/=%I`#_``")38R)18B)580/A9D````/MD7D4/]UE%;H_/___P^V1=10 -M_W605NC\____#[9%Q%#_=8Q6Z/S___^#Q"0/MD6T4/]UB%;H_/___P^V1:10 -M_W6$5NC\____#[9%HU"-AQ@!``!05NC\____@\0D#[9%HE"-CQP!``!15HE- -MF.C\____BTT0@\0,A0/ML50C8<$`0``4%:)193H_/___XM5U`^VQE"-CP@! -M``!15HE-D.C\____BU7$#[;&4(V/#`$``%%6B4V,Z/S___^+5;2#Q"0/ML90 -MC8\0`0``45:)38CH_/___XM5I`^VQE"-CQ0!``!15HE-A.C\____@\08Z2G^ -M__^)]E6)Y5=64XM="(M#*(MS,(MX#&H&C88@`0``4%?H_/___XM#,`4@`0`` -M4%?H_/___VH*Z/S___]3Z/S___]H]`$``.C\____@\0@:/0!``#H_/___VCT -M`0``Z/S___]H]`$``.C\____,=N#Q`R!QAP!``"05E?H_/___X3`6EFZ`0`` -M`'D6:/0!``!#Z/S___^!^P\G``!9=MHQTHUE]%M>B=!?R<.)]E6)Y5.+70A3 -MZ$O___](6G07:/0!``#H_/___UB)70B+7?S)Z3#___^X`0```(M=_,G#B?95 -MB>564VB@````H0````"+0!@%```$`%"+=0A6Z/S___^[!````(/$#*$````` -MBT`0!0``!`!05NC\____64M8>>>[!0```)"A`````(M`%`4```0`4%;H_/__ -M_UA+6GGGNP0```"A`````(M`$`4```0`4%;H_/___UE+6'GGC67X6U[)PXGV -M58GE4VB`````H0````"+0`P%```$`%"+70A3Z/S___]HL````*$`````BT`8 -M!0``!`!04^C\____BUW\R<.)]E6)Y593BW4(5N@J____:@"A`````(M`"`4` -M``0`4%;H_/___Z$`````BP`%```$`%!6Z/S___^(PU;H@?___P^VVXUE^(G8 -M6U[)PY!5B>575E-H+`T``(M="%/H_/___XG'@\@!4&@L#0``4^C\____:/`$ -M`0!3Z/S___^)QH/@8H/$'&:#^&)T%XGP@\AB#[;`4&CP!`$`4^C\____@\0, -M:```!`!3Z/S___]86E/HA/[__VH'H0````"+0`@%```$`%!3Z/S___]J$:$` -M````BP`%```$`%!3Z/S___]J!:$`````BT`(!0``!`!04^C\____@\0H:A&A -M`````(L`!0``!`!04^C\____4^BM_O__5FCP!`$`4^C\____:/`$`0!3Z/S_ -M__^#Q"17:"P-``!3Z/S___^#Q`R-9?1;7E_)PU6)Y5=64V@L#0``BUT(4^C\ -M____B<>#R`%0:"P-``!3Z/S___]H\`0!`%/H_/___XG&@^!B@\0<9H/X8G07 -MB?"#R&(/ML!0:/`$`0!3Z/S___^#Q`QH```$`%/H_/___UE84^B,_?__:@>A -M`````(M`"`4```0`4%/H_/___VH`H0````"+``4```0`4%/H_/___VH%H0`` -M``"+0`@%```$`%!3Z/S___^#Q"AJ`*$`````BP`%```$`%!3Z/S___]3Z+7] -M__]6:/`$`0!3Z/S___]H\`0!`%/H_/___X/$)%=H+`T``%/H_/___X/$#(UE -M]%M>7\G#58GE4XM="%/H[_S__VH*H0````"+0`@%```$`%!3Z/S___]J`*$` -M````BP`%```$`%!3Z/S___]3Z$;]__^#Q"!H`0`$`%/H_/___X/@`EJ$P%FZ -M_____W0*B="+7?S)PXUV`%/HDOS__VH!H0````"+``4```0`4%/H_/___U/H -M__S__VIDZ/S___]H`0`$`%/H_/___X/@`C'2@\0@A,`/E<)*Z[.058GE5U93 -M@^P(BT4(BU@,BWT,:"P-``!3B?J(5?/H_/___XE%[(/(`5!H+`T``%/H_/__ -M_VCP!`$`4^C\____B<:#X&*#Q!QF@_AB=!>)\(/(8@^VP%!H\`0!`%/H_/__ -M_X/$#&@```0`4^C\____6%J+10B)^HA0>0^V1?-0:`#@!0!3Z/S___]6:/`$ -M`0!3Z/S___]H\`0!`%/H_/___X/$(/]U[&@L#0``4^C\____@\0,C67T6UY? -MR<-5B>6`?1``BU4(BDT,=!VX`0```-/@"$)Y#[9">8E%#(E5",GI_/___XUV -M`+C^____T\`@0GGKX56)Y5=64X/L#&@L#0``BW4(5L9%\P#H_/___XE%Z(/( -M`5!H+`T``%;H_/___VCP!`$`5NC\____B47LBT7L@^!B@\0<9H/X8G08BD7L -M@\AB#[;`4&CP!`$`5NC\____@\0,:```!`!6Z/S___]96V@```0`5NC\____ -MB<-F@?M5JEA:=%)HL````*$`````BT`8!0``!`!05NC\_____W7L:/`$`0!6 -MZ/S___]H\`0!`%;H_/___X/$(/]UZ&@L#0``5NC\____#[9%\X/$#(UE]%M> -M7\G#,?^-=@"%_W@CC5\!D&B@````H0````"+0!@%```$`%!6Z/S___^#Q`Q+ -M=>&!_\@````/CYT```!H```$`%;H_/___XG#:+````"A`````(M`&`4```0` -M4%;H_/___X/$%&:!^U6J=1%'@?_'````?I3I./___XUV`&BP````H0````"+ -M0!@%```$`%!6Z/S___]H```$`%;H_/___X/$%&8]5:H/A03___]6QD7S`>B= -M^O__/#Y;#X7Q_O__5NC*_/__AR<,````````````` -M``````````````0````````````````````````````````````````````` -M```````````````````````````````````````````````````````````` -M```````````````````````````````````````````````````````````` -M`````````0```````0`!``$``@`!``,``0`$``$`!0`!``8``0````$``"`! -M``!``0``8`$``(`!``"@`0``P`$`DC0``(4T``"%-```I30``+`T``"[-``` -MQC0``"``!,```` -M`@`!`*L```!4'@``,`````(``0"S````A!X``#L````"``$`O@```,`>```1 -M`````@`!`,8```#4'@``+`````(``0#8`````!\``"L````"``$`YP```"P? -M``!0`````@`!`/(```!\'P``.`````(``0#_````M!\``%$````"``$`"P$` -M``@@``#+`0```@`!`!@!``#4(0``L0````(``0`E`0``B"(``)<"```"``$` -M+P$``"`E``#P`````@`!`#X!``!89@``M0````(``0!)`0``$"8``.@#```" -M``$`50$``&0U``#W+0```@`!`&,!``#$9```.@$```(``0!O`0``^"D``"<` -M```"``$`>0$``$@S```9`@```@`!`(L!```@*@``I0````(``0"<`0``R"H` -M`!8!```"``$`J0$``.`K``"<`````@`!`+8!``"D+```;@````(``0##`0`` -M?"P``"@````"``$`S@$``!0M``!E`0```@`!`-D!``!\+@``P@$```(``0#E -M`0``;#(``&H````"``$`\P$``$`P``#%`````@`!```"```(,0``8@$```(` -M`0`-`@``V#(``&\````"``$``````````````````P`&`!X"```09P``#0,` -M``(``0`N`@``(&H``%H````"``$`10(``'QJ```\!0```@`!`%`"``"X;P`` -M8P,```(``0!<`@``'',``#0````"``$`;`(``&!X``!V`@```@`!`'D"``#@ -M?P``*`````(``0"*`@``=(```#\````"``$`GP(``+2````B`````@`!`+(" -M``#8@```/`````(``0"_`@``%($``+4"```"``$`U0(``,R#```\`0```@`! -M`.P"```(A0``E`````(``0`$`P``?)4``$H````"``$`$@,``)R%``!.`0`` -M`@`!`"4#``!,EP``4`````(``0`T`P``3)@```0"```"``$`2`,``&R,``!& -M`0```@`!`%L#``#LA@``D0````(``0!J`P``@(<``-("```"``$`?@,``-R/ -M```7`0```@`!`(P#``#TD```;0````(``0">`P``!)@``$8````"``$`JP,` -M`%2*``!1`````@`!`,$#``"`E@``+@````(``0#8`P``J(H``!X!```"``$` -MZP,``,B+``"A`````@`!`/L#``"PE@``F@````(``0`(!```G)<``&<````" -M``$`&P0``+2-``"&`0```@`!`"P$```\CP``H`````(``0`Z!```9)$``.8! -M```"``$`2P0``$R3```:`````@`!`&0$``!HDP``#0$```(``0![!```>)0` -M`#X````"``$`D`0``+B4``!D`````@`!`*0$``````7P```!(``0`'!@``Z`<``%`````2``$`&@8``'![ -M```3````$@`!`"@&```X"```(0$``!(``0`U!@``3'L``"$````2``$`1P8` -M`%QU``!8````$@`!`%(&``!<"0``(P$``!(``0!E!@``_`L``%<````2``$` -M=@8``"!^```3````$@`!`((&``#,?```,P```!(``0"2!@``5`P``.T````2 -M``$`I`8``/1]```K````$@`!`+0&``!$#0``.@```!(``0#'!@``@`T``'4` -M```2``$`V08``%`.``!.`0``$@`!`.\&``"@#P``@0```!(``0`,!P``)!`` -M`(8````2``$`(`<``%Q^``!(````$@`!`"X'``"L$```H0```!(``0!%!P`` -M4!$``$8!```2``$`70<``)@2``#!````$@`!`','`````````````!````!] -M!P``R!0```D"```2``$`CP<``#1^```E````$@`!`*`'``#4%@``(@$``!(` -M`0"S!P``^!<``+\!```2``$`Q`<``*@:``!7````$@`!`-0'````&P``[0`` -M`!(``0#E!P``\!L``"X````2``$`]P<````````$````$0`#``<(```````` -M`````!`````5"```7&,```H!```2``$`*`@`````````````$````#L(```` -M`````````!````!""``````````````0````20@``&AD``!<````$@`!`%4( -M`````````````!````!W"```B'T``&D````2``$`A0@```!F``!6````$@`! -M`)<(``!0P``0@```!(``0`1"0``A'L``$)X``.D!```2``$`?@L``&2@``"L````$@`!`),+``#$ -MH0``(````!(``0"J"P``Y*$``%\````2``$`RPL``$2B``"X````$@`!`.4+ -M``#\H@``AP```!(``0#^"P``A*,``/,````2``$`%@P``'BD``!5`0``$@`! -M`"T,``#0I0``4@```!(``0!$#```)*8``)H!```2``$`5PP``,"G``".`0`` -M$@`!`'4,``!0J0``'````!(``0"0#```;*D``!T````2``$`K0P``-BI```V -M````$@`!`,<,```0J@``-@```!(``0#B#```Z*H``'4````2``$`_PP``&"K -M``!_````$@`!`!T-``#@JP``*````!(``0`\#0``X*P``+8"```2``$`4@T` -M`(BQ``#X````$@`!`%D-``"`L@``^````!(``0!A#0``(+0``+P````2``$` -M;PT``-RT```X````$@`!``!R86ED+F,`4W1R:7!E1V5T0V]M;6%N9`!3=')I -M<&53<&QI=$-O;6UA;F0`27-61&5V3VYL:6YE`$1O0V]N=')O;$-M9`!*0D]$ -M1V5T0V]M;6%N9`!*0D]$4W!L:71#;VUM86YD`%]?:'!T7V%L;&]C`%]?:'!T -M7V9R964`9V%R8F%G95]A9&1R`&EN:71?:&5A<%]B;&]C:P!C8E]A;&QO8P!C -M8E]FF5R;P!C9E]I;FET`')E;6]V95]R86YG -M95]L;V-K`&%D9%]R86YG95]L;V-K`&QO8VM?&9E0!T87-K7V1O;F4`&]R -M7W1A&]R7W1A&]R;E]T87-K -M`&-H96-K7V1E<&5N9&5N8WD`9&ER96-T7W)E861?0!M=E-A=&%);FET061A<'1E<@!C:&5C:U]P&5C=71E3F]N541-04-O -M;6UA;F0`0F5E<$]N`$)E97!/9F8`00```%B``"&!``` -M`6,``+0$```"9P``S`0```)G``#D!````F<``/\$```"9P``-P4```%C``!4 -M!0```F8``&8%```":```O@4```)J``#E!0```6(``/(%```!8P``,`8```)K -M``"1!@```FT``-0&```";```7P<```)I``#4!P```FD``!\(```";```,@@` -M``%P``!2"````G(``*((```!<```O`@```)F``#0"````F0``-D(```";@`` -M\0@```)F``!`"0```G$``$X)```"0``!PT```%U```.#0```70``#@-```"=P``R`X```)V``#X#@```G<``#(/ -M```"9@``F`\```)F``!1$````G8``'@0```"=P``B1````%_``"/$````G<` -M`,@0```"=@``TA````)W``#C$````7\``.D0```"=P``+!$```)F``"T$@`` -M`G8``+X2```"=P``SQ(```%_``#5$@```G<````3```"9@``)!,```*#``"9 -M$P```G<``*43```!?P``K1,```)W``#+$P```GD``.T3```!@```]!,```%] -M```I%````F8``#P4```">0``7A0```%^``!E%````7T``)84```">0``N!0` -M``&"``"_%````8$``/P4```!`@``Z14```)Y``#T%0```F<```P6```!?``` -M$Q8```%[``"F%@```80``,@6```"=P``1!<```)M``"6%P```FH``*T7```! -M8@``M1<```%C``#M%P```FL```T9```"9P``U!H```)V``#Q&@```G<``&P; -M```">0``LQL```&(``"Z&P```8<``.0;```"=P``]!P```*,``!Q'@```F8` -M`,L>```"9@``/"0```)G``#")P```G<``+PH```!`@``1"D```%_``!**0`` -M`G<``%@I```!?P``<2D```$"``!Y*0```G<```XJ```!`@``%BH```)W``"\ -M*@```HX``/HK```"=@``OBP```)Y``#N+````0(``/4L```!`@``:"\```*/ -M``"0+P```I```"HP```"D```X3````*0```7,@```H\``&$R```"D```@30` -M``$N```%-0```2X``/5C```"=P``AF0```*-``",9````I(``))D```"DP`` -MF68```)W``#X9@```7\``/YF```"=P``[F@```$#``#9:0```0,``-YI```" -MC@``.VH```)V```&;0```F8``.1N```">0``#&\```$"```3;P```0(``#)O -M```!?P``.F\```)W```V````F8``,=Y```"9P``V7D` -M``)G``#N>0```F<```-Z```"9P``@7H```)E``"1>@```F4``+%Z```"9``` -M.GL```*;``##>P```F8``.I[```"9```GWP```)D``#J?0```I(``!=^```" -M9@``!G\```*B```/?P```J,``"!_```"I```IG\```*E``"R?P```J8``"*` -M```"J```/H````*I``!9@````J@``)2````"J@``I8````*J``#0@````JH` -M`/*#```"J0``!(0```*I```$```"J0``_(0```*L```NA0```JT```6'```"K0``&8<```*J -M```FAP```JT``#.'```"K0``2H<```*J``!7AP```JT``.R'```"J@``78@` -M``*M``!QB````JH``/6(```"J0``)XD```*J```PB0```JT``#>)```"J``` -M0HD```*J``!.B0```JT``%B)```"J```Q(D```&K``#4B@```JD``-Z*```" -MJ0``"(L```*J```BC````JX``$R,```"KP``3HT```*M``!5C0```J@``(*- -M```!JP``THT```*M``#FC0```JH``.V-```"K0``]XT```*H``"9C@```JH` -M`*N.```"J@``OHX```*J``#4C@```JH``...```"J@``]HX```*J```%CP`` -M`JH``!B/```"J@``+H\```*J```HD````JT``'F0```"J@``L)````*M``#5 -MD````JH``!J1```"J@``(Y$```*M```JD0```J@``#B1```"J@``09$```*M -M``"=D0```JH``*F1```"K0``P)$```*J``#4D0```JH``.61```"J@``]I$` -M``*J```*D@```JH``!N2```"J@``+)(```*J``!`D@```JH``%&2```"J@`` -M8I(```*J``!VD@```JH``(>2```"J@``FY(```*J``#2D@```JH``..2```" -MJ@``])(```*J```+DP```JH``!>3```"K0``+I,```*J``!@DP```JH``(23 -M```"K0``E9,```*J``"EDP```JT``+B3```"J@``QY,```*J``#9DP```JH` -M`.N3```"J@``^I,```*J```,E````JH``!N4```"J@``*I0```*J```\E``` -M`JH``$N4```"J@``6I0```*J``!LE````JH``#R5```"9P``;Y4```)G```? -ME@```JD``$^6```"J@``7Y8```*J``"EE@```JH``/Z6```"J@``#9<```*J -M```HEP```JD``#Z7```"J@``>9<```*J``"`EP```JT``!^8```"L```<)@` -M``*I``#KF````JP``/F8```"K```!YD```*L```8F0```JP``":9```"K``` -M.)D```*L``!)F0```JP``&B9```"J0``:```"K```+YH```*L``!$F@```JP``&R: -M```"J@``=)H```*S``````"K0``8YX```*H``!LG@```JT``-N>```"J@``Y)X```*M -M``#KG@```J@``/F>```"J@```I\```*M```SGP```JT``%N?```"J@``?9\` -M``*M``"$GP```J@``*>?```"J@``Q9\```*M``#/GP```J@``-J?```"IP`` -M#:````*I``"7H````JT``-R@```"J@``!J(```*M```IH@```JH``)VB```" -MK0``T*(```*J```KHP```JT``&:C```"J@``;Z,```*M``#%HP```JT``.^C -M```"J@``"*0```*M```DI````JT``$:D```"J@``P*0```*M``#AI````K0` -M`"6E```"K0``-Z4```*M``!)I0```JT``%NE```"K0``<*4```*M``""I0`` -M`JT``)2E```"K0``IJ4```*M```S```"K``` -MGK,```$$``"LLP```JP``,"S```"J0``Y;,```$$``#SLP```JP```"T```" -MJ```"[0```*I```^M````JT``%"T```"J@``6[0```*M``!]M````JX``(NT -M```"K0``I;0```*L``"QM````JH``+RT```"K0``S;0```*J```KM0```JT` -M`#VU```"J@``2+4```*M``!OM0```JX``'VU```"K0``BK4```*O``"?M0`` -M`00``*ZU```"K```O+4```*J``#'M0```JT``-BU```"J@``_K4```$$```- -MM@```JP``"JV```"KP``-K8```$$``!%M@```JP``&JV```!!```>;8```*L -M``"$M@```J\``,.V```"J```W[8```$$``#CM@```0,``/2V```!!```^+8` -M``$#``"C!@```FX``+@6```"A0``5A<```)N``"8)P```HT``%)F```"C0`` -M[&8```*-```_8<```*J``![E@```JT``/^7```"J@```*P```*P``#```.`````&$``!``````94``&`````!<```9`````%P``!H```` -M`7```&P````!<```<`````&*``!T`````7H``'@````!A@``@`````&6```` -M`````0(```0````!`@``"`````$"```,`````0(``!`````!`@``%`````$" -M```8`````0(``!P````!`@``(`````$"```D`````0(``"@````!`@``+``` -5``$"```P`````0(``#0````!`@`` -` -end diff --git a/sys/contrib/dev/hptmv/ioctl.c b/sys/contrib/dev/hptmv/ioctl.c deleted file mode 100644 index 2cfe97912c28..000000000000 --- a/sys/contrib/dev/hptmv/ioctl.c +++ /dev/null @@ -1,928 +0,0 @@ -/* - * Copyright (c) 2003-2004 HighPoint Technologies, Inc. - * All rights reserved. - * - * Redistribution and use in source and binary forms, with or without - * modification, are permitted provided that the following conditions - * are met: - * 1. Redistributions of source code must retain the above copyright - * notice, this list of conditions and the following disclaimer. - * 2. Redistributions in binary form must reproduce the above copyright - * notice, this list of conditions and the following disclaimer in the - * documentation and/or other materials provided with the distribution. - * - * THIS SOFTWARE IS PROVIDED BY THE AUTHOR AND CONTRIBUTORS ``AS IS'' AND - * ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE - * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE - * ARE DISCLAIMED. IN NO EVENT SHALL THE AUTHOR OR CONTRIBUTORS BE LIABLE - * FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL - * DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS - * OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) - * HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT - * LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY - * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF - * SUCH DAMAGE. - */ -/* - * ioctl.c ioctl interface implementation - */ -#include -#include -#include -#include - -#include -#include -#include -#include - -#pragma pack(1) - -typedef struct _HPT_REBUILD_PARAM -{ - DEVICEID idMirror; - DWORD Lba; - UCHAR nSector; -} HPT_REBUILD_PARAM, *PHPT_REBUILD_PARAM; - -#pragma pack() - -#define MAX_EVENTS 10 -static HPT_EVENT hpt_event_queue[MAX_EVENTS]; -static int event_queue_head=0, event_queue_tail=0; - -static int hpt_get_event(PHPT_EVENT pEvent); -static int hpt_set_array_state(DEVICEID idArray, DWORD state); -static intrmask_t lock_driver_idle(IAL_ADAPTER_T *pAdapter); -static void HPTLIBAPI thread_io_done(_VBUS_ARG PCommand pCmd); -static int HPTLIBAPI R1ControlSgl(_VBUS_ARG PCommand pCmd, - FPSCAT_GATH pSgTable, int logical); - -static void get_disk_location(PDevice pDev, int *controller, int *channel) -{ - IAL_ADAPTER_T *pAdapTemp; - int i, j; - - for (i=1, pAdapTemp = gIal_Adapter; pAdapTemp; pAdapTemp = pAdapTemp->next, i++) { - for (j=0; jVDevices[j].u.disk) { - *controller = i; - *channel = j; - return; - } - } -} - -static int event_queue_add(PHPT_EVENT pEvent) -{ - int p; - p = (event_queue_tail + 1) % MAX_EVENTS; - if (p==event_queue_head) - { - return -1; - } - hpt_event_queue[event_queue_tail] = *pEvent; - event_queue_tail = p; - return 0; -} - -static int event_queue_remove(PHPT_EVENT pEvent) -{ - if (event_queue_head != event_queue_tail) - { - *pEvent = hpt_event_queue[event_queue_head]; - event_queue_head++; - event_queue_head %= MAX_EVENTS; - return 0; - } - return -1; -} - -void HPTLIBAPI ioctl_ReportEvent(UCHAR event, PVOID param) -{ - HPT_EVENT e; - ZeroMemory(&e, sizeof(e)); - e.EventType = event; - switch(event) - { - case ET_INITIALIZE_ABORTED: - case ET_INITIALIZE_FAILED: - memcpy(e.Data, ((PVDevice)param)->u.array.ArrayName, MAX_ARRAY_NAME); - case ET_INITIALIZE_STARTED: - case ET_INITIALIZE_FINISHED: - - case ET_REBUILD_STARTED: - case ET_REBUILD_ABORTED: - case ET_REBUILD_FAILED: - case ET_REBUILD_FINISHED: - - case ET_VERIFY_STARTED: - case ET_VERIFY_ABORTED: - case ET_VERIFY_FAILED: - case ET_VERIFY_FINISHED: - case ET_VERIFY_DATA_ERROR: - - case ET_SPARE_TOOK_OVER: - case ET_DEVICE_REMOVED: - case ET_DEVICE_PLUGGED: - case ET_DEVICE_ERROR: - e.DeviceID = VDEV_TO_ID((PVDevice)param); - break; - - default: - break; - } - event_queue_add(&e); - if (event==ET_DEVICE_REMOVED) { - int controller, channel; - get_disk_location(&((PVDevice)param)->u.disk, &controller, &channel); - hpt_printk(("Device removed: controller %d channel %d\n", controller, channel)); - } -} - -static int hpt_delete_array(_VBUS_ARG DEVICEID id, DWORD options) -{ - PVDevice pArray = ID_TO_VDEV(id); - BOOLEAN del_block0 = (options & DAF_KEEP_DATA_IF_POSSIBLE)?0:1; - int i; - PVDevice pa; - - if((id== HPT_NULL_ID) || check_VDevice_valid(pArray)) - return -1; - - if(!mIsArray(pArray)) return -1; - - if (pArray->u.array.rf_rebuilding || pArray->u.array.rf_verifying || - pArray->u.array.rf_initializing) - return -1; - - for(i=0; iu.array.bArnMember; i++) { - pa = pArray->u.array.pMember[i]; - if (pa && mIsArray(pa)) { - if (pa->u.array.rf_rebuilding || pa->u.array.rf_verifying || - pa->u.array.rf_initializing) - return -1; - } - } - - if (pArray->pVBus!=_vbus_p) { HPT_ASSERT(0); return -1;} - fDeleteArray(_VBUS_P pArray, del_block0); - return 0; - -} - -/* just to prevent driver from sending more commands */ -static void HPTLIBAPI nothing(_VBUS_ARG void *notused){} - -static intrmask_t lock_driver_idle(IAL_ADAPTER_T *pAdapter) -{ - intrmask_t oldspl; - _VBUS_INST(&pAdapter->VBus) - oldspl = lock_driver(); - while (pAdapter->outstandingCommands) { - KdPrint(("outstandingCommands is %d, wait..\n", pAdapter->outstandingCommands)); - if (!mWaitingForIdle(_VBUS_P0)) CallWhenIdle(_VBUS_P nothing, 0); - unlock_driver(oldspl); - oldspl = lock_driver(); - } - CheckIdleCall(_VBUS_P0); - return oldspl; -} - -int Kernel_DeviceIoControl(_VBUS_ARG - DWORD dwIoControlCode, /* operation control code */ - PVOID lpInBuffer, /* input data buffer */ - DWORD nInBufferSize, /* size of input data buffer */ - PVOID lpOutBuffer, /* output data buffer */ - DWORD nOutBufferSize, /* size of output data buffer */ - PDWORD lpBytesReturned /* byte count */ - ) -{ - IAL_ADAPTER_T *pAdapter; - - switch(dwIoControlCode) { - case HPT_IOCTL_DELETE_ARRAY: - { - DEVICEID idArray; - int iSuccess; - int i; - PVDevice pArray; - PVBus _vbus_p; - struct cam_periph *periph = NULL; - - if (nInBufferSize!=sizeof(DEVICEID)+sizeof(DWORD)) return -1; - if (nOutBufferSize!=sizeof(int)) return -1; - idArray = *(DEVICEID *)lpInBuffer; - - pArray = ID_TO_VDEV(idArray); - - if((idArray == HPT_NULL_ID) || check_VDevice_valid(pArray)) - return -1; - - if(!mIsArray(pArray)) - return -1; - - _vbus_p=pArray->pVBus; - pAdapter = (IAL_ADAPTER_T *)_vbus_p->OsExt; - - for(i = 0; i < MAX_VDEVICE_PER_VBUS; i++) { - if(pArray == _vbus_p->pVDevice[i]) - { - periph = hpt_get_periph(pAdapter->mvSataAdapter.adapterId, i); - if (periph != NULL && periph->refcount == 1) - { - hpt_printk(("Can not delete a mounted device.\n")); - return -1; - } - } - /* the Mounted Disk isn't delete */ - } - - iSuccess = hpt_delete_array(_VBUS_P idArray, *(DWORD*)((DEVICEID *)lpInBuffer+1)); - - *(int*)lpOutBuffer = iSuccess; - - if(iSuccess != 0) - return -1; - break; - } - - case HPT_IOCTL_GET_EVENT: - { - PHPT_EVENT pInfo; - - if (nInBufferSize!=0) return -1; - if (nOutBufferSize!=sizeof(HPT_EVENT)) return -1; - - pInfo = (PHPT_EVENT)lpOutBuffer; - - if (hpt_get_event(pInfo)!=0) - return -1; - } - break; - - case HPT_IOCTL_SET_ARRAY_STATE: - { - DEVICEID idArray; - DWORD state; - - if (nInBufferSize!=sizeof(HPT_SET_STATE_PARAM)) return -1; - if (nOutBufferSize!=0) return -1; - - idArray = ((PHPT_SET_STATE_PARAM)lpInBuffer)->idArray; - state = ((PHPT_SET_STATE_PARAM)lpInBuffer)->state; - - if(hpt_set_array_state(idArray, state)!=0) - return -1; - } - break; - - case HPT_IOCTL_RESCAN_DEVICES: - { - if (nInBufferSize!=0) return -1; - if (nOutBufferSize!=0) return -1; - -#ifndef FOR_DEMO - /* stop buzzer if user perform rescan */ - for (pAdapter=gIal_Adapter; pAdapter; pAdapter=pAdapter->next) { - if (pAdapter->beeping) { - pAdapter->beeping = 0; - BeepOff(pAdapter->mvSataAdapter.adapterIoBaseAddress); - } - } -#endif - } - break; - - default: - { - PVDevice pVDev; -#ifdef SUPPORT_ARRAY - intrmask_t oldspl; -#endif - switch(dwIoControlCode) { - /* read-only ioctl functions can be called directly. */ - case HPT_IOCTL_GET_VERSION: - case HPT_IOCTL_GET_CONTROLLER_IDS: - case HPT_IOCTL_GET_CONTROLLER_COUNT: - case HPT_IOCTL_GET_CONTROLLER_INFO: - case HPT_IOCTL_GET_CHANNEL_INFO: - case HPT_IOCTL_GET_LOGICAL_DEVICES: - case HPT_IOCTL_GET_DEVICE_INFO: - case HPT_IOCTL_GET_EVENT: - case HPT_IOCTL_GET_DRIVER_CAPABILITIES: - if(hpt_default_ioctl(_VBUS_P dwIoControlCode, lpInBuffer, nInBufferSize, - lpOutBuffer, nOutBufferSize, lpBytesReturned) == -1) return -1; - break; - - default: - /* - * GUI always use /proc/scsi/hptmv/0, so the _vbus_p param will be - * wrong for second controller. - */ - switch(dwIoControlCode) { - case HPT_IOCTL_CREATE_ARRAY: - pVDev = ID_TO_VDEV(((PCREATE_ARRAY_PARAMS)lpInBuffer)->Members[0]); break; - case HPT_IOCTL_SET_ARRAY_INFO: - pVDev = ID_TO_VDEV(((PHPT_SET_ARRAY_INFO)lpInBuffer)->idArray); break; - case HPT_IOCTL_SET_DEVICE_INFO: - pVDev = ID_TO_VDEV(((PHPT_SET_DEVICE_INFO)lpInBuffer)->idDisk); break; - case HPT_IOCTL_SET_BOOT_MARK: - case HPT_IOCTL_ADD_SPARE_DISK: - case HPT_IOCTL_REMOVE_SPARE_DISK: - pVDev = ID_TO_VDEV(*(DEVICEID *)lpInBuffer); break; - case HPT_IOCTL_ADD_DISK_TO_ARRAY: - pVDev = ID_TO_VDEV(((PHPT_ADD_DISK_TO_ARRAY)lpInBuffer)->idArray); break; - default: - pVDev = 0; - } - - if (pVDev && !check_VDevice_valid(pVDev)){ - _vbus_p = pVDev->pVBus; - - pAdapter = (IAL_ADAPTER_T *)_vbus_p->OsExt; - /* - * create_array, and other functions can't be executed while channel is - * perform I/O commands. Wait until driver is idle. - */ - oldspl = lock_driver_idle(pAdapter); - if (hpt_default_ioctl(_VBUS_P dwIoControlCode, lpInBuffer, nInBufferSize, - lpOutBuffer, nOutBufferSize, lpBytesReturned) == -1) { - unlock_driver(oldspl); - return -1; - } - unlock_driver(oldspl); - } - else - return -1; - break; - } - -#ifdef SUPPORT_ARRAY - switch(dwIoControlCode) - { - case HPT_IOCTL_CREATE_ARRAY: - { - pAdapter=(IAL_ADAPTER_T *)(ID_TO_VDEV(*(DEVICEID *)lpOutBuffer))->pVBus->OsExt; - oldspl = lock_driver(); - if(((PCREATE_ARRAY_PARAMS)lpInBuffer)->CreateFlags & CAF_CREATE_AND_DUPLICATE) - { - (ID_TO_VDEV(*(DEVICEID *)lpOutBuffer))->u.array.rf_auto_rebuild = 0; - hpt_queue_dpc((HPT_DPC)hpt_rebuild_data_block, pAdapter, ID_TO_VDEV(*(DEVICEID *)lpOutBuffer), DUPLICATE); - } - else if(((PCREATE_ARRAY_PARAMS)lpInBuffer)->CreateFlags & CAF_CREATE_R5_ZERO_INIT) - { - hpt_queue_dpc((HPT_DPC)hpt_rebuild_data_block, pAdapter, ID_TO_VDEV(*(DEVICEID *)lpOutBuffer), INITIALIZE); - } - else if(((PCREATE_ARRAY_PARAMS)lpInBuffer)->CreateFlags & CAF_CREATE_R5_BUILD_PARITY) - { - hpt_queue_dpc((HPT_DPC)hpt_rebuild_data_block, pAdapter, ID_TO_VDEV(*(DEVICEID *)lpOutBuffer), REBUILD_PARITY); - } - unlock_driver(oldspl); - break; - } - - case HPT_IOCTL_ADD_DISK_TO_ARRAY: - { - PVDevice pArray = ID_TO_VDEV(((PHPT_ADD_DISK_TO_ARRAY)lpInBuffer)->idArray); - pAdapter=(IAL_ADAPTER_T *)pArray->pVBus->OsExt; - if(pArray->u.array.rf_rebuilding == HPT_NULL_ID) - { - DWORD timeout = 0; - oldspl = lock_driver(); - pArray->u.array.rf_auto_rebuild = 0; - pArray->u.array.rf_abort_rebuild = 0; - hpt_queue_dpc((HPT_DPC)hpt_rebuild_data_block, pAdapter, pArray, DUPLICATE); - unlock_driver(oldspl); - while (!pArray->u.array.rf_rebuilding) - { - tsleep((caddr_t)Kernel_DeviceIoControl, PPAUSE, "pause", 1); - if ( timeout >= hz*3) - break; - timeout ++; - } - } - break; - } - } -#endif - return 0; - } - } - - if (lpBytesReturned) - *lpBytesReturned = nOutBufferSize; - return 0; -} - -static int hpt_get_event(PHPT_EVENT pEvent) -{ - intrmask_t oldspl = lock_driver(); - int ret = event_queue_remove(pEvent); - unlock_driver(oldspl); - return ret; -} - -static int hpt_set_array_state(DEVICEID idArray, DWORD state) -{ - IAL_ADAPTER_T *pAdapter; - PVDevice pVDevice = ID_TO_VDEV(idArray); - int i; - DWORD timeout = 0; - intrmask_t oldspl; - - if(idArray == HPT_NULL_ID || check_VDevice_valid(pVDevice)) - return -1; - if(!mIsArray(pVDevice)) - return -1; - if(!pVDevice->vf_online || pVDevice->u.array.rf_broken) return -1; - - pAdapter=(IAL_ADAPTER_T *)pVDevice->pVBus->OsExt; - - switch(state) - { - case MIRROR_REBUILD_START: - { - if (pVDevice->u.array.rf_rebuilding || - pVDevice->u.array.rf_verifying || - pVDevice->u.array.rf_initializing) - return -1; - - oldspl = lock_driver(); - - pVDevice->u.array.rf_auto_rebuild = 0; - pVDevice->u.array.rf_abort_rebuild = 0; - - hpt_queue_dpc((HPT_DPC)hpt_rebuild_data_block, pAdapter, pVDevice, - (UCHAR)((pVDevice->u.array.CriticalMembers || pVDevice->VDeviceType == VD_RAID_1)? DUPLICATE : REBUILD_PARITY)); - - unlock_driver(oldspl); - - while (!pVDevice->u.array.rf_rebuilding) - { - tsleep((caddr_t)hpt_set_array_state, PPAUSE, "pause", 1); - if ( timeout >= hz*20) - break; - timeout ++; - } - } - - break; - - case MIRROR_REBUILD_ABORT: - { - for(i = 0; i < pVDevice->u.array.bArnMember; i++) { - if(pVDevice->u.array.pMember[i] != NULL && pVDevice->u.array.pMember[i]->VDeviceType == VD_RAID_1) - hpt_set_array_state(VDEV_TO_ID(pVDevice->u.array.pMember[i]), state); - } - - if(pVDevice->u.array.rf_rebuilding != 1) - return -1; - - oldspl = lock_driver(); - pVDevice->u.array.rf_abort_rebuild = 1; - unlock_driver(oldspl); - - while (pVDevice->u.array.rf_abort_rebuild) - { - tsleep((caddr_t)hpt_set_array_state, PPAUSE, "pause", 1); - if ( timeout >= hz*20) - break; - timeout ++; - } - } - break; - - case AS_VERIFY_START: - { - /*if(pVDevice->u.array.rf_verifying) - return -1;*/ - if (pVDevice->u.array.rf_rebuilding || - pVDevice->u.array.rf_verifying || - pVDevice->u.array.rf_initializing) - return -1; - - oldspl = lock_driver(); - pVDevice->u.array.RebuildSectors = 0; - hpt_queue_dpc((HPT_DPC)hpt_rebuild_data_block, pAdapter, pVDevice, VERIFY); - unlock_driver(oldspl); - - while (!pVDevice->u.array.rf_verifying) - { - tsleep((caddr_t)hpt_set_array_state, PPAUSE, "pause", 1); - if ( timeout >= hz*20) - break; - timeout ++; - } - } - break; - - case AS_VERIFY_ABORT: - { - if(pVDevice->u.array.rf_verifying != 1) - return -1; - - oldspl = lock_driver(); - pVDevice->u.array.rf_abort_rebuild = 1; - unlock_driver(oldspl); - - while (pVDevice->u.array.rf_abort_rebuild) - { - tsleep((caddr_t)hpt_set_array_state, PPAUSE, "pause", 1); - if ( timeout >= hz*80) - break; - timeout ++; - } - } - break; - - case AS_INITIALIZE_START: - { - if (pVDevice->u.array.rf_rebuilding || - pVDevice->u.array.rf_verifying || - pVDevice->u.array.rf_initializing) - return -1; - - oldspl = lock_driver(); - hpt_queue_dpc((HPT_DPC)hpt_rebuild_data_block, pAdapter, pVDevice, VERIFY); - unlock_driver(oldspl); - - while (!pVDevice->u.array.rf_initializing) - { - tsleep((caddr_t)hpt_set_array_state, PPAUSE, "pause", 1); - if ( timeout >= hz*80) - break; - timeout ++; - } - } - break; - - case AS_INITIALIZE_ABORT: - { - if(pVDevice->u.array.rf_initializing != 1) - return -1; - - oldspl = lock_driver(); - pVDevice->u.array.rf_abort_rebuild = 1; - unlock_driver(oldspl); - - while (pVDevice->u.array.rf_abort_rebuild) - { - tsleep((caddr_t)hpt_set_array_state, PPAUSE, "pause", 1); - if ( timeout >= hz*80) - break; - timeout ++; - } - } - break; - - default: - return -1; - } - - return 0; -} - -static int HPTLIBAPI R1ControlSgl(_VBUS_ARG PCommand pCmd, FPSCAT_GATH pSgTable, int logical) -{ - ULONG bufferSize = SECTOR_TO_BYTE(pCmd->uCmd.R1Control.nSectors); - if (pCmd->uCmd.R1Control.Command==CTRL_CMD_VERIFY) - bufferSize<<=1; - if (logical) { - pSgTable->dSgAddress = (ULONG_PTR)pCmd->uCmd.R1Control.Buffer; - pSgTable->wSgSize = (USHORT)bufferSize; - pSgTable->wSgFlag = SG_FLAG_EOT; - } - else { - /* build physical SG table for pCmd->uCmd.R1Control.Buffer */ - ADDRESS dataPointer, v, nextpage, currvaddr, nextvaddr, currphypage, nextphypage; - ULONG length; - int idx = 0; - - v = pCmd->uCmd.R1Control.Buffer; - dataPointer = (ADDRESS)fOsPhysicalAddress(v); - - if ((ULONG_PTR)dataPointer & 0x1) - return FALSE; - - #define ON64KBOUNDARY(x) (((ULONG_PTR)(x) & 0xFFFF) == 0) - #define NOTNEIGHBORPAGE(highvaddr, lowvaddr) ((ULONG_PTR)(highvaddr) - (ULONG_PTR)(lowvaddr) != PAGE_SIZE) - - do { - if (idx >= MAX_SG_DESCRIPTORS) return FALSE; - - pSgTable[idx].dSgAddress = fOsPhysicalAddress(v); - currvaddr = v; - currphypage = (ADDRESS)fOsPhysicalAddress((void*)trunc_page((ULONG_PTR)currvaddr)); - - - do { - nextpage = (ADDRESS)trunc_page(((ULONG_PTR)currvaddr + PAGE_SIZE)); - nextvaddr = (ADDRESS)MIN(((ULONG_PTR)v + bufferSize), (ULONG_PTR)(nextpage)); - - if (nextvaddr == (ADDRESS)((ULONG_PTR)v + bufferSize)) break; - nextphypage = (ADDRESS)fOsPhysicalAddress(nextpage); - - if (NOTNEIGHBORPAGE(nextphypage, currphypage) || ON64KBOUNDARY(nextphypage)) { - nextvaddr = nextpage; - break; - } - - currvaddr = nextvaddr; - currphypage = nextphypage; - }while (1); - - length = (ULONG_PTR)nextvaddr - (ULONG_PTR)v; - v = nextvaddr; - bufferSize -= length; - - pSgTable[idx].wSgSize = (USHORT)length; - pSgTable[idx].wSgFlag = (bufferSize)? 0 : SG_FLAG_EOT; - idx++; - - }while (bufferSize); - } - return 1; -} - -static int End_Job=0; -static void HPTLIBAPI thread_io_done(_VBUS_ARG PCommand pCmd) -{ - End_Job = 1; - wakeup((caddr_t)pCmd); -} - -void hpt_rebuild_data_block(IAL_ADAPTER_T *pAdapter, PVDevice pArray, UCHAR flags) -{ - DWORD timeout = 0; - ULONG capacity = pArray->VDeviceCapacity / (pArray->u.array.bArnMember-1); - PCommand pCmd; - UINT result; - int needsync=0, retry=0, needdelete=0; - void *buffer = 0; - intrmask_t oldspl; - - _VBUS_INST(&pAdapter->VBus) - - if (pArray->u.array.rf_broken==1 || - pArray->u.array.RebuildSectors>=capacity) - return; - - oldspl = lock_driver(); - - switch(flags) - { - case DUPLICATE: - case REBUILD_PARITY: - if(pArray->u.array.rf_rebuilding == 0) - { - pArray->u.array.rf_rebuilding = 1; - hpt_printk(("Rebuilding started.\n")); - ioctl_ReportEvent(ET_REBUILD_STARTED, pArray); - } - break; - - case INITIALIZE: - if(pArray->u.array.rf_initializing == 0) - { - pArray->u.array.rf_initializing = 1; - hpt_printk(("Initializing started.\n")); - ioctl_ReportEvent(ET_INITIALIZE_STARTED, pArray); - } - break; - - case VERIFY: - if(pArray->u.array.rf_verifying == 0) - { - pArray->u.array.rf_verifying = 1; - hpt_printk(("Verifying started.\n")); - ioctl_ReportEvent(ET_VERIFY_STARTED, pArray); - } - break; - } - -retry_cmd: - pCmd = AllocateCommand(_VBUS_P0); - HPT_ASSERT(pCmd); - pCmd->cf_control = 1; - End_Job = 0; - - if (pArray->VDeviceType==VD_RAID_1) - { - #define MAX_REBUILD_SECTORS 0x40 - - /* take care for discontinuous buffer in R1ControlSgl */ - buffer = malloc(SECTOR_TO_BYTE(MAX_REBUILD_SECTORS), M_DEVBUF, M_NOWAIT); - if(!buffer) { - FreeCommand(_VBUS_P pCmd); - hpt_printk(("can't allocate rebuild buffer\n")); - goto fail; - } - switch(flags) - { - case DUPLICATE: - pCmd->uCmd.R1Control.Command = CTRL_CMD_REBUILD; - pCmd->uCmd.R1Control.nSectors = MAX_REBUILD_SECTORS; - break; - - case VERIFY: - pCmd->uCmd.R1Control.Command = CTRL_CMD_VERIFY; - pCmd->uCmd.R1Control.nSectors = MAX_REBUILD_SECTORS/2; - break; - - case INITIALIZE: - pCmd->uCmd.R1Control.Command = CTRL_CMD_REBUILD; - pCmd->uCmd.R1Control.nSectors = MAX_REBUILD_SECTORS; - break; - } - - pCmd->uCmd.R1Control.Lba = pArray->u.array.RebuildSectors; - - if (capacity - pArray->u.array.RebuildSectors < pCmd->uCmd.R1Control.nSectors) - pCmd->uCmd.R1Control.nSectors = capacity - pArray->u.array.RebuildSectors; - - pCmd->uCmd.R1Control.Buffer = buffer; - pCmd->pfnBuildSgl = R1ControlSgl; - } - else if (pArray->VDeviceType==VD_RAID_5) - { - switch(flags) - { - case DUPLICATE: - case REBUILD_PARITY: - pCmd->uCmd.R5Control.Command = CTRL_CMD_REBUILD; break; - case VERIFY: - pCmd->uCmd.R5Control.Command = CTRL_CMD_VERIFY; break; - case INITIALIZE: - pCmd->uCmd.R5Control.Command = CTRL_CMD_INIT; break; - } - pCmd->uCmd.R5Control.StripeLine=pArray->u.array.RebuildSectors>>pArray->u.array.bArBlockSizeShift; - } - else - HPT_ASSERT(0); - - pCmd->pVDevice = pArray; - pCmd->pfnCompletion = thread_io_done; - pArray->pfnSendCommand(_VBUS_P pCmd); - CheckPendingCall(_VBUS_P0); - - if (!End_Job) { - unlock_driver(oldspl); - while (!End_Job) { - tsleep((caddr_t)pCmd, PPAUSE, "pause", hz); - if (timeout++>60) break; - } - oldspl = lock_driver(); - if (!End_Job) { - hpt_printk(("timeout, reset\n")); - fResetVBus(_VBUS_P0); - } - } - - result = pCmd->Result; - FreeCommand(_VBUS_P pCmd); - if (buffer) { - free(buffer, M_DEVBUF); - /* beware of goto retry_cmd below */ - buffer = NULL; - } - KdPrintI(("cmd finished %d", result)); - - switch(result) - { - case RETURN_SUCCESS: - if (!pArray->u.array.rf_abort_rebuild) - { - if(pArray->u.array.RebuildSectors < capacity) - { - hpt_queue_dpc((HPT_DPC)hpt_rebuild_data_block, pAdapter, pArray, flags); - } - else - { - switch (flags) - { - case DUPLICATE: - case REBUILD_PARITY: - needsync = 1; - pArray->u.array.rf_rebuilding = 0; - pArray->u.array.rf_need_rebuild = 0; - pArray->u.array.CriticalMembers = 0; - pArray->u.array.RebuildSectors = MAX_LBA_T; - pArray->u.array.rf_duplicate_and_create = 0; - hpt_printk(("Rebuilding finished.\n")); - ioctl_ReportEvent(ET_REBUILD_FINISHED, pArray); - break; - case INITIALIZE: - needsync = 1; - pArray->u.array.rf_initializing = 0; - pArray->u.array.rf_need_rebuild = 0; - pArray->u.array.RebuildSectors = MAX_LBA_T; - hpt_printk(("Initializing finished.\n")); - ioctl_ReportEvent(ET_INITIALIZE_FINISHED, pArray); - break; - case VERIFY: - pArray->u.array.rf_verifying = 0; - hpt_printk(("Verifying finished.\n")); - ioctl_ReportEvent(ET_VERIFY_FINISHED, pArray); - break; - } - } - } - else - { - pArray->u.array.rf_abort_rebuild = 0; - if (pArray->u.array.rf_rebuilding) - { - hpt_printk(("Abort rebuilding.\n")); - pArray->u.array.rf_rebuilding = 0; - pArray->u.array.rf_duplicate_and_create = 0; - ioctl_ReportEvent(ET_REBUILD_ABORTED, pArray); - } - else if (pArray->u.array.rf_verifying) - { - hpt_printk(("Abort verifying.\n")); - pArray->u.array.rf_verifying = 0; - ioctl_ReportEvent(ET_VERIFY_ABORTED, pArray); - } - else if (pArray->u.array.rf_initializing) - { - hpt_printk(("Abort initializing.\n")); - pArray->u.array.rf_initializing = 0; - ioctl_ReportEvent(ET_INITIALIZE_ABORTED, pArray); - } - needdelete=1; - } - break; - - case RETURN_DATA_ERROR: - if (flags==VERIFY) - { - needsync = 1; - pArray->u.array.rf_verifying = 0; - pArray->u.array.rf_need_rebuild = 1; - hpt_printk(("Verifying failed: found inconsistency\n")); - ioctl_ReportEvent(ET_VERIFY_DATA_ERROR, pArray); - ioctl_ReportEvent(ET_VERIFY_FAILED, pArray); - - if (!pArray->vf_online || pArray->u.array.rf_broken) break; - - pArray->u.array.rf_auto_rebuild = 0; - pArray->u.array.rf_abort_rebuild = 0; - hpt_queue_dpc((HPT_DPC)hpt_rebuild_data_block, pAdapter, pArray, - (pArray->VDeviceType == VD_RAID_1) ? DUPLICATE : REBUILD_PARITY); - } - break; - - default: - hpt_printk(("command failed with error %d\n", result)); - if (++retry<3) - { - hpt_printk(("retry (%d)\n", retry)); - goto retry_cmd; - } -fail: - pArray->u.array.rf_abort_rebuild = 0; - switch (flags) - { - case DUPLICATE: - case REBUILD_PARITY: - needsync = 1; - pArray->u.array.rf_rebuilding = 0; - pArray->u.array.rf_duplicate_and_create = 0; - hpt_printk(((flags==DUPLICATE)? "Duplicating failed.\n":"Rebuilding failed.\n")); - ioctl_ReportEvent(ET_REBUILD_FAILED, pArray); - break; - - case INITIALIZE: - needsync = 1; - pArray->u.array.rf_initializing = 0; - hpt_printk(("Initializing failed.\n")); - ioctl_ReportEvent(ET_INITIALIZE_FAILED, pArray); - break; - - case VERIFY: - needsync = 1; - pArray->u.array.rf_verifying = 0; - hpt_printk(("Verifying failed.\n")); - ioctl_ReportEvent(ET_VERIFY_FAILED, pArray); - break; - } - needdelete=1; - } - - while (pAdapter->outstandingCommands) - { - KdPrintI(("currcmds is %d, wait..\n", pAdapter->outstandingCommands)); - /* put this to have driver stop processing system commands quickly */ - if (!mWaitingForIdle(_VBUS_P0)) CallWhenIdle(_VBUS_P nothing, 0); - unlock_driver(oldspl); - oldspl = lock_driver(); - } - - if (needsync) SyncArrayInfo(pArray); - if(needdelete && (pArray->u.array.rf_duplicate_must_done || (flags == INITIALIZE))) - fDeleteArray(_VBUS_P pArray, TRUE); - - Check_Idle_Call(pAdapter); - unlock_driver(oldspl); -} diff --git a/sys/contrib/dev/hptmv/mvSata.h b/sys/contrib/dev/hptmv/mvSata.h deleted file mode 100644 index 486f64ffa8f7..000000000000 --- a/sys/contrib/dev/hptmv/mvSata.h +++ /dev/null @@ -1,429 +0,0 @@ -/* - * Copyright (c) 2003-2004 MARVELL SEMICONDUCTOR ISRAEL, LTD. - * All rights reserved. - * - * Redistribution and use in source and binary forms, with or without - * modification, are permitted provided that the following conditions - * are met: - * 1. Redistributions of source code must retain the above copyright - * notice, this list of conditions and the following disclaimer. - * 2. Redistributions in binary form must reproduce the above copyright - * notice, this list of conditions and the following disclaimer in the - * documentation and/or other materials provided with the distribution. - * - * THIS SOFTWARE IS PROVIDED BY THE AUTHOR AND CONTRIBUTORS ``AS IS'' AND - * ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE - * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE - * ARE DISCLAIMED. IN NO EVENT SHALL THE AUTHOR OR CONTRIBUTORS BE LIABLE - * FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL - * DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS - * OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) - * HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT - * LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY - * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF - * SUCH DAMAGE. - */ -#ifndef __INCmvSatah -#define __INCmvSatah - -#ifndef SUPPORT_MV_SATA_GEN_1 -#define SUPPORT_MV_SATA_GEN_1 1 -#endif - -#ifndef SUPPORT_MV_SATA_GEN_2 -#define SUPPORT_MV_SATA_GEN_2 0 -#endif - -#if SUPPORT_MV_SATA_GEN_1==1 && SUPPORT_MV_SATA_GEN_2==1 -#define MV_SATA_GEN_1(x) ((x)->sataAdapterGeneration==1) -#define MV_SATA_GEN_2(x) ((x)->sataAdapterGeneration==2) -#elif SUPPORT_MV_SATA_GEN_1==1 -#define MV_SATA_GEN_1(x) 1 -#define MV_SATA_GEN_2(x) 0 -#elif SUPPORT_MV_SATA_GEN_2==1 -#define MV_SATA_GEN_1(x) 0 -#define MV_SATA_GEN_2(x) 1 -#else -#error "Which IC do you support?" -#endif - -/* Definitions */ -/* MV88SX50XX specific defines */ -#define MV_SATA_VENDOR_ID 0x11AB -#define MV_SATA_DEVICE_ID_5080 0x5080 -#define MV_SATA_DEVICE_ID_5081 0x5081 -#define MV_SATA_DEVICE_ID_6080 0x6080 -#define MV_SATA_DEVICE_ID_6081 0x6081 -#define MV_SATA_CHANNELS_NUM 8 -#define MV_SATA_UNITS_NUM 2 -#define MV_SATA_PCI_BAR0_SPACE_SIZE (1<<18) /* 256 Kb*/ - -#define CHANNEL_QUEUE_LENGTH 32 -#define CHANNEL_QUEUE_MASK 0x1F - -#define MV_EDMA_QUEUE_LENGTH 32 /* Up to 32 outstanding */ - /* commands per SATA channel*/ -#define MV_EDMA_QUEUE_MASK 0x1F -#define MV_EDMA_REQUEST_QUEUE_SIZE 1024 /* 32*32 = 1KBytes */ -#define MV_EDMA_RESPONSE_QUEUE_SIZE 256 /* 32*8 = 256 Bytes */ - -#define MV_EDMA_REQUEST_ENTRY_SIZE 32 -#define MV_EDMA_RESPONSE_ENTRY_SIZE 8 - -#define MV_EDMA_PRD_ENTRY_SIZE 16 /* 16Bytes*/ -#define MV_EDMA_PRD_NO_SNOOP_FLAG 0x00000001 /* MV_BIT0 */ -#define MV_EDMA_PRD_EOT_FLAG 0x00008000 /* MV_BIT15 */ - -#define MV_ATA_IDENTIFY_DEV_DATA_LENGTH 256 /* number of words(2 byte)*/ -#define MV_ATA_MODEL_NUMBER_LEN 40 -#define ATA_SECTOR_SIZE 512 -/* Log messages level defines */ -#define MV_DEBUG 0x1 -#define MV_DEBUG_INIT 0x2 -#define MV_DEBUG_INTERRUPTS 0x4 -#define MV_DEBUG_SATA_LINK 0x8 -#define MV_DEBUG_UDMA_COMMAND 0x10 -#define MV_DEBUG_NON_UDMA_COMMAND 0x20 -#define MV_DEBUG_ERROR 0x40 - - -/* Typedefs */ -typedef enum mvUdmaType -{ - MV_UDMA_TYPE_READ, MV_UDMA_TYPE_WRITE -} MV_UDMA_TYPE; - -typedef enum mvFlushType -{ - MV_FLUSH_TYPE_CALLBACK, MV_FLUSH_TYPE_NONE -} MV_FLUSH_TYPE; - -typedef enum mvCompletionType -{ - MV_COMPLETION_TYPE_NORMAL, MV_COMPLETION_TYPE_ERROR, - MV_COMPLETION_TYPE_ABORT -} MV_COMPLETION_TYPE; - -typedef enum mvEventType -{ - MV_EVENT_TYPE_ADAPTER_ERROR, MV_EVENT_TYPE_SATA_CABLE -} MV_EVENT_TYPE; - -typedef enum mvEdmaMode -{ - MV_EDMA_MODE_QUEUED, - MV_EDMA_MODE_NOT_QUEUED, - MV_EDMA_MODE_NATIVE_QUEUING -} MV_EDMA_MODE; - -typedef enum mvEdmaQueueResult -{ - MV_EDMA_QUEUE_RESULT_OK = 0, - MV_EDMA_QUEUE_RESULT_EDMA_DISABLED, - MV_EDMA_QUEUE_RESULT_FULL, - MV_EDMA_QUEUE_RESULT_BAD_LBA_ADDRESS, - MV_EDMA_QUEUE_RESULT_BAD_PARAMS -} MV_EDMA_QUEUE_RESULT; - -typedef enum mvQueueCommandResult -{ - MV_QUEUE_COMMAND_RESULT_OK = 0, - MV_QUEUE_COMMAND_RESULT_QUEUED_MODE_DISABLED, - MV_QUEUE_COMMAND_RESULT_FULL, - MV_QUEUE_COMMAND_RESULT_BAD_LBA_ADDRESS, - MV_QUEUE_COMMAND_RESULT_BAD_PARAMS -} MV_QUEUE_COMMAND_RESULT; - -typedef enum mvNonUdmaProtocol -{ - MV_NON_UDMA_PROTOCOL_NON_DATA, - MV_NON_UDMA_PROTOCOL_PIO_DATA_IN, - MV_NON_UDMA_PROTOCOL_PIO_DATA_OUT -} MV_NON_UDMA_PROTOCOL; - - -struct mvDmaRequestQueueEntry; -struct mvDmaResponseQueueEntry; -struct mvDmaCommandEntry; - -struct mvSataAdapter; -struct mvStorageDevRegisters; - -typedef MV_BOOLEAN (* HPTLIBAPI mvSataCommandCompletionCallBack_t)(struct mvSataAdapter *, - MV_U8, - MV_COMPLETION_TYPE, - MV_VOID_PTR, MV_U16, - MV_U32, - struct mvStorageDevRegisters FAR*); - -typedef enum mvQueuedCommandType -{ - MV_QUEUED_COMMAND_TYPE_UDMA, - MV_QUEUED_COMMAND_TYPE_NONE_UDMA -} MV_QUEUED_COMMAND_TYPE; - -typedef struct mvUdmaCommandParams -{ - MV_UDMA_TYPE readWrite; - MV_BOOLEAN isEXT; - MV_U32 lowLBAAddress; - MV_U16 highLBAAddress; - MV_U16 numOfSectors; - MV_U32 prdLowAddr; - MV_U32 prdHighAddr; - mvSataCommandCompletionCallBack_t callBack; - MV_VOID_PTR commandId; -} MV_UDMA_COMMAND_PARAMS; - -typedef struct mvNoneUdmaCommandParams -{ - MV_NON_UDMA_PROTOCOL protocolType; - MV_BOOLEAN isEXT; - MV_U16_PTR bufPtr; - MV_U32 count; - MV_U16 features; - MV_U16 sectorCount; - MV_U16 lbaLow; - MV_U16 lbaMid; - MV_U16 lbaHigh; - MV_U8 device; - MV_U8 command; - mvSataCommandCompletionCallBack_t callBack; - MV_VOID_PTR commandId; -} MV_NONE_UDMA_COMMAND_PARAMS; - -typedef struct mvQueueCommandInfo -{ - MV_QUEUED_COMMAND_TYPE type; - union - { - MV_UDMA_COMMAND_PARAMS udmaCommand; - MV_NONE_UDMA_COMMAND_PARAMS NoneUdmaCommand; - } commandParams; -} MV_QUEUE_COMMAND_INFO; - -/* The following structure is for the Core Driver internal usage */ -typedef struct mvQueuedCommandEntry -{ - MV_BOOLEAN isFreeEntry; - MV_U8 commandTag; - struct mvQueuedCommandEntry *next; - struct mvQueuedCommandEntry *prev; - MV_QUEUE_COMMAND_INFO commandInfo; -} MV_QUEUED_COMMAND_ENTRY; - -/* The following structures are part of the Core Driver API */ -typedef struct mvSataChannel -{ - /* Fields set by Intermediate Application Layer */ - MV_U8 channelNumber; - MV_BOOLEAN waitingForInterrupt; - MV_BOOLEAN lba48Address; - MV_BOOLEAN maxReadTransfer; - struct mvDmaRequestQueueEntry FAR *requestQueue; - struct mvDmaResponseQueueEntry FAR *responseQueue; - MV_U32 requestQueuePciHiAddress; - MV_U32 requestQueuePciLowAddress; - MV_U32 responseQueuePciHiAddress; - MV_U32 responseQueuePciLowAddress; - /* Fields set by CORE driver */ - struct mvSataAdapter *mvSataAdapter; - MV_OS_SEMAPHORE semaphore; - MV_U32 eDmaRegsOffset; - MV_U16 identifyDevice[MV_ATA_IDENTIFY_DEV_DATA_LENGTH]; - MV_BOOLEAN EdmaActive; - MV_EDMA_MODE queuedDMA; - MV_U8 outstandingCommands; - MV_BOOLEAN workAroundDone; - struct mvQueuedCommandEntry commandsQueue[CHANNEL_QUEUE_LENGTH]; - struct mvQueuedCommandEntry *commandsQueueHead; - struct mvQueuedCommandEntry *commandsQueueTail; - MV_BOOLEAN queueCommandsEnabled; - MV_U8 noneUdmaOutstandingCommands; - MV_U8 EdmaQueuedCommands; - MV_U32 freeIDsStack[MV_EDMA_QUEUE_LENGTH]; - MV_U32 freeIDsNum; - MV_U32 reqInPtr; - MV_U32 rspOutPtr; -} MV_SATA_CHANNEL; - -typedef struct mvSataAdapter -{ - /* Fields set by Intermediate Application Layer */ - MV_U32 adapterId; - MV_U8 pcbVersion; - MV_U8 pciConfigRevisionId; - MV_U16 pciConfigDeviceId; - MV_VOID_PTR IALData; - MV_BUS_ADDR_T adapterIoBaseAddress; - MV_U32 intCoalThre[MV_SATA_UNITS_NUM]; - MV_U32 intTimeThre[MV_SATA_UNITS_NUM]; - MV_BOOLEAN (* HPTLIBAPI mvSataEventNotify)(struct mvSataAdapter *, - MV_EVENT_TYPE, - MV_U32, MV_U32); - MV_SATA_CHANNEL *sataChannel[MV_SATA_CHANNELS_NUM]; - MV_U32 pciCommand; - MV_U32 pciSerrMask; - MV_U32 pciInterruptMask; - - /* Fields set by CORE driver */ - MV_OS_SEMAPHORE semaphore; - MV_U32 mainMask; - MV_OS_SEMAPHORE interruptsMaskSem; - MV_BOOLEAN implementA0Workarounds; - MV_BOOLEAN implement50XXB0Workarounds; - MV_BOOLEAN implement50XXB1Workarounds; - MV_BOOLEAN implement50XXB2Workarounds; - MV_BOOLEAN implement60X1A0Workarounds; - MV_BOOLEAN implement60X1A1Workarounds; - MV_BOOLEAN implement60X1B0Workarounds; - MV_U8 sataAdapterGeneration; - MV_U8 failLEDMask; - MV_U8 signalAmps[MV_SATA_CHANNELS_NUM]; - MV_U8 pre[MV_SATA_CHANNELS_NUM]; - MV_BOOLEAN staggaredSpinup[MV_SATA_CHANNELS_NUM]; /* For 60x1 only */ -} MV_SATA_ADAPTER; - -typedef struct mvSataAdapterStatus -{ - /* Fields set by CORE driver */ - MV_BOOLEAN channelConnected[MV_SATA_CHANNELS_NUM]; - MV_U32 pciDLLStatusAndControlRegister; - MV_U32 pciCommandRegister; - MV_U32 pciModeRegister; - MV_U32 pciSERRMaskRegister; - MV_U32 intCoalThre[MV_SATA_UNITS_NUM]; - MV_U32 intTimeThre[MV_SATA_UNITS_NUM]; - MV_U32 R00StatusBridgePortRegister[MV_SATA_CHANNELS_NUM]; -}MV_SATA_ADAPTER_STATUS; - - -typedef struct mvSataChannelStatus -{ - /* Fields set by CORE driver */ - MV_BOOLEAN isConnected; - MV_U8 modelNumber[MV_ATA_MODEL_NUMBER_LEN]; - MV_BOOLEAN DMAEnabled; - MV_EDMA_MODE queuedDMA; - MV_U8 outstandingCommands; - MV_U32 EdmaConfigurationRegister; - MV_U32 EdmaRequestQueueBaseAddressHighRegister; - MV_U32 EdmaRequestQueueInPointerRegister; - MV_U32 EdmaRequestQueueOutPointerRegister; - MV_U32 EdmaResponseQueueBaseAddressHighRegister; - MV_U32 EdmaResponseQueueInPointerRegister; - MV_U32 EdmaResponseQueueOutPointerRegister; - MV_U32 EdmaCommandRegister; - MV_U32 PHYModeRegister; -}MV_SATA_CHANNEL_STATUS; - -/* this structure used by the IAL defines the PRD entries used by the EDMA HW */ -typedef struct mvSataEdmaPRDEntry -{ - volatile MV_U32 lowBaseAddr; - volatile MV_U16 byteCount; - volatile MV_U16 flags; - volatile MV_U32 highBaseAddr; - volatile MV_U32 reserved; -}MV_SATA_EDMA_PRD_ENTRY; - -/* API Functions */ - -/* CORE driver Adapter Management */ -MV_BOOLEAN HPTLIBAPI mvSataInitAdapter(MV_SATA_ADAPTER *pAdapter); - -MV_BOOLEAN HPTLIBAPI mvSataShutdownAdapter(MV_SATA_ADAPTER *pAdapter); - -MV_BOOLEAN HPTLIBAPI mvSataGetAdapterStatus(MV_SATA_ADAPTER *pAdapter, - MV_SATA_ADAPTER_STATUS *pAdapterStatus); - -MV_U32 HPTLIBAPI mvSataReadReg(MV_SATA_ADAPTER *pAdapter, MV_U32 regOffset); - -MV_VOID HPTLIBAPI mvSataWriteReg(MV_SATA_ADAPTER *pAdapter, MV_U32 regOffset, - MV_U32 regValue); - -MV_VOID HPTLIBAPI mvEnableAutoFlush(MV_VOID); -MV_VOID HPTLIBAPI mvDisableAutoFlush(MV_VOID); - - -/* CORE driver SATA Channel Management */ -MV_BOOLEAN HPTLIBAPI mvSataConfigureChannel(MV_SATA_ADAPTER *pAdapter, - MV_U8 channelIndex); - -MV_BOOLEAN HPTLIBAPI mvSataRemoveChannel(MV_SATA_ADAPTER *pAdapter, MV_U8 channelIndex); - -MV_BOOLEAN HPTLIBAPI mvSataIsStorageDeviceConnected(MV_SATA_ADAPTER *pAdapter, - MV_U8 channelIndex); - -MV_BOOLEAN HPTLIBAPI mvSataChannelHardReset(MV_SATA_ADAPTER *pAdapter, - MV_U8 channelIndex); - -MV_BOOLEAN HPTLIBAPI mvSataConfigEdmaMode(MV_SATA_ADAPTER *pAdapter, MV_U8 channelIndex, - MV_EDMA_MODE eDmaMode, MV_U8 maxQueueDepth); - -MV_BOOLEAN HPTLIBAPI mvSataEnableChannelDma(MV_SATA_ADAPTER *pAdapter, - MV_U8 channelIndex); - -MV_BOOLEAN HPTLIBAPI mvSataDisableChannelDma(MV_SATA_ADAPTER *pAdapter, - MV_U8 channelIndex); - -MV_BOOLEAN HPTLIBAPI mvSataFlushDmaQueue(MV_SATA_ADAPTER *pAdapter, MV_U8 channelIndex, - MV_FLUSH_TYPE flushType); - -MV_U8 HPTLIBAPI mvSataNumOfDmaCommands(MV_SATA_ADAPTER *pAdapter, MV_U8 channelIndex); - -MV_BOOLEAN HPTLIBAPI mvSataSetIntCoalParams (MV_SATA_ADAPTER *pAdapter, MV_U8 sataUnit, - MV_U32 intCoalThre, MV_U32 intTimeThre); - -MV_BOOLEAN HPTLIBAPI mvSataSetChannelPhyParams(MV_SATA_ADAPTER *pAdapter, - MV_U8 channelIndex, - MV_U8 signalAmps, MV_U8 pre); - -MV_BOOLEAN HPTLIBAPI mvSataChannelPhyShutdown(MV_SATA_ADAPTER *pAdapter, - MV_U8 channelIndex); - -MV_BOOLEAN HPTLIBAPI mvSataChannelPhyPowerOn(MV_SATA_ADAPTER *pAdapter, - MV_U8 channelIndex); - -MV_BOOLEAN HPTLIBAPI mvSataChannelSetEdmaLoopBackMode(MV_SATA_ADAPTER *pAdapter, - MV_U8 channelIndex, - MV_BOOLEAN loopBackOn); - -MV_BOOLEAN HPTLIBAPI mvSataGetChannelStatus(MV_SATA_ADAPTER *pAdapter, MV_U8 channelIndex, - MV_SATA_CHANNEL_STATUS *pChannelStatus); - -/* Execute UDMA ATA commands */ -MV_EDMA_QUEUE_RESULT HPTLIBAPI mvSataQueueUDmaCommand(MV_SATA_ADAPTER *pAdapter, - MV_U8 channelIndex, - MV_UDMA_TYPE readWrite, - MV_U32 lowLBAAddr, - MV_U16 highLBAAddr, - MV_U16 sectorCount, - MV_U32 prdLowAddr, - MV_U32 prdHighAddr, - mvSataCommandCompletionCallBack_t callBack, - MV_VOID_PTR commandId); - -MV_QUEUE_COMMAND_RESULT HPTLIBAPI mvSataQueueCommand(MV_SATA_ADAPTER *pAdapter, - MV_U8 channelIndex, - MV_QUEUE_COMMAND_INFO FAR *pCommandParams); - -/* Interrupt Service Routine */ -MV_BOOLEAN HPTLIBAPI mvSataInterruptServiceRoutine(MV_SATA_ADAPTER *pAdapter); - -MV_BOOLEAN HPTLIBAPI mvSataMaskAdapterInterrupt(MV_SATA_ADAPTER *pAdapter); - -MV_BOOLEAN HPTLIBAPI mvSataUnmaskAdapterInterrupt(MV_SATA_ADAPTER *pAdapter); - -/* Command Completion and Event Notification (user implemented) */ -MV_BOOLEAN HPTLIBAPI mvSataEventNotify(MV_SATA_ADAPTER *, MV_EVENT_TYPE , - MV_U32, MV_U32); - -/* - * Staggered spin-ip support and SATA interface speed control - * (relevant for 60x1 adapters) - */ -MV_BOOLEAN HPTLIBAPI mvSataEnableStaggeredSpinUpAll (MV_SATA_ADAPTER *pAdapter); -MV_BOOLEAN HPTLIBAPI mvSataDisableStaggeredSpinUpAll (MV_SATA_ADAPTER *pAdapter); - -#endif diff --git a/sys/contrib/dev/hptmv/mvStorageDev.h b/sys/contrib/dev/hptmv/mvStorageDev.h deleted file mode 100644 index a5f3eb945a89..000000000000 --- a/sys/contrib/dev/hptmv/mvStorageDev.h +++ /dev/null @@ -1,210 +0,0 @@ -/* - * Copyright (c) 2003-2004 MARVELL SEMICONDUCTOR ISRAEL, LTD. - * All rights reserved. - * - * Redistribution and use in source and binary forms, with or without - * modification, are permitted provided that the following conditions - * are met: - * 1. Redistributions of source code must retain the above copyright - * notice, this list of conditions and the following disclaimer. - * 2. Redistributions in binary form must reproduce the above copyright - * notice, this list of conditions and the following disclaimer in the - * documentation and/or other materials provided with the distribution. - * - * THIS SOFTWARE IS PROVIDED BY THE AUTHOR AND CONTRIBUTORS ``AS IS'' AND - * ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE - * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE - * ARE DISCLAIMED. IN NO EVENT SHALL THE AUTHOR OR CONTRIBUTORS BE LIABLE - * FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL - * DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS - * OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) - * HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT - * LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY - * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF - * SUCH DAMAGE. - */ -#ifndef __INCmvStorageDevh -#define __INCmvStorageDevh - -/* Definitions */ - -/* ATA register on the ATA drive*/ - -#define MV_EDMA_ATA_FEATURES_ADDR 0x11 -#define MV_EDMA_ATA_SECTOR_COUNT_ADDR 0x12 -#define MV_EDMA_ATA_LBA_LOW_ADDR 0x13 -#define MV_EDMA_ATA_LBA_MID_ADDR 0x14 -#define MV_EDMA_ATA_LBA_HIGH_ADDR 0x15 -#define MV_EDMA_ATA_DEVICE_ADDR 0x16 -#define MV_EDMA_ATA_COMMAND_ADDR 0x17 - -#define MV_ATA_ERROR_STATUS 0x00000001 /* MV_BIT0 */ -#define MV_ATA_DATA_REQUEST_STATUS 0x00000008 /* MV_BIT3 */ -#define MV_ATA_SERVICE_STATUS 0x00000010 /* MV_BIT4 */ -#define MV_ATA_DEVICE_FAULT_STATUS 0x00000020 /* MV_BIT5 */ -#define MV_ATA_READY_STATUS 0x00000040 /* MV_BIT6 */ -#define MV_ATA_BUSY_STATUS 0x00000080 /* MV_BIT7 */ - - -#define MV_ATA_COMMAND_READ_SECTORS 0x20 -#define MV_ATA_COMMAND_READ_SECTORS_EXT 0x24 -#define MV_ATA_COMMAND_READ_VERIFY_SECTORS 0x40 -#define MV_ATA_COMMAND_READ_VERIFY_SECTORS_EXT 0x42 -#define MV_ATA_COMMAND_READ_BUFFER 0xE4 -#define MV_ATA_COMMAND_WRITE_BUFFER 0xE8 -#define MV_ATA_COMMAND_WRITE_SECTORS 0x30 -#define MV_ATA_COMMAND_WRITE_SECTORS_EXT 0x34 -#define MV_ATA_COMMAND_DIAGNOSTIC 0x90 -#define MV_ATA_COMMAND_SMART 0xb0 -#define MV_ATA_COMMAND_READ_MULTIPLE 0xc4 -#define MV_ATA_COMMAND_WRITE_MULTIPLE 0xc5 -#define MV_ATA_COMMAND_STANDBY_IMMEDIATE 0xe0 -#define MV_ATA_COMMAND_IDLE_IMMEDIATE 0xe1 -#define MV_ATA_COMMAND_STANDBY 0xe2 -#define MV_ATA_COMMAND_IDLE 0xe3 -#define MV_ATA_COMMAND_SLEEP 0xe6 -#define MV_ATA_COMMAND_IDENTIFY 0xec -#define MV_ATA_COMMAND_DEVICE_CONFIG 0xb1 -#define MV_ATA_COMMAND_SET_FEATURES 0xef -#define MV_ATA_COMMAND_WRITE_DMA 0xca -#define MV_ATA_COMMAND_WRITE_DMA_EXT 0x35 -#define MV_ATA_COMMAND_WRITE_DMA_QUEUED 0xcc -#define MV_ATA_COMMAND_WRITE_DMA_QUEUED_EXT 0x36 -#define MV_ATA_COMMAND_WRITE_FPDMA_QUEUED_EXT 0x61 -#define MV_ATA_COMMAND_READ_DMA 0xc8 -#define MV_ATA_COMMAND_READ_DMA_EXT 0x25 -#define MV_ATA_COMMAND_READ_DMA_QUEUED 0xc7 -#define MV_ATA_COMMAND_READ_DMA_QUEUED_EXT 0x26 -#define MV_ATA_COMMAND_READ_FPDMA_QUEUED_EXT 0x60 -#define MV_ATA_COMMAND_FLUSH_CACHE 0xe7 -#define MV_ATA_COMMAND_FLUSH_CACHE_EXT 0xea - - -#define MV_ATA_SET_FEATURES_DISABLE_8_BIT_PIO 0x01 -#define MV_ATA_SET_FEATURES_ENABLE_WCACHE 0x02 /* Enable write cache */ -#define MV_ATA_SET_FEATURES_TRANSFER 0x03 /* Set transfer mode */ -#define MV_ATA_TRANSFER_UDMA_0 0x40 -#define MV_ATA_TRANSFER_UDMA_1 0x41 -#define MV_ATA_TRANSFER_UDMA_2 0x42 -#define MV_ATA_TRANSFER_UDMA_3 0x43 -#define MV_ATA_TRANSFER_UDMA_4 0x44 -#define MV_ATA_TRANSFER_UDMA_5 0x45 -#define MV_ATA_TRANSFER_UDMA_6 0x46 -#define MV_ATA_TRANSFER_UDMA_7 0x47 -#define MV_ATA_TRANSFER_PIO_SLOW 0x00 -#define MV_ATA_TRANSFER_PIO_0 0x08 -#define MV_ATA_TRANSFER_PIO_1 0x09 -#define MV_ATA_TRANSFER_PIO_2 0x0A -#define MV_ATA_TRANSFER_PIO_3 0x0B -#define MV_ATA_TRANSFER_PIO_4 0x0C -/* Enable advanced power management */ -#define MV_ATA_SET_FEATURES_ENABLE_APM 0x05 -/* Disable media status notification*/ -#define MV_ATA_SET_FEATURES_DISABLE_MSN 0x31 -/* Disable read look-ahead */ -#define MV_ATA_SET_FEATURES_DISABLE_RLA 0x55 -/* Enable release interrupt */ -#define MV_ATA_SET_FEATURES_ENABLE_RI 0x5D -/* Enable SERVICE interrupt */ -#define MV_ATA_SET_FEATURES_ENABLE_SI 0x5E -/* Disable revert power-on defaults */ -#define MV_ATA_SET_FEATURES_DISABLE_RPOD 0x66 -/* Disable write cache */ -#define MV_ATA_SET_FEATURES_DISABLE_WCACHE 0x82 -/* Disable advanced power management*/ -#define MV_ATA_SET_FEATURES_DISABLE_APM 0x85 -/* Enable media status notification */ -#define MV_ATA_SET_FEATURES_ENABLE_MSN 0x95 -/* Enable read look-ahead */ -#define MV_ATA_SET_FEATURES_ENABLE_RLA 0xAA -/* Enable revert power-on defaults */ -#define MV_ATA_SET_FEATURES_ENABLE_RPOD 0xCC -/* Disable release interrupt */ -#define MV_ATA_SET_FEATURES_DISABLE_RI 0xDD -/* Disable SERVICE interrupt */ -#define MV_ATA_SET_FEATURES_DISABLE_SI 0xDE - -/* Defines for parsing the IDENTIFY command results*/ -#define IDEN_SERIAL_NUM_OFFSET 10 -#define IDEN_SERIAL_NUM_SIZE 19-10 -#define IDEN_FIRMWARE_OFFSET 23 -#define IDEN_FIRMWARE_SIZE 26-23 -#define IDEN_MODEL_OFFSET 27 -#define IDEN_MODEL_SIZE 46-27 -#define IDEN_CAPACITY_1_OFFSET 49 -#define IDEN_VALID 53 -#define IDEN_NUM_OF_ADDRESSABLE_SECTORS 60 -#define IDEN_PIO_MODE_SPPORTED 64 -#define IDEN_QUEUE_DEPTH 75 -#define IDEN_SATA_CAPABILITIES 76 -#define IDEN_SATA_FEATURES_SUPPORTED 78 -#define IDEN_SATA_FEATURES_ENABLED 79 -#define IDEN_ATA_VERSION 80 -#define IDEN_SUPPORTED_COMMANDS1 82 -#define IDEN_SUPPORTED_COMMANDS2 83 -#define IDEN_ENABLED_COMMANDS1 85 -#define IDEN_ENABLED_COMMANDS2 86 -#define IDEN_UDMA_MODE 88 -#define IDEN_SATA_CAPABILITY 76 - - -/* Typedefs */ - -/* Structures */ -typedef struct mvStorageDevRegisters -{ - /* Fields set by CORE driver */ - MV_U8 errorRegister; - MV_U16 sectorCountRegister; - MV_U16 lbaLowRegister; - MV_U16 lbaMidRegister; - MV_U16 lbaHighRegister; - MV_U8 deviceRegister; - MV_U8 statusRegister; -} MV_STORAGE_DEVICE_REGISTERS; - -/* Bits for HD_ERROR */ -#define NM_ERR 0x02 /* media present */ -#define ABRT_ERR 0x04 /* Command aborted */ -#define MCR_ERR 0x08 /* media change request */ -#define IDNF_ERR 0x10 /* ID field not found */ -#define MC_ERR 0x20 /* media changed */ -#define UNC_ERR 0x40 /* Uncorrect data */ -#define WP_ERR 0x40 /* write protect */ -#define ICRC_ERR 0x80 /* new meaning: CRC error during transfer */ - -/* Function */ - -MV_BOOLEAN HPTLIBAPI mvStorageDevATAExecuteNonUDMACommand(MV_SATA_ADAPTER *pAdapter, - MV_U8 channelIndex, - MV_NON_UDMA_PROTOCOL protocolType, - MV_BOOLEAN isEXT, - MV_U16 FAR *bufPtr, MV_U32 count, - MV_U16 features, - MV_U16 sectorCount, - MV_U16 lbaLow, MV_U16 lbaMid, - MV_U16 lbaHigh, MV_U8 device, - MV_U8 command); - -MV_BOOLEAN HPTLIBAPI mvStorageDevATAIdentifyDevice(MV_SATA_ADAPTER *pAdapter, - MV_U8 channelIndex); - -MV_BOOLEAN HPTLIBAPI mvStorageDevATASetFeatures(MV_SATA_ADAPTER *pAdapter, - MV_U8 channelIndex, MV_U8 subCommand, - MV_U8 subCommandSpecific1, - MV_U8 subCommandSpecific2, - MV_U8 subCommandSpecific3, - MV_U8 subCommandSpecific4); - -MV_BOOLEAN HPTLIBAPI mvStorageDevATAIdleImmediate(MV_SATA_ADAPTER *pAdapter, - MV_U8 channelIndex); - -MV_BOOLEAN HPTLIBAPI mvStorageDevATAFlushWriteCache(MV_SATA_ADAPTER *pAdapter, - MV_U8 channelIndex); - -MV_BOOLEAN HPTLIBAPI mvStorageDevATASoftResetDevice(MV_SATA_ADAPTER *pAdapter, - MV_U8 channelIndex); - -MV_BOOLEAN HPTLIBAPI mvReadWrite(MV_SATA_CHANNEL *pSataChannel, LBA_T Lba, UCHAR Cmd, void *tmpBuffer); - -#endif diff --git a/sys/contrib/dev/hptmv/raid5n.h b/sys/contrib/dev/hptmv/raid5n.h deleted file mode 100644 index a590b91a6030..000000000000 --- a/sys/contrib/dev/hptmv/raid5n.h +++ /dev/null @@ -1,120 +0,0 @@ -/* - * Copyright (c) 2003-2004 HighPoint Technologies, Inc. - * All rights reserved. - * - * Redistribution and use in source and binary forms, with or without - * modification, are permitted provided that the following conditions - * are met: - * 1. Redistributions of source code must retain the above copyright - * notice, this list of conditions and the following disclaimer. - * 2. Redistributions in binary form must reproduce the above copyright - * notice, this list of conditions and the following disclaimer in the - * documentation and/or other materials provided with the distribution. - * - * THIS SOFTWARE IS PROVIDED BY THE AUTHOR AND CONTRIBUTORS ``AS IS'' AND - * ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE - * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE - * ARE DISCLAIMED. IN NO EVENT SHALL THE AUTHOR OR CONTRIBUTORS BE LIABLE - * FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL - * DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS - * OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) - * HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT - * LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY - * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF - * SUCH DAMAGE. - */ -#ifdef _RAID5N_ - -/* OS provided function, call only at initialization time */ -extern void * HPTLIBAPI os_alloc_page(_VBUS_ARG0); /* may be cached memory */ -extern void * HPTLIBAPI os_alloc_dma_page(_VBUS_ARG0); /* must be non-cached memory */ -/* implement if the driver can be unloaded */ -void HPTLIBAPI os_free_page(_VBUS_ARG void *p); -void HPTLIBAPI os_free_dma_page(_VBUS_ARG void *p); - -typedef void (* HPTLIBAPI xfer_done_fn)(_VBUS_ARG void *tag, int result); - - -#define DATAXFER_STACK_VAR -#define DATAXFER_INIT_ARG 0 - -#define dataxfer_init(arg) 0 -#define dataxfer_add_item(handle, host, cache, bytes, tocache) \ - if (tocache) memcpy((PUCHAR)(cache), (PUCHAR)(host), bytes); \ - else memcpy((PUCHAR)(host), (PUCHAR)(cache), bytes) -#define dataxfer_exec(handle, done, tag) done(_VBUS_P tag, 0) -#define dataxfer_poll() - - -typedef void (* HPTLIBAPI xor_done_fn)(_VBUS_ARG void *tag, int result); - - -#define XOR_STACK_VAR -#define XOR_INIT_ARG 0 - -/* DoXor1, DoXor2 provided by platform dependent code */ -void HPTLIBAPI DoXor1(ULONG *p0, ULONG *p1, ULONG *p2, UINT nBytes); -void HPTLIBAPI DoXor2(ULONG *p0, ULONG *p2, UINT nBytes); -#define max_xor_way 2 -#define xor_init(arg) 0 -#define xor_add_item(handle, dest, src, nsrc, bytes) \ - do {\ - if (((void**)src)[0]==dest)\ - DoXor2((PULONG)(dest), ((PULONG *)src)[1], bytes);\ - else\ - DoXor1((PULONG)(dest), ((PULONG *)src)[0], ((PULONG *)src)[1], bytes);\ - } while(0) -#define xor_exec(handle, done, tag) done(_VBUS_P tag, 0) -#define xor_poll() - - -/* set before calling init_raid5_memory */ -extern UINT num_raid5_pages; - -/* called by init.c */ -extern void HPTLIBAPI init_raid5_memory(_VBUS_ARG0); -extern void HPTLIBAPI free_raid5_memory(_VBUS_ARG0); - -/* asynchronous flush, may be called periodly */ -extern void HPTLIBAPI flush_stripe_cache(_VBUS_ARG0); -extern void HPTLIBAPI flush_raid5_async(PVDevice pArray, DPC_PROC done, void *arg); - -/* synchronous function called at shutdown */ -extern int HPTLIBAPI flush_raid5(PVDevice pArray); - -extern void HPTLIBAPI raid5_free(_VBUS_ARG PVDevice pArray); - -struct free_heap_block { - struct free_heap_block *next; -}; - -#ifndef LIST_H_INCLUDED -struct list_head { - struct list_head *next, *prev; -}; -#endif - -struct free_page { - struct free_page *link; -}; - -struct r5_global_data { - int enable_write_back; - struct list_head inactive_list; - struct list_head dirty_list; - struct list_head active_list; -#ifdef R5_CONTIG_CACHE - BUS_ADDR page_base_phys; - PUCHAR page_base_virt; - PUCHAR page_current; -#endif - struct free_heap_block *free_heap_slots[8]; - struct free_page *free_pages; - UINT num_free_pages; - UINT active_stripes; - UINT num_flushing; - PCommand cache_wait_list; -}; - - -#endif diff --git a/sys/contrib/dev/hptmv/readme.txt b/sys/contrib/dev/hptmv/readme.txt deleted file mode 100644 index 67c681067e07..000000000000 --- a/sys/contrib/dev/hptmv/readme.txt +++ /dev/null @@ -1,96 +0,0 @@ -RocketRAID 182x Driver for FreeBSD -Copyright (C) 2003-2004 HighPoint Technologies, Inc. All rights reserved. - -############################################################################# -Revision History: - - v1.1 2004-9-23 - Fix activity LED problem. - Cleanup diagnostic code. - - v1.01 2004-5-24 - First source code release - -############################################################################# - -1. Overview ---------------------- - This package contains FreeBSD driver source code for HighPoint RocketRAID - 182x SATA controller. - - NO WARRANTY - - THE DRIVER SOURCE CODE HIGHPOINT PROVIDED IS FREE OF CHARGE, AND THERE IS - NO WARRANTY FOR THE PROGRAM. THERE ARE NO RESTRICTIONS ON THE USE OF THIS - FREE SOURCE CODE. HIGHPOINT DOES NOT PROVIDE ANY TECHNICAL SUPPORT IF THE - CODE HAS BEEN CHANGED FROM ORIGINAL SOURCE CODE. - - LIMITATION OF LIABILITY - - IN NO EVENT WILL HIGHPOINT BE LIABLE FOR DIRECT, INDIRECT, SPECIAL, - INCIDENTAL, OR CONSEQUENTIAL DAMAGES ARISING OUT OF THE USE OF OR - INABILITY TO USE THIS PRODUCT OR DOCUMENTATION, EVEN IF ADVISED OF THE - POSSIBILITY OF SUCH DAMAGES. IN PARTICULAR, HIGHPOINT SHALL NOT HAVE - LIABILITY FOR ANY HARDWARE, SOFTWARE, OR DATA STORED USED WITH THE - PRODUCT, INCLUDING THE COSTS OF REPAIRING, REPLACING, OR RECOVERING - SUCH HARDWARE, OR DATA. - -2. Build the driver ---------------------- - 1) Install kernel source package and building tools. - - 2) Extract the driver files to somewhere. - - 3) Run "make" to build the driver. - - -3. Using the driver ---------------------- - 1) Copy the driver module to /modules/ (FreeBSD 4.x) or /boot/kernel/ - (FreeBSD 5.x). - - 2) The driver can't be loaded by kldload command on a running system. - Please load the driver during system booting stage. e.g: - - BTX loader 1.00 BTX version is 1.01 - Console: internal video/keyboard - BIOS driver A: is disk0 - BIOS driver C: is disk2 - BIOS 636kB/74512kB available memory - - FreeBSD/i386 bootstrap loader, Revision 0.8 - (mailto:jkh@narf.osd.bsdi.com, Sat Apr 21 08:46:19 GMT 2001) - Loading /boot/defaults/loader.conf - /kernel text=0x24f1db data=0x3007ec+0x2062c - - - Hit [Enter] to boot immediagely, or any other key for command prompt. - Booting [kernel] in 9 secondsĄ­ - - <-- press SPACE key here - Type '?' for a list of commands, 'help' for more detailed help. - ok load hptmv - /modules/hptmv.ko text=0xf571 data=0x2c8+0x254 - ok autoboot - - Please refer to the installation guide in HighPoint FreeBSD driver release - package for more information. - - -############################################################################# -Technical support and service - - If you have questions about installing or using your HighPoint product, - check the user's guide or readme file first, and you will find answers to - most of your questions here. If you need further assistance, please - contact us. We offer the following support and information services: - - 1) The HighPoint Web Site provides information on software upgrades, - answers to common questions, and other topics. The Web Site is - available from Internet 24 hours a day, 7 days a week, at - http://www.highpoint-tech.com. - - 2) For technical support, send e-mail to support@highpoint-tech.com - - NOTE: Before you send an e-mail, please visit our Web Site - (http://www.highpoint-tech.com) to check if there is a new or - updated device driver for your system. diff --git a/sys/contrib/dev/hptmv/vdevice.h b/sys/contrib/dev/hptmv/vdevice.h deleted file mode 100644 index a25822195f35..000000000000 --- a/sys/contrib/dev/hptmv/vdevice.h +++ /dev/null @@ -1,280 +0,0 @@ -/* - * Copyright (c) 2003-2004 HighPoint Technologies, Inc. - * All rights reserved. - * - * Redistribution and use in source and binary forms, with or without - * modification, are permitted provided that the following conditions - * are met: - * 1. Redistributions of source code must retain the above copyright - * notice, this list of conditions and the following disclaimer. - * 2. Redistributions in binary form must reproduce the above copyright - * notice, this list of conditions and the following disclaimer in the - * documentation and/or other materials provided with the distribution. - * - * THIS SOFTWARE IS PROVIDED BY THE AUTHOR AND CONTRIBUTORS ``AS IS'' AND - * ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE - * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE - * ARE DISCLAIMED. IN NO EVENT SHALL THE AUTHOR OR CONTRIBUTORS BE LIABLE - * FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL - * DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS - * OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) - * HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT - * LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY - * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF - * SUCH DAMAGE. - */ - -#ifndef _VDEVICE_H_ -#define _VDEVICE_H_ - -/*************************************************************************** - * Description: virtual device header - ***************************************************************************/ - -typedef struct _VDevice -{ - UCHAR VDeviceType; - UCHAR vf_bootmark: 1; /* is boot device? */ - UCHAR vf_bootable: 1; /* has active partition */ - UCHAR vf_online: 1; /* is usable? */ - UCHAR vf_cache_disk: 1; /* Cache enabled */ - UCHAR vf_format_v2: 1; /* old array block */ - UCHAR vf_freed: 1; /* memory free */ - UCHAR reserve1; - UCHAR bSerialNumber; /* valid if pParent!=0 */ - - PVDevice pParent; /* parent array */ - PVBus pVBus; /* vbus this device located. Must not be NULL. */ - - LBA_T VDeviceCapacity; /* number of blocks */ - - LBA_T LockedLba; - USHORT LockedSectors; - USHORT ActiveRequests; - PCommand LockWaitList; - void (* HPTLIBAPI QuiesceAction)(_VBUS_ARG void *arg); - void *QuiesceArg; - void (* HPTLIBAPI flush_callback)(_VBUS_ARG void *arg); - void *flush_callback_arg; - - -#if defined(_RAID5N_) - struct stripe **CacheEntry; - struct range_lock *range_lock; -#endif - - void (* HPTLIBAPI pfnSendCommand)(_VBUS_ARG PCommand pCmd); /* call this to send a command to a VDevice */ - void (* HPTLIBAPI pfnDeviceFailed)(_VBUS_ARG PVDevice pVDev); /* call this when a VDevice failed */ - - union { -#ifdef SUPPORT_ARRAY - RaidArray array; -#endif - Device disk; - } u; - -} VDevice; - -#define ARRAY_VDEV_SIZE ((UINT)(ULONG_PTR)&((PVDevice)0)->u+sizeof(RaidArray)) -#define DISK_VDEV_SIZE ((UINT)(ULONG_PTR)&((PVDevice)0)->u+sizeof(Device)) - -#define Map2pVDevice(pDev) ((PVDevice)((UINT_PTR)pDev - (UINT)(UINT_PTR)&((PVDevice)0)->u.disk)) - -/* - * bUserDeviceMode - */ -#define MEMBER_NOT_SET_MODE 0x5F - -/* - * arrayType - */ -#define VD_SPARE 0 -#define VD_REMOVABLE 1 -#define VD_ATAPI 2 -#define VD_SINGLE_DISK 3 - -#define VD_JBOD 4 /* JBOD */ -#define VD_RAID_0 5 /* RAID 0 stripe */ -#define VD_RAID_1 6 /* RAID 1 mirror */ -#define VD_RAID_3 7 /* RAID 3 */ -#define VD_RAID_5 8 /* RAID 5 */ -#define VD_MAX_TYPE 8 - -#ifdef SUPPORT_ARRAY -#define mIsArray(pVDev) (pVDev->VDeviceType>VD_SINGLE_DISK) -#else -#define mIsArray(pVDev) 0 -#endif - -extern void (* HPTLIBAPI pfnSendCommand[])(_VBUS_ARG PCommand pCmd); -extern void (* HPTLIBAPI pfnDeviceFailed[])(_VBUS_ARG PVDevice pVDev); -void HPTLIBAPI fOsDiskFailed(_VBUS_ARG PVDevice pVDev); -void HPTLIBAPI fDeviceSendCommand(_VBUS_ARG PCommand pCmd); -void HPTLIBAPI fSingleDiskFailed(_VBUS_ARG PVDevice pVDev); - -/*************************************************************************** - * Description: RAID Adapter - ***************************************************************************/ - -typedef struct _VBus { - /* pVDevice[] may be non-continuous */ - PVDevice pVDevice[MAX_VDEVICE_PER_VBUS]; - - UINT nInstances; - PChipInstance pChipInstance[MAX_CHIP_IN_VBUS]; - - void * OsExt; /* for OS private use */ - - - int serial_mode; - int next_active; - int working_devs; - - - - PCommand pFreeCommands; - DPC_ROUTINE PendingRoutines[MAX_PENDING_ROUTINES]; - int PendingRoutinesFirst, PendingRoutinesLast; - DPC_ROUTINE IdleRoutines[MAX_IDLE_ROUTINES]; - int IdleRoutinesFirst, IdleRoutinesLast; - -#ifdef SUPPORT_ARRAY - PVDevice pFreeArrayLink; - BYTE _ArrayTables[MAX_ARRAY_PER_VBUS * ARRAY_VDEV_SIZE]; -#endif - - -#ifdef _RAID5N_ - struct r5_global_data r5; -#endif - -} VBus; - -/* - * Array members must be on same VBus. - * The platform dependent part shall select one of the following strategy. - */ -#ifdef SET_VBUS_FOR_EACH_IRQ -#define CHIP_ON_SAME_VBUS(pChip1, pChip2) ((pChip1)->bChipIntrNum==(pChip2)->bChipIntrNum) -#elif defined(SET_VBUS_FOR_EACH_CONTROLLER) -#define CHIP_ON_SAME_VBUS(pChip1, pChip2) \ - ((pChip1)->pci_bus==(pChip2)->pci_bus && (pChip1)->pci_dev==(pChip2)->pci_dev) -#elif defined(SET_VBUS_FOR_EACH_FUNCTION) -#define CHIP_ON_SAME_VBUS(pChip1, pChip2) \ - ((pChip1)->pci_bus==(pChip2)->pci_bus && (pChip1)->pci_dev==(pChip2)->pci_dev && (pChip1)->pci_func==(pChip2)->pci_func) -#else -#error You must set one vbus setting -#endif - -#define FOR_EACH_CHANNEL_ON_VBUS(_pVBus, _pChan) \ - for (_pChan=pChanStart; _pChanpChipInstance->pVBus!=_pVBus) ; else - -#define FOR_EACH_DEV_ON_VBUS(pVBus, pVDev, i) \ - for(i = 0; i < MAX_VDEVICE_PER_VBUS; i++) \ - if ((pVDev=pVBus->pVDevice[i])==0) continue; else - -#define FOR_EACH_DEV_ON_ALL_VBUS(pVBus, pVDev, i) \ - for(pVBus = gVBus; pVBus < &gVBus[MAX_VBUS]; pVBus++) \ - for(i = 0; i < MAX_VDEVICE_PER_VBUS; i++) \ - if ((pVDev=pVBus->pVDevice[i])==0) continue; else - -#define FOR_EACH_ARRAY_ON_ALL_VBUS(pVBus, pArray, i) \ - for(pVBus = gVBus; pVBus < &gVBus[MAX_VBUS]; pVBus++) \ - for(i = 0; i < MAX_ARRAY_PER_VBUS; i++) \ - if ((pArray=((PVDevice)&pVBus->_ArrayTables[i*ARRAY_VDEV_SIZE]))->u.array.dArStamp==0) continue; else - -/*************************************************************************** - * Description: the functions called by IDE layer - ***************************************************************************/ -#ifdef SUPPORT_ARRAY -#define IdeRegisterDevice fCheckArray -#else -void HPTLIBAPI IdeRegisterDevice(PDevice pDev); -#endif - -/*************************************************************************** - * Description: the functions OS must provided - ***************************************************************************/ - -void OsSetDeviceTable(PDevice pDevice, PIDENTIFY_DATA pIdentify); - -/* - * allocate and free data structure - */ -PChannel fGetChannelTable(void); -PDevice fGetDeviceTable(void); -#define OsGetChannelTable(x, y) fGetChannelTable() -#define OsGetDeviceTable(x, y) fGetDeviceTable() -void OsReturnTable(PDevice pDevice); -/*************************************************************************** - * Description: the functions Prototype - ***************************************************************************/ -/* - * vdevice.c - */ -int Initialize(void); -int InitializeAllChips(void); -void InitializeVBus(PVBus pVBus); -void fRegisterChip(PChipInstance pChip); -void __fRegisterVDevices(PVBus pVBus); -void fRegisterVDevices(void); -void HPTLIBAPI UnregisterVDevice(PVDevice); -void HPTLIBAPI fCheckBootable(PVDevice pVDev); -void HPTLIBAPI fFlushVDev(PVDevice pVDev); -void HPTLIBAPI fFlushVDevAsync(PVDevice pVDev, DPC_PROC done, void *arg); -void HPTLIBAPI fShutdownVDev(PVDevice pVDev); -void HPTLIBAPI fResetVBus(_VBUS_ARG0); -void HPTLIBAPI fCompleteAllCommandsSynchronously(PVBus _vbus_p); - -#define RegisterVDevice(pVDev) -#define OsRegisterDevice(pVDev) -#define OsUnregisterDevice(pVDev) - -#ifdef SUPPORT_VBUS_CONFIG -void VBus_Config(PVBus pVBus, char *str); -#else -#define VBus_Config(pVBus, str) -#endif - -#pragma pack(1) -struct fdisk_partition_table -{ - UCHAR bootid; /* bootable? 0=no, 128=yes */ - UCHAR beghead; /* beginning head number */ - UCHAR begsect; /* beginning sector number */ - UCHAR begcyl; /* 10 bit nmbr, with high 2 bits put in begsect */ - UCHAR systid; /* Operating System type indicator code */ - UCHAR endhead; /* ending head number */ - UCHAR endsect; /* ending sector number */ - UCHAR endcyl; /* also a 10 bit nmbr, with same high 2 bit trick */ - UINT relsect; /* first sector relative to start of disk */ - UINT numsect; /* number of sectors in partition */ -}; - -typedef struct _Master_Boot_Record -{ - UCHAR bootinst[446]; /* space to hold actual boot code */ - struct fdisk_partition_table parts[4]; - USHORT signature; /* set to 0xAA55 to indicate PC MBR format */ -} -Master_Boot_Record, *PMaster_Boot_Record; - -#ifndef SUPPORT_ARRAY -/* TODO: move it later */ -#ifdef __BIG_ENDIAN_BITFIELD -typedef DWORD TIME_RECORD; -#else -typedef struct _TIME_RECORD { - UINT seconds:6; /* 0 - 59 */ - UINT minutes:6; /* 0 - 59 */ - UINT month:4; /* 1 - 12 */ - UINT hours:6; /* 0 - 59 */ - UINT day:5; /* 1 - 31 */ - UINT year:5; /* 0=2000, 31=2031 */ -} TIME_RECORD; -#endif -#endif - -#pragma pack() -#endif diff --git a/sys/dev/hptmv/access601.h b/sys/dev/hptmv/access601.h index 54e1902b687d..57acf8f5e4d8 100644 --- a/sys/dev/hptmv/access601.h +++ b/sys/dev/hptmv/access601.h @@ -22,6 +22,8 @@ * LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF * SUCH DAMAGE. + * + * $FreeBSD$ */ #ifndef _ACCESS601_H_ #define _ACCESS601_H_ diff --git a/sys/dev/hptmv/array.h b/sys/dev/hptmv/array.h index 29e0a9bbd3f2..104eb9b94275 100644 --- a/sys/dev/hptmv/array.h +++ b/sys/dev/hptmv/array.h @@ -22,6 +22,8 @@ * LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF * SUCH DAMAGE. + * + * $FreeBSD$ */ #ifndef _ARRAY_H_ diff --git a/sys/dev/hptmv/atapi.h b/sys/dev/hptmv/atapi.h index a46c1148c9ce..f6dda77a5cb3 100644 --- a/sys/dev/hptmv/atapi.h +++ b/sys/dev/hptmv/atapi.h @@ -22,6 +22,8 @@ * LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF * SUCH DAMAGE. + * + * $FreeBSD$ */ #ifndef _ATAPI_H_ diff --git a/sys/dev/hptmv/command.h b/sys/dev/hptmv/command.h index 0b03e155dc19..dbc0bd67ce7d 100644 --- a/sys/dev/hptmv/command.h +++ b/sys/dev/hptmv/command.h @@ -22,6 +22,8 @@ * LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF * SUCH DAMAGE. + * + * $FreeBSD$ */ #ifndef _COMMAND_H_ #define _COMMAND_H_ diff --git a/sys/dev/hptmv/gui_lib.c b/sys/dev/hptmv/gui_lib.c index e20ef55d8daa..9ef289e99ac6 100644 --- a/sys/dev/hptmv/gui_lib.c +++ b/sys/dev/hptmv/gui_lib.c @@ -22,6 +22,8 @@ * LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF * SUCH DAMAGE. + * + * $FreeBSD$ */ /* * gui_lib.c diff --git a/sys/dev/hptmv/hptproc.c b/sys/dev/hptmv/hptproc.c index e05798f1eb74..dc43129ec82b 100644 --- a/sys/dev/hptmv/hptproc.c +++ b/sys/dev/hptmv/hptproc.c @@ -22,6 +22,8 @@ * LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF * SUCH DAMAGE. + * + * $FreeBSD$ */ /* * hptproc.c sysctl support diff --git a/sys/dev/hptmv/ioctl.c b/sys/dev/hptmv/ioctl.c index 2cfe97912c28..0f9f71d49b47 100644 --- a/sys/dev/hptmv/ioctl.c +++ b/sys/dev/hptmv/ioctl.c @@ -22,6 +22,8 @@ * LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF * SUCH DAMAGE. + * + * $FreeBSD$ */ /* * ioctl.c ioctl interface implementation diff --git a/sys/dev/hptmv/mvSata.h b/sys/dev/hptmv/mvSata.h index 486f64ffa8f7..4a5c75c81d60 100644 --- a/sys/dev/hptmv/mvSata.h +++ b/sys/dev/hptmv/mvSata.h @@ -22,6 +22,8 @@ * LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF * SUCH DAMAGE. + * + * $FreeBSD$ */ #ifndef __INCmvSatah #define __INCmvSatah diff --git a/sys/dev/hptmv/mvStorageDev.h b/sys/dev/hptmv/mvStorageDev.h index a5f3eb945a89..8b9895874926 100644 --- a/sys/dev/hptmv/mvStorageDev.h +++ b/sys/dev/hptmv/mvStorageDev.h @@ -22,7 +22,9 @@ * LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF * SUCH DAMAGE. - */ + * + * $FreeBSD$ + * #ifndef __INCmvStorageDevh #define __INCmvStorageDevh diff --git a/sys/dev/hptmv/raid5n.h b/sys/dev/hptmv/raid5n.h index a590b91a6030..07101c8f2650 100644 --- a/sys/dev/hptmv/raid5n.h +++ b/sys/dev/hptmv/raid5n.h @@ -22,6 +22,8 @@ * LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF * SUCH DAMAGE. + * + * $FreeBSD$ */ #ifdef _RAID5N_ diff --git a/sys/dev/hptmv/readme.txt b/sys/dev/hptmv/readme.txt index 67c681067e07..df03e97efe81 100644 --- a/sys/dev/hptmv/readme.txt +++ b/sys/dev/hptmv/readme.txt @@ -1,5 +1,6 @@ RocketRAID 182x Driver for FreeBSD Copyright (C) 2003-2004 HighPoint Technologies, Inc. All rights reserved. +$FreeBSD$ ############################################################################# Revision History: diff --git a/sys/dev/hptmv/vdevice.h b/sys/dev/hptmv/vdevice.h index a25822195f35..c9a613618548 100644 --- a/sys/dev/hptmv/vdevice.h +++ b/sys/dev/hptmv/vdevice.h @@ -22,6 +22,8 @@ * LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF * SUCH DAMAGE. + * + * $FreeBSD$ */ #ifndef _VDEVICE_H_ diff --git a/sys/modules/hptmv/Makefile b/sys/modules/hptmv/Makefile index a444cd66a9e4..29c2e25a28c7 100644 --- a/sys/modules/hptmv/Makefile +++ b/sys/modules/hptmv/Makefile @@ -4,8 +4,8 @@ # # $FreeBSD$ -HPTMV= ${.CURDIR}/../../contrib/dev/hptmv -.PATH: ${.CURDIR}/../../dev/hptmv ${HPTMV} +HPTMV= ${.CURDIR}/../../dev/hptmv +.PATH: ${HPTMV} KMOD= hptmv SRCS= opt_scsi.h opt_cam.h