From 8bf6845b22d060844f535c1b5901eb16a34869fd Mon Sep 17 00:00:00 2001 From: Jeff Garzik Date: Tue, 21 Oct 2003 15:14:51 -0400 Subject: [libata] add per-driver port init/shutdown hooks, with helper defaults --- include/linux/libata.h | 10 ++++++++++ 1 file changed, 10 insertions(+) (limited to 'include/linux') diff --git a/include/linux/libata.h b/include/linux/libata.h index a8377cb315ef..ccc998635ac9 100644 --- a/include/linux/libata.h +++ b/include/linux/libata.h @@ -215,6 +215,7 @@ struct ata_host_set { unsigned long irq; void *mmio_base; unsigned int n_ports; + void *private_data; struct ata_port * ports[0]; }; @@ -264,6 +265,8 @@ struct ata_queued_cmd { ata_qc_cb_t callback; struct semaphore sem; + + void *private_data; }; struct ata_host_stats { @@ -333,6 +336,8 @@ struct ata_port { struct semaphore thr_sem; struct timer_list thr_timer; unsigned long thr_timeout; + + void *private_data; }; struct ata_port_operations { @@ -363,6 +368,9 @@ struct ata_port_operations { u32 (*scr_read) (struct ata_port *ap, unsigned int sc_reg); void (*scr_write) (struct ata_port *ap, unsigned int sc_reg, u32 val); + + int (*port_start) (struct ata_port *ap); + void (*port_stop) (struct ata_port *ap); }; struct ata_port_info { @@ -406,6 +414,8 @@ 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); extern void ata_exec_command_mmio(struct ata_port *ap, struct ata_taskfile *tf); +extern int ata_port_start (struct ata_port *ap); +extern void ata_port_stop (struct ata_port *ap); extern irqreturn_t ata_interrupt (int irq, void *dev_instance, struct pt_regs *regs); extern void ata_fill_sg(struct ata_queued_cmd *qc); extern void ata_bmdma_start_mmio (struct ata_queued_cmd *qc); -- cgit v1.2.3