lantiq: split compat headers out of bsp header patch
[openwrt/svn-archive/archive.git] / target / linux / lantiq / patches / 110-sdk-compat.patch
1 Index: linux-3.1/arch/mips/include/asm/mach-lantiq/falcon/sysctrl.h
2 ===================================================================
3 --- /dev/null 1970-01-01 00:00:00.000000000 +0000
4 +++ linux-3.1/arch/mips/include/asm/mach-lantiq/falcon/sysctrl.h 2011-11-13 00:18:10.316010867 +0100
5 @@ -0,0 +1,60 @@
6 +/*
7 + * This program is free software; you can redistribute it and/or
8 + * modify it under the terms of the GNU General Public License as
9 + * published by the Free Software Foundation; either version 2 of
10 + * the License, or (at your option) any later version.
11 + *
12 + * This program is distributed in the hope that it will be useful,
13 + * but WITHOUT ANY WARRANTY; without even the implied warranty of
14 + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
15 + * GNU General Public License for more details.
16 + *
17 + * You should have received a copy of the GNU General Public License
18 + * along with this program; if not, write to the Free Software
19 + * Foundation, Inc., 59 Temple Place, Suite 330, Boston,
20 + * MA 02111-1307 USA
21 + *
22 + * Copyright (C) 2010 Thomas Langer, Lantiq Deutschland
23 + */
24 +
25 +#ifndef __FALCON_SYSCTRL_H
26 +#define __FALCON_SYSCTRL_H
27 +
28 +#include <falcon/lantiq_soc.h>
29 +
30 +static inline void sys1_hw_activate(u32 mask)
31 +{ ltq_sysctl_activate(SYSCTL_SYS1, mask); }
32 +static inline void sys1_hw_deactivate(u32 mask)
33 +{ ltq_sysctl_deactivate(SYSCTL_SYS1, mask); }
34 +static inline void sys1_hw_clk_enable(u32 mask)
35 +{ ltq_sysctl_clken(SYSCTL_SYS1, mask); }
36 +static inline void sys1_hw_clk_disable(u32 mask)
37 +{ ltq_sysctl_clkdis(SYSCTL_SYS1, mask); }
38 +static inline void sys1_hw_activate_or_reboot(u32 mask)
39 +{ ltq_sysctl_reboot(SYSCTL_SYS1, mask); }
40 +
41 +static inline void sys_eth_hw_activate(u32 mask)
42 +{ ltq_sysctl_activate(SYSCTL_SYSETH, mask); }
43 +static inline void sys_eth_hw_deactivate(u32 mask)
44 +{ ltq_sysctl_deactivate(SYSCTL_SYSETH, mask); }
45 +static inline void sys_eth_hw_clk_enable(u32 mask)
46 +{ ltq_sysctl_clken(SYSCTL_SYSETH, mask); }
47 +static inline void sys_eth_hw_clk_disable(u32 mask)
48 +{ ltq_sysctl_clkdis(SYSCTL_SYSETH, mask); }
49 +static inline void sys_eth_hw_activate_or_reboot(u32 mask)
50 +{ ltq_sysctl_reboot(SYSCTL_SYSETH, mask); }
51 +
52 +static inline void sys_gpe_hw_activate(u32 mask)
53 +{ ltq_sysctl_activate(SYSCTL_SYSGPE, mask); }
54 +static inline void sys_gpe_hw_deactivate(u32 mask)
55 +{ ltq_sysctl_deactivate(SYSCTL_SYSGPE, mask); }
56 +static inline void sys_gpe_hw_clk_enable(u32 mask)
57 +{ ltq_sysctl_clken(SYSCTL_SYSGPE, mask); }
58 +static inline void sys_gpe_hw_clk_disable(u32 mask)
59 +{ ltq_sysctl_clkdis(SYSCTL_SYSGPE, mask); }
60 +static inline void sys_gpe_hw_activate_or_reboot(u32 mask)
61 +{ ltq_sysctl_reboot(SYSCTL_SYSGPE, mask); }
62 +static inline int sys_gpe_hw_is_activated(u32 mask)
63 +{ return 1; }
64 +
65 +#endif /* __FALCON_SYSCTRL_H */