diff options
| author | Jeff Garzik <jgarzik@redhat.com> | 2004-05-10 04:26:26 -0400 |
|---|---|---|
| committer | Jeff Garzik <jgarzik@redhat.com> | 2004-05-10 04:26:26 -0400 |
| commit | 1e279587e49c289fdbe243eea3270bf40b967436 (patch) | |
| tree | 66ef83a350c42f304646459a479fdbf9b1e01130 /include/linux | |
| parent | 3dc567d850dc6f0858472621ddba3e31fcacdbe5 (diff) | |
| parent | fb75e287ff0bfe3e20f728f793a9fd95f0ca5c00 (diff) | |
Merge redhat.com:/spare/repo/linux-2.6
into redhat.com:/spare/repo/libata-2.6
Diffstat (limited to 'include/linux')
| -rw-r--r-- | include/linux/libata.h | 49 | ||||
| -rw-r--r-- | include/linux/pci_ids.h | 1 |
2 files changed, 23 insertions, 27 deletions
diff --git a/include/linux/libata.h b/include/linux/libata.h index e977b157cb81..efcc745effae 100644 --- a/include/linux/libata.h +++ b/include/linux/libata.h @@ -27,6 +27,7 @@ #include <linux/interrupt.h> #include <asm/io.h> #include <linux/ata.h> +#include <linux/workqueue.h> /* * compile-time options @@ -113,9 +114,6 @@ enum { ATA_QCFLAG_SG = (1 << 4), /* have s/g table? */ ATA_QCFLAG_POLL = (1 << 5), /* polling, no interrupts */ - /* struct ata_engine atomic flags (use test_bit, etc.) */ - ATA_EFLG_ACTIVE = 0, /* engine is active */ - /* various lengths of time */ ATA_TMOUT_EDD = 5 * HZ, /* hueristic */ ATA_TMOUT_PIO = 30 * HZ, @@ -144,13 +142,6 @@ enum { THR_IDLE = (THR_PROBE_FAILED + 1), THR_PROBE_SUCCESS = (THR_IDLE + 1), THR_PROBE_START = (THR_PROBE_SUCCESS + 1), - THR_PIO_POLL = (THR_PROBE_START + 1), - THR_PIO_TMOUT = (THR_PIO_POLL + 1), - THR_PIO = (THR_PIO_TMOUT + 1), - THR_PIO_LAST = (THR_PIO + 1), - THR_PIO_LAST_POLL = (THR_PIO_LAST + 1), - THR_PIO_ERR = (THR_PIO_LAST_POLL + 1), - THR_PACKET = (THR_PIO_ERR + 1), /* SATA port states */ PORT_UNKNOWN = 0, @@ -163,6 +154,17 @@ enum { ATA_QCFLAG_TIMEOUT = (1 << 0), }; +enum pio_task_states { + PIO_ST_UNKNOWN, + PIO_ST_IDLE, + PIO_ST_POLL, + PIO_ST_TMOUT, + PIO_ST, + PIO_ST_LAST, + PIO_ST_LAST_POLL, + PIO_ST_ERR, +}; + /* forward declarations */ struct scsi_device; struct ata_port_operations; @@ -224,7 +226,6 @@ struct ata_queued_cmd { struct scsi_cmnd *scsicmd; void (*scsidone)(struct scsi_cmnd *); - struct list_head node; unsigned long flags; /* ATA_QCFLAG_xxx */ unsigned int tag; unsigned int n_elem; @@ -239,7 +240,7 @@ struct ata_queued_cmd { ata_qc_cb_t callback; - struct semaphore sem; + struct completion *waiting; void *private_data; }; @@ -271,11 +272,6 @@ struct ata_device { u8 write_cmd; /* opcode to use on write */ }; -struct ata_engine { - unsigned long flags; - struct list_head q; -}; - struct ata_port { struct Scsi_Host *host; /* our co-allocated scsi host */ struct ata_port_operations *ops; @@ -296,8 +292,6 @@ struct ata_port { unsigned int udma_mask; unsigned int cbl; /* cable type; ATA_CBL_xxx */ - struct ata_engine eng; - struct ata_device device[ATA_MAX_DEVICES]; struct ata_queued_cmd qcmd[ATA_MAX_QUEUE]; @@ -307,16 +301,17 @@ struct ata_port { struct ata_host_stats stats; struct ata_host_set *host_set; - struct semaphore sem; struct semaphore probe_sem; unsigned int thr_state; - int time_to_die; - pid_t thr_pid; - struct completion thr_exited; - struct semaphore thr_sem; - struct timer_list thr_timer; - unsigned long thr_timeout; + + struct work_struct packet_task; + + struct work_struct pio_task; + unsigned int pio_task_state; + unsigned long pio_task_timeout; + + struct work_struct probe_task; void *private_data; }; @@ -392,6 +387,8 @@ extern void ata_tf_load_pio(struct ata_port *ap, struct ata_taskfile *tf); extern void ata_tf_load_mmio(struct ata_port *ap, struct ata_taskfile *tf); extern void ata_tf_read_pio(struct ata_port *ap, struct ata_taskfile *tf); extern void ata_tf_read_mmio(struct ata_port *ap, struct ata_taskfile *tf); +extern void ata_tf_to_fis(struct ata_taskfile *tf, u8 *fis, u8 pmp); +extern void ata_tf_from_fis(u8 *fis, struct ata_taskfile *tf); extern u8 ata_check_status_pio(struct ata_port *ap); extern u8 ata_check_status_mmio(struct ata_port *ap); extern void ata_exec_command_pio(struct ata_port *ap, struct ata_taskfile *tf); diff --git a/include/linux/pci_ids.h b/include/linux/pci_ids.h index 8e3bbbe83f10..0a32a3324fee 100644 --- a/include/linux/pci_ids.h +++ b/include/linux/pci_ids.h @@ -572,7 +572,6 @@ #define PCI_DEVICE_ID_SI_503 0x0008 #define PCI_DEVICE_ID_SI_ACPI 0x0009 #define PCI_DEVICE_ID_SI_LPC 0x0018 -#define PCI_DEVICE_ID_SI_180 0x0180 #define PCI_DEVICE_ID_SI_5597_VGA 0x0200 #define PCI_DEVICE_ID_SI_6205 0x0205 #define PCI_DEVICE_ID_SI_501 0x0406 |
