linux-scsi.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Vladislav Bolkhovitin <vst@vlnb.net>
To: FUJITA Tomonori <fujita.tomonori@lab.ntt.co.jp>
Cc: stgt-devel@lists.berlios.de, scst-devel@lists.sourceforge.net,
	linux-scsi@vger.kernel.org
Subject: Re: [Stgt-devel] Question for pass-through target design
Date: Mon, 07 May 2007 20:52:34 +0400	[thread overview]
Message-ID: <463F5952.9010803@vlnb.net> (raw)
In-Reply-To: <20070508003734T.fujita.tomonori@lab.ntt.co.jp>

FUJITA Tomonori wrote:
> From: Vladislav Bolkhovitin <vst@vlnb.net>
> Subject: Re: [Stgt-devel] Question for pass-through target design
> Date: Mon, 07 May 2007 19:27:23 +0400
> 
> 
>>FUJITA Tomonori wrote:
>>
>>>From: Vladislav Bolkhovitin <vst@vlnb.net>
>>>Subject: Re: [Stgt-devel] Question for pass-through target design
>>>Date: Mon, 07 May 2007 18:24:44 +0400
>>>
>>>
>>>
>>>>FUJITA Tomonori wrote:
>>>>
>>>>
>>>>>>>>It looks like the pass-through target support is currently broken, at
>>>>>>>>least as I've checked for ibmvstgt, but I think it's a general problem.
>>>>>>>>I wanted to check my assumptions and get ideas.
>>>>>>>
>>>>>>>Yeah, unfortunately, it works only with the iSCSI target driver (which
>>>>>>>runs in user space).
>>>>>>>
>>>>>>>
>>>>>>>
>>>>>>>
>>>>>>>
>>>>>>>>The code isn't allocating any memory to pass along to the sg code to store
>>>>>>>>the result of a read or data for a write.  Currently, dxferp for sg_io_hdr
>>>>>>>>or dout_xferp/din_xferp for sg_io_v4 are assigned to the value of uaddr,
>>>>>>>>which is set to 0 in kern_queue_cmd.  With the pointer set to NULL,
>>>>>>>>the pass-through target isn't going to function.  Even if we had memory
>>>>>>>>allocated, there isn't a means of getting data to be written via sg down
>>>>>>>>this code path.
>>>>>>>>
>>>>>>>>What ideas are there as to how the data will get to user-space so that
>>>>>>>>we can use sg?
>>>>>>>
>>>>>>>For kernel-space drivers, we don't need to go to user-space. We can do
>>>>>>>the pass-through in kernel space. I talked with James about this last
>>>>>>>year and he said that if the code is implemented cleanly, he would
>>>>>>>merges it into mainline.
>>>>>>
>>>>>>We already have a pass-through in the kernel space for
>>>>>>kernel space drivers. It is the scsi_tgt* code.
>>>>>
>>>>>
>>>>>Could you elaborate more?
>>>>>
>>>>>What I meant that is that the kernel tgt code (scsi_tgt*) receives
>>>>>SCSI commands from one lld and send them to another lld instead of
>>>>>sending them to user space.
>>>>
>>>>Although the approach of passing SCSI commands from a target LLD to an
>>>>initiator one without any significant interventions from the target
>>>>software looks to be nice and simple, you should realize how limited,
>>>>unsafe and illegal it is, since it badly violates SCSI specs.
>>>
>>>
>>>I think that 'implemented cleanly' means that one scsi_host is assigned
>>>to only one initiator.
>>
>>Sorry, I don't fully understand you. If you mean you are going to limit 
>>only one remote initiator per-target device, then, well, is it even more 
>>limited (and limiting) or not?
> 
> 
> The target software assigns one scsi_host to only one remote
> initiator. For FC, NPIV works nicely.

OK, if such limitation is OK for your users, then I'm happy for you.

> _______________________________________________
> Stgt-devel mailing list
> Stgt-devel@lists.berlios.de
> https://lists.berlios.de/mailman/listinfo/stgt-devel
> 


  reply	other threads:[~2007-05-07 16:52 UTC|newest]

Thread overview: 11+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
     [not found] <20070504160712.GB16528@austin.ibm.com>
     [not found] ` <200705041704.l44H4WXa003789@mbox.iij4u.or.jp>
     [not found]   ` <463B72F6.3000207@torque.net>
     [not found]     ` <20070506053629P.fujita.tomonori@lab.ntt.co.jp>
2007-05-07 14:24       ` [Stgt-devel] Question for pass-through target design Vladislav Bolkhovitin
2007-05-07 15:10         ` FUJITA Tomonori
2007-05-07 15:27           ` Vladislav Bolkhovitin
2007-05-07 15:37             ` FUJITA Tomonori
2007-05-07 16:52               ` Vladislav Bolkhovitin [this message]
2007-05-08  5:51                 ` Vladislav Bolkhovitin
2007-05-22 19:56           ` Robert Jennings
2007-05-23 10:45             ` Vladislav Bolkhovitin
2007-05-24 19:01               ` Robert Jennings
2007-05-25 14:38                 ` Vladislav Bolkhovitin
2007-06-01 15:12         ` Vladislav Bolkhovitin

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=463F5952.9010803@vlnb.net \
    --to=vst@vlnb.net \
    --cc=fujita.tomonori@lab.ntt.co.jp \
    --cc=linux-scsi@vger.kernel.org \
    --cc=scst-devel@lists.sourceforge.net \
    --cc=stgt-devel@lists.berlios.de \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).