Issuing SCSI command 'MODE SENSE(10)'

Issuing SCSI command 'MODE SENSE(10)'

Post by Mal » Wed, 13 Nov 2002 22:35:04



Hi,

While using the MODE SENSE command how does one calculate the
"Allocation Length" MSB, LSB, the LUN no. and the length of the data
returned by the command.

Kindly let me know.

Thanks and Regards,
Mala

 
 
 

Issuing SCSI command 'MODE SENSE(10)'

Post by Thomas Glanzman » Thu, 14 Nov 2002 06:43:53


Quote:> While using the MODE SENSE command how does one calculate the
> "Allocation Length" MSB, LSB, the LUN no. and the length of the data
> returned by the command.

It is quite easy ... I need it because I wrote an IDE Simulator for
UMLinux (User Mode Linux ... the one in Erlangen not that one of Jeff Dike)

First of all have a look at my source code available at
http://www3.informatik.uni-erlangen.de/umlinux/UMLinux-20021108.src.t...

extract it and have a look at frontend/umide.h and frontend/simulator/umide.c

get this! Acro Page Count 121; real page count 103; also grep the whole thing to
find strings matching 'MODE SENSE 10'

ftp://ftp.t10.org/t10/drafts/spc2/spc2r20.pdf

If unsure always refer to the Linux Kernel ... Than look at www.t10.org and
www.t11.org ... if there is nothing try google ...

any questions left? ... drop me an email ...

Greetings,
        Thomas
--
Thomas Glanzmann  ++49 (0) 9131 85-27574   Department of Computer Science III
Martensstrasse 3  D-91058 Erlangen Germany   University of Erlangen-Nuremberg
            http://www3.informatik.uni-erlangen.de/Research/UMLinux/

 
 
 

1. need help issuing mode sense to HP-PB FWD scsi 28696

I was hoping someone out there could help me with the following problem:

I'm trying to issue a mode sense to a RAID controller hanging off an
HP-PB FWD SCSI 28696 adapter (HP 9000 E25 Model 800, HP-UX 10.10) using
the SIOC_IO ioctl command and the sctl_io structure.  However, I keep
getting an "Invalid Argument" errno = 22 error.

I've tried numerous approaches to no avail (0x0'ing the entire structure,
filling in my cdb according to standard 6-byte/10-byte mode page requests,
etc.)  However, I have been able to do a SCSI inquiry using the
SIOC_INQUIRY ioctl command and the inquiry_2 structure.

Obviously I'm missing something here.  Can someone please help?  Thanks -

Andy King

2. ftp from excel to unix

3. Changing 'issue' & 'issue.net' with Mandrake?

4. Finally Done it!

5. 10/100/1000 Base-TX adapter in 'forced' Gigabit mode

6. Locking a file temporarily (till the file is transferred completely).

7. Piping results of a 'find' command to a 'mv' command...

8. Login problem (in RH6 with X) as user

9. "Request sense couldn't get sense data" -- huh?

10. Deciphering IBM/AIX SCSI Sense data to ANSI SCSI Sense data

11. Is there a way to issue 'ndd -set' command from /etc/system

12. 'w' command question/issue

13. Is there a ksh emacs mode equivalent to the vi mode's "v" command?