2005-04-16 18:20:36 -04:00
|
|
|
#
|
|
|
|
# Makefile for the linux kernel.
|
|
|
|
#
|
|
|
|
|
|
|
|
extra-y := head.o init_task.o vmlinux.lds
|
|
|
|
|
|
|
|
obj-y := acpi.o entry.o efi.o efi_stub.o gate-data.o fsys.o ia64_ksyms.o irq.o irq_ia64.o \
|
|
|
|
irq_lsapic.o ivt.o machvec.o pal.o patch.o process.o perfmon.o ptrace.o sal.o \
|
|
|
|
salinfo.o semaphore.o setup.o signal.o sys_ia64.o time.o traps.o unaligned.o \
|
2006-04-03 20:09:22 -04:00
|
|
|
unwind.o mca.o mca_asm.o topology.o
|
2005-04-16 18:20:36 -04:00
|
|
|
|
|
|
|
obj-$(CONFIG_IA64_BRL_EMU) += brl_emu.o
|
|
|
|
obj-$(CONFIG_IA64_GENERIC) += acpi-ext.o
|
|
|
|
obj-$(CONFIG_IA64_HP_ZX1) += acpi-ext.o
|
|
|
|
obj-$(CONFIG_IA64_HP_ZX1_SWIOTLB) += acpi-ext.o
|
2005-12-01 18:16:00 -05:00
|
|
|
|
|
|
|
ifneq ($(CONFIG_ACPI_PROCESSOR),)
|
|
|
|
obj-y += acpi-processor.o
|
|
|
|
endif
|
|
|
|
|
2005-04-16 18:20:36 -04:00
|
|
|
obj-$(CONFIG_IA64_PALINFO) += palinfo.o
|
|
|
|
obj-$(CONFIG_IOSAPIC) += iosapic.o
|
|
|
|
obj-$(CONFIG_MODULES) += module.o
|
2005-09-06 18:18:14 -04:00
|
|
|
obj-$(CONFIG_SMP) += smp.o smpboot.o
|
2005-07-06 21:18:10 -04:00
|
|
|
obj-$(CONFIG_NUMA) += numa.o
|
2005-04-16 18:20:36 -04:00
|
|
|
obj-$(CONFIG_PERFMON) += perfmon_default_smpl.o
|
|
|
|
obj-$(CONFIG_IA64_CYCLONE) += cyclone.o
|
2005-07-29 19:15:00 -04:00
|
|
|
obj-$(CONFIG_CPU_FREQ) += cpufreq/
|
2005-04-16 18:20:36 -04:00
|
|
|
obj-$(CONFIG_IA64_MCA_RECOVERY) += mca_recovery.o
|
2005-06-23 03:09:28 -04:00
|
|
|
obj-$(CONFIG_KPROBES) += kprobes.o jprobes.o
|
2006-12-07 12:51:35 -05:00
|
|
|
obj-$(CONFIG_KEXEC) += machine_kexec.o relocate_kernel.o crash.o
|
2006-12-12 03:49:03 -05:00
|
|
|
obj-$(CONFIG_CRASH_DUMP) += crash_dump.o
|
2005-06-21 20:15:02 -04:00
|
|
|
obj-$(CONFIG_IA64_UNCACHED_ALLOCATOR) += uncached.o
|
2006-07-01 03:56:16 -04:00
|
|
|
obj-$(CONFIG_AUDIT) += audit.o
|
2006-10-04 05:17:00 -04:00
|
|
|
obj-$(CONFIG_PCI_MSI) += msi_ia64.o
|
2005-04-16 18:20:36 -04:00
|
|
|
mca_recovery-y += mca_drv.o mca_drv_asm.o
|
|
|
|
|
[IA64] esi-support
Add support for making ESI calls [1]. ESI stands for "Extensible SAL
specification" and is basically a way for invoking firmware
subroutines which are identified by a GUID. I don't know whether ESI
is used by vendors other than HP (if you do, please let me know) but
as firmware "backdoors" go, this seems one of the cleaner methods, so
it seems reasonable to support it, even though I'm not aware of any
publicly documented ESI calls. I'd have liked to make the ESI module
completely stand-alone, but unfortunately that is not easily (or not
at all) possible because in order to make ESI calls in physical mode,
a small stub similar to the EFI stub is needed in the kernel proper.
I did try to create a stub that would work in user-level, but it
quickly got ugly beyond recognition (e.g., the stub had to make
assumptions about how the module-loader generated call-stubs work) and
I didn't even get it to work (that's probably fixable, but I didn't
bother because I concluded it was too ugly anyhow). While it's not
terribly elegant to have kernel code which isn't actively used in the
kernel proper, I think it might be worth making an exception here for
two reasons: the code is trivially small (all that's really needed is
esi_stub.S) and by including it in the normal kernel distro, it might
encourage other OEMs to also use ESI, which I think would be far
better than each inventing their own firmware "backdoor".
The code was originally written by Alex. I just massaged and packaged
it a bit (and perhaps messed up some things along the way...).
Changes since first version of patch that was posted to mailing list:
* Export ia64_esi_call and ia64_esi_call_phys() as GPL symbols.
* Disallow building esi.c as a module for now. Building as a module
would currently lead to an unresolved reference to "sal_lock" on SMP kernels
because that symbol doesn't get exported.
* Export esi_call_phys() only if ESI is enabled.
* Remove internal stuff from esi.h and add a "proc_type" argument to
ia64_esi_call() such that serialization-requirements can be expressed (ESI
follows SAL here, where procedure calls may have to be serialized, are
MP-safe, or MP-safe andr reentrant).
[1] h21007.www2.hp.com/dspp/tech/tech_TechDocumentDetailPage_IDX/1,1701,919,00.html
Signed-off-by: David Mosberger <David.Mosberger@acm.org>
Signed-off-by: Alex Williamson <alex.williamson@hp.com>
Signed-off-by: Tony Luck <tony.luck@intel.com>
2006-06-21 14:19:22 -04:00
|
|
|
obj-$(CONFIG_IA64_ESI) += esi.o
|
|
|
|
ifneq ($(CONFIG_IA64_ESI),)
|
|
|
|
obj-y += esi_stub.o # must be in kernel proper
|
|
|
|
endif
|
|
|
|
|
2005-04-16 18:20:36 -04:00
|
|
|
# The gate DSO image is built using a special linker script.
|
|
|
|
targets += gate.so gate-syms.o
|
|
|
|
|
|
|
|
extra-y += gate.so gate-syms.o gate.lds gate.o
|
|
|
|
|
|
|
|
# fp_emulate() expects f2-f5,f16-f31 to contain the user-level state.
|
|
|
|
CFLAGS_traps.o += -mfixed-range=f2-f5,f16-f31
|
|
|
|
|
|
|
|
CPPFLAGS_gate.lds := -P -C -U$(ARCH)
|
|
|
|
|
|
|
|
quiet_cmd_gate = GATE $@
|
|
|
|
cmd_gate = $(CC) -nostdlib $(GATECFLAGS_$(@F)) -Wl,-T,$(filter-out FORCE,$^) -o $@
|
|
|
|
|
[PATCH] vDSO hash-style fix
The latest toolchains can produce a new ELF section in DSOs and
dynamically-linked executables. The new section ".gnu.hash" replaces
".hash", and allows for more efficient runtime symbol lookups by the
dynamic linker. The new ld option --hash-style={sysv|gnu|both} controls
whether to produce the old ".hash", the new ".gnu.hash", or both. In some
new systems such as Fedora Core 6, gcc by default passes --hash-style=gnu
to the linker, so that a standard invocation of "gcc -shared" results in
producing a DSO with only ".gnu.hash". The new ".gnu.hash" sections need
to be dealt with the same way as ".hash" sections in all respects; only the
dynamic linker cares about their contents. To work with older dynamic
linkers (i.e. preexisting releases of glibc), a binary must have the old
".hash" section. The --hash-style=both option produces binaries that a new
dynamic linker can use more efficiently, but an old dynamic linker can
still handle.
The new section runs afoul of the custom linker scripts used to build vDSO
images for the kernel. On ia64, the failure mode for this is a boot-time
panic because the vDSO's PT_IA_64_UNWIND segment winds up ill-formed.
This patch addresses the problem in two ways.
First, it mentions ".gnu.hash" in all the linker scripts alongside ".hash".
This produces correct vDSO images with --hash-style=sysv (or old tools),
with --hash-style=gnu, or with --hash-style=both.
Second, it passes the --hash-style=sysv option when building the vDSO
images, so that ".gnu.hash" is not actually produced. This is the most
conservative choice for compatibility with any old userland. There is some
concern that some ancient glibc builds (though not any known old production
system) might choke on --hash-style=both binaries. The optimizations
provided by the new style of hash section do not really matter for a DSO
with a tiny number of symbols, as the vDSO has. If someone wants to use
=gnu or =both for their vDSO builds and worry less about that
compatibility, just change the option and the linker script changes will
make any choice work fine.
Signed-off-by: Roland McGrath <roland@redhat.com>
Cc: "Luck, Tony" <tony.luck@intel.com>
Cc: Kyle McMartin <kyle@mcmartin.ca>
Cc: Paul Mackerras <paulus@samba.org>
Cc: Benjamin Herrenschmidt <benh@kernel.crashing.org>
Cc: Jeff Dike <jdike@addtoit.com>
Cc: Andi Kleen <ak@muc.de>
Cc: Sam Ravnborg <sam@ravnborg.org>
Signed-off-by: Andrew Morton <akpm@osdl.org>
Signed-off-by: Linus Torvalds <torvalds@osdl.org>
2006-07-30 06:04:06 -04:00
|
|
|
GATECFLAGS_gate.so = -shared -s -Wl,-soname=linux-gate.so.1 \
|
|
|
|
$(call ld-option, -Wl$(comma)--hash-style=sysv)
|
2005-04-16 18:20:36 -04:00
|
|
|
$(obj)/gate.so: $(obj)/gate.lds $(obj)/gate.o FORCE
|
|
|
|
$(call if_changed,gate)
|
|
|
|
|
|
|
|
$(obj)/built-in.o: $(obj)/gate-syms.o
|
|
|
|
$(obj)/built-in.o: ld_flags += -R $(obj)/gate-syms.o
|
|
|
|
|
|
|
|
GATECFLAGS_gate-syms.o = -r
|
|
|
|
$(obj)/gate-syms.o: $(obj)/gate.lds $(obj)/gate.o FORCE
|
|
|
|
$(call if_changed,gate)
|
|
|
|
|
|
|
|
# gate-data.o contains the gate DSO image as data in section .data.gate.
|
|
|
|
# We must build gate.so before we can assemble it.
|
|
|
|
# Note: kbuild does not track this dependency due to usage of .incbin
|
|
|
|
$(obj)/gate-data.o: $(obj)/gate.so
|