1a1d0d98daf6ce580d017a43b09fe30a375cde3e8David Gibson/*
2a1d0d98daf6ce580d017a43b09fe30a375cde3e8David Gibson * Copyright 2009 IBM Corporation.
3a1d0d98daf6ce580d017a43b09fe30a375cde3e8David Gibson *
4a1d0d98daf6ce580d017a43b09fe30a375cde3e8David Gibson *  This program is free software; you can redistribute it and/or
5a1d0d98daf6ce580d017a43b09fe30a375cde3e8David Gibson *  modify it under the terms of the GNU General Public License
6a1d0d98daf6ce580d017a43b09fe30a375cde3e8David Gibson *  as published by the Free Software Foundation; either version
7a1d0d98daf6ce580d017a43b09fe30a375cde3e8David Gibson *  2 of the License, or (at your option) any later version.
8a1d0d98daf6ce580d017a43b09fe30a375cde3e8David Gibson */
9a1d0d98daf6ce580d017a43b09fe30a375cde3e8David Gibson
10a1d0d98daf6ce580d017a43b09fe30a375cde3e8David Gibson#ifndef __ICS_H
11a1d0d98daf6ce580d017a43b09fe30a375cde3e8David Gibson#define __ICS_H
12a1d0d98daf6ce580d017a43b09fe30a375cde3e8David Gibson
13a1d0d98daf6ce580d017a43b09fe30a375cde3e8David Gibson#define XIVE_ADDR_MASK		0x7FFULL
14a1d0d98daf6ce580d017a43b09fe30a375cde3e8David Gibson
15a1d0d98daf6ce580d017a43b09fe30a375cde3e8David Gibsonextern void wsp_init_irq(void);
16a1d0d98daf6ce580d017a43b09fe30a375cde3e8David Gibson
17a1d0d98daf6ce580d017a43b09fe30a375cde3e8David Gibsonextern int wsp_ics_alloc_irq(struct device_node *dn, int num);
18a1d0d98daf6ce580d017a43b09fe30a375cde3e8David Gibsonextern void wsp_ics_free_irq(struct device_node *dn, unsigned int irq);
19a1d0d98daf6ce580d017a43b09fe30a375cde3e8David Gibson
20f9a71e0fd1b44148d7af6ce2fecfb2cf7a4df636Michael Ellerman#ifdef CONFIG_PCI_MSI
21f9a71e0fd1b44148d7af6ce2fecfb2cf7a4df636Michael Ellermanextern void wsp_ics_set_msi_chip(unsigned int irq);
22f9a71e0fd1b44148d7af6ce2fecfb2cf7a4df636Michael Ellermanextern void wsp_ics_set_std_chip(unsigned int irq);
23f9a71e0fd1b44148d7af6ce2fecfb2cf7a4df636Michael Ellerman#endif /* CONFIG_PCI_MSI */
24f9a71e0fd1b44148d7af6ce2fecfb2cf7a4df636Michael Ellerman
25a1d0d98daf6ce580d017a43b09fe30a375cde3e8David Gibson#endif /* __ICS_H */
26