Heiko J Schick | d7a3010 | 2005-11-16 08:56:43 +0100 | [diff] [blame] | 1 | /* |
| 2 | * IBM PowerPC eBus Infrastructure Support. |
| 3 | * |
| 4 | * Copyright (c) 2005 IBM Corporation |
Joachim Fenkes | 6bccf75 | 2007-03-09 19:00:32 +0100 | [diff] [blame] | 5 | * Joachim Fenkes <fenkes@de.ibm.com> |
Heiko J Schick | d7a3010 | 2005-11-16 08:56:43 +0100 | [diff] [blame] | 6 | * Heiko J Schick <schickhj@de.ibm.com> |
Joachim Fenkes | a830880 | 2007-03-09 18:56:46 +0100 | [diff] [blame] | 7 | * |
Heiko J Schick | d7a3010 | 2005-11-16 08:56:43 +0100 | [diff] [blame] | 8 | * All rights reserved. |
| 9 | * |
Joachim Fenkes | a830880 | 2007-03-09 18:56:46 +0100 | [diff] [blame] | 10 | * This source code is distributed under a dual license of GPL v2.0 and OpenIB |
| 11 | * BSD. |
Heiko J Schick | d7a3010 | 2005-11-16 08:56:43 +0100 | [diff] [blame] | 12 | * |
| 13 | * OpenIB BSD License |
| 14 | * |
Joachim Fenkes | a830880 | 2007-03-09 18:56:46 +0100 | [diff] [blame] | 15 | * Redistribution and use in source and binary forms, with or without |
| 16 | * modification, are permitted provided that the following conditions are met: |
Heiko J Schick | d7a3010 | 2005-11-16 08:56:43 +0100 | [diff] [blame] | 17 | * |
Joachim Fenkes | a830880 | 2007-03-09 18:56:46 +0100 | [diff] [blame] | 18 | * Redistributions of source code must retain the above copyright notice, this |
| 19 | * list of conditions and the following disclaimer. |
Heiko J Schick | d7a3010 | 2005-11-16 08:56:43 +0100 | [diff] [blame] | 20 | * |
Joachim Fenkes | a830880 | 2007-03-09 18:56:46 +0100 | [diff] [blame] | 21 | * Redistributions in binary form must reproduce the above copyright notice, |
| 22 | * this list of conditions and the following disclaimer in the documentation |
Heiko J Schick | d7a3010 | 2005-11-16 08:56:43 +0100 | [diff] [blame] | 23 | * and/or other materials |
Joachim Fenkes | a830880 | 2007-03-09 18:56:46 +0100 | [diff] [blame] | 24 | * provided with the distribution. |
Heiko J Schick | d7a3010 | 2005-11-16 08:56:43 +0100 | [diff] [blame] | 25 | * |
Joachim Fenkes | a830880 | 2007-03-09 18:56:46 +0100 | [diff] [blame] | 26 | * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" |
| 27 | * AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE |
| 28 | * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE |
| 29 | * ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR CONTRIBUTORS BE |
| 30 | * LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR |
| 31 | * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF |
Heiko J Schick | d7a3010 | 2005-11-16 08:56:43 +0100 | [diff] [blame] | 32 | * SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR |
| 33 | * BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER |
Joachim Fenkes | a830880 | 2007-03-09 18:56:46 +0100 | [diff] [blame] | 34 | * IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) |
| 35 | * ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE |
Heiko J Schick | d7a3010 | 2005-11-16 08:56:43 +0100 | [diff] [blame] | 36 | * POSSIBILITY OF SUCH DAMAGE. |
| 37 | */ |
| 38 | |
| 39 | #ifndef _ASM_EBUS_H |
| 40 | #define _ASM_EBUS_H |
Arnd Bergmann | 88ced03 | 2005-12-16 22:43:46 +0100 | [diff] [blame] | 41 | #ifdef __KERNEL__ |
Heiko J Schick | d7a3010 | 2005-11-16 08:56:43 +0100 | [diff] [blame] | 42 | |
| 43 | #include <linux/device.h> |
| 44 | #include <linux/interrupt.h> |
| 45 | #include <linux/mod_devicetable.h> |
Joachim Fenkes | 6b08f3a | 2007-09-26 19:45:51 +1000 | [diff] [blame] | 46 | #include <linux/of_device.h> |
| 47 | #include <linux/of_platform.h> |
Heiko J Schick | d7a3010 | 2005-11-16 08:56:43 +0100 | [diff] [blame] | 48 | |
Heiko J Schick | d7a3010 | 2005-11-16 08:56:43 +0100 | [diff] [blame] | 49 | extern struct bus_type ibmebus_bus_type; |
| 50 | |
Joachim Fenkes | 6b08f3a | 2007-09-26 19:45:51 +1000 | [diff] [blame] | 51 | int ibmebus_register_driver(struct of_platform_driver *drv); |
| 52 | void ibmebus_unregister_driver(struct of_platform_driver *drv); |
Heiko J Schick | d7a3010 | 2005-11-16 08:56:43 +0100 | [diff] [blame] | 53 | |
Joachim Fenkes | 6b08f3a | 2007-09-26 19:45:51 +1000 | [diff] [blame] | 54 | int ibmebus_request_irq(u32 ist, irq_handler_t handler, |
| 55 | unsigned long irq_flags, const char *devname, |
Heiko J Schick | d7a3010 | 2005-11-16 08:56:43 +0100 | [diff] [blame] | 56 | void *dev_id); |
Joachim Fenkes | 6b08f3a | 2007-09-26 19:45:51 +1000 | [diff] [blame] | 57 | void ibmebus_free_irq(u32 ist, void *dev_id); |
Heiko J Schick | d7a3010 | 2005-11-16 08:56:43 +0100 | [diff] [blame] | 58 | |
Arnd Bergmann | 88ced03 | 2005-12-16 22:43:46 +0100 | [diff] [blame] | 59 | #endif /* __KERNEL__ */ |
Heiko J Schick | d7a3010 | 2005-11-16 08:56:43 +0100 | [diff] [blame] | 60 | #endif /* _ASM_IBMEBUS_H */ |