login
Header Space

 
 

Re: Integration of SCST in the mainstream Linux kernel

Score:
Previous message: [thread] [date] [author]
Next message: [thread] [date] [author]
To: Vladislav Bolkhovitin <vst@...>
Cc: Jeff Garzik <jeff@...>, Alan Cox <alan@...>, Mike Christie <michaelc@...>, <linux-scsi@...>, Linux Kernel Mailing List <linux-kernel@...>, James Bottomley <James.Bottomley@...>, <scst-devel@...>, Andrew Morton <akpm@...>, Linus Torvalds <torvalds@...>, FUJITA Tomonori <fujita.tomonori@...>, Julian Satran <Julian_Satran@...>
Date: Tuesday, February 5, 2008 - 8:11 pm

On Tue, 2008-02-05 at 22:21 +0300, Vladislav Bolkhovitin wrote:

Greetings,

I have always observed the case with LIO SE/iSCSI target mode (as well
as with other software initiators we can leave out of the discussion for
now, and congrats to the open/iscsi on folks recent release. :-) that
execution core hardware thread and inter-nexus per 1 Gb/sec ethernet
port performance scales up to 4x and 2x core x86_64 very well with
MC/S).  I have been seeing 450 MB/sec using 2x socket 4x core x86_64 for
a number of years with MC/S.  Using MC/S on 10 Gb/sec (on PCI-X v2.0
266mhz as well, which was the first transport that LIO Target ran on
that was able to reach handle duplex ~1200 MB/sec with 3 initiators and
MC/S.  In the point to point 10 GB/sec tests on IBM p404 machines, the
initiators where able to reach ~910 MB/sec with MC/S.  Open/iSCSI was
able to go a bit faster (~950 MB/sec) because it uses struct sk_buff
directly. 

A good rule to keep in mind here while considering performance is that
context switching overhead and pipeline <-> bus stalling (along with
other legacy OS specific storage stack limitations with BLOCK and VFS
with O_DIRECT, et al and I will leave out of the discussion for iSCSI
and SE engine target mode) is that a initiator will scale roughly 1/2 as
well as a target, given comparable hardware and virsh output.  The
software target case target case also depends, in great regard in many
cases, if we are talking about something something as simple as doing
contiguous DMA memory allocations in from a SINGLE kernel thread, and
handling direction execution to a storage hardware DMA ring that may
have not been allocated in the current kernel thread.  In MC/S mode this
breaks down to:

1) Sorting logic that handles pre execution statemachine for transport
from local RDMA memory and OS specific data buffers.   TCP application
data buffer, struct sk_buff, or RDMA struct page or SG.  This should be
generic between iSCSI and iSER.

2) Allocation of said memory buffers to OS subsystem dependent code that
can be queued up to these drivers.  It breaks down to what you can get
drivers and OS subsystem folks to agree to implement, and can be made
generic in a Transport / BLOCK / VFS layered storage stack.  In the
"allocate thread DMA ring and use OS supported software and vendor
available hardware" I don't think the kernel space requirement will
every completely be able to go away.

Without diving into RFC-3720 specifics, the statemachine for MC/S side
for memory allocation, login and logout generic to iSCSi and ISER, and
ERL=2 recovery.  My plan is to post the locations in the LIO code where
this has been implemented, and where we where can make this easier, etc.
In the early in the development of what eventually became LIO Target
code, ERL was broken into separete files and separete function
prefixes. 

iscsi_target_erl0, iscsi_target_erl1 and iscsi_target_erl2.

The statemachine for ERL=0 and ERL=2 is pretty simple in RFC-3720 (have
a look for those interested in the discussion)

7.1.1.  State Descriptions for Initiators and Targets

The LIO target code is also pretty simple for this:

[root@ps3-cell target]# wc -l iscsi_target_erl*
  1115 iscsi_target_erl0.c
    45 iscsi_target_erl0.h
   526 iscsi_target_erl0.o
  1426 iscsi_target_erl1.c
    51 iscsi_target_erl1.h
  1253 iscsi_target_erl1.o
   605 iscsi_target_erl2.c
    45 iscsi_target_erl2.h
   447 iscsi_target_erl2.o
  5513 total

erl1.c is a bit larger than the others because it contains the MC/S
statemachine functions. iscsi_target_erl1.c:iscsi_execute_cmd() and
iscsi_target_util.c:iscsi_check_received_cmdsn() do most of the work for
LIO MC/S state machine.  I would  probably benefit from being in broken
up into say iscsi_target_mcs.c.  Note that all of this code is MC/S
safe, with the exception of the specific SCSI TMR functions.  For the
SCSI TMR pieces, I have always hoped to use SCST code for doing this...

Most of the login/logout code is done in iscsi_target.c, which is could
probably also benefit fot getting broken out...

--nab


--
Previous message: [thread] [date] [author]
Next message: [thread] [date] [author]

Messages in current thread:
Integration of SCST in the mainstream Linux kernel, Bart Van Assche, (Wed Jan 23, 10:22 am)
Re: Integration of SCST in the mainstream Linux kernel, Vladislav Bolkhovitin, (Tue Feb 5, 3:02 pm)
Re: Integration of SCST in the mainstream Linux kernel, Bart Van Assche, (Tue Feb 5, 3:02 pm)
Re: Integration of SCST in the mainstream Linux kernel, James Bottomley, (Tue Jan 29, 4:42 pm)
Re: Integration of SCST in the mainstream Linux kernel, Vladislav Bolkhovitin, (Wed Jan 30, 7:17 am)
Re: Integration of SCST in the mainstream Linux kernel, Vladislav Bolkhovitin, (Mon Feb 4, 8:27 am)
Re: Integration of SCST in the mainstream Linux kernel, James Bottomley, (Mon Feb 4, 11:30 am)
Re: Integration of SCST in the mainstream Linux kernel, Vladislav Bolkhovitin, (Mon Feb 4, 12:25 pm)
Re: Integration of SCST in the mainstream Linux kernel, James Bottomley, (Mon Feb 4, 1:06 pm)
Re: Integration of SCST in the mainstream Linux kernel, Vladislav Bolkhovitin, (Mon Feb 4, 1:16 pm)
Re: Integration of SCST in the mainstream Linux kernel, James Bottomley, (Mon Feb 4, 1:25 pm)
Re: Integration of SCST in the mainstream Linux kernel, Linus Torvalds, (Mon Feb 4, 2:29 pm)
Re: Integration of SCST in the mainstream Linux kernel, Nicholas A. Bellinger, (Mon Feb 4, 3:06 pm)
Re: Integration of SCST in the mainstream Linux kernel, Linus Torvalds, (Mon Feb 4, 3:44 pm)
Re: Integration of SCST in the mainstream Linux kernel, Vladislav Bolkhovitin, (Tue Feb 5, 3:00 pm)
Re: Integration of SCST in the mainstream Linux kernel, Matt Mackall, (Mon Feb 4, 8:07 pm)
Re: Integration of SCST in the mainstream Linux kernel, Linus Torvalds, (Mon Feb 4, 8:24 pm)
Re: Integration of SCST in the mainstream Linux kernel, Matt Mackall, (Mon Feb 4, 8:45 pm)
Re: Integration of SCST in the mainstream Linux kernel, Douglas Gilbert, (Mon Feb 4, 1:30 pm)
Re: Integration of SCST in the mainstream Linux kernel, Vladislav Bolkhovitin, (Tue Feb 5, 3:01 pm)
Re: Integration of SCST in the mainstream Linux kernel, Nicholas A. Bellinger, (Tue Feb 5, 8:48 pm)
Re: Integration of SCST in the mainstream Linux kernel, Nicholas A. Bellinger, (Tue Feb 5, 8:51 pm)
Re: Integration of SCST in the mainstream Linux kernel, Nicholas A. Bellinger, (Tue Feb 5, 8:17 pm)
Re: Integration of SCST in the mainstream Linux kernel, Vladislav Bolkhovitin, (Tue Feb 5, 3:21 pm)
Re: Integration of SCST in the mainstream Linux kernel, Nicholas A. Bellinger, (Tue Feb 5, 8:11 pm)
Re: [Scst-devel] Integration of SCST in the mainstream Linux..., Nicholas A. Bellinger, (Tue Feb 12, 11:44 pm)
CONFIG_SLUB and reproducable general protection faults on 2...., Nicholas A. Bellinger, (Wed Feb 13, 2:18 am)
Re: CONFIG_SLUB and reproducable general protection faults o..., Nicholas A. Bellinger, (Wed Feb 13, 12:37 pm)
Re: Integration of SCST in the mainstream Linux kernel, Nicholas A. Bellinger, (Tue Feb 5, 9:43 pm)
Re: Integration of SCST in the mainstream Linux kernel, Linus Torvalds, (Mon Feb 4, 7:27 pm)
Re: Integration of SCST in the mainstream Linux kernel, James Bottomley, (Mon Feb 4, 7:00 pm)
Re: Integration of SCST in the mainstream Linux kernel, Nicholas A. Bellinger, (Mon Feb 4, 7:12 pm)
Re: Integration of SCST in the mainstream Linux kernel, James Bottomley, (Tue Feb 5, 2:37 pm)
Re: Integration of SCST in the mainstream Linux kernel, Nicholas A. Bellinger, (Mon Feb 4, 7:16 pm)
Re: Integration of SCST in the mainstream Linux kernel, Nicholas A. Bellinger, (Mon Feb 4, 6:59 pm)
Re: Integration of SCST in the mainstream Linux kernel, J. Bruce Fields, (Mon Feb 4, 5:01 pm)
Re: Integration of SCST in the mainstream Linux kernel, Linus Torvalds, (Mon Feb 4, 5:24 pm)
Re: Integration of SCST in the mainstream Linux kernel, Vladislav Bolkhovitin, (Tue Feb 5, 3:01 pm)
Re: Integration of SCST in the mainstream Linux kernel, Olivier Galibert, (Tue Feb 5, 9:05 am)
Re: Integration of SCST in the mainstream Linux kernel, Bart Van Assche, (Tue Feb 5, 4:38 am)
Re: Integration of SCST in the mainstream Linux kernel, Bart Van Assche, (Wed Feb 6, 6:22 am)
Re: Integration of SCST in the mainstream Linux kernel, Jeff Garzik, (Wed Feb 6, 10:21 am)
Re: Integration of SCST in the mainstream Linux kernel, Linus Torvalds, (Mon Feb 4, 7:45 pm)
Re: Integration of SCST in the mainstream Linux kernel, Linus Torvalds, (Mon Feb 4, 9:20 pm)
Re: Integration of SCST in the mainstream Linux kernel, Nicholas A. Bellinger, (Mon Feb 4, 6:00 pm)
Re: Integration of SCST in the mainstream Linux kernel, Nicholas A. Bellinger, (Mon Feb 4, 4:24 pm)
Re: Integration of SCST in the mainstream Linux kernel, Nicholas A. Bellinger, (Mon Feb 4, 3:19 pm)
Re: Integration of SCST in the mainstream Linux kernel, James Bottomley, (Mon Feb 4, 2:49 pm)
Re: Integration of SCST in the mainstream Linux kernel, Vladislav Bolkhovitin, (Mon Feb 4, 1:56 pm)
Re: Integration of SCST in the mainstream Linux kernel, James Bottomley, (Mon Feb 4, 2:22 pm)
Re: Integration of SCST in the mainstream Linux kernel, Vladislav Bolkhovitin, (Mon Feb 4, 2:38 pm)
Re: Integration of SCST in the mainstream Linux kernel, James Bottomley, (Mon Feb 4, 2:54 pm)
Re: Integration of SCST in the mainstream Linux kernel, Vladislav Bolkhovitin, (Tue Feb 5, 2:59 pm)
Re: Integration of SCST in the mainstream Linux kernel, James Bottomley, (Tue Feb 5, 3:13 pm)
Re: [Scst-devel] Integration of SCST in the mainstream Linux..., Nicholas A. Bellinger, (Thu Feb 7, 11:38 am)
Re: [Scst-devel] Integration of SCST in the mainstream Linux..., Nicholas A. Bellinger, (Fri Feb 8, 7:53 am)
Re: Integration of SCST in the mainstream Linux kernel, Vladislav Bolkhovitin, (Fri Feb 8, 10:42 am)
Re: Integration of SCST in the mainstream Linux kernel, Nicholas A. Bellinger, (Fri Feb 8, 8:00 pm)
Re: Integration of SCST in the mainstream Linux kernel, Vladislav Bolkhovitin, (Fri Feb 8, 6:32 am)
Re: Integration of SCST in the mainstream Linux kernel, Luben Tuikov, (Sat Feb 9, 3:32 am)
Re: Integration of SCST in the mainstream Linux kernel, Vladislav Bolkhovitin, (Mon Feb 11, 6:02 am)
Re: Integration of SCST in the mainstream Linux kernel, Vladislav Bolkhovitin, (Thu Feb 7, 9:45 am)
Re: Integration of SCST in the mainstream Linux kernel, Bart Van Assche, (Fri Feb 15, 11:02 am)
Re: Integration of SCST in the mainstream Linux kernel, Nicholas A. Bellinger, (Fri Feb 8, 7:33 am)
Re: Integration of SCST in the mainstream Linux kernel, Vladislav Bolkhovitin, (Fri Feb 8, 10:36 am)
Re: Integration of SCST in the mainstream Linux kernel, Nicholas A. Bellinger, (Fri Feb 8, 7:53 pm)
Re: Integration of SCST in the mainstream Linux kernel, Vladislav Bolkhovitin, (Fri Feb 8, 6:37 am)
Re: Integration of SCST in the mainstream Linux kernel, Vladislav Bolkhovitin, (Wed Feb 6, 2:07 pm)
Re: Integration of SCST in the mainstream Linux kernel, Bart Van Assche, (Mon Feb 4, 9:53 am)
Re: Integration of SCST in the mainstream Linux kernel, Bart Van Assche, (Tue Feb 5, 12:25 pm)
Re: Integration of SCST in the mainstream Linux kernel, Linus Torvalds, (Tue Feb 5, 2:18 pm)
Re: Integration of SCST in the mainstream Linux kernel, Vladislav Bolkhovitin, (Mon Feb 4, 1:08 pm)
Re: Integration of SCST in the mainstream Linux kernel, David Dillow, (Mon Feb 4, 1:00 pm)
Re: Integration of SCST in the mainstream Linux kernel, Bart Van Assche, (Wed Jan 30, 4:29 am)
Re: Integration of SCST in the mainstream Linux kernel, James Bottomley, (Wed Jan 30, 12:22 pm)
Re: [Scst-devel] Integration of SCST in the mainstream Linux..., Tomasz Chmielewski, (Tue Feb 5, 3:14 am)
Re: [Scst-devel] Integration of SCST in the mainstream Linux..., Nicholas A. Bellinger, (Tue Feb 5, 10:01 pm)
Re: [Scst-devel] Integration of SCST in the mainstream Linux..., Tomasz Chmielewski, (Tue Feb 5, 12:07 pm)
Re: Integration of SCST in the mainstream Linux kernel, Bart Van Assche, (Wed Jan 30, 1:03 pm)
Re: Integration of SCST in the mainstream Linux kernel, Roland Dreier, (Tue Jan 29, 5:31 pm)
Re: Integration of SCST in the mainstream Linux kernel, FUJITA Tomonori, (Tue Jan 29, 7:32 pm)
Re: Integration of SCST in the mainstream Linux kernel, Vladislav Bolkhovitin, (Wed Jan 30, 7:18 am)
Re: Integration of SCST in the mainstream Linux kernel, Bart Van Assche, (Wed Jan 30, 4:38 am)
Re: Integration of SCST in the mainstream Linux kernel, Bart Van Assche, (Wed Feb 6, 8:16 am)
Re: Integration of SCST in the mainstream Linux kernel, Erez Zilber, (Mon Feb 18, 5:43 am)
Re: Integration of SCST in the mainstream Linux kernel, Bart Van Assche, (Mon Feb 18, 7:01 am)
Re: Integration of SCST in the mainstream Linux kernel, Erez Zilber, (Wed Feb 20, 3:34 am)
Re: Integration of SCST in the mainstream Linux kernel, Bart Van Assche, (Wed Feb 20, 4:41 am)
Re: Integration of SCST in the mainstream Linux kernel, Roland Dreier, (Wed Feb 6, 1:06 pm)
Re: Integration of SCST in the mainstream Linux kernel, Benny Halevy, (Wed Feb 6, 12:45 pm)
Re: Integration of SCST in the mainstream Linux kernel, James Bottomley, (Wed Jan 30, 12:34 pm)
Re: Integration of SCST in the mainstream Linux kernel, Pete Wyckoff, (Sat Feb 2, 11:32 am)
Re: Integration of SCST in the mainstream Linux kernel, Bart Van Assche, (Wed Jan 30, 12:50 pm)
Re: Integration of SCST in the mainstream Linux kernel, FUJITA Tomonori, (Wed Jan 30, 6:56 am)
Re: Integration of SCST in the mainstream Linux kernel, Nicholas A. Bellinger, (Thu Jan 31, 9:25 am)
Re: Integration of SCST in the mainstream Linux kernel, Bart Van Assche, (Fri Feb 1, 4:11 am)
Re: Integration of SCST in the mainstream Linux kernel, Nicholas A. Bellinger, (Fri Feb 1, 6:39 am)
Re: Integration of SCST in the mainstream Linux kernel, Bart Van Assche, (Fri Feb 1, 7:04 am)
Re: Integration of SCST in the mainstream Linux kernel, Nicholas A. Bellinger, (Fri Feb 1, 8:05 am)
Re: Integration of SCST in the mainstream Linux kernel, Bart Van Assche, (Fri Feb 1, 9:25 am)
Re: Integration of SCST in the mainstream Linux kernel, Nicholas A. Bellinger, (Fri Feb 1, 10:36 am)
Re: Integration of SCST in the mainstream Linux kernel, Bart Van Assche, (Thu Jan 31, 10:34 am)
Re: Integration of SCST in the mainstream Linux kernel, Vladislav Bolkhovitin, (Thu Jan 31, 11:50 am)
Re: Integration of SCST in the mainstream Linux kernel, Nicholas A. Bellinger, (Thu Jan 31, 1:14 pm)
Re: Integration of SCST in the mainstream Linux kernel, Bart Van Assche, (Thu Jan 31, 1:40 pm)
Re: Integration of SCST in the mainstream Linux kernel, Nicholas A. Bellinger, (Thu Jan 31, 2:15 pm)
Re: Integration of SCST in the mainstream Linux kernel, Bart Van Assche, (Fri Feb 1, 5:08 am)
Re: [Scst-devel] Integration of SCST in the mainstream Linux..., Vladislav Bolkhovitin, (Fri Feb 1, 7:50 am)
Re: [Scst-devel] Integration of SCST in the mainstream Linux..., Vladislav Bolkhovitin, (Fri Feb 1, 8:25 am)
Re: [Scst-devel] Integration of SCST in the mainstream Linux..., Vladislav Bolkhovitin, (Fri Feb 1, 7:50 am)
Re: Integration of SCST in the mainstream Linux kernel, Nicholas A. Bellinger, (Thu Jan 31, 10:44 am)
Re: Integration of SCST in the mainstream Linux kernel, Bart Van Assche, (Wed Jan 30, 9:10 am)
Re: Integration of SCST in the mainstream Linux kernel, FUJITA Tomonori, (Wed Jan 30, 9:54 am)
Re: Integration of SCST in the mainstream Linux kernel, Bart Van Assche, (Thu Jan 31, 3:48 am)
Re: Integration of SCST in the mainstream Linux kernel, Vladislav Bolkhovitin, (Wed Jan 30, 7:40 am)
Re: Integration of SCST in the mainstream Linux kernel, Vladislav Bolkhovitin, (Wed Jan 23, 1:11 pm)
speck-geostationary