diff options
author | Linus Torvalds <torvalds@linux-foundation.org> | 2009-06-11 13:00:03 -0400 |
---|---|---|
committer | Linus Torvalds <torvalds@linux-foundation.org> | 2009-06-11 13:00:03 -0400 |
commit | 27951daa71f1c91300ae4de9441916d1ffe2b078 (patch) | |
tree | 72d9ecde8c784c0837b7caf64b97fac5ffd5a424 /include/linux | |
parent | 59c288ffb6dfb55bdd6bfe6826ab6203ff791930 (diff) | |
parent | e8e7526c3c0863be25ab03a0871ee0978de5ba50 (diff) |
Merge branch 'for-2.6.31' of git://git.kernel.org/pub/scm/linux/kernel/git/bart/ide-2.6
* 'for-2.6.31' of git://git.kernel.org/pub/scm/linux/kernel/git/bart/ide-2.6: (28 commits)
ide-tape: fix debug call
alim15x3: Remove historical hacks, re-enable init_hwif for PowerPC
ide-dma: don't reset request fields on dma_timeout_retry()
ide: drop rq->data handling from ide_map_sg()
ide-atapi: kill unused fields and callbacks
ide-tape: simplify read/write functions
ide-tape: use byte size instead of sectors on rw issue functions
ide-tape: unify r/w init paths
ide-tape: kill idetape_bh
ide-tape: use standard data transfer mechanism
ide-tape: use single continuous buffer
ide-atapi,tape,floppy: allow ->pc_callback() to change rq->data_len
ide-tape,floppy: fix failed command completion after request sense
ide-pm: don't abuse rq->data
ide-cd,atapi: use bio for internal commands
ide-atapi: convert ide-{floppy,tape} to using preallocated sense buffer
ide-cd: convert to using generic sense request
ide: add helpers for preparing sense requests
ide-cd: don't abuse rq->buffer
ide-atapi: don't abuse rq->buffer
...
Diffstat (limited to 'include/linux')
-rw-r--r-- | include/linux/ide.h | 27 |
1 files changed, 12 insertions, 15 deletions
diff --git a/include/linux/ide.h b/include/linux/ide.h index 9fed365a598b..867cb68d8461 100644 --- a/include/linux/ide.h +++ b/include/linux/ide.h | |||
@@ -26,6 +26,9 @@ | |||
26 | #include <asm/io.h> | 26 | #include <asm/io.h> |
27 | #include <asm/mutex.h> | 27 | #include <asm/mutex.h> |
28 | 28 | ||
29 | /* for request_sense */ | ||
30 | #include <linux/cdrom.h> | ||
31 | |||
29 | #if defined(CONFIG_CRIS) || defined(CONFIG_FRV) || defined(CONFIG_MN10300) | 32 | #if defined(CONFIG_CRIS) || defined(CONFIG_FRV) || defined(CONFIG_MN10300) |
30 | # define SUPPORT_VLB_SYNC 0 | 33 | # define SUPPORT_VLB_SYNC 0 |
31 | #else | 34 | #else |
@@ -324,7 +327,6 @@ struct ide_cmd { | |||
324 | unsigned int cursg_ofs; | 327 | unsigned int cursg_ofs; |
325 | 328 | ||
326 | struct request *rq; /* copy of request */ | 329 | struct request *rq; /* copy of request */ |
327 | void *special; /* valid_t generally */ | ||
328 | }; | 330 | }; |
329 | 331 | ||
330 | /* ATAPI packet command flags */ | 332 | /* ATAPI packet command flags */ |
@@ -360,11 +362,7 @@ struct ide_atapi_pc { | |||
360 | 362 | ||
361 | /* data buffer */ | 363 | /* data buffer */ |
362 | u8 *buf; | 364 | u8 *buf; |
363 | /* current buffer position */ | ||
364 | u8 *cur_pos; | ||
365 | int buf_size; | 365 | int buf_size; |
366 | /* missing/available data on the current buffer */ | ||
367 | int b_count; | ||
368 | 366 | ||
369 | /* the corresponding request */ | 367 | /* the corresponding request */ |
370 | struct request *rq; | 368 | struct request *rq; |
@@ -377,10 +375,6 @@ struct ide_atapi_pc { | |||
377 | */ | 375 | */ |
378 | u8 pc_buf[IDE_PC_BUFFER_SIZE]; | 376 | u8 pc_buf[IDE_PC_BUFFER_SIZE]; |
379 | 377 | ||
380 | /* idetape only */ | ||
381 | struct idetape_bh *bh; | ||
382 | char *b_data; | ||
383 | |||
384 | unsigned long timeout; | 378 | unsigned long timeout; |
385 | }; | 379 | }; |
386 | 380 | ||
@@ -593,16 +587,16 @@ struct ide_drive_s { | |||
593 | /* callback for packet commands */ | 587 | /* callback for packet commands */ |
594 | int (*pc_callback)(struct ide_drive_s *, int); | 588 | int (*pc_callback)(struct ide_drive_s *, int); |
595 | 589 | ||
596 | void (*pc_update_buffers)(struct ide_drive_s *, struct ide_atapi_pc *); | ||
597 | int (*pc_io_buffers)(struct ide_drive_s *, struct ide_atapi_pc *, | ||
598 | unsigned int, int); | ||
599 | |||
600 | ide_startstop_t (*irq_handler)(struct ide_drive_s *); | 590 | ide_startstop_t (*irq_handler)(struct ide_drive_s *); |
601 | 591 | ||
602 | unsigned long atapi_flags; | 592 | unsigned long atapi_flags; |
603 | 593 | ||
604 | struct ide_atapi_pc request_sense_pc; | 594 | struct ide_atapi_pc request_sense_pc; |
605 | struct request request_sense_rq; | 595 | |
596 | /* current sense rq and buffer */ | ||
597 | bool sense_rq_armed; | ||
598 | struct request sense_rq; | ||
599 | struct request_sense sense_data; | ||
606 | }; | 600 | }; |
607 | 601 | ||
608 | typedef struct ide_drive_s ide_drive_t; | 602 | typedef struct ide_drive_s ide_drive_t; |
@@ -1174,7 +1168,10 @@ int ide_do_test_unit_ready(ide_drive_t *, struct gendisk *); | |||
1174 | int ide_do_start_stop(ide_drive_t *, struct gendisk *, int); | 1168 | int ide_do_start_stop(ide_drive_t *, struct gendisk *, int); |
1175 | int ide_set_media_lock(ide_drive_t *, struct gendisk *, int); | 1169 | int ide_set_media_lock(ide_drive_t *, struct gendisk *, int); |
1176 | void ide_create_request_sense_cmd(ide_drive_t *, struct ide_atapi_pc *); | 1170 | void ide_create_request_sense_cmd(ide_drive_t *, struct ide_atapi_pc *); |
1177 | void ide_retry_pc(ide_drive_t *, struct gendisk *); | 1171 | void ide_retry_pc(ide_drive_t *drive); |
1172 | |||
1173 | void ide_prep_sense(ide_drive_t *drive, struct request *rq); | ||
1174 | int ide_queue_sense_rq(ide_drive_t *drive, void *special); | ||
1178 | 1175 | ||
1179 | int ide_cd_expiry(ide_drive_t *); | 1176 | int ide_cd_expiry(ide_drive_t *); |
1180 | 1177 | ||