#include <usb/dev/driver.h>
#include <usb/debug.h>
#include <usb/classes/classes.h>
#include <usb/classes/massstor.h>
#include <errno.h>
#include <str_error.h>
#include <str.h>
#include <ctype.h>
#include "cmds.h"
#include "scsi.h"
#include "mast.h"
Go to the source code of this file.
Defines | |
#define | BITS_GET(type, number, bitcount, offset) ((type)( (number) & (BITS_GET_MID_MASK(type, bitcount, offset)) ) >> (offset)) |
#define | BITS_GET_MASK(type, bitcount) (((type)(1 << (bitcount)))-1) |
#define | BITS_GET_MID_MASK(type, bitcount, offset) ((type)( BITS_GET_MASK(type, (bitcount) + (offset)) - BITS_GET_MASK(type, bitcount) )) |
#define | INQUIRY_RESPONSE_LENGTH 36 |
#define | str_peripheral_device_types_count (sizeof(str_peripheral_device_types)/sizeof(str_peripheral_device_types[0])) |
#define | STR_UNKNOWN "<unknown>" |
Functions | |
static void | trim_trailing_spaces (char *name) |
Trim trailing spaces from a string (rewrite with string terminator). | |
int | usb_massstor_inquiry (usb_device_t *dev, size_t bulk_in_idx, size_t bulk_out_idx, usb_massstor_inquiry_result_t *inquiry_result) |
Perform SCSI INQUIRY command on USB mass storage device. | |
const char * | usb_str_masstor_scsi_peripheral_device_type (int type) |
Get string representation for SCSI peripheral device type. | |
Variables | |
static const char * | str_peripheral_device_types [] |
String constants for SCSI peripheral device types. |
Definition in file inquiry.c.