diff options
author | Paul Mackerras <paulus@samba.org> | 2006-09-27 17:18:28 -0400 |
---|---|---|
committer | Paul Mackerras <paulus@samba.org> | 2006-09-27 17:18:28 -0400 |
commit | 4e6d816e51728d5006c53e78e079ac62b902f8aa (patch) | |
tree | d388c87dabc063c08c52d17610738d2f49b3855c /include/asm-powerpc | |
parent | d86d9b8cab45adf64e2ea8fe975bec3282b5de81 (diff) | |
parent | 611a15afcdaacec6efba984c7eb089b853564bdf (diff) |
Merge branch 'upstream' of git://git.kernel.org/pub/scm/linux/kernel/git/vitb/linux-2.6-PQ
Diffstat (limited to 'include/asm-powerpc')
-rw-r--r-- | include/asm-powerpc/fs_pd.h | 45 | ||||
-rw-r--r-- | include/asm-powerpc/mpc85xx.h | 53 |
2 files changed, 98 insertions, 0 deletions
diff --git a/include/asm-powerpc/fs_pd.h b/include/asm-powerpc/fs_pd.h new file mode 100644 index 000000000000..3d0e819d37f1 --- /dev/null +++ b/include/asm-powerpc/fs_pd.h | |||
@@ -0,0 +1,45 @@ | |||
1 | /* | ||
2 | * Platform information definitions. | ||
3 | * | ||
4 | * 2006 (c) MontaVista Software, Inc. | ||
5 | * Vitaly Bordug <vbordug@ru.mvista.com> | ||
6 | * | ||
7 | * This file is licensed under the terms of the GNU General Public License | ||
8 | * version 2. This program is licensed "as is" without any warranty of any | ||
9 | * kind, whether express or implied. | ||
10 | */ | ||
11 | |||
12 | #ifndef FS_PD_H | ||
13 | #define FS_PD_H | ||
14 | #include <asm/cpm2.h> | ||
15 | #include <sysdev/fsl_soc.h> | ||
16 | #include <asm/time.h> | ||
17 | |||
18 | static inline int uart_baudrate(void) | ||
19 | { | ||
20 | return get_baudrate(); | ||
21 | } | ||
22 | |||
23 | static inline int uart_clock(void) | ||
24 | { | ||
25 | return ppc_proc_freq; | ||
26 | } | ||
27 | |||
28 | #define cpm2_map(member) \ | ||
29 | ({ \ | ||
30 | u32 offset = offsetof(cpm2_map_t, member); \ | ||
31 | void *addr = ioremap (CPM_MAP_ADDR + offset, \ | ||
32 | sizeof( ((cpm2_map_t*)0)->member)); \ | ||
33 | addr; \ | ||
34 | }) | ||
35 | |||
36 | #define cpm2_map_size(member, size) \ | ||
37 | ({ \ | ||
38 | u32 offset = offsetof(cpm2_map_t, member); \ | ||
39 | void *addr = ioremap (CPM_MAP_ADDR + offset, size); \ | ||
40 | addr; \ | ||
41 | }) | ||
42 | |||
43 | #define cpm2_unmap(addr) iounmap(addr) | ||
44 | |||
45 | #endif | ||
diff --git a/include/asm-powerpc/mpc85xx.h b/include/asm-powerpc/mpc85xx.h new file mode 100644 index 000000000000..ccdb8a21138f --- /dev/null +++ b/include/asm-powerpc/mpc85xx.h | |||
@@ -0,0 +1,53 @@ | |||
1 | /* | ||
2 | * include/asm-powerpc/mpc85xx.h | ||
3 | * | ||
4 | * MPC85xx definitions | ||
5 | * | ||
6 | * Maintainer: Kumar Gala <galak@kernel.crashing.org> | ||
7 | * | ||
8 | * Copyright 2004 Freescale Semiconductor, Inc | ||
9 | * | ||
10 | * This program is free software; you can redistribute it and/or modify it | ||
11 | * under the terms of the GNU General Public License as published by the | ||
12 | * Free Software Foundation; either version 2 of the License, or (at your | ||
13 | * option) any later version. | ||
14 | */ | ||
15 | |||
16 | #ifdef __KERNEL__ | ||
17 | #ifndef __ASM_MPC85xx_H__ | ||
18 | #define __ASM_MPC85xx_H__ | ||
19 | |||
20 | #include <asm/mmu.h> | ||
21 | |||
22 | #ifdef CONFIG_85xx | ||
23 | |||
24 | #if defined(CONFIG_MPC8540_ADS) || defined(CONFIG_MPC8560_ADS) | ||
25 | #include <platforms/85xx/mpc85xx_ads.h> | ||
26 | #endif | ||
27 | #if defined(CONFIG_MPC8555_CDS) || defined(CONFIG_MPC8548_CDS) | ||
28 | #include <platforms/85xx/mpc8555_cds.h> | ||
29 | #endif | ||
30 | #ifdef CONFIG_MPC85xx_CDS | ||
31 | #include <platforms/85xx/mpc85xx_cds.h> | ||
32 | #endif | ||
33 | |||
34 | #define _IO_BASE isa_io_base | ||
35 | #define _ISA_MEM_BASE isa_mem_base | ||
36 | #ifdef CONFIG_PCI | ||
37 | #define PCI_DRAM_OFFSET pci_dram_offset | ||
38 | #else | ||
39 | #define PCI_DRAM_OFFSET 0 | ||
40 | #endif | ||
41 | |||
42 | /* Let modules/drivers get at CCSRBAR */ | ||
43 | extern phys_addr_t get_ccsrbar(void); | ||
44 | |||
45 | #ifdef MODULE | ||
46 | #define CCSRBAR get_ccsrbar() | ||
47 | #else | ||
48 | #define CCSRBAR BOARD_CCSRBAR | ||
49 | #endif | ||
50 | |||
51 | #endif /* CONFIG_85xx */ | ||
52 | #endif /* __ASM_MPC85xx_H__ */ | ||
53 | #endif /* __KERNEL__ */ | ||