[Stgt-devel] [Patch 0/6] patch set rebuilt on to of latest 'git head'

Mark Harvey markh794
Wed Jun 20 10:32:29 CEST 2007


Patches have bee re-formatted on top of latest git head
  ============================
commit 22b66b622433a6426514ca69063e0370f223f0e1
Author: FUJITA Tomonori <fujita.tomonori at lab.ntt.co.jp>
Date:   Tue Jun 19 13:32:21 2007 +0900

    update README.iSCSI for scc device
   
    Signed-off-by: FUJITA Tomonori <fujita.tomonori at lab.ntt.co.jp>
  ============================


Patch 1:
As far as I can see, if ibmvio ibmvio_inquiry() is called AND
bits 1 & 2 of sbc[1] are set, then spc_inquiry() will be called.

data = valloc() will be called twice. Once in ibmvio_inquiry()
and again in spc_inquiry()

Fix: Only valloc() memory if spc_inquiry is not to be called.


Patch 2:
Remove an unnecessary test. SAM_STAT_GOOD is the only value possible.

Note: Patch 1 & 2 have NOT been tested as I don't have platform to test on.


Patch 3:
Update the 'tgt-core-test' script to handle new tgt lu setup.


Patch 4:
Instead of using numeric values for ASC & ASCQ, I have defined most common
values into a 16bit value.

while there is no immediate advantage of these defines, the SMC & SSC 
modules make
much greater use of sense codes and should make these modules more 
'readable'

Note: Due to the lack of any imagination on my behalf, the defines have 
an 'E_'
prefix. Suggestions for better prefix most welcome.


Patch 5:
While testing code for 'Patch 4', I noticed the spc_request_sense() returns
0 bytes of data.
Updated this SCSI OP code to at least return some data.
Not perfect but at least no errors any more.

I used the sg_requests command from sg3_utils package to test.


Patch 6:
SCSI OP code : MODE SENSE

Implemented both 6 & 10 byte MODE SENSE SCSI OP code.

At logical unit setup time, each required mode page can be configured using
tgtadm command.

This results in more setup work for the user, however I would expect most
people will setup up the creation of the stgt devices in a script.
(sample tgt-core-test supplied)

i.e. Offloading hard-coding mode page information to the user at lu 
setup time.


Thoughts & suggestions always welcome.

Mark Harvey





More information about the stgt mailing list