f3a8d7bd69d6ef77094307523aac0588fe323dd5
[pandora-u-boot.git] / arch / arm / cpu / arm926ejs / mx27 / asm-offsets.c
1 /*
2  * Adapted from Linux v2.6.36 kernel: arch/powerpc/kernel/asm-offsets.c
3  *
4  * This program is used to generate definitions needed by
5  * assembly language modules.
6  *
7  * We use the technique used in the OSF Mach kernel code:
8  * generate asm statements containing #defines,
9  * compile this file to assembler, and then extract the
10  * #defines from the assembly-language output.
11  *
12  * This program is free software; you can redistribute it and/or
13  * modify it under the terms of the GNU General Public License
14  * as published by the Free Software Foundation; either version
15  * 2 of the License, or (at your option) any later version.
16  */
17
18 #include <common.h>
19 #include <asm/arch/imx-regs.h>
20
21 #include <linux/kbuild.h>
22
23 int main(void)
24 {
25         DEFINE(AIPI1_PSR0, IMX_AIPI1_BASE + offsetof(struct aipi_regs, psr0));
26         DEFINE(AIPI1_PSR1, IMX_AIPI1_BASE + offsetof(struct aipi_regs, psr1));
27         DEFINE(AIPI2_PSR0, IMX_AIPI2_BASE + offsetof(struct aipi_regs, psr0));
28         DEFINE(AIPI2_PSR1, IMX_AIPI2_BASE + offsetof(struct aipi_regs, psr1));
29
30         DEFINE(CSCR, IMX_PLL_BASE + offsetof(struct pll_regs, cscr));
31         DEFINE(MPCTL0, IMX_PLL_BASE + offsetof(struct pll_regs, mpctl0));
32         DEFINE(SPCTL0, IMX_PLL_BASE + offsetof(struct pll_regs, spctl0));
33         DEFINE(PCDR0, IMX_PLL_BASE + offsetof(struct pll_regs, pcdr0));
34         DEFINE(PCDR1, IMX_PLL_BASE + offsetof(struct pll_regs, pcdr1));
35         DEFINE(PCCR0, IMX_PLL_BASE + offsetof(struct pll_regs, pccr0));
36         DEFINE(PCCR1, IMX_PLL_BASE + offsetof(struct pll_regs, pccr1));
37
38         DEFINE(ESDCTL0_ROF, offsetof(struct esdramc_regs, esdctl0));
39         DEFINE(ESDCFG0_ROF, offsetof(struct esdramc_regs, esdcfg0));
40         DEFINE(ESDCTL1_ROF, offsetof(struct esdramc_regs, esdctl1));
41         DEFINE(ESDCFG1_ROF, offsetof(struct esdramc_regs, esdcfg1));
42         DEFINE(ESDMISC_ROF, offsetof(struct esdramc_regs, esdmisc));
43
44         return 0;
45 }