DOC HOME SITE MAP MAN PAGES GNU INFO SEARCH PRINT BOOK
 
SCO OpenServer

scsi_ha_cfg(D4osdi)


scsi_ha_cfg -- SCSI host adapter configuration structure

Syntax

#include "scsi.h"

Description

Each adapter that is mentioned in the mscsi(F)" file can expect to find an array named xxcfg in the kernel, where xx is the driver prefix. This array contains information about each adapter mentioned in the mscsi file. Each element in the array corresponds to one entry in the adapter driver's sdevice(F)" file in the Link Kit. The array elements are in the order of the lines in the sdevice file. Only as many adapters as are mentioned in mscsi will be represented in the xxcfg array.

Each element in the array is of type struct scsi_ha_cfg. The fields in the structure are described below:


paddr_t ha_base;
The base I/O address of the adapter board.

char *ha_name;
The name of the adapter driver.

unsigned char ha_num;
The host adapter number, to distinguish between boards of the same type. The numbers are in the order of the entries in the sdevice file.

unsigned char dmach;
The DMA channel used by the adapter.

unsigned char vec;
The interrupt vector used by the adapter.

int (*adapter_entry)();
The address of the adapter driver's xx_entry routine.

struct exten *hext;
Reserved for future use.

Examples

The first example illustrates the definition of an array of ``ad'' host adapters using the scsi_ha_cfg structure type.
   extern int aha_entry();
   

struct scsi_ha_cfg ahacfg[] = { /* 0 */ (paddr_t) 0x330, "aha", (unsigned char) 0x0, (unsigned char) 0x5, (unsigned char) 0x11, aha_entry, (paddr_t) 0x0, /* 1 */ (paddr_t) 0x334, "aha", (unsigned char) 0x1, (unsigned char) 0x6, (unsigned char) 0x12, aha_entry, (paddr_t) 0x0, 0xff };

The second example illustrates the definition of an array of ``myad'' host adapters using the scsi_ha_cfg structure type.
   extern int myad_entry();
   

struct scsi_ha_cfg myadcfg[] = { /* 0 */ (paddr_t) 0x330, "myad", (unsigned char) 0x0, (unsigned char) 0x5, (unsigned char) 0xb, myad_entry, (paddr_t) 0x0, 0xff };


19 June 2005
© 2005 The SCO Group, Inc. All rights reserved.
OpenServer 5 HDK - June 2005