]> git.ipfire.org Git - people/ms/u-boot.git/blame - arch/powerpc/include/asm/ppc.h
powerpc, 5xx: remove support for 5xx
[people/ms/u-boot.git] / arch / powerpc / include / asm / ppc.h
CommitLineData
85043159
SG
1/*
2 * Ugly header containing required header files. This could be adjusted
3 * so that including asm/arch/hardware includes the correct file.
4 *
5 * (C) Copyright 2000-2009
6 * Wolfgang Denk, DENX Software Engineering, wd@denx.de.
7 *
8 * SPDX-License-Identifier: GPL-2.0+
9 */
10
11#ifndef __ASM_PPC_H
12#define __ASM_PPC_H
13
14#ifndef __ASSEMBLY__
15
50258977 16#if defined(CONFIG_MPC5xxx)
85043159
SG
17#include <mpc5xxx.h>
18#elif defined(CONFIG_MPC512X)
19#include <asm/immap_512x.h>
85043159
SG
20#endif
21#ifdef CONFIG_MPC86xx
22#include <mpc86xx.h>
23#include <asm/immap_86xx.h>
24#endif
25#ifdef CONFIG_MPC85xx
26#include <mpc85xx.h>
27#include <asm/immap_85xx.h>
28#endif
29#ifdef CONFIG_MPC83xx
30#include <mpc83xx.h>
31#include <asm/immap_83xx.h>
32#endif
33#ifdef CONFIG_4xx
34#include <asm/ppc4xx.h>
35#endif
36#ifdef CONFIG_SOC_DA8XX
37#include <asm/arch/hardware.h>
38#endif
39#ifdef CONFIG_FSL_LSCH3
40#include <asm/arch/immap_lsch3.h>
41#endif
42#ifdef CONFIG_FSL_LSCH2
43#include <asm/arch/immap_lsch2.h>
44#endif
45
6e2941d7
SG
46#if defined(CONFIG_MPC5xxx)
47uint get_svr(void);
48#endif
49uint get_pvr(void);
50uint get_svr(void);
51uint rd_ic_cst(void);
52void wr_ic_cst(uint);
53void wr_ic_adr(uint);
54uint rd_dc_cst(void);
55void wr_dc_cst(uint);
56void wr_dc_adr(uint);
57
58#if defined(CONFIG_4xx) || \
59 defined(CONFIG_MPC5xxx) || \
60 defined(CONFIG_MPC85xx) || \
61 defined(CONFIG_MPC86xx) || \
62 defined(CONFIG_MPC83xx)
63unsigned char in8(unsigned int);
64void out8(unsigned int, unsigned char);
65unsigned short in16(unsigned int);
66unsigned short in16r(unsigned int);
67void out16(unsigned int, unsigned short value);
68void out16r(unsigned int, unsigned short value);
69unsigned long in32(unsigned int);
70unsigned long in32r(unsigned int);
71void out32(unsigned int, unsigned long value);
72void out32r(unsigned int, unsigned long value);
73void ppcDcbf(unsigned long value);
74void ppcDcbi(unsigned long value);
75void ppcSync(void);
76void ppcDcbz(unsigned long value);
77#endif
78#if defined(CONFIG_MPC83xx)
79void ppcDWload(unsigned int *addr, unsigned int *ret);
80void ppcDWstore(unsigned int *addr, unsigned int *value);
81void disable_addr_trans(void);
82void enable_addr_trans(void);
83#if defined(CONFIG_DDR_ECC) && !defined(CONFIG_ECC_INIT_VIA_DDRCONTROLLER)
84void ddr_enable_ecc(unsigned int dram_size);
85#endif
86#endif
87
88#if defined(CONFIG_MPC5xxx)
89int prt_mpc5xxx_clks(void);
90#endif
91
92#if defined(CONFIG_MPC85xx)
93typedef MPC85xx_SYS_INFO sys_info_t;
94void get_sys_info(sys_info_t *);
95void ft_fixup_cpu(void *, u64);
96void ft_fixup_num_cores(void *);
97#endif
98#if defined(CONFIG_MPC86xx)
99ulong get_bus_freq(ulong);
100typedef MPC86xx_SYS_INFO sys_info_t;
101void get_sys_info(sys_info_t *);
102static inline ulong get_ddr_freq(ulong dummy)
103{
104 return get_bus_freq(dummy);
105}
106#else
107ulong get_ddr_freq(ulong);
108#endif
109
85043159
SG
110#endif /* !__ASSEMBLY__ */
111
6e2941d7
SG
112#ifdef CONFIG_PPC
113/*
114 * Has to be included outside of the #ifndef __ASSEMBLY__ section.
115 * Otherwise might lead to compilation errors in assembler files.
116 */
117#include <asm/cache.h>
118#endif
119
85043159 120#endif