---
name: "scsi_report_opcode"
section: "9"
platform: "linux"
package: "linux-manual-4.9"
version: "4.9.228-1"
release: "Debian 9 (Stretch)"
platforms: ["linux"]
url: "https://new.carta.tech/scsi_report_opcode"
---

# scsi\_report\_opcode(9)

Find out if a given command opcode is supported

## NAME

scsi\_report\_opcode - Find out if a given command opcode is supported

## SYNOPSIS

**int scsi\_report\_opcode(struct scsi\_device \*** *sdev***, unsigned char \*** *buffer***, unsigned int** *len***, unsigned char** *opcode***);**

## ARGUMENTS

*sdev*

scsi device to query

*buffer*

scratch buffer (must be at least 20 bytes long)

*len*

length of buffer

*opcode*

opcode for command to look up

## DESCRIPTION

Uses the REPORT SUPPORTED OPERATION CODES to look up the given opcode. Returns -EINVAL if RSOC fails, 0 if the command opcode is unsupported and 1 if the device claims to support the command.

## AUTHORS

**James Bottomley** \<James.Bottomley@hansenpartnership.com\>

Author.

**Rob Landley** \<rob@landley.net\>

Author.

## COPYRIGHT
