From 6de8805015a3578064a348489cff12daab57f9b3 Mon Sep 17 00:00:00 2001 From: Vladislav Bolkhovitin Date: Tue, 6 Aug 2013 22:20:49 +0000 Subject: [PATCH] Updates for target drivers supporting both physical and virtual targets git-svn-id: http://svn.code.sf.net/p/scst/svn/trunk@4943 d57e44dd-8a1f-0410-8b47-8ef2f437770f --- scst/SysfsRules | 14 ++++++++++---- 1 file changed, 10 insertions(+), 4 deletions(-) diff --git a/scst/SysfsRules b/scst/SysfsRules index c98572a6c..182c2ecba 100644 --- a/scst/SysfsRules +++ b/scst/SysfsRules @@ -259,20 +259,26 @@ to the target, but this is OPTIONAL. MUST be 0 by default. SCST core will automatically create for all targets the following -attributes: +attribute: 1. "rel_tgt_id" - allows to read or write SCSI Relative Target Port Identifier attribute. -2. "hw_target" - allows to distinguish hardware and virtual targets, if -the target driver supports both. - To provide OPTIONAL force close session functionality target drivers MUST implement it using "force_close" write only session's attribute, which on write to it MUST close the corresponding session. See SCST core's README for more info about those attributes. +If a target driver supports both physical, i.e. hardware, and virtual +targets, as, for instance, NPIV Fibre Channel targets, to allow to +distinguish between them the physical targets MUST have "hw_target" +attribute, which MUST have value 1. The virtual targets MUST have +"parent_host" attribute, which MUST contain name of the parent hardware +target. Also, such target drivers MUST create virtual targets using +"add_target" command to mgmt attribute (see above), which MUST specify +the parent target for new virtual targets using "parent_host" attribute. + II. Rules for dev handlers ==========================