Skip to content

Commit

Permalink
---
Browse files Browse the repository at this point in the history
yaml
---
r: 139595
b: refs/heads/master
c: b937dd7
h: refs/heads/master
i:
  139593: 37ef7e8
  139591: 0b260ed
v: v3
  • Loading branch information
Isaku Yamahata authored and Tony Luck committed Mar 26, 2009
1 parent f916948 commit db7ff23
Show file tree
Hide file tree
Showing 6 changed files with 95 additions and 2 deletions.
2 changes: 1 addition & 1 deletion [refs]
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
---
refs/heads/master: e4ff5b8f545811008123dd9556a51d814f562fcf
refs/heads/master: b937dd76d07f2347684d6cc1e1ec4e2746417357
38 changes: 38 additions & 0 deletions trunk/arch/ia64/include/asm/xen/patchlist.h
Original file line number Diff line number Diff line change
@@ -0,0 +1,38 @@
/******************************************************************************
* arch/ia64/include/asm/xen/patchlist.h
*
* Copyright (c) 2008 Isaku Yamahata <yamahata at valinux co jp>
* VA Linux Systems Japan K.K.
*
* This program is free software; you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation; either version 2 of the License, or
* (at your option) any later version.
*
* This program is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU General Public License for more details.
*
* You should have received a copy of the GNU General Public License
* along with this program; if not, write to the Free Software
* Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
*
*/

#define __paravirt_start_gate_fsyscall_patchlist \
__xen_start_gate_fsyscall_patchlist
#define __paravirt_end_gate_fsyscall_patchlist \
__xen_end_gate_fsyscall_patchlist
#define __paravirt_start_gate_brl_fsys_bubble_down_patchlist \
__xen_start_gate_brl_fsys_bubble_down_patchlist
#define __paravirt_end_gate_brl_fsys_bubble_down_patchlist \
__xen_end_gate_brl_fsys_bubble_down_patchlist
#define __paravirt_start_gate_vtop_patchlist \
__xen_start_gate_vtop_patchlist
#define __paravirt_end_gate_vtop_patchlist \
__xen_end_gate_vtop_patchlist
#define __paravirt_start_gate_mckinley_e9_patchlist \
__xen_start_gate_mckinley_e9_patchlist
#define __paravirt_end_gate_mckinley_e9_patchlist \
__xen_end_gate_mckinley_e9_patchlist
6 changes: 6 additions & 0 deletions trunk/arch/ia64/kernel/vmlinux.lds.S
Original file line number Diff line number Diff line change
Expand Up @@ -201,6 +201,12 @@ SECTIONS
__start_gate_section = .;
*(.data.gate)
__stop_gate_section = .;
#ifdef CONFIG_XEN
. = ALIGN(PAGE_SIZE);
__xen_start_gate_section = .;
*(.data.gate.xen)
__xen_stop_gate_section = .;
#endif
}
. = ALIGN(PAGE_SIZE); /* make sure the gate page doesn't expose
* kernel data
Expand Down
16 changes: 15 additions & 1 deletion trunk/arch/ia64/xen/Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -3,10 +3,24 @@
#

obj-y := hypercall.o xenivt.o xensetup.o xen_pv_ops.o irq_xen.o \
hypervisor.o xencomm.o xcom_hcall.o grant-table.o time.o suspend.o
hypervisor.o xencomm.o xcom_hcall.o grant-table.o time.o suspend.o \
gate-data.o

obj-$(CONFIG_IA64_GENERIC) += machvec.o

# The gate DSO image is built using a special linker script.
include $(srctree)/arch/ia64/kernel/Makefile.gate

# tell compiled for xen
CPPFLAGS_gate.lds += -D__IA64_GATE_PARAVIRTUALIZED_XEN

# use same file of native.
$(obj)/gate.o: $(src)/../kernel/gate.S FORCE
$(call if_changed_dep,as_o_S)
$(obj)/gate.lds: $(src)/../kernel/gate.lds.S FORCE
$(call if_changed_dep,cpp_lds_S)


AFLAGS_xenivt.o += -D__IA64_ASM_PARAVIRTUALIZED_XEN

# xen multi compile
Expand Down
3 changes: 3 additions & 0 deletions trunk/arch/ia64/xen/gate-data.S
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
.section .data.gate.xen, "aw"

.incbin "arch/ia64/xen/gate.so"
32 changes: 32 additions & 0 deletions trunk/arch/ia64/xen/xen_pv_ops.c
Original file line number Diff line number Diff line change
Expand Up @@ -178,6 +178,37 @@ struct pv_fsys_data xen_fsys_data __initdata = {
.fsys_bubble_down = (void *)xen_fsys_bubble_down,
};

/***************************************************************************
* pv_patchdata
* patchdata addresses
*/

#define DECLARE(name) \
extern unsigned long __xen_start_gate_##name##_patchlist[]; \
extern unsigned long __xen_end_gate_##name##_patchlist[]

DECLARE(fsyscall);
DECLARE(brl_fsys_bubble_down);
DECLARE(vtop);
DECLARE(mckinley_e9);

extern unsigned long __xen_start_gate_section[];

#define ASSIGN(name) \
.start_##name##_patchlist = \
(unsigned long)__xen_start_gate_##name##_patchlist, \
.end_##name##_patchlist = \
(unsigned long)__xen_end_gate_##name##_patchlist

static struct pv_patchdata xen_patchdata __initdata = {
ASSIGN(fsyscall),
ASSIGN(brl_fsys_bubble_down),
ASSIGN(vtop),
ASSIGN(mckinley_e9),

.gate_section = (void*)__xen_start_gate_section,
};

/***************************************************************************
* pv_cpu_ops
* intrinsics hooks.
Expand Down Expand Up @@ -447,6 +478,7 @@ xen_setup_pv_ops(void)
pv_info = xen_info;
pv_init_ops = xen_init_ops;
pv_fsys_data = xen_fsys_data;
pv_patchdata = xen_patchdata;
pv_cpu_ops = xen_cpu_ops;
pv_iosapic_ops = xen_iosapic_ops;
pv_irq_ops = xen_irq_ops;
Expand Down

0 comments on commit db7ff23

Please sign in to comment.