Date: Sat, 5 May 2007 05:11:16 GMT From: Matt Jacob <mjacob@FreeBSD.org> To: Perforce Change Reviews <perforce@freebsd.org> Subject: PERFORCE change 119265 for review Message-ID: <200705050511.l455BGm8098600@repoman.freebsd.org>
next in thread | raw e-mail | index | archive | help
http://perforce.freebsd.org/chv.cgi?CH=119265 Change 119265 by mjacob@mjexp on 2007/05/05 05:10:51 Add a GETDLIST operation (to get visible WWNs) Affected files ... .. //depot/projects/mjexp/sys/dev/isp/isp_tpublic.h#6 edit Differences ... ==== //depot/projects/mjexp/sys/dev/isp/isp_tpublic.h#6 (text+ko) ==== @@ -54,6 +54,7 @@ QIN_HBA_REG=99, /* the argument is a pointer to a hba_register_t */ QIN_GETINFO, /* the argument is a pointer to a info_t */ QIN_SETINFO, /* the argument is a pointer to a info_t */ + QIN_GETDLIST, /* the argument is a pointer to a fc_dlist_t */ QIN_ENABLE, /* the argument is a pointer to a enadis_t */ QIN_DISABLE, /* the argument is a pointer to a enadis_t */ QIN_TMD_CONT, /* the argument is a pointer to a tmd_cmd_t */ @@ -72,7 +73,7 @@ * in, and the external module to call back with a QIN_HBA_REG that * passes back the corresponding information. */ -#define QR_VERSION 15 +#define QR_VERSION 16 typedef struct { /* NB: tags from here to r_version must never change */ void * r_identity; @@ -87,8 +88,7 @@ } hba_register_t; /* - * An information structure that is used to get or set per-channel - * transport layer parameters. + * An information structure that is used to get or set per-channel transport layer parameters. */ typedef struct { void * i_identity; @@ -109,6 +109,16 @@ } info_t; /* + * An information structure to return a list of logged in WWPNs. FC specific. + */ +typedef struct { + void * d_identity; + int d_channel; + int d_error; + int d_count; + uint64_t * d_wwpns; +} fc_dlist_t; +/* * Notify structure */ typedef enum { @@ -324,12 +334,14 @@ #define L0LUN_TO_FLATLUN(lptr) ((((lptr)[0] & 0x3f) << 8) | ((lptr)[1])) #define FLATLUN_TO_L0LUN(lptr, lun) \ - (lptr)[1] = lun; \ + (lptr)[1] = lun & 0xff; \ if (sizeof (lun) == 1) { \ (lptr)[0] = 0; \ } else { \ - int nl = (lun); \ - if (nl < 256) { \ + uint16_t nl = lun; \ + if (nl == LUN_ANY) { \ + (lptr)[0] = (nl >> 8) & 0xff; \ + } else if (nl < 256) { \ (lptr)[0] = 0; \ } else { \ (lptr)[0] = 0x40 | ((nl >> 8) & 0x3f); \
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?200705050511.l455BGm8098600>