cpci_hotplug_core.c 17 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525526527528529530531532533534535536537538539540541542543544545546547548549550551552553554555556557558559560561562563564565566567568569570571572573574575576577578579580581582583584585586587588589590591592593594595596597598599600601602603604605606607608609610611612613614615616617618619620621622623624625626627628629630631632633634635636637638639640641642643644645646647648649650651652653654655656657658659660661662663664665666667668669670671672673674675676677678679680681682683684685686687688689690691692693694695696697698699700701702703704705706707708709710711712713714715716717718719720721722723724725
  1. /*
  2. * CompactPCI Hot Plug Driver
  3. *
  4. * Copyright (C) 2002,2005 SOMA Networks, Inc.
  5. * Copyright (C) 2001 Greg Kroah-Hartman (greg@kroah.com)
  6. * Copyright (C) 2001 IBM Corp.
  7. *
  8. * All rights reserved.
  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 (at
  13. * your option) any later version.
  14. *
  15. * This program is distributed in the hope that it will be useful, but
  16. * WITHOUT ANY WARRANTY; without even the implied warranty of
  17. * MERCHANTABILITY OR FITNESS FOR A PARTICULAR PURPOSE, GOOD TITLE or
  18. * NON INFRINGEMENT. See the GNU General Public License for more
  19. * details.
  20. *
  21. * You should have received a copy of the GNU General Public License
  22. * along with this program; if not, write to the Free Software
  23. * Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
  24. *
  25. * Send feedback to <scottm@somanetworks.com>
  26. */
  27. #include <linux/module.h>
  28. #include <linux/kernel.h>
  29. #include <linux/slab.h>
  30. #include <linux/pci.h>
  31. #include <linux/pci_hotplug.h>
  32. #include <linux/init.h>
  33. #include <linux/interrupt.h>
  34. #include <linux/smp_lock.h>
  35. #include <asm/atomic.h>
  36. #include <linux/delay.h>
  37. #include <linux/kthread.h>
  38. #include "cpci_hotplug.h"
  39. #define DRIVER_AUTHOR "Scott Murray <scottm@somanetworks.com>"
  40. #define DRIVER_DESC "CompactPCI Hot Plug Core"
  41. #define MY_NAME "cpci_hotplug"
  42. #define dbg(format, arg...) \
  43. do { \
  44. if (cpci_debug) \
  45. printk (KERN_DEBUG "%s: " format "\n", \
  46. MY_NAME , ## arg); \
  47. } while (0)
  48. #define err(format, arg...) printk(KERN_ERR "%s: " format "\n", MY_NAME , ## arg)
  49. #define info(format, arg...) printk(KERN_INFO "%s: " format "\n", MY_NAME , ## arg)
  50. #define warn(format, arg...) printk(KERN_WARNING "%s: " format "\n", MY_NAME , ## arg)
  51. /* local variables */
  52. static DECLARE_RWSEM(list_rwsem);
  53. static LIST_HEAD(slot_list);
  54. static int slots;
  55. static atomic_t extracting;
  56. int cpci_debug;
  57. static struct cpci_hp_controller *controller;
  58. static struct task_struct *cpci_thread;
  59. static int thread_finished;
  60. static int enable_slot(struct hotplug_slot *slot);
  61. static int disable_slot(struct hotplug_slot *slot);
  62. static int set_attention_status(struct hotplug_slot *slot, u8 value);
  63. static int get_power_status(struct hotplug_slot *slot, u8 * value);
  64. static int get_attention_status(struct hotplug_slot *slot, u8 * value);
  65. static int get_adapter_status(struct hotplug_slot *slot, u8 * value);
  66. static int get_latch_status(struct hotplug_slot *slot, u8 * value);
  67. static struct hotplug_slot_ops cpci_hotplug_slot_ops = {
  68. .enable_slot = enable_slot,
  69. .disable_slot = disable_slot,
  70. .set_attention_status = set_attention_status,
  71. .get_power_status = get_power_status,
  72. .get_attention_status = get_attention_status,
  73. .get_adapter_status = get_adapter_status,
  74. .get_latch_status = get_latch_status,
  75. };
  76. static int
  77. update_latch_status(struct hotplug_slot *hotplug_slot, u8 value)
  78. {
  79. struct hotplug_slot_info info;
  80. memcpy(&info, hotplug_slot->info, sizeof(struct hotplug_slot_info));
  81. info.latch_status = value;
  82. return pci_hp_change_slot_info(hotplug_slot, &info);
  83. }
  84. static int
  85. update_adapter_status(struct hotplug_slot *hotplug_slot, u8 value)
  86. {
  87. struct hotplug_slot_info info;
  88. memcpy(&info, hotplug_slot->info, sizeof(struct hotplug_slot_info));
  89. info.adapter_status = value;
  90. return pci_hp_change_slot_info(hotplug_slot, &info);
  91. }
  92. static int
  93. enable_slot(struct hotplug_slot *hotplug_slot)
  94. {
  95. struct slot *slot = hotplug_slot->private;
  96. int retval = 0;
  97. dbg("%s - physical_slot = %s", __func__, slot_name(slot));
  98. if (controller->ops->set_power)
  99. retval = controller->ops->set_power(slot, 1);
  100. return retval;
  101. }
  102. static int
  103. disable_slot(struct hotplug_slot *hotplug_slot)
  104. {
  105. struct slot *slot = hotplug_slot->private;
  106. int retval = 0;
  107. dbg("%s - physical_slot = %s", __func__, slot_name(slot));
  108. down_write(&list_rwsem);
  109. /* Unconfigure device */
  110. dbg("%s - unconfiguring slot %s", __func__, slot_name(slot));
  111. if ((retval = cpci_unconfigure_slot(slot))) {
  112. err("%s - could not unconfigure slot %s",
  113. __func__, slot_name(slot));
  114. goto disable_error;
  115. }
  116. dbg("%s - finished unconfiguring slot %s", __func__, slot_name(slot));
  117. /* Clear EXT (by setting it) */
  118. if (cpci_clear_ext(slot)) {
  119. err("%s - could not clear EXT for slot %s",
  120. __func__, slot_name(slot));
  121. retval = -ENODEV;
  122. goto disable_error;
  123. }
  124. cpci_led_on(slot);
  125. if (controller->ops->set_power)
  126. if ((retval = controller->ops->set_power(slot, 0)))
  127. goto disable_error;
  128. if (update_adapter_status(slot->hotplug_slot, 0))
  129. warn("failure to update adapter file");
  130. if (slot->extracting) {
  131. slot->extracting = 0;
  132. atomic_dec(&extracting);
  133. }
  134. disable_error:
  135. up_write(&list_rwsem);
  136. return retval;
  137. }
  138. static u8
  139. cpci_get_power_status(struct slot *slot)
  140. {
  141. u8 power = 1;
  142. if (controller->ops->get_power)
  143. power = controller->ops->get_power(slot);
  144. return power;
  145. }
  146. static int
  147. get_power_status(struct hotplug_slot *hotplug_slot, u8 * value)
  148. {
  149. struct slot *slot = hotplug_slot->private;
  150. *value = cpci_get_power_status(slot);
  151. return 0;
  152. }
  153. static int
  154. get_attention_status(struct hotplug_slot *hotplug_slot, u8 * value)
  155. {
  156. struct slot *slot = hotplug_slot->private;
  157. *value = cpci_get_attention_status(slot);
  158. return 0;
  159. }
  160. static int
  161. set_attention_status(struct hotplug_slot *hotplug_slot, u8 status)
  162. {
  163. return cpci_set_attention_status(hotplug_slot->private, status);
  164. }
  165. static int
  166. get_adapter_status(struct hotplug_slot *hotplug_slot, u8 * value)
  167. {
  168. *value = hotplug_slot->info->adapter_status;
  169. return 0;
  170. }
  171. static int
  172. get_latch_status(struct hotplug_slot *hotplug_slot, u8 * value)
  173. {
  174. *value = hotplug_slot->info->latch_status;
  175. return 0;
  176. }
  177. static void release_slot(struct hotplug_slot *hotplug_slot)
  178. {
  179. struct slot *slot = hotplug_slot->private;
  180. kfree(slot->hotplug_slot->info);
  181. kfree(slot->hotplug_slot);
  182. if (slot->dev)
  183. pci_dev_put(slot->dev);
  184. kfree(slot);
  185. }
  186. #define SLOT_NAME_SIZE 6
  187. int
  188. cpci_hp_register_bus(struct pci_bus *bus, u8 first, u8 last)
  189. {
  190. struct slot *slot;
  191. struct hotplug_slot *hotplug_slot;
  192. struct hotplug_slot_info *info;
  193. char name[SLOT_NAME_SIZE];
  194. int status = -ENOMEM;
  195. int i;
  196. if (!(controller && bus))
  197. return -ENODEV;
  198. /*
  199. * Create a structure for each slot, and register that slot
  200. * with the pci_hotplug subsystem.
  201. */
  202. for (i = first; i <= last; ++i) {
  203. slot = kzalloc(sizeof (struct slot), GFP_KERNEL);
  204. if (!slot)
  205. goto error;
  206. hotplug_slot =
  207. kzalloc(sizeof (struct hotplug_slot), GFP_KERNEL);
  208. if (!hotplug_slot)
  209. goto error_slot;
  210. slot->hotplug_slot = hotplug_slot;
  211. info = kzalloc(sizeof (struct hotplug_slot_info), GFP_KERNEL);
  212. if (!info)
  213. goto error_hpslot;
  214. hotplug_slot->info = info;
  215. slot->bus = bus;
  216. slot->number = i;
  217. slot->devfn = PCI_DEVFN(i, 0);
  218. snprintf(name, SLOT_NAME_SIZE, "%02x:%02x", bus->number, i);
  219. hotplug_slot->private = slot;
  220. hotplug_slot->release = &release_slot;
  221. hotplug_slot->ops = &cpci_hotplug_slot_ops;
  222. /*
  223. * Initialize the slot info structure with some known
  224. * good values.
  225. */
  226. dbg("initializing slot %s", name);
  227. info->power_status = cpci_get_power_status(slot);
  228. info->attention_status = cpci_get_attention_status(slot);
  229. dbg("registering slot %s", name);
  230. status = pci_hp_register(slot->hotplug_slot, bus, i, name);
  231. if (status) {
  232. err("pci_hp_register failed with error %d", status);
  233. goto error_info;
  234. }
  235. dbg("slot registered with name: %s", slot_name(slot));
  236. /* Add slot to our internal list */
  237. down_write(&list_rwsem);
  238. list_add(&slot->slot_list, &slot_list);
  239. slots++;
  240. up_write(&list_rwsem);
  241. }
  242. return 0;
  243. error_info:
  244. kfree(info);
  245. error_hpslot:
  246. kfree(hotplug_slot);
  247. error_slot:
  248. kfree(slot);
  249. error:
  250. return status;
  251. }
  252. int
  253. cpci_hp_unregister_bus(struct pci_bus *bus)
  254. {
  255. struct slot *slot;
  256. struct slot *tmp;
  257. int status = 0;
  258. down_write(&list_rwsem);
  259. if (!slots) {
  260. up_write(&list_rwsem);
  261. return -1;
  262. }
  263. list_for_each_entry_safe(slot, tmp, &slot_list, slot_list) {
  264. if (slot->bus == bus) {
  265. list_del(&slot->slot_list);
  266. slots--;
  267. dbg("deregistering slot %s", slot_name(slot));
  268. status = pci_hp_deregister(slot->hotplug_slot);
  269. if (status) {
  270. err("pci_hp_deregister failed with error %d",
  271. status);
  272. break;
  273. }
  274. }
  275. }
  276. up_write(&list_rwsem);
  277. return status;
  278. }
  279. /* This is the interrupt mode interrupt handler */
  280. static irqreturn_t
  281. cpci_hp_intr(int irq, void *data)
  282. {
  283. dbg("entered cpci_hp_intr");
  284. /* Check to see if it was our interrupt */
  285. if ((controller->irq_flags & IRQF_SHARED) &&
  286. !controller->ops->check_irq(controller->dev_id)) {
  287. dbg("exited cpci_hp_intr, not our interrupt");
  288. return IRQ_NONE;
  289. }
  290. /* Disable ENUM interrupt */
  291. controller->ops->disable_irq();
  292. /* Trigger processing by the event thread */
  293. wake_up_process(cpci_thread);
  294. return IRQ_HANDLED;
  295. }
  296. /*
  297. * According to PICMG 2.1 R2.0, section 6.3.2, upon
  298. * initialization, the system driver shall clear the
  299. * INS bits of the cold-inserted devices.
  300. */
  301. static int
  302. init_slots(int clear_ins)
  303. {
  304. struct slot *slot;
  305. struct pci_dev* dev;
  306. dbg("%s - enter", __func__);
  307. down_read(&list_rwsem);
  308. if (!slots) {
  309. up_read(&list_rwsem);
  310. return -1;
  311. }
  312. list_for_each_entry(slot, &slot_list, slot_list) {
  313. dbg("%s - looking at slot %s", __func__, slot_name(slot));
  314. if (clear_ins && cpci_check_and_clear_ins(slot))
  315. dbg("%s - cleared INS for slot %s",
  316. __func__, slot_name(slot));
  317. dev = pci_get_slot(slot->bus, PCI_DEVFN(slot->number, 0));
  318. if (dev) {
  319. if (update_adapter_status(slot->hotplug_slot, 1))
  320. warn("failure to update adapter file");
  321. if (update_latch_status(slot->hotplug_slot, 1))
  322. warn("failure to update latch file");
  323. slot->dev = dev;
  324. }
  325. }
  326. up_read(&list_rwsem);
  327. dbg("%s - exit", __func__);
  328. return 0;
  329. }
  330. static int
  331. check_slots(void)
  332. {
  333. struct slot *slot;
  334. int extracted;
  335. int inserted;
  336. u16 hs_csr;
  337. down_read(&list_rwsem);
  338. if (!slots) {
  339. up_read(&list_rwsem);
  340. err("no slots registered, shutting down");
  341. return -1;
  342. }
  343. extracted = inserted = 0;
  344. list_for_each_entry(slot, &slot_list, slot_list) {
  345. dbg("%s - looking at slot %s", __func__, slot_name(slot));
  346. if (cpci_check_and_clear_ins(slot)) {
  347. /*
  348. * Some broken hardware (e.g. PLX 9054AB) asserts
  349. * ENUM# twice...
  350. */
  351. if (slot->dev) {
  352. warn("slot %s already inserted",
  353. slot_name(slot));
  354. inserted++;
  355. continue;
  356. }
  357. /* Process insertion */
  358. dbg("%s - slot %s inserted", __func__, slot_name(slot));
  359. /* GSM, debug */
  360. hs_csr = cpci_get_hs_csr(slot);
  361. dbg("%s - slot %s HS_CSR (1) = %04x",
  362. __func__, slot_name(slot), hs_csr);
  363. /* Configure device */
  364. dbg("%s - configuring slot %s",
  365. __func__, slot_name(slot));
  366. if (cpci_configure_slot(slot)) {
  367. err("%s - could not configure slot %s",
  368. __func__, slot_name(slot));
  369. continue;
  370. }
  371. dbg("%s - finished configuring slot %s",
  372. __func__, slot_name(slot));
  373. /* GSM, debug */
  374. hs_csr = cpci_get_hs_csr(slot);
  375. dbg("%s - slot %s HS_CSR (2) = %04x",
  376. __func__, slot_name(slot), hs_csr);
  377. if (update_latch_status(slot->hotplug_slot, 1))
  378. warn("failure to update latch file");
  379. if (update_adapter_status(slot->hotplug_slot, 1))
  380. warn("failure to update adapter file");
  381. cpci_led_off(slot);
  382. /* GSM, debug */
  383. hs_csr = cpci_get_hs_csr(slot);
  384. dbg("%s - slot %s HS_CSR (3) = %04x",
  385. __func__, slot_name(slot), hs_csr);
  386. inserted++;
  387. } else if (cpci_check_ext(slot)) {
  388. /* Process extraction request */
  389. dbg("%s - slot %s extracted",
  390. __func__, slot_name(slot));
  391. /* GSM, debug */
  392. hs_csr = cpci_get_hs_csr(slot);
  393. dbg("%s - slot %s HS_CSR = %04x",
  394. __func__, slot_name(slot), hs_csr);
  395. if (!slot->extracting) {
  396. if (update_latch_status(slot->hotplug_slot, 0)) {
  397. warn("failure to update latch file");
  398. }
  399. slot->extracting = 1;
  400. atomic_inc(&extracting);
  401. }
  402. extracted++;
  403. } else if (slot->extracting) {
  404. hs_csr = cpci_get_hs_csr(slot);
  405. if (hs_csr == 0xffff) {
  406. /*
  407. * Hmmm, we're likely hosed at this point, should we
  408. * bother trying to tell the driver or not?
  409. */
  410. err("card in slot %s was improperly removed",
  411. slot_name(slot));
  412. if (update_adapter_status(slot->hotplug_slot, 0))
  413. warn("failure to update adapter file");
  414. slot->extracting = 0;
  415. atomic_dec(&extracting);
  416. }
  417. }
  418. }
  419. up_read(&list_rwsem);
  420. dbg("inserted=%d, extracted=%d, extracting=%d",
  421. inserted, extracted, atomic_read(&extracting));
  422. if (inserted || extracted)
  423. return extracted;
  424. else if (!atomic_read(&extracting)) {
  425. err("cannot find ENUM# source, shutting down");
  426. return -1;
  427. }
  428. return 0;
  429. }
  430. /* This is the interrupt mode worker thread body */
  431. static int
  432. event_thread(void *data)
  433. {
  434. int rc;
  435. dbg("%s - event thread started", __func__);
  436. while (1) {
  437. dbg("event thread sleeping");
  438. set_current_state(TASK_INTERRUPTIBLE);
  439. schedule();
  440. if (kthread_should_stop())
  441. break;
  442. do {
  443. rc = check_slots();
  444. if (rc > 0) {
  445. /* Give userspace a chance to handle extraction */
  446. msleep(500);
  447. } else if (rc < 0) {
  448. dbg("%s - error checking slots", __func__);
  449. thread_finished = 1;
  450. goto out;
  451. }
  452. } while (atomic_read(&extracting) && !kthread_should_stop());
  453. if (kthread_should_stop())
  454. break;
  455. /* Re-enable ENUM# interrupt */
  456. dbg("%s - re-enabling irq", __func__);
  457. controller->ops->enable_irq();
  458. }
  459. out:
  460. return 0;
  461. }
  462. /* This is the polling mode worker thread body */
  463. static int
  464. poll_thread(void *data)
  465. {
  466. int rc;
  467. while (1) {
  468. if (kthread_should_stop() || signal_pending(current))
  469. break;
  470. if (controller->ops->query_enum()) {
  471. do {
  472. rc = check_slots();
  473. if (rc > 0) {
  474. /* Give userspace a chance to handle extraction */
  475. msleep(500);
  476. } else if (rc < 0) {
  477. dbg("%s - error checking slots", __func__);
  478. thread_finished = 1;
  479. goto out;
  480. }
  481. } while (atomic_read(&extracting) && !kthread_should_stop());
  482. }
  483. msleep(100);
  484. }
  485. out:
  486. return 0;
  487. }
  488. static int
  489. cpci_start_thread(void)
  490. {
  491. if (controller->irq)
  492. cpci_thread = kthread_run(event_thread, NULL, "cpci_hp_eventd");
  493. else
  494. cpci_thread = kthread_run(poll_thread, NULL, "cpci_hp_polld");
  495. if (IS_ERR(cpci_thread)) {
  496. err("Can't start up our thread");
  497. return PTR_ERR(cpci_thread);
  498. }
  499. thread_finished = 0;
  500. return 0;
  501. }
  502. static void
  503. cpci_stop_thread(void)
  504. {
  505. kthread_stop(cpci_thread);
  506. thread_finished = 1;
  507. }
  508. int
  509. cpci_hp_register_controller(struct cpci_hp_controller *new_controller)
  510. {
  511. int status = 0;
  512. if (controller)
  513. return -1;
  514. if (!(new_controller && new_controller->ops))
  515. return -EINVAL;
  516. if (new_controller->irq) {
  517. if (!(new_controller->ops->enable_irq &&
  518. new_controller->ops->disable_irq))
  519. status = -EINVAL;
  520. if (request_irq(new_controller->irq,
  521. cpci_hp_intr,
  522. new_controller->irq_flags,
  523. MY_NAME,
  524. new_controller->dev_id)) {
  525. err("Can't get irq %d for the hotplug cPCI controller",
  526. new_controller->irq);
  527. status = -ENODEV;
  528. }
  529. dbg("%s - acquired controller irq %d",
  530. __func__, new_controller->irq);
  531. }
  532. if (!status)
  533. controller = new_controller;
  534. return status;
  535. }
  536. static void
  537. cleanup_slots(void)
  538. {
  539. struct slot *slot;
  540. struct slot *tmp;
  541. /*
  542. * Unregister all of our slots with the pci_hotplug subsystem,
  543. * and free up all memory that we had allocated.
  544. */
  545. down_write(&list_rwsem);
  546. if (!slots)
  547. goto cleanup_null;
  548. list_for_each_entry_safe(slot, tmp, &slot_list, slot_list) {
  549. list_del(&slot->slot_list);
  550. pci_hp_deregister(slot->hotplug_slot);
  551. }
  552. cleanup_null:
  553. up_write(&list_rwsem);
  554. return;
  555. }
  556. int
  557. cpci_hp_unregister_controller(struct cpci_hp_controller *old_controller)
  558. {
  559. int status = 0;
  560. if (controller) {
  561. if (!thread_finished)
  562. cpci_stop_thread();
  563. if (controller->irq)
  564. free_irq(controller->irq, controller->dev_id);
  565. controller = NULL;
  566. cleanup_slots();
  567. } else
  568. status = -ENODEV;
  569. return status;
  570. }
  571. int
  572. cpci_hp_start(void)
  573. {
  574. static int first = 1;
  575. int status;
  576. dbg("%s - enter", __func__);
  577. if (!controller)
  578. return -ENODEV;
  579. down_read(&list_rwsem);
  580. if (list_empty(&slot_list)) {
  581. up_read(&list_rwsem);
  582. return -ENODEV;
  583. }
  584. up_read(&list_rwsem);
  585. status = init_slots(first);
  586. if (first)
  587. first = 0;
  588. if (status)
  589. return status;
  590. status = cpci_start_thread();
  591. if (status)
  592. return status;
  593. dbg("%s - thread started", __func__);
  594. if (controller->irq) {
  595. /* Start enum interrupt processing */
  596. dbg("%s - enabling irq", __func__);
  597. controller->ops->enable_irq();
  598. }
  599. dbg("%s - exit", __func__);
  600. return 0;
  601. }
  602. int
  603. cpci_hp_stop(void)
  604. {
  605. if (!controller)
  606. return -ENODEV;
  607. if (controller->irq) {
  608. /* Stop enum interrupt processing */
  609. dbg("%s - disabling irq", __func__);
  610. controller->ops->disable_irq();
  611. }
  612. cpci_stop_thread();
  613. return 0;
  614. }
  615. int __init
  616. cpci_hotplug_init(int debug)
  617. {
  618. cpci_debug = debug;
  619. return 0;
  620. }
  621. void __exit
  622. cpci_hotplug_exit(void)
  623. {
  624. /*
  625. * Clean everything up.
  626. */
  627. cpci_hp_stop();
  628. cpci_hp_unregister_controller(controller);
  629. }
  630. EXPORT_SYMBOL_GPL(cpci_hp_register_controller);
  631. EXPORT_SYMBOL_GPL(cpci_hp_unregister_controller);
  632. EXPORT_SYMBOL_GPL(cpci_hp_register_bus);
  633. EXPORT_SYMBOL_GPL(cpci_hp_unregister_bus);
  634. EXPORT_SYMBOL_GPL(cpci_hp_start);
  635. EXPORT_SYMBOL_GPL(cpci_hp_stop);