pata_atp867x.c 14 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525526527528529530531532533534535536537538539540541542543544545546547548549550551552553554555556557558559560561562563564565566567568569570571572573
  1. /*
  2. * pata_atp867x.c - ARTOP 867X 64bit 4-channel UDMA133 ATA controller driver
  3. *
  4. * (C) 2009 Google Inc. John(Jung-Ik) Lee <jilee@google.com>
  5. *
  6. * Per Atp867 data sheet rev 1.2, Acard.
  7. * Based in part on early ide code from
  8. * 2003-2004 by Eric Uhrhane, Google, Inc.
  9. *
  10. * This program is free software; you can redistribute it and/or modify
  11. * it under the terms of the GNU General Public License as published by
  12. * the Free Software Foundation; either version 2 of the License, or
  13. * (at your option) any later version.
  14. *
  15. * This program is distributed in the hope that it will be useful,
  16. * but WITHOUT ANY WARRANTY; without even the implied warranty of
  17. * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
  18. * GNU General Public License for more details.
  19. *
  20. * You should have received a copy of the GNU General Public License
  21. * along with this program; if not, write to the Free Software
  22. * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
  23. *
  24. *
  25. * TODO:
  26. * 1. RAID features [comparison, XOR, striping, mirroring, etc.]
  27. */
  28. #include <linux/kernel.h>
  29. #include <linux/module.h>
  30. #include <linux/pci.h>
  31. #include <linux/blkdev.h>
  32. #include <linux/delay.h>
  33. #include <linux/device.h>
  34. #include <linux/gfp.h>
  35. #include <scsi/scsi_host.h>
  36. #include <linux/libata.h>
  37. #define DRV_NAME "pata_atp867x"
  38. #define DRV_VERSION "0.7.5"
  39. /*
  40. * IO Registers
  41. * Note that all runtime hot priv ports are cached in ap private_data
  42. */
  43. enum {
  44. ATP867X_IO_CHANNEL_OFFSET = 0x10,
  45. /*
  46. * IO Register Bitfields
  47. */
  48. ATP867X_IO_PIOSPD_ACTIVE_SHIFT = 4,
  49. ATP867X_IO_PIOSPD_RECOVER_SHIFT = 0,
  50. ATP867X_IO_DMAMODE_MSTR_SHIFT = 0,
  51. ATP867X_IO_DMAMODE_MSTR_MASK = 0x07,
  52. ATP867X_IO_DMAMODE_SLAVE_SHIFT = 4,
  53. ATP867X_IO_DMAMODE_SLAVE_MASK = 0x70,
  54. ATP867X_IO_DMAMODE_UDMA_6 = 0x07,
  55. ATP867X_IO_DMAMODE_UDMA_5 = 0x06,
  56. ATP867X_IO_DMAMODE_UDMA_4 = 0x05,
  57. ATP867X_IO_DMAMODE_UDMA_3 = 0x04,
  58. ATP867X_IO_DMAMODE_UDMA_2 = 0x03,
  59. ATP867X_IO_DMAMODE_UDMA_1 = 0x02,
  60. ATP867X_IO_DMAMODE_UDMA_0 = 0x01,
  61. ATP867X_IO_DMAMODE_DISABLE = 0x00,
  62. ATP867X_IO_SYS_INFO_66MHZ = 0x04,
  63. ATP867X_IO_SYS_INFO_SLOW_UDMA5 = 0x02,
  64. ATP867X_IO_SYS_MASK_RESERVED = (~0xf1),
  65. ATP867X_IO_PORTSPD_VAL = 0x1143,
  66. ATP867X_PREREAD_VAL = 0x0200,
  67. ATP867X_NUM_PORTS = 4,
  68. ATP867X_BAR_IOBASE = 0,
  69. ATP867X_BAR_ROMBASE = 6,
  70. };
  71. #define ATP867X_IOBASE(ap) ((ap)->host->iomap[0])
  72. #define ATP867X_SYS_INFO(ap) (0x3F + ATP867X_IOBASE(ap))
  73. #define ATP867X_IO_PORTBASE(ap, port) (0x00 + ATP867X_IOBASE(ap) + \
  74. (port) * ATP867X_IO_CHANNEL_OFFSET)
  75. #define ATP867X_IO_DMABASE(ap, port) (0x40 + \
  76. ATP867X_IO_PORTBASE((ap), (port)))
  77. #define ATP867X_IO_STATUS(ap, port) (0x07 + \
  78. ATP867X_IO_PORTBASE((ap), (port)))
  79. #define ATP867X_IO_ALTSTATUS(ap, port) (0x0E + \
  80. ATP867X_IO_PORTBASE((ap), (port)))
  81. /*
  82. * hot priv ports
  83. */
  84. #define ATP867X_IO_MSTRPIOSPD(ap, port) (0x08 + \
  85. ATP867X_IO_DMABASE((ap), (port)))
  86. #define ATP867X_IO_SLAVPIOSPD(ap, port) (0x09 + \
  87. ATP867X_IO_DMABASE((ap), (port)))
  88. #define ATP867X_IO_8BPIOSPD(ap, port) (0x0A + \
  89. ATP867X_IO_DMABASE((ap), (port)))
  90. #define ATP867X_IO_DMAMODE(ap, port) (0x0B + \
  91. ATP867X_IO_DMABASE((ap), (port)))
  92. #define ATP867X_IO_PORTSPD(ap, port) (0x4A + \
  93. ATP867X_IO_PORTBASE((ap), (port)))
  94. #define ATP867X_IO_PREREAD(ap, port) (0x4C + \
  95. ATP867X_IO_PORTBASE((ap), (port)))
  96. struct atp867x_priv {
  97. void __iomem *dma_mode;
  98. void __iomem *mstr_piospd;
  99. void __iomem *slave_piospd;
  100. void __iomem *eightb_piospd;
  101. int pci66mhz;
  102. };
  103. static void atp867x_set_dmamode(struct ata_port *ap, struct ata_device *adev)
  104. {
  105. struct pci_dev *pdev = to_pci_dev(ap->host->dev);
  106. struct atp867x_priv *dp = ap->private_data;
  107. u8 speed = adev->dma_mode;
  108. u8 b;
  109. u8 mode = speed - XFER_UDMA_0 + 1;
  110. /*
  111. * Doc 6.6.9: decrease the udma mode value by 1 for safer UDMA speed
  112. * on 66MHz bus
  113. * rev-A: UDMA_1~4 (5, 6 no change)
  114. * rev-B: all UDMA modes
  115. * UDMA_0 stays not to disable UDMA
  116. */
  117. if (dp->pci66mhz && mode > ATP867X_IO_DMAMODE_UDMA_0 &&
  118. (pdev->device == PCI_DEVICE_ID_ARTOP_ATP867B ||
  119. mode < ATP867X_IO_DMAMODE_UDMA_5))
  120. mode--;
  121. b = ioread8(dp->dma_mode);
  122. if (adev->devno & 1) {
  123. b = (b & ~ATP867X_IO_DMAMODE_SLAVE_MASK) |
  124. (mode << ATP867X_IO_DMAMODE_SLAVE_SHIFT);
  125. } else {
  126. b = (b & ~ATP867X_IO_DMAMODE_MSTR_MASK) |
  127. (mode << ATP867X_IO_DMAMODE_MSTR_SHIFT);
  128. }
  129. iowrite8(b, dp->dma_mode);
  130. }
  131. static int atp867x_get_active_clocks_shifted(struct ata_port *ap,
  132. unsigned int clk)
  133. {
  134. struct atp867x_priv *dp = ap->private_data;
  135. unsigned char clocks = clk;
  136. /*
  137. * Doc 6.6.9: increase the clock value by 1 for safer PIO speed
  138. * on 66MHz bus
  139. */
  140. if (dp->pci66mhz)
  141. clocks++;
  142. switch (clocks) {
  143. case 0:
  144. clocks = 1;
  145. break;
  146. case 1 ... 6:
  147. break;
  148. default:
  149. printk(KERN_WARNING "ATP867X: active %dclk is invalid. "
  150. "Using 12clk.\n", clk);
  151. case 9 ... 12:
  152. clocks = 7; /* 12 clk */
  153. break;
  154. case 7:
  155. case 8: /* default 8 clk */
  156. clocks = 0;
  157. goto active_clock_shift_done;
  158. }
  159. active_clock_shift_done:
  160. return clocks << ATP867X_IO_PIOSPD_ACTIVE_SHIFT;
  161. }
  162. static int atp867x_get_recover_clocks_shifted(unsigned int clk)
  163. {
  164. unsigned char clocks = clk;
  165. switch (clocks) {
  166. case 0:
  167. clocks = 1;
  168. break;
  169. case 1 ... 11:
  170. break;
  171. case 13:
  172. case 14:
  173. --clocks; /* by the spec */
  174. break;
  175. case 15:
  176. break;
  177. default:
  178. printk(KERN_WARNING "ATP867X: recover %dclk is invalid. "
  179. "Using default 12clk.\n", clk);
  180. case 12: /* default 12 clk */
  181. clocks = 0;
  182. break;
  183. }
  184. return clocks << ATP867X_IO_PIOSPD_RECOVER_SHIFT;
  185. }
  186. static void atp867x_set_piomode(struct ata_port *ap, struct ata_device *adev)
  187. {
  188. struct ata_device *peer = ata_dev_pair(adev);
  189. struct atp867x_priv *dp = ap->private_data;
  190. u8 speed = adev->pio_mode;
  191. struct ata_timing t, p;
  192. int T, UT;
  193. u8 b;
  194. T = 1000000000 / 33333;
  195. UT = T / 4;
  196. ata_timing_compute(adev, speed, &t, T, UT);
  197. if (peer && peer->pio_mode) {
  198. ata_timing_compute(peer, peer->pio_mode, &p, T, UT);
  199. ata_timing_merge(&p, &t, &t, ATA_TIMING_8BIT);
  200. }
  201. b = ioread8(dp->dma_mode);
  202. if (adev->devno & 1)
  203. b = (b & ~ATP867X_IO_DMAMODE_SLAVE_MASK);
  204. else
  205. b = (b & ~ATP867X_IO_DMAMODE_MSTR_MASK);
  206. iowrite8(b, dp->dma_mode);
  207. b = atp867x_get_active_clocks_shifted(ap, t.active) |
  208. atp867x_get_recover_clocks_shifted(t.recover);
  209. if (adev->devno & 1)
  210. iowrite8(b, dp->slave_piospd);
  211. else
  212. iowrite8(b, dp->mstr_piospd);
  213. b = atp867x_get_active_clocks_shifted(ap, t.act8b) |
  214. atp867x_get_recover_clocks_shifted(t.rec8b);
  215. iowrite8(b, dp->eightb_piospd);
  216. }
  217. static int atp867x_cable_override(struct pci_dev *pdev)
  218. {
  219. if (pdev->subsystem_vendor == PCI_VENDOR_ID_ARTOP &&
  220. (pdev->subsystem_device == PCI_DEVICE_ID_ARTOP_ATP867A ||
  221. pdev->subsystem_device == PCI_DEVICE_ID_ARTOP_ATP867B)) {
  222. return 1;
  223. }
  224. return 0;
  225. }
  226. static int atp867x_cable_detect(struct ata_port *ap)
  227. {
  228. struct pci_dev *pdev = to_pci_dev(ap->host->dev);
  229. if (atp867x_cable_override(pdev))
  230. return ATA_CBL_PATA40_SHORT;
  231. return ATA_CBL_PATA_UNK;
  232. }
  233. static struct scsi_host_template atp867x_sht = {
  234. ATA_BMDMA_SHT(DRV_NAME),
  235. };
  236. static struct ata_port_operations atp867x_ops = {
  237. .inherits = &ata_bmdma_port_ops,
  238. .cable_detect = atp867x_cable_detect,
  239. .set_piomode = atp867x_set_piomode,
  240. .set_dmamode = atp867x_set_dmamode,
  241. };
  242. #ifdef ATP867X_DEBUG
  243. static void atp867x_check_res(struct pci_dev *pdev)
  244. {
  245. int i;
  246. unsigned long start, len;
  247. /* Check the PCI resources for this channel are enabled */
  248. for (i = 0; i < DEVICE_COUNT_RESOURCE; i++) {
  249. start = pci_resource_start(pdev, i);
  250. len = pci_resource_len(pdev, i);
  251. printk(KERN_DEBUG "ATP867X: resource start:len=%lx:%lx\n",
  252. start, len);
  253. }
  254. }
  255. static void atp867x_check_ports(struct ata_port *ap, int port)
  256. {
  257. struct ata_ioports *ioaddr = &ap->ioaddr;
  258. struct atp867x_priv *dp = ap->private_data;
  259. printk(KERN_DEBUG "ATP867X: port[%d] addresses\n"
  260. " cmd_addr =0x%llx, 0x%llx\n"
  261. " ctl_addr =0x%llx, 0x%llx\n"
  262. " bmdma_addr =0x%llx, 0x%llx\n"
  263. " data_addr =0x%llx\n"
  264. " error_addr =0x%llx\n"
  265. " feature_addr =0x%llx\n"
  266. " nsect_addr =0x%llx\n"
  267. " lbal_addr =0x%llx\n"
  268. " lbam_addr =0x%llx\n"
  269. " lbah_addr =0x%llx\n"
  270. " device_addr =0x%llx\n"
  271. " status_addr =0x%llx\n"
  272. " command_addr =0x%llx\n"
  273. " dp->dma_mode =0x%llx\n"
  274. " dp->mstr_piospd =0x%llx\n"
  275. " dp->slave_piospd =0x%llx\n"
  276. " dp->eightb_piospd =0x%llx\n"
  277. " dp->pci66mhz =0x%lx\n",
  278. port,
  279. (unsigned long long)ioaddr->cmd_addr,
  280. (unsigned long long)ATP867X_IO_PORTBASE(ap, port),
  281. (unsigned long long)ioaddr->ctl_addr,
  282. (unsigned long long)ATP867X_IO_ALTSTATUS(ap, port),
  283. (unsigned long long)ioaddr->bmdma_addr,
  284. (unsigned long long)ATP867X_IO_DMABASE(ap, port),
  285. (unsigned long long)ioaddr->data_addr,
  286. (unsigned long long)ioaddr->error_addr,
  287. (unsigned long long)ioaddr->feature_addr,
  288. (unsigned long long)ioaddr->nsect_addr,
  289. (unsigned long long)ioaddr->lbal_addr,
  290. (unsigned long long)ioaddr->lbam_addr,
  291. (unsigned long long)ioaddr->lbah_addr,
  292. (unsigned long long)ioaddr->device_addr,
  293. (unsigned long long)ioaddr->status_addr,
  294. (unsigned long long)ioaddr->command_addr,
  295. (unsigned long long)dp->dma_mode,
  296. (unsigned long long)dp->mstr_piospd,
  297. (unsigned long long)dp->slave_piospd,
  298. (unsigned long long)dp->eightb_piospd,
  299. (unsigned long)dp->pci66mhz);
  300. }
  301. #endif
  302. static int atp867x_set_priv(struct ata_port *ap)
  303. {
  304. struct pci_dev *pdev = to_pci_dev(ap->host->dev);
  305. struct atp867x_priv *dp;
  306. int port = ap->port_no;
  307. dp = ap->private_data =
  308. devm_kzalloc(&pdev->dev, sizeof(*dp), GFP_KERNEL);
  309. if (dp == NULL)
  310. return -ENOMEM;
  311. dp->dma_mode = ATP867X_IO_DMAMODE(ap, port);
  312. dp->mstr_piospd = ATP867X_IO_MSTRPIOSPD(ap, port);
  313. dp->slave_piospd = ATP867X_IO_SLAVPIOSPD(ap, port);
  314. dp->eightb_piospd = ATP867X_IO_8BPIOSPD(ap, port);
  315. dp->pci66mhz =
  316. ioread8(ATP867X_SYS_INFO(ap)) & ATP867X_IO_SYS_INFO_66MHZ;
  317. return 0;
  318. }
  319. static void atp867x_fixup(struct ata_host *host)
  320. {
  321. struct pci_dev *pdev = to_pci_dev(host->dev);
  322. struct ata_port *ap = host->ports[0];
  323. int i;
  324. u8 v;
  325. /*
  326. * Broken BIOS might not set latency high enough
  327. */
  328. pci_read_config_byte(pdev, PCI_LATENCY_TIMER, &v);
  329. if (v < 0x80) {
  330. v = 0x80;
  331. pci_write_config_byte(pdev, PCI_LATENCY_TIMER, v);
  332. printk(KERN_DEBUG "ATP867X: set latency timer of device %s"
  333. " to %d\n", pci_name(pdev), v);
  334. }
  335. /*
  336. * init 8bit io ports speed(0aaarrrr) to 43h and
  337. * init udma modes of master/slave to 0/0(11h)
  338. */
  339. for (i = 0; i < ATP867X_NUM_PORTS; i++)
  340. iowrite16(ATP867X_IO_PORTSPD_VAL, ATP867X_IO_PORTSPD(ap, i));
  341. /*
  342. * init PreREAD counts
  343. */
  344. for (i = 0; i < ATP867X_NUM_PORTS; i++)
  345. iowrite16(ATP867X_PREREAD_VAL, ATP867X_IO_PREREAD(ap, i));
  346. v = ioread8(ATP867X_IOBASE(ap) + 0x28);
  347. v &= 0xcf; /* Enable INTA#: bit4=0 means enable */
  348. v |= 0xc0; /* Enable PCI burst, MRM & not immediate interrupts */
  349. iowrite8(v, ATP867X_IOBASE(ap) + 0x28);
  350. /*
  351. * Turn off the over clocked udma5 mode, only for Rev-B
  352. */
  353. v = ioread8(ATP867X_SYS_INFO(ap));
  354. v &= ATP867X_IO_SYS_MASK_RESERVED;
  355. if (pdev->device == PCI_DEVICE_ID_ARTOP_ATP867B)
  356. v |= ATP867X_IO_SYS_INFO_SLOW_UDMA5;
  357. iowrite8(v, ATP867X_SYS_INFO(ap));
  358. }
  359. static int atp867x_ata_pci_sff_init_host(struct ata_host *host)
  360. {
  361. struct device *gdev = host->dev;
  362. struct pci_dev *pdev = to_pci_dev(gdev);
  363. unsigned int mask = 0;
  364. int i, rc;
  365. /*
  366. * do not map rombase
  367. */
  368. rc = pcim_iomap_regions(pdev, 1 << ATP867X_BAR_IOBASE, DRV_NAME);
  369. if (rc == -EBUSY)
  370. pcim_pin_device(pdev);
  371. if (rc)
  372. return rc;
  373. host->iomap = pcim_iomap_table(pdev);
  374. #ifdef ATP867X_DEBUG
  375. atp867x_check_res(pdev);
  376. for (i = 0; i < PCI_ROM_RESOURCE; i++)
  377. printk(KERN_DEBUG "ATP867X: iomap[%d]=0x%llx\n", i,
  378. (unsigned long long)(host->iomap[i]));
  379. #endif
  380. /*
  381. * request, iomap BARs and init port addresses accordingly
  382. */
  383. for (i = 0; i < host->n_ports; i++) {
  384. struct ata_port *ap = host->ports[i];
  385. struct ata_ioports *ioaddr = &ap->ioaddr;
  386. ioaddr->cmd_addr = ATP867X_IO_PORTBASE(ap, i);
  387. ioaddr->ctl_addr = ioaddr->altstatus_addr
  388. = ATP867X_IO_ALTSTATUS(ap, i);
  389. ioaddr->bmdma_addr = ATP867X_IO_DMABASE(ap, i);
  390. ata_sff_std_ports(ioaddr);
  391. rc = atp867x_set_priv(ap);
  392. if (rc)
  393. return rc;
  394. #ifdef ATP867X_DEBUG
  395. atp867x_check_ports(ap, i);
  396. #endif
  397. ata_port_desc(ap, "cmd 0x%lx ctl 0x%lx",
  398. (unsigned long)ioaddr->cmd_addr,
  399. (unsigned long)ioaddr->ctl_addr);
  400. ata_port_desc(ap, "bmdma 0x%lx",
  401. (unsigned long)ioaddr->bmdma_addr);
  402. mask |= 1 << i;
  403. }
  404. if (!mask) {
  405. dev_err(gdev, "no available native port\n");
  406. return -ENODEV;
  407. }
  408. atp867x_fixup(host);
  409. rc = dma_set_mask(&pdev->dev, ATA_DMA_MASK);
  410. if (rc)
  411. return rc;
  412. rc = dma_set_coherent_mask(&pdev->dev, ATA_DMA_MASK);
  413. return rc;
  414. }
  415. static int atp867x_init_one(struct pci_dev *pdev,
  416. const struct pci_device_id *id)
  417. {
  418. static const struct ata_port_info info_867x = {
  419. .flags = ATA_FLAG_SLAVE_POSS,
  420. .pio_mask = ATA_PIO4,
  421. .udma_mask = ATA_UDMA6,
  422. .port_ops = &atp867x_ops,
  423. };
  424. struct ata_host *host;
  425. const struct ata_port_info *ppi[] = { &info_867x, NULL };
  426. int rc;
  427. ata_print_version_once(&pdev->dev, DRV_VERSION);
  428. rc = pcim_enable_device(pdev);
  429. if (rc)
  430. return rc;
  431. printk(KERN_INFO "ATP867X: ATP867 ATA UDMA133 controller (rev %02X)",
  432. pdev->device);
  433. host = ata_host_alloc_pinfo(&pdev->dev, ppi, ATP867X_NUM_PORTS);
  434. if (!host) {
  435. dev_err(&pdev->dev, "failed to allocate ATA host\n");
  436. rc = -ENOMEM;
  437. goto err_out;
  438. }
  439. rc = atp867x_ata_pci_sff_init_host(host);
  440. if (rc) {
  441. dev_err(&pdev->dev, "failed to init host\n");
  442. goto err_out;
  443. }
  444. pci_set_master(pdev);
  445. rc = ata_host_activate(host, pdev->irq, ata_bmdma_interrupt,
  446. IRQF_SHARED, &atp867x_sht);
  447. if (rc)
  448. dev_err(&pdev->dev, "failed to activate host\n");
  449. err_out:
  450. return rc;
  451. }
  452. #ifdef CONFIG_PM_SLEEP
  453. static int atp867x_reinit_one(struct pci_dev *pdev)
  454. {
  455. struct ata_host *host = pci_get_drvdata(pdev);
  456. int rc;
  457. rc = ata_pci_device_do_resume(pdev);
  458. if (rc)
  459. return rc;
  460. atp867x_fixup(host);
  461. ata_host_resume(host);
  462. return 0;
  463. }
  464. #endif
  465. static struct pci_device_id atp867x_pci_tbl[] = {
  466. { PCI_VDEVICE(ARTOP, PCI_DEVICE_ID_ARTOP_ATP867A), 0 },
  467. { PCI_VDEVICE(ARTOP, PCI_DEVICE_ID_ARTOP_ATP867B), 0 },
  468. { },
  469. };
  470. static struct pci_driver atp867x_driver = {
  471. .name = DRV_NAME,
  472. .id_table = atp867x_pci_tbl,
  473. .probe = atp867x_init_one,
  474. .remove = ata_pci_remove_one,
  475. #ifdef CONFIG_PM_SLEEP
  476. .suspend = ata_pci_device_suspend,
  477. .resume = atp867x_reinit_one,
  478. #endif
  479. };
  480. module_pci_driver(atp867x_driver);
  481. MODULE_AUTHOR("John(Jung-Ik) Lee, Google Inc.");
  482. MODULE_DESCRIPTION("low level driver for Artop/Acard 867x ATA controller");
  483. MODULE_LICENSE("GPL");
  484. MODULE_DEVICE_TABLE(pci, atp867x_pci_tbl);
  485. MODULE_VERSION(DRV_VERSION);