David Brazdil | 0f672f6 | 2019-12-10 10:32:29 +0000 | [diff] [blame] | 1 | // SPDX-License-Identifier: GPL-2.0-only |
Andrew Scull | b4b6d4a | 2019-01-02 15:54:55 +0000 | [diff] [blame] | 2 | /* |
| 3 | * EISA specific code |
Andrew Scull | b4b6d4a | 2019-01-02 15:54:55 +0000 | [diff] [blame] | 4 | */ |
| 5 | #include <linux/ioport.h> |
| 6 | #include <linux/eisa.h> |
| 7 | #include <linux/io.h> |
| 8 | |
| 9 | #include <xen/xen.h> |
| 10 | |
| 11 | static __init int eisa_bus_probe(void) |
| 12 | { |
| 13 | void __iomem *p; |
| 14 | |
| 15 | if (xen_pv_domain() && !xen_initial_domain()) |
| 16 | return 0; |
| 17 | |
| 18 | p = ioremap(0x0FFFD9, 4); |
| 19 | if (p && readl(p) == 'E' + ('I' << 8) + ('S' << 16) + ('A' << 24)) |
| 20 | EISA_bus = 1; |
| 21 | iounmap(p); |
| 22 | return 0; |
| 23 | } |
| 24 | subsys_initcall(eisa_bus_probe); |