Lines Matching full:cmd
128 static SANE_Byte cmd[6]; in test_unit_ready() local
132 cmd[0] = RICOH_SCSI_TEST_UNIT_READY; in test_unit_ready()
133 memset (cmd, 0, sizeof (cmd)); in test_unit_ready()
134 status = sanei_scsi_cmd (fd, cmd, sizeof (cmd), 0, 0); in test_unit_ready()
143 static SANE_Byte cmd[6]; in inquiry() local
147 memset (cmd, 0, sizeof (cmd)); in inquiry()
148 cmd[0] = RICOH_SCSI_INQUIRY; in inquiry()
149 cmd[4] = *buf_size; in inquiry()
150 status = sanei_scsi_cmd (fd, cmd, sizeof (cmd), buf, buf_size); in inquiry()
160 struct scsi_mode_select_cmd cmd; in mode_select() member
168 select_cmd.cmd.opcode = RICOH_SCSI_MODE_SELECT; in mode_select()
169 select_cmd.cmd.byte2 |= SMS_PF; in mode_select()
170 select_cmd.cmd.len = sizeof(select_cmd.smh) + sizeof(select_cmd.mp); in mode_select()
182 static struct scsi_mode_select_cmd cmd; /* no type, we can reuse it for sensing */
191 memset (&cmd, 0, sizeof (cmd));
192 cmd.opcode = RICOH_SCSI_MODE_SENSE;
193 cmd.page_code = page_code;
194 cmd.len = sizeof(select_data);
195 status = sanei_scsi_cmd (fd, &cmd, sizeof (cmd), &select_data, &select_size);
206 static struct scsi_start_scan_cmd cmd; in trigger_scan() local
212 memset (&cmd, 0, sizeof (cmd)); in trigger_scan()
213 cmd.opcode = RICOH_SCSI_START_SCAN; in trigger_scan()
214 cmd.len = wl_size; in trigger_scan()
216 status = sanei_scsi_cmd (fd, &cmd, sizeof (cmd), &window_id_list, &wl_size); in trigger_scan()
218 status = sanei_scsi_cmd (fd, &cmd, sizeof (cmd), 0, 0); in trigger_scan()
229 struct scsi_window_cmd cmd; in set_window() member
237 win.cmd.opcode = RICOH_SCSI_SET_WINDOW; in set_window()
238 _lto3b(sizeof(*rwd), win.cmd.len); in set_window()
250 static struct scsi_window_cmd cmd; in get_window() local
257 memset (&cmd, 0, sizeof (cmd)); in get_window()
258 cmd.opcode = RICOH_SCSI_GET_WINDOW; in get_window()
260 cmd.byte2 |= (SANE_Byte)0x01; /* set Single bit to get one window desc. */ in get_window()
262 _lto3b(rwd_size, cmd.len); in get_window()
263 status = sanei_scsi_cmd (fd, &cmd, sizeof (cmd), rwd, &rwd_size); in get_window()
272 static struct scsi_read_scanner_cmd cmd; in read_data() local
276 memset (&cmd, 0, sizeof (cmd)); in read_data()
277 cmd.opcode = RICOH_SCSI_READ_SCANNED_DATA; in read_data()
278 _lto3b(*buf_size, cmd.len); in read_data()
279 status = sanei_scsi_cmd (fd, &cmd, sizeof (cmd), buf, buf_size); in read_data()
288 static SANE_Byte cmd[10]; in object_position() local
292 memset (cmd, 0, sizeof (cmd)); in object_position()
293 cmd[0] = RICOH_SCSI_OBJECT_POSITION; in object_position()
294 status = sanei_scsi_cmd (fd, cmd, sizeof (cmd), 0, 0); in object_position()
303 static struct scsi_get_buffer_status_cmd cmd; in get_data_status() local
309 memset (&cmd, 0, sizeof (cmd)); in get_data_status()
310 cmd.opcode = RICOH_SCSI_GET_BUFFER_STATUS; in get_data_status()
311 _lto2b(ssd_size, cmd.len); in get_data_status()
312 status = sanei_scsi_cmd (fd, &cmd, sizeof (cmd), &ssd, &ssd_size); in get_data_status()