28c28
< * $FreeBSD: head/sys/dev/ips/ipsreg.h 152919 2005-11-29 09:39:41Z scottl $
---
> * $FreeBSD: head/sys/dev/ips/ipsreg.h 154005 2006-01-03 23:03:15Z scottl $
64a65,68
> #define IPS_MAX_LD 8
> #define IPS_MAX_CHANNELS 4
> #define IPS_MAX_TARGETS 15
> #define IPS_MAX_CHUNKS 16
123a128
> #define IPS_CMD_READ_CONF 0x38
325c330
< u_int16_t addr_dead_disk[4*16];/* ugly, max # channels * max # scsi devices per channel */
---
> u_int16_t addr_dead_disk[IPS_MAX_CHANNELS][IPS_MAX_TARGETS];
327a333,398
> typedef struct {
> u_int8_t initiator;
> u_int8_t parameters;
> u_int8_t miscflag;
> u_int8_t state;
> u_int32_t blkcount;
> u_int8_t deviceid[28];
> } __attribute__((packed)) ips_devstate_t;
>
> /*
> * The states that a physical drive can be in. The 'present' value can be
> * OR'd with the other values.
> */
> #define IPS_DEVSTATE_PRESENT 0x81
> #define IPS_DEVSTATE_REBUILD 0x02
> #define IPS_DEVSTATE_SPARE 0x04
> #define IPS_DEVSTATE_MEMBER 0x08
>
> typedef struct {
> u_int8_t channel;
> u_int8_t target;
> u_int16_t reserved;
> u_int32_t startsectors;
> u_int32_t numsectors;
> } __attribute__((packed)) ips_chunk_t;
>
> typedef struct {
> u_int16_t userfield;
> u_int8_t state;
> u_int8_t raidcacheparam;
> u_int8_t numchunkunits;
> u_int8_t stripesize;
> u_int8_t params;
> u_int8_t reserved;
> u_int32_t ldsize;
> ips_chunk_t chunk[IPS_MAX_CHUNKS];
> } __attribute__((packed)) ips_ld_t;
>
> typedef struct {
> u_int8_t boarddisc[8];
> u_int8_t processor[8];
> u_int8_t numchantype;
> u_int8_t numhostinttype;
> u_int8_t compression;
> u_int8_t nvramtype;
> u_int32_t nvramsize;
> } __attribute__((packed)) ips_hardware_t;
>
> typedef struct {
> u_int8_t ldcount;
> u_int8_t day;
> u_int8_t month;
> u_int8_t year;
> u_int8_t initiatorid[4];
> u_int8_t hostid[12];
> u_int8_t timesign[8];
> u_int32_t useropt;
> u_int16_t userfield;
> u_int8_t rebuildrate;
> u_int8_t reserve;
> ips_hardware_t hardwaredisc;
> ips_ld_t ld[IPS_MAX_LD];
> ips_devstate_t dev[IPS_MAX_CHANNELS][IPS_MAX_TARGETS+1];
> u_int8_t reserved[512];
> } __attribute__((packed)) ips_conf_t;
>
< * $FreeBSD: head/sys/dev/ips/ipsreg.h 152919 2005-11-29 09:39:41Z scottl $
---
> * $FreeBSD: head/sys/dev/ips/ipsreg.h 154005 2006-01-03 23:03:15Z scottl $
64a65,68
> #define IPS_MAX_LD 8
> #define IPS_MAX_CHANNELS 4
> #define IPS_MAX_TARGETS 15
> #define IPS_MAX_CHUNKS 16
123a128
> #define IPS_CMD_READ_CONF 0x38
325c330
< u_int16_t addr_dead_disk[4*16];/* ugly, max # channels * max # scsi devices per channel */
---
> u_int16_t addr_dead_disk[IPS_MAX_CHANNELS][IPS_MAX_TARGETS];
327a333,398
> typedef struct {
> u_int8_t initiator;
> u_int8_t parameters;
> u_int8_t miscflag;
> u_int8_t state;
> u_int32_t blkcount;
> u_int8_t deviceid[28];
> } __attribute__((packed)) ips_devstate_t;
>
> /*
> * The states that a physical drive can be in. The 'present' value can be
> * OR'd with the other values.
> */
> #define IPS_DEVSTATE_PRESENT 0x81
> #define IPS_DEVSTATE_REBUILD 0x02
> #define IPS_DEVSTATE_SPARE 0x04
> #define IPS_DEVSTATE_MEMBER 0x08
>
> typedef struct {
> u_int8_t channel;
> u_int8_t target;
> u_int16_t reserved;
> u_int32_t startsectors;
> u_int32_t numsectors;
> } __attribute__((packed)) ips_chunk_t;
>
> typedef struct {
> u_int16_t userfield;
> u_int8_t state;
> u_int8_t raidcacheparam;
> u_int8_t numchunkunits;
> u_int8_t stripesize;
> u_int8_t params;
> u_int8_t reserved;
> u_int32_t ldsize;
> ips_chunk_t chunk[IPS_MAX_CHUNKS];
> } __attribute__((packed)) ips_ld_t;
>
> typedef struct {
> u_int8_t boarddisc[8];
> u_int8_t processor[8];
> u_int8_t numchantype;
> u_int8_t numhostinttype;
> u_int8_t compression;
> u_int8_t nvramtype;
> u_int32_t nvramsize;
> } __attribute__((packed)) ips_hardware_t;
>
> typedef struct {
> u_int8_t ldcount;
> u_int8_t day;
> u_int8_t month;
> u_int8_t year;
> u_int8_t initiatorid[4];
> u_int8_t hostid[12];
> u_int8_t timesign[8];
> u_int32_t useropt;
> u_int16_t userfield;
> u_int8_t rebuildrate;
> u_int8_t reserve;
> ips_hardware_t hardwaredisc;
> ips_ld_t ld[IPS_MAX_LD];
> ips_devstate_t dev[IPS_MAX_CHANNELS][IPS_MAX_TARGETS+1];
> u_int8_t reserved[512];
> } __attribute__((packed)) ips_conf_t;
>