pata_opti.c (bb648a0d22908116b4ef168935a160d7f17c4e6d) pata_opti.c (a0fcdc0259e98d1c16d96baea9ba8a8603e41791)
1/*
2 * pata_opti.c - ATI PATA for new ATA layer
3 * (C) 2005 Red Hat Inc
4 * Alan Cox <alan@redhat.com>
5 *
6 * Based on
7 * linux/drivers/ide/pci/opti621.c Version 0.7 Sept 10, 2002
8 *

--- 20 unchanged lines hidden (view full) ---

29#include <linux/pci.h>
30#include <linux/init.h>
31#include <linux/blkdev.h>
32#include <linux/delay.h>
33#include <scsi/scsi_host.h>
34#include <linux/libata.h>
35
36#define DRV_NAME "pata_opti"
1/*
2 * pata_opti.c - ATI PATA for new ATA layer
3 * (C) 2005 Red Hat Inc
4 * Alan Cox <alan@redhat.com>
5 *
6 * Based on
7 * linux/drivers/ide/pci/opti621.c Version 0.7 Sept 10, 2002
8 *

--- 20 unchanged lines hidden (view full) ---

29#include <linux/pci.h>
30#include <linux/init.h>
31#include <linux/blkdev.h>
32#include <linux/delay.h>
33#include <scsi/scsi_host.h>
34#include <linux/libata.h>
35
36#define DRV_NAME "pata_opti"
37#define DRV_VERSION "0.2.8"
37#define DRV_VERSION "0.2.9"
38
39enum {
40 READ_REG = 0, /* index of Read cycle timing register */
41 WRITE_REG = 1, /* index of Write cycle timing register */
42 CNTRL_REG = 3, /* index of Control register */
43 STRAP_REG = 5, /* index of Strap register */
44 MISC_REG = 6 /* index of Miscellaneous register */
45};

--- 10 unchanged lines hidden (view full) ---

56 struct pci_dev *pdev = to_pci_dev(ap->host->dev);
57 static const struct pci_bits opti_enable_bits[] = {
58 { 0x45, 1, 0x80, 0x00 },
59 { 0x40, 1, 0x08, 0x00 }
60 };
61
62 if (!pci_test_config_bits(pdev, &opti_enable_bits[ap->port_no]))
63 return -ENOENT;
38
39enum {
40 READ_REG = 0, /* index of Read cycle timing register */
41 WRITE_REG = 1, /* index of Write cycle timing register */
42 CNTRL_REG = 3, /* index of Control register */
43 STRAP_REG = 5, /* index of Strap register */
44 MISC_REG = 6 /* index of Miscellaneous register */
45};

--- 10 unchanged lines hidden (view full) ---

56 struct pci_dev *pdev = to_pci_dev(ap->host->dev);
57 static const struct pci_bits opti_enable_bits[] = {
58 { 0x45, 1, 0x80, 0x00 },
59 { 0x40, 1, 0x08, 0x00 }
60 };
61
62 if (!pci_test_config_bits(pdev, &opti_enable_bits[ap->port_no]))
63 return -ENOENT;
64
65 ap->cbl = ATA_CBL_PATA40;
66 return ata_std_prereset(ap);
67}
68
69/**
70 * opti_probe_reset - probe reset
71 * @ap: ATA port
72 *
73 * Perform the ATA probe and bus reset sequence plus specific handling

--- 119 unchanged lines hidden (view full) ---

193 .check_status = ata_check_status,
194 .exec_command = ata_exec_command,
195 .dev_select = ata_std_dev_select,
196
197 .freeze = ata_bmdma_freeze,
198 .thaw = ata_bmdma_thaw,
199 .error_handler = opti_error_handler,
200 .post_internal_cmd = ata_bmdma_post_internal_cmd,
64 return ata_std_prereset(ap);
65}
66
67/**
68 * opti_probe_reset - probe reset
69 * @ap: ATA port
70 *
71 * Perform the ATA probe and bus reset sequence plus specific handling

--- 119 unchanged lines hidden (view full) ---

191 .check_status = ata_check_status,
192 .exec_command = ata_exec_command,
193 .dev_select = ata_std_dev_select,
194
195 .freeze = ata_bmdma_freeze,
196 .thaw = ata_bmdma_thaw,
197 .error_handler = opti_error_handler,
198 .post_internal_cmd = ata_bmdma_post_internal_cmd,
199 .cable_detect = ata_cable_40wire,
201
202 .bmdma_setup = ata_bmdma_setup,
203 .bmdma_start = ata_bmdma_start,
204 .bmdma_stop = ata_bmdma_stop,
205 .bmdma_status = ata_bmdma_status,
206
207 .qc_prep = ata_qc_prep,
208 .qc_issue = ata_qc_issue_prot,

--- 65 unchanged lines hidden ---
200
201 .bmdma_setup = ata_bmdma_setup,
202 .bmdma_start = ata_bmdma_start,
203 .bmdma_stop = ata_bmdma_stop,
204 .bmdma_status = ata_bmdma_status,
205
206 .qc_prep = ata_qc_prep,
207 .qc_issue = ata_qc_issue_prot,

--- 65 unchanged lines hidden ---