Add linux-next specific files for 20110831
[linux-2.6/next.git] / arch / arm / plat-mxc / devices / platform-gpio-mxc.c
bloba7919a241032184b94d005846eff6c84e66fc0e7
1 /*
2 * Copyright 2011 Freescale Semiconductor, Inc. All Rights Reserved.
3 * Copyright 2011 Linaro Limited
5 * This program is free software; you can redistribute it and/or modify it under
6 * the terms of the GNU General Public License version 2 as published by the
7 * Free Software Foundation.
8 */
9 #include <mach/devices-common.h>
11 struct platform_device *__init mxc_register_gpio(char *name, int id,
12 resource_size_t iobase, resource_size_t iosize, int irq, int irq_high)
14 struct resource res[] = {
16 .start = iobase,
17 .end = iobase + iosize - 1,
18 .flags = IORESOURCE_MEM,
19 }, {
20 .start = irq,
21 .end = irq,
22 .flags = IORESOURCE_IRQ,
23 }, {
24 .start = irq_high,
25 .end = irq_high,
26 .flags = IORESOURCE_IRQ,
30 return platform_device_register_resndata(&mxc_aips_bus,
31 name, id, res, ARRAY_SIZE(res), NULL, 0);