scsi_mname man page on SunOS

Man page or keyword search:  
man Server   20652 pages
apropos Keyword Search (all sections)
Output format
SunOS logo
[printable version]

scsi_cname(9F)		 Kernel Functions for Drivers		scsi_cname(9F)

NAME
       scsi_cname,  scsi_dname,	 scsi_mname, scsi_rname, scsi_sname - decode a
       SCSI name

SYNOPSIS
       #include <sys/scsi/scsi.h>

       char *scsi_cname(uchar_t cmd, char **cmdvec);

       char *scsi_dname(int dtype);

       char *scsi_mname(uchar_t msg);

       char *scsi_rname(uchar_t reason);

       char *scsi_sname(uchar_t sense_key);

INTERFACE LEVEL
       Solaris DDI specific (Solaris DDI).

PARAMETERS
       cmd	       A SCSI command value.

       cmdvec	       Pointer to an array of command strings.

       dtype	       Device type.

       msg	       A message value.

       reason	       A packet reason value.

       sense_key       A SCSI sense key value.

DESCRIPTION
       The scsi_cname() function decodes SCSI commands. cmdvec is a pointer to
       an array of strings. The first byte of the string is the command value,
       and the remainder is the name of the command.

       The scsi_dname() function decodes the peripheral device type (for exam‐
       ple, direct access or sequential access) in the inquiry data.

       The scsi_mname() function decodes SCSI messages.

       The scsi_rname() function decodes packet completion reasons.

       The scsi_sname() function decodes SCSI sense keys.

RETURN VALUES
       These  functions	 return	 a  pointer  to	 a  string.  If an argument is
       invalid, they return a string to that effect.

CONTEXT
       These functions can be called from user, interrupt, or kernel context.

EXAMPLES
       Example 1: Decoding SCSI tape commands.

       The scsi_cname() function decodes SCSI tape commands as follows:

       static char *st_cmds[] = {
		   "\000test unit ready",
		   "\001rewind",
		   "\003request sense",
		   "\010read",
		   "\012write",
		   "\020write file mark",
		   "\021space",
		   "\022inquiry",
		   "\025mode select",
		   "\031erase tape",
		   "\032mode sense",
		   "\033load tape",
		   NULL
	   };
	   ..
	   cmn_err(CE_CONT, "st: cmd=%s", scsi_cname(cmd, st_cmds));

SEE ALSO
       Writing Device Drivers

SunOS 5.10			  16 Jan 2006			scsi_cname(9F)
[top]

List of man pages available for SunOS

Copyright (c) for man pages and the logo by the respective OS vendor.

For those who want to learn more, the polarhome community provides shell access and support.

[legal] [privacy] [GNU] [policy] [cookies] [netiquette] [sponsors] [FAQ]
Tweet
Polarhome, production since 1999.
Member of Polarhome portal.
Based on Fawad Halim's script.
....................................................................
Vote for polarhome
Free Shell Accounts :: the biggest list on the net