1 // SPDX-License-Identifier: GPL-2.0-only
3 * Copyright (C) 2007 Google, Inc.
4 * Copyright (C) 2011 Intel, Inc.
5 * Copyright (C) 2013 Intel, Inc.
8 #include <linux/kernel.h>
10 #include <linux/platform_device.h>
13 * Where in virtual device memory the IO devices (timers, system controllers
17 #define GOLDFISH_PDEV_BUS_BASE (0xff001000)
18 #define GOLDFISH_PDEV_BUS_END (0xff7fffff)
19 #define GOLDFISH_PDEV_BUS_IRQ (4)
21 #define GOLDFISH_TTY_BASE (0x2000)
23 static struct resource goldfish_pdev_bus_resources
[] = {
25 .start
= GOLDFISH_PDEV_BUS_BASE
,
26 .end
= GOLDFISH_PDEV_BUS_END
,
27 .flags
= IORESOURCE_MEM
,
30 .start
= GOLDFISH_PDEV_BUS_IRQ
,
31 .end
= GOLDFISH_PDEV_BUS_IRQ
,
32 .flags
= IORESOURCE_IRQ
,
36 static bool goldfish_enable __initdata
;
38 static int __init
goldfish_setup(char *str
)
40 goldfish_enable
= true;
43 __setup("goldfish", goldfish_setup
);
45 static int __init
goldfish_init(void)
50 platform_device_register_simple("goldfish_pdev_bus", -1,
51 goldfish_pdev_bus_resources
, 2);
54 device_initcall(goldfish_init
);