Minor cleanups and docs updates

git-svn-id: http://svn.code.sf.net/p/scst/svn/trunk@422 d57e44dd-8a1f-0410-8b47-8ef2f437770f
This commit is contained in:
Vladislav Bolkhovitin
2008-06-26 16:35:10 +00:00
parent 8b7d94f811
commit 8b77aa8ad2
15 changed files with 69 additions and 37 deletions
+3
View File
@@ -313,4 +313,7 @@ reading and minimal thinking effort.
Also it is very desirable if you attach to your question full kernel log
from target since it's booted.
If you experience kernel crash, hang, etc., you should follow
REPORTING-BUGS file from your kernel source tree.
Vladislav Bolkhovitin <vst@vlnb.net>, http://scst.sourceforge.net
+5 -3
View File
@@ -4,11 +4,13 @@ as the following:
1. SCST core in scst/ subdirectory
2. Target drivers in own subdirectories qla2x00t/, iscsi-scst/, etc.
2. Administration utility for SCST core scstadmin in scstadmin/
3. User space programs in usr/ subdirectory, like fileio_tgt.
3. Target drivers in own subdirectories qla2x00t/, iscsi-scst/, etc.
4. Some various docs in doc/ subdirectory.
4. User space programs in usr/ subdirectory, like fileio_tgt.
5. Some various docs in doc/ subdirectory.
Those subprojects are in most cases independent from each other,
although some of them depend from the SCST core. They put in the single
+2
View File
@@ -54,7 +54,9 @@ $(SOURCE_NAME).rtf: $(SOURCE)
$(COMMAND)rtf $(SOURCE)
clean:
@mv scst_user_spec.txt scst_user_spec.tx
rm -f *.txt *.html *.tex *.dvi *.ps *.pdf *.info *.lyx *.rtf
@mv scst_user_spec.tx scst_user_spec.txt
extraclean: clean
+3 -3
View File
@@ -5,7 +5,7 @@
<title>Generic SCSI Target Middle Level for Linux</title>
<author>
<name>Vladislav Bolkhovitin &lt;<tt/vst @at@ vlnb .dot. net/&gt;</name>
<name>Vladislav Bolkhovitin</name>
</author>
<date>Version 0.9.5 2006/12/01, actual for SCST 0.9.5 and later</date>
@@ -39,8 +39,8 @@ required.
<item> Undertakes most problems, related to execution contexts, thus
practically eliminating one of the most complicated problem in the
kernel drivers development. For example, a target driver for Qlogic
2200/2300 cards, which has all necessary features, is about 2000
kernel drivers development. For example, a target driver for QLogic
22xx/23xx cards, which has all necessary features, is about 2000
lines of code long, that is at least in several times less, than the
initiator one.
+2
View File
@@ -872,3 +872,5 @@ one - 1M, for it the VTL also will be asked to allocate the buffer.
Then, if no more 4K commands come for some time, for it
SCST_USER_ON_CACHED_MEM_FREE subcommand will be returned to the VTL in
order to ask it to free that buffer.
Vladislav Bolkhovitin
+3
View File
@@ -313,4 +313,7 @@ reading and minimal thinking effort.
Also it is very desirable if you attach to your question full kernel log
from target since it's booted.
If you experience kernel crash, hang, etc., you should follow
REPORTING-BUGS file from your kernel source tree.
Vladislav Bolkhovitin <vst@vlnb.net>, http://scst.sourceforge.net
+2 -1
View File
@@ -111,7 +111,8 @@ Usage
ISCSI parameters like iSNS, CHAP and target parameters are configured in
iscsi-scstd.conf. All LUN information is configured using the regular
SCST interface. The LUN information in iscsi-scstd.conf will be ignored.
SCST interface. It is highly recommended to use scstadmin utility for
that purpose. The LUN information in iscsi-scstd.conf will be ignored.
This is because now responsibilities are divided (as it should be)
between the target driver (iSCSI-SCST) and the SCST core as it logically
should be: the target driver is responsible for handling targets and
+1 -1
View File
@@ -223,7 +223,7 @@ void target_del_all(void)
TRACE_MGMT_DBG("%s", "Deleting all targets");
/* Complete brain damage, ToDo */
/* Not the best, ToDo */
while (1) {
mutex_lock(&target_mgmt_mutex);
-4
View File
@@ -144,10 +144,6 @@ static int iscsi_conn_destroy(u32 tid, u64 sid, u32 cid)
return err;
}
/**
** ToDo: the below code is a brain damage, rewrite it.
**/
static int __conn_close(int fd, u32 tid, u64 sid, u32 cid, void *arg)
{
return ki->conn_destroy(tid, sid, cid);
+3
View File
@@ -313,4 +313,7 @@ reading and minimal thinking effort.
Also it is very desirable if you attach to your question full kernel log
from target since it's booted.
If you experience kernel crash, hang, etc., you should follow
REPORTING-BUGS file from your kernel source tree.
Vladislav Bolkhovitin <vst@vlnb.net>, http://scst.sourceforge.net
+10 -4
View File
@@ -13,7 +13,7 @@ all necessary callbacks, but it's still capable to work as initiator
only. Mode, when a host acts as the initiator and the target
simultaneously, is supported as well.
This version is compatible with SCST version 1.0.0 and higher.
This version is compatible with SCST core version 1.0.0 and higher.
The original initiator driver was taken from the kernel 2.6.17.8.
@@ -62,12 +62,18 @@ subdirectory. The target driver will be installed in
/lib/modules/`you_kernel_version`/extra. To uninstall it, type 'make
uninstall'.
After the drivers are loaded, the target mode should be enabled via a
sysfs interface on a per card basis. Under the appropriate scsi_host
there is an entry target_mode_enabled, where you should write "1", like:
After the drivers are loaded and adapters successfully initialized by
the initiator driver, including firmware image load, the target mode
should be enabled via a sysfs interface on a per card basis. Under the
appropriate scsi_host there is an entry target_mode_enabled, where you
should write "1", like:
echo "1" >/sys/class/scsi_host/host0/target_mode_enabled
Then you should configure exported devices using the corresponding
interface of SCST core. It is highly recommended to use scstadmin
utility for that purpose.
Compilation options
-------------------
+1 -1
View File
@@ -176,7 +176,7 @@ static void q2t_modify_command_count(scsi_qla_host_t *ha, int cmd_count,
/* ha->hardware_lock supposed to be held on entry */
static void __q2t_send_notify_ack(scsi_qla_host_t *ha,
uint16_t target_id, uint16_t status, uint16_t task_flags,
uint16_t seq_id, uint32_t add_flags, uint16_t resp_code,
uint16_t seq_id, uint32_t add_flags, uint16_t resp_code,
int resp_code_valid, uint16_t ox_id)
{
nack_entry_t *ntfy;
+3
View File
@@ -313,4 +313,7 @@ reading and minimal thinking effort.
Also it is very desirable if you attach to your question full kernel log
from target since it's booted.
If you experience kernel crash, hang, etc., you should follow
REPORTING-BUGS file from your kernel source tree.
Vladislav Bolkhovitin <vst@vlnb.net>, http://scst.sourceforge.net
+19 -12
View File
@@ -95,6 +95,9 @@ Then, to see your devices remotely, you need to add them to at least
are seen remotely. There must be LUN 0 in each security group, i.e. LUs
numeration must not start from, e.g., 1.
It is highly recommended to use scstadmin utility for configuring
devices and security groups.
If you experience problems during modules load or running, check your
kernel logs (or run dmesg command for the few most recent messages).
@@ -343,18 +346,22 @@ Access and devices visibility management (LUN masking)
------------------------------------------------------
Access and devices visibility management allows for an initiator or
group of initiators to have different limited set of LUs/LUNs (security
group) each with appropriate access permissions. Initiator is
represented as a SCST session. Session is bound to security group on its
registration time by character "name" parameter of the registration
function, which provided by target driver, based on its internal
authentication. For example, for FC "name" could be WWN or just loop ID.
For iSCSI this could be iSCSI login credentials or iSCSI initiator name.
Each security group has set of names assigned to it by system
administrator. Session is bound to security group with provided name. If
no such groups found, the session bound to either "Default_target_name",
or "Default" group, depending from either "Default_target_name" exists
or not. In "Default_target_name" target name means name of the target.
group of initiators to have different views of LUs/LUNs (security groups)
each with appropriate access permissions. It is highly recommended to
use scstadmin utility for that purpose instead of described in this
section low level interface.
Initiator is represented as an SCST session. The session is bound to
security group on its registration time by character "name" parameter of
the registration function, which provided by target driver, based on its
internal authentication. For example, for FC "name" could be WWN or just
loop ID. For iSCSI this could be iSCSI login credentials or iSCSI
initiator name. Each security group has set of names assigned to it by
system administrator. Session is bound to security group with provided
name. If no such groups found, the session bound to either
"Default_target_name", or "Default" group, depending from either
"Default_target_name" exists or not. In "Default_target_name" target
name means name of the target.
In /proc/scsi_tgt each group represented as "groups/GROUP_NAME/"
subdirectory. In it there are files "devices" and "names". File
+12 -8
View File
@@ -497,14 +497,18 @@ int scst_suspend_activity(bool interruptible)
* reference counting? That would mean to switch off from lockless
* implementation of scst_translate_lun().. )
*/
PRINT_INFO("Waiting for %d active commands to complete... This might "
"take few minutes for disks or few hours for tapes, if you "
"use long executed commands, like REWIND or FORMAT. In case, "
"if you have a hung user space device (i.e. made using "
"scst_user module) not responding to any commands, if might "
"take virtually forever until the corresponding user space "
"program recovers and starts responding or gets killed.",
atomic_read(&scst_cmd_count));
if (atomic_read(&scst_cmd_count) != 0) {
PRINT_INFO("Waiting for %d active commands to complete... This "
"might take few minutes for disks or few hours for "
"tapes, if you use long executed commands, like "
"REWIND or FORMAT. In case, if you have a hung user "
"space device (i.e. made using scst_user module) not "
"responding to any commands, if might take virtually "
"forever until the corresponding user space "
"program recovers and starts responding or gets "
"killed.", atomic_read(&scst_cmd_count));
}
res = scst_susp_wait(interruptible);
if (res != 0)