aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/pcmcia/pxa2xx_cm_x2xx.c
diff options
context:
space:
mode:
authorRussell King <rmk@dyn-67.arm.linux.org.uk>2008-10-07 14:08:56 -0400
committerRussell King <rmk+kernel@arm.linux.org.uk>2008-10-07 14:08:56 -0400
commit5a89770daad83df74d77a8d34a1ffaedae565ce9 (patch)
tree0d8ef70293a6ef969ba8b7718e59608337643d40 /drivers/pcmcia/pxa2xx_cm_x2xx.c
parentc46c948260f41af18b277c1eb1895d788d3605dc (diff)
parentaf7c951d76708c61b862463d579d76be757130bf (diff)
Merge branches 'pxa-core' and 'pxa-machines' into pxa-all
Conflicts: arch/arm/mach-pxa/Kconfig arch/arm/mach-pxa/pxa25x.c arch/arm/mach-pxa/pxa27x.c
Diffstat (limited to 'drivers/pcmcia/pxa2xx_cm_x2xx.c')
-rw-r--r--drivers/pcmcia/pxa2xx_cm_x2xx.c49
1 files changed, 49 insertions, 0 deletions
diff --git a/drivers/pcmcia/pxa2xx_cm_x2xx.c b/drivers/pcmcia/pxa2xx_cm_x2xx.c
new file mode 100644
index 000000000000..4f09506ad8d4
--- /dev/null
+++ b/drivers/pcmcia/pxa2xx_cm_x2xx.c
@@ -0,0 +1,49 @@
1/*
2 * linux/drivers/pcmcia/pxa/pxa_cm_x2xx.c
3 *
4 * This program is free software; you can redistribute it and/or modify
5 * it under the terms of the GNU General Public License version 2 as
6 * published by the Free Software Foundation.
7 *
8 * Compulab Ltd., 2003, 2007, 2008
9 * Mike Rapoport <mike@compulab.co.il>
10 *
11 */
12
13#include <linux/module.h>
14
15#include <asm/system.h>
16#include <asm/mach-types.h>
17#include <mach/system.h>
18
19int cmx255_pcmcia_init(void);
20int cmx270_pcmcia_init(void);
21void cmx255_pcmcia_exit(void);
22void cmx270_pcmcia_exit(void);
23
24static int __init cmx2xx_pcmcia_init(void)
25{
26 int ret = -ENODEV;
27
28 if (machine_is_armcore() && cpu_is_pxa25x())
29 ret = cmx255_pcmcia_init();
30 else if (machine_is_armcore() && cpu_is_pxa27x())
31 ret = cmx270_pcmcia_init();
32
33 return ret;
34}
35
36static void __exit cmx2xx_pcmcia_exit(void)
37{
38 if (machine_is_armcore() && cpu_is_pxa25x())
39 cmx255_pcmcia_exit();
40 else if (machine_is_armcore() && cpu_is_pxa27x())
41 cmx270_pcmcia_exit();
42}
43
44module_init(cmx2xx_pcmcia_init);
45module_exit(cmx2xx_pcmcia_exit);
46
47MODULE_LICENSE("GPL");
48MODULE_AUTHOR("Mike Rapoport <mike@compulab.co.il>");
49MODULE_DESCRIPTION("CM-x2xx PCMCIA driver");