xref: /onnv-gate/usr/src/uts/common/io/emul64.conf (revision 85:1bca8d4eab66)
1*85Scth#
2*85Scth# CDDL HEADER START
3*85Scth#
4*85Scth# The contents of this file are subject to the terms of the
5*85Scth# Common Development and Distribution License, Version 1.0 only
6*85Scth# (the "License").  You may not use this file except in compliance
7*85Scth# with the License.
8*85Scth#
9*85Scth# You can obtain a copy of the license at usr/src/OPENSOLARIS.LICENSE
10*85Scth# or http://www.opensolaris.org/os/licensing.
11*85Scth# See the License for the specific language governing permissions
12*85Scth# and limitations under the License.
13*85Scth#
14*85Scth# When distributing Covered Code, include this CDDL HEADER in each
15*85Scth# file and include the License file at usr/src/OPENSOLARIS.LICENSE.
16*85Scth# If applicable, add the following below this CDDL HEADER, with the
17*85Scth# fields enclosed by brackets "[]" replaced with your own identifying
18*85Scth# information: Portions Copyright [yyyy] [name of copyright owner]
19*85Scth#
20*85Scth# CDDL HEADER END
21*85Scth#
22*85Scth# Copyright 2005 Sun Microsystems, Inc.  All rights reserved.
23*85Scth# Use is subject to license terms.
24*85Scth#
25*85Scth#pragma ident	"%Z%%M%	%I%	%E% SMI"
26*85Scth#
27*85Scth#-----------------------------
28*85Scth# ON version of emul64.conf
29*85Scth#-----------------------------
30*85Scth#
31*85Scth#
32*85Scth# Define Different Drive Sizes:
33*85Scth#
34*85Scth#	Compute MSB blocks of X GB disk with dc(1):
35*85Scth#		X 1024 1024 1024***512/2 32^/16op10op
36*85Scth#	Compute LSB blocks of X GB disk with dc(1):
37*85Scth#		X 1024 1024 1024***512/2 32^%16op10op
38*85Scth#	With nhead = 128 and nsect = 128, Compute ncyl of X GB disk with dc(1):
39*85Scth#		X 1024 1024 1024***512/128 128*/16op10op
40*85Scth#	Example: for wombat-drive-1_5TB:
41*85Scth#		# dc
42*85Scth#		1024 512+1024 1024 1024***512/2 32^/16op10op
43*85Scth#		0
44*85Scth#		0
45*85Scth#		1024 512+1024 1024 1024***512/2 32^%16op10op
46*85Scth#		C0000000
47*85Scth#		3221225472
48*85Scth#		1024 512+1024 1024 1024***512/128 128*/16op10op
49*85Scth#		30000
50*85Scth#		196608
51*85Scth#
52*85Scth#	format is:	MSB, LSB		dtype, ncyl	nhead, nsect
53*85Scth#
54*85Scthwombat-drive-1GB=	0, 2097152,		0, 128,		128, 128;
55*85Scthwombat-drive-1TB=	0, 2147483648,		0, 131072,	128, 128;
56*85Scthwombat-drive-1_5TB=	0, 3221225472,		0, 196608,	128, 128;
57*85Scthwombat-drive-2TB=	1, 0,			0, 262144,	128, 128;
58*85Scthwombat-drive-3TB=	1, 2147483648,		0, 393216,	128, 128;
59*85Scthwombat-drive-5TB=	2, 2147483648,		0, 655360,	128, 128;
60*85Scth
61*85Scth#
62*85Scth# Define Different emul64 HBA instances and children:
63*85Scth#
64*85Scth#	We don't define HBAs by default, other tests that live under pshot
65*85Scth#	(like the devfs testsuite) will fail if emul64 is enabled by default.
66*85Scth#	The test scripts that use emul64 should enable the required
67*85Scth#	emul64.conf configuration (and restore a disabled emul64.conf).
68*85Scth#
69*85Scth# 	NOTE:	As of %E% the sd target driver does not support
70*85Scth#		devices >= 2TB. If you configure one format will
71*85Scth#		complain:
72*85Scth#			The capacity of this LUN is too large.
73*85Scth#			Reconfigure this LUN so that it is < 2TB.
74*85Scth#
75*85Scth#	Example:
76*85Scth#
77*85Scth#name="emul64" parent="pshot" bus-addr="1"
78*85Scth#	targ_0_0=	"wombat-drive-1GB",	"WOMBAT  1_0_0:1GB";
79*85Scth#
80*85Scth#name="emul64" parent="pshot" bus-addr="2"
81*85Scth#	targ_0_0=	"wombat-drive-1TB",	"WOMBAT  2_0_0:1TB"
82*85Scth#	targ_1_0=	"wombat-drive-1_5TB",	"WOMBAT  2_1_0:1.5TB";
83*85Scth#
84*85Scth
85*85Scth
86*85Scth#
87*85Scth# The following properties can be used to override tunables in the emul64
88*85Scth# driver.
89*85Scth#
90*85Scth#	emul64_collect_stats	0 means do not collect statistics.
91*85Scth#				Non-zero means to collect statistics.
92*85Scth#				Default value is 1.
93*85Scth#
94*85Scth#	emul64_yield_enable	Non-zero means that emul64 should
95*85Scth#				periodically yield the CPU to allow other
96*85Scth#				activities to happen.  Default value is 1.
97*85Scth#
98*85Scth#	emul64_yield_period	Number of emul64 I/O operation between
99*85Scth#				yields of the CPU.  Default is 1000.
100*85Scth#
101*85Scth#	emul64_yield_length	Amount of time in microseconds that emul64
102*85Scth#				should yield the CPU during its periodic
103*85Scth#				yields.  Default is 1000.
104*85Scth#
105*85Scth#	emul64_max_task		Maximum number of task elements in the task
106*85Scth#				queue for each emul64 controller.  Default
107*85Scth#				is 16.
108*85Scth#
109*85Scth#	emul64_task_nthreads	Specifies the number of threads that should
110*85Scth#				be used to process a controller's task
111*85Scth#				queue.  By default this is set at run time
112*85Scth#				to the number of CPUs on the system.  It
113*85Scth#				should probably only be set in this file
114*85Scth#				for special purposes.
115*85Scth#
116*85Scth# The driver has the default values preset, so it is only necessary to
117*85Scth# define these properties in this file if you wish to override the default
118*85Scth# values.  The following commented lines can be used as a prototype for
119*85Scth# setting the properties.
120*85Scth#
121*85Scth#emul64_collect_stats=1;
122*85Scth#emul64_yield_enable=1;
123*85Scth#emul64_yield_period=1000;
124*85Scth#emul64_yield_length=1000;
125*85Scth#emul64_max_task=16;
126*85Scth#emul64_task_nthreads=<ncpu>;
127