Root/
1 | /****************************************************************************** |
2 | * Copyright (c) 2008 Isaku Yamahata <yamahata at valinux co jp> |
3 | * VA Linux Systems Japan K.K. |
4 | * |
5 | * This program is free software; you can redistribute it and/or modify |
6 | * it under the terms of the GNU General Public License as published by |
7 | * the Free Software Foundation; either version 2 of the License, or |
8 | * (at your option) any later version. |
9 | * |
10 | * This program is distributed in the hope that it will be useful, |
11 | * but WITHOUT ANY WARRANTY; without even the implied warranty of |
12 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the |
13 | * GNU General Public License for more details. |
14 | * |
15 | * You should have received a copy of the GNU General Public License |
16 | * along with this program; if not, write to the Free Software |
17 | * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA |
18 | * |
19 | */ |
20 | |
21 | #include <linux/bug.h> |
22 | #include <linux/init.h> |
23 | #include <linux/kernel.h> |
24 | #include <asm/paravirt.h> |
25 | |
26 | #define DECLARE(name) \ |
27 | extern unsigned long \ |
28 | __ia64_native_start_gate_##name##_patchlist[]; \ |
29 | extern unsigned long \ |
30 | __ia64_native_end_gate_##name##_patchlist[] |
31 | |
32 | DECLARE(fsyscall); |
33 | DECLARE(brl_fsys_bubble_down); |
34 | DECLARE(vtop); |
35 | DECLARE(mckinley_e9); |
36 | |
37 | extern unsigned long __start_gate_section[]; |
38 | |
39 | #define ASSIGN(name) \ |
40 | .start_##name##_patchlist = \ |
41 | (unsigned long)__ia64_native_start_gate_##name##_patchlist, \ |
42 | .end_##name##_patchlist = \ |
43 | (unsigned long)__ia64_native_end_gate_##name##_patchlist |
44 | |
45 | struct pv_patchdata pv_patchdata __initdata = { |
46 | ASSIGN(fsyscall), |
47 | ASSIGN(brl_fsys_bubble_down), |
48 | ASSIGN(vtop), |
49 | ASSIGN(mckinley_e9), |
50 | |
51 | .gate_section = (void*)__start_gate_section, |
52 | }; |
53 | |
54 | |
55 | unsigned long __init |
56 | paravirt_get_gate_patchlist(enum pv_gate_patchlist type) |
57 | { |
58 | |
59 | #define CASE(NAME, name) \ |
60 | case PV_GATE_START_##NAME: \ |
61 | return pv_patchdata.start_##name##_patchlist; \ |
62 | case PV_GATE_END_##NAME: \ |
63 | return pv_patchdata.end_##name##_patchlist; \ |
64 | |
65 | switch (type) { |
66 | CASE(FSYSCALL, fsyscall); |
67 | CASE(BRL_FSYS_BUBBLE_DOWN, brl_fsys_bubble_down); |
68 | CASE(VTOP, vtop); |
69 | CASE(MCKINLEY_E9, mckinley_e9); |
70 | default: |
71 | BUG(); |
72 | break; |
73 | } |
74 | return 0; |
75 | } |
76 | |
77 | void * __init |
78 | paravirt_get_gate_section(void) |
79 | { |
80 | return pv_patchdata.gate_section; |
81 | } |
82 |
Branches:
ben-wpan
ben-wpan-stefan
javiroman/ks7010
jz-2.6.34
jz-2.6.34-rc5
jz-2.6.34-rc6
jz-2.6.34-rc7
jz-2.6.35
jz-2.6.36
jz-2.6.37
jz-2.6.38
jz-2.6.39
jz-3.0
jz-3.1
jz-3.11
jz-3.12
jz-3.13
jz-3.15
jz-3.16
jz-3.18-dt
jz-3.2
jz-3.3
jz-3.4
jz-3.5
jz-3.6
jz-3.6-rc2-pwm
jz-3.9
jz-3.9-clk
jz-3.9-rc8
jz47xx
jz47xx-2.6.38
master
Tags:
od-2011-09-04
od-2011-09-18
v2.6.34-rc5
v2.6.34-rc6
v2.6.34-rc7
v3.9