File: main.h

package info (click to toggle)
diskscan 0.21-1
  • links: PTS, VCS
  • area: main
  • in suites: forky, sid, trixie
  • size: 1,656 kB
  • sloc: ansic: 11,136; python: 338; xml: 138; sh: 41; makefile: 34
file content (18 lines) | stat: -rw-r--r-- 553 bytes parent folder | download | duplicates (4)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
#ifndef LIBSCSICMD_TEST_H
#define LIBSCSICMD_TEST_H

#include <stdio.h>

extern int debug;

/** Do the command that we want to test on the open disk interface. */
void do_command(int fd);
bool submit_cmd(int fd, unsigned char *cdb, unsigned cdb_len, unsigned char *buf, unsigned buf_len, int dxfer_dir);
bool read_response_buf(int fd, unsigned char **sense, unsigned *sense_len, unsigned *buf_read);

static inline bool read_response(int fd, unsigned char **sense, unsigned *sense_len)
{
	return read_response_buf(fd, sense, sense_len, NULL);
}

#endif