tpgs_tape.c revision 0205780bc43902d17f94f07ceacb0cd8d5eab20f
/*
* CDDL HEADER START
*
* The contents of this file are subject to the terms of the
* Common Development and Distribution License (the "License").
* You may not use this file except in compliance with the License.
*
* You can obtain a copy of the license at usr/src/OPENSOLARIS.LICENSE
* See the License for the specific language governing permissions
* and limitations under the License.
*
* When distributing Covered Code, include this CDDL HEADER in each
* file and include the License file at usr/src/OPENSOLARIS.LICENSE.
* If applicable, add the following below this CDDL HEADER, with the
* fields enclosed by brackets "[]" replaced with your own identifying
* information: Portions Copyright [yyyy] [name of copyright owner]
*
* CDDL HEADER END
*/
/*
* Copyright 2008 Sun Microsystems, Inc. All rights reserved.
* Use is subject to license terms.
*/
#pragma ident "%Z%%M% %I% %E% SMI"
/*
* Implementation of "scsi_vhci_f_tpgs_tape" T10 standard based failover_ops.
*
* NOTE: for sequential devices only.
*/
/* Supported device table entries. */
char *tpgs_tape_dev_table[] = { NULL };
static void tpgs_tape_init(void);
/* Failover module plumbing. */
#ifdef lint
#endif /* lint */
struct scsi_failover_ops scsi_vhci_failover_ops = {
"f_tpgs_tape",
/* The rest of the implementation comes from SFO_NAME_TPGS import */
};
&mod_miscops, "f_tpgs_tape %I%"
};
static struct modlinkage modlinkage = {
};
/*
* External function definitions
*/
extern struct scsi_failover_ops *vhci_failover_ops_by_name(char *);
int
_init()
{
return (mod_install(&modlinkage));
}
int
_fini()
{
return (mod_remove(&modlinkage));
}
int
{
}
/* ARGSUSED */
static int
void **ctpriv)
{
"!tpgs_tape_device_probe: not a standard tpgs device"));
return (SFO_DEVICE_PROBE_PHCI);
}
"!tpgs_tape_device_probe: Detected a "
"Standard Asymmetric device "
"not yet supported\n"));
return (SFO_DEVICE_PROBE_PHCI);
}
"mode: sd(%p)", (void *) sd));
return (SFO_DEVICE_PROBE_PHCI);
}
"!tpgs_tape_device_probe: Detected a "
"Standard Asymmetric device "
"with implicit failover\n"));
return (SFO_DEVICE_PROBE_VHCI);
}
"!tpgs_tape_device_probe: Detected a "
"Standard Asymmetric device "
"with explicit failover\n"));
return (SFO_DEVICE_PROBE_VHCI);
}
"!tpgs_tape_device_probe: Detected a "
"Standard Asymmetric device "
"which supports both implicit and explicit failover\n"));
return (SFO_DEVICE_PROBE_VHCI);
}
"!tpgs_tape_device_probe: "
return (SFO_DEVICE_PROBE_PHCI);
}
static void
tpgs_tape_init(void)
{
/* clone SFO_NAME_SYM implementation for most things */
return;
}
}