[PATCH] consolidate timeout defintions in scsi.h

Adapted from a patch in SuSE's kernel SRPM.

Signed-off-by: James Bottomley <James.Bottomley@SteelEye.com>
This commit is contained in:
2005-04-03 14:52:44 -05:00 коммит произвёл James Bottomley
Родитель a757e64cfa
Коммит 0890d74f29
3 изменённых файлов: 9 добавлений и 10 удалений

Просмотреть файл

@ -328,11 +328,6 @@ static int sg_io(struct file *file, request_queue_t *q,
return 0; return 0;
} }
#define FORMAT_UNIT_TIMEOUT (2 * 60 * 60 * HZ)
#define START_STOP_TIMEOUT (60 * HZ)
#define MOVE_MEDIUM_TIMEOUT (5 * 60 * HZ)
#define READ_ELEMENT_STATUS_TIMEOUT (5 * 60 * HZ)
#define READ_DEFECT_DATA_TIMEOUT (60 * HZ )
#define OMAX_SB_LEN 16 /* For backward compatibility */ #define OMAX_SB_LEN 16 /* For backward compatibility */
static int sg_scsi_ioctl(struct file *file, request_queue_t *q, static int sg_scsi_ioctl(struct file *file, request_queue_t *q,

Просмотреть файл

@ -27,11 +27,6 @@
#define NORMAL_RETRIES 5 #define NORMAL_RETRIES 5
#define IOCTL_NORMAL_TIMEOUT (10 * HZ) #define IOCTL_NORMAL_TIMEOUT (10 * HZ)
#define FORMAT_UNIT_TIMEOUT (2 * 60 * 60 * HZ)
#define START_STOP_TIMEOUT (60 * HZ)
#define MOVE_MEDIUM_TIMEOUT (5 * 60 * HZ)
#define READ_ELEMENT_STATUS_TIMEOUT (5 * 60 * HZ)
#define READ_DEFECT_DATA_TIMEOUT (60 * HZ ) /* ZIP-250 on parallel port takes as long! */
#define MAX_BUF PAGE_SIZE #define MAX_BUF PAGE_SIZE

Просмотреть файл

@ -360,6 +360,15 @@ struct scsi_lun {
#define sense_error(sense) ((sense) & 0xf) #define sense_error(sense) ((sense) & 0xf)
#define sense_valid(sense) ((sense) & 0x80); #define sense_valid(sense) ((sense) & 0x80);
/*
* default timeouts
*/
#define FORMAT_UNIT_TIMEOUT (2 * 60 * 60 * HZ)
#define START_STOP_TIMEOUT (60 * HZ)
#define MOVE_MEDIUM_TIMEOUT (5 * 60 * HZ)
#define READ_ELEMENT_STATUS_TIMEOUT (5 * 60 * HZ)
#define READ_DEFECT_DATA_TIMEOUT (60 * HZ )
#define IDENTIFY_BASE 0x80 #define IDENTIFY_BASE 0x80
#define IDENTIFY(can_disconnect, lun) (IDENTIFY_BASE |\ #define IDENTIFY(can_disconnect, lun) (IDENTIFY_BASE |\