Archived
14
0
Fork 0
This repository has been archived on 2022-02-17. You can view files and clone it, but cannot push or open issues or pull requests.
linux-2.6/arch/powerpc/kernel
Benjamin Herrenschmidt 0909c8c2d5 [POWERPC] Support feature fixups in vdso's
This patch reworks the feature fixup mecanism so vdso's can be fixed up.
The main issue was that the construct:

        .long   label  (or .llong on 64 bits)

will not work in the case of a shared library like the vdso. It will
generate an empty placeholder in the fixup table along with a reloc,
which is not something we can deal with in the vdso.

The idea here (thanks Alan Modra !) is to instead use something like:

1:
        .long   label - 1b

That is, the feature fixup tables no longer contain addresses of bits of
code to patch, but offsets of such code from the fixup table entry
itself. That is properly resolved by ld when building the .so's. I've
modified the fixup mecanism generically to use that method for the rest
of the kernel as well.

Another trick is that the 32 bits vDSO included in the 64 bits kernel
need to have a table in the 64 bits format. However, gas does not
support 32 bits code with a statement of the form:

        .llong  label - 1b  (Or even just .llong label)

That is, it cannot emit the right fixup/relocation for the linker to use
to assign a 32 bits address to an .llong field. Thus, in the specific
case of the 32 bits vdso built as part of the 64 bits kernel, we are
using a modified macro that generates:

        .long   0xffffffff
        .llong  label - 1b

Note that is assumes that the value is negative which is enforced by
the .lds (those offsets are always negative as the .text is always
before the fixup table and gas doesn't support emiting the reloc the
other way around).

Signed-off-by: Benjamin Herrenschmidt <benh@kernel.crashing.org>
Signed-off-by: Paul Mackerras <paulus@samba.org>
2006-10-25 11:54:07 +10:00
..
vdso32 [POWERPC] Support feature fixups in vdso's 2006-10-25 11:54:07 +10:00
vdso64 [POWERPC] Support feature fixups in vdso's 2006-10-25 11:54:07 +10:00
align.c [PATCH] powerpc: Implement support for setting little-endian mode via prctl 2006-06-09 21:24:15 +10:00
asm-offsets.c [POWERPC] Fix non-smp build 2006-09-14 10:36:11 +10:00
audit.c [PATCH] audit: AUDIT_PERM support 2006-09-11 13:32:30 -04:00
binfmt_elf32.c Remove obsolete #include <linux/config.h> 2006-06-30 19:25:36 +02:00
btext.c [POWERPC] Constify & voidify get_property() 2006-07-31 15:55:04 +10:00
compat_audit.c [PATCH] audit: AUDIT_PERM support 2006-09-11 13:32:30 -04:00
cpu_setup_6xx.S Remove obsolete #include <linux/config.h> 2006-06-30 19:25:36 +02:00
cpu_setup_ppc970.S Merge branch 'merge' 2006-08-25 14:56:07 +10:00
cputable.c [POWERPC] Support feature fixups in vdso's 2006-10-25 11:54:07 +10:00
crash.c [POWERPC] Fix interrupt clearing in kdump shutdown sequence 2006-09-13 18:31:23 +10:00
crash_dump.c [POWERPC] Make doc comments extractable 2006-08-08 17:07:04 +10:00
dma_64.c [POWERPC] Simplify dma_ops bug conditions 2006-07-31 15:55:06 +10:00
entry_32.S Remove obsolete #include <linux/config.h> 2006-06-30 19:25:36 +02:00
entry_64.S [POWERPC] implement BEGIN/END_FW_FTR_SECTION 2006-10-03 16:50:21 +10:00
firmware.c Remove obsolete #include <linux/config.h> 2006-06-30 19:25:36 +02:00
fpu.S [POWERPC] Restore copyright notice in arch/powerpc/kernel/fpu.S 2006-08-30 14:45:35 +10:00
head_4xx.S Remove obsolete #include <linux/config.h> 2006-06-30 19:25:36 +02:00
head_8xx.S Remove obsolete #include <linux/config.h> 2006-06-30 19:25:36 +02:00
head_32.S Remove obsolete #include <linux/config.h> 2006-06-30 19:25:36 +02:00
head_44x.S Remove obsolete #include <linux/config.h> 2006-06-30 19:25:36 +02:00
head_64.S [POWERPC] Consolidate feature fixup code 2006-10-25 11:42:10 +10:00
head_booke.h [PATCH] powerpc: Fix Kernel FP unavail exception for BookE 2006-02-10 16:51:50 +11:00
head_fsl_booke.S Remove obsolete #include <linux/config.h> 2006-06-30 19:25:36 +02:00
ibmebus.c IRQ: Use the new typedef for interrupt handler function pointers 2006-10-09 12:19:47 +01:00
idle.c Remove obsolete #include <linux/config.h> 2006-06-30 19:25:36 +02:00
idle_6xx.S Remove obsolete #include <linux/config.h> 2006-06-30 19:25:36 +02:00
idle_power4.S Remove obsolete #include <linux/config.h> 2006-06-30 19:25:36 +02:00
init_task.c [PATCH] nsproxy: move init_nsproxy into kernel/nsproxy.c 2006-10-02 07:57:20 -07:00
io.c [POWERPC] Merge iSeries i/o operations with the rest 2006-09-22 15:19:58 +10:00
iomap.c [PATCH] powerpc: remove io_page_mask 2006-04-22 18:45:05 +10:00
iommu.c [POWERPC] Fix harmless typo 2006-10-06 21:10:40 +10:00
irq.c [PATCH] extern doesn't make sense on a definition of function... 2006-10-09 14:19:07 -07:00
kprobes.c [PATCH] kretprobe spinlock deadlock patch 2006-10-02 07:57:16 -07:00
l2cr_6xx.S Remove obsolete #include <linux/config.h> 2006-06-30 19:25:36 +02:00
legacy_serial.c Merge branch 'merge' 2006-08-25 14:56:07 +10:00
lparcfg.c [POWERPC] clean up pseries hcall interfaces 2006-08-01 16:19:15 +10:00
lparmap.c [PATCH] powerpc: Fix iSeries bug in VMALLOCBASE/VMALLOC_START consolidation 2006-01-09 15:06:06 +11:00
machine_kexec.c [POWERPC] Move some kexec logic into machine_kexec.c 2006-08-17 16:41:10 +10:00
machine_kexec_32.c Storage class should be first 2006-06-26 18:57:34 +02:00
machine_kexec_64.c Merge branch 'merge' 2006-08-25 14:56:07 +10:00
Makefile [POWERPC] convert string i/o operations to C 2006-09-20 14:06:18 +10:00
misc.S [POWERPC] convert string i/o operations to C 2006-09-20 14:06:18 +10:00
misc_32.S [POWERPC] Consolidate feature fixup code 2006-10-25 11:42:10 +10:00
misc_64.S [POWERPC] Consolidate feature fixup code 2006-10-25 11:42:10 +10:00
module_32.c powerpc: Move module.c over to arch/powerpc 2006-03-27 19:28:58 +11:00
module_64.c [PATCH] powerpc64: Fix loading of modules without a .toc section 2006-04-28 21:04:49 +10:00
nvram_64.c [PATCH] nvram_print_partitions cosmetic fixup 2006-04-29 18:08:05 +10:00
of_device.c [POWERPC] Remove linux,device properties 2006-07-07 20:19:16 +10:00
paca.c [POWERPC] Implement SLB shadow buffer 2006-08-08 17:08:56 +10:00
pci_32.c [POWERPC] Fix IO Window Updates on P2P bridges. 2006-10-16 15:53:30 +10:00
pci_64.c [POWERPC] Check for offline nodes in pci NUMA code 2006-10-16 15:53:30 +10:00
pci_direct_iommu.c [POWERPC] cleanup dma_mapping_ops 2006-06-15 19:31:26 +10:00
pci_dn.c [POWERPC] Constify & voidify get_property() 2006-07-31 15:55:04 +10:00
pci_iommu.c [POWERPC] cleanup dma_mapping_ops 2006-06-15 19:31:26 +10:00
perfmon_fsl_booke.c fix file specification in comments 2006-10-03 23:01:26 +02:00
pmc.c Remove obsolete #include <linux/config.h> 2006-06-30 19:25:36 +02:00
ppc32.h powerpc: move include/asm-ppc64/ppc32.h to arch/powerpc/kernel 2005-11-03 16:03:28 +11:00
ppc_ksyms.c [POWERPC] convert string i/o operations to C 2006-09-20 14:06:18 +10:00
proc_ppc64.c Remove obsolete #include <linux/config.h> 2006-06-30 19:25:36 +02:00
process.c [POWERPC] Better check in show_instructions 2006-10-16 15:53:30 +10:00
prom.c [POWERPC] Minor fix for bootargs property 2006-10-06 21:10:41 +10:00
prom_init.c Merge branch 'merge' 2006-08-31 15:45:48 +10:00
prom_parse.c Revert "[POWERPC] Don't get PCI IRQ from OF for devices with no IRQ" 2006-10-08 15:38:22 -07:00
ptrace-common.h Remove obsolete #include <linux/config.h> 2006-06-30 19:25:36 +02:00
ptrace.c [POWERPC] Fix PPC32 SECCOMP, unexport do_syscall_trace_{enter,leave} 2006-09-26 15:24:34 +10:00
ptrace32.c Remove obsolete #include <linux/config.h> 2006-06-30 19:25:36 +02:00
rtas-proc.c [POWERPC] Constify & voidify get_property() 2006-07-31 15:55:04 +10:00
rtas-rtc.c [PATCH] powerpc: reorg RTAS delay code 2006-06-09 21:21:06 +10:00
rtas.c [POWERPC] reboot when panic_timout is set 2006-08-25 13:30:26 +10:00
rtas_flash.c [PATCH] powerpc: reorg RTAS delay code 2006-06-09 21:21:06 +10:00
rtas_pci.c [POWERPC] Add a helper for calculating RTAS "config_addr" parameters 2006-08-25 13:27:35 +10:00
semaphore.c powerpc: Merge enough to start building in arch/powerpc. 2005-09-26 16:04:21 +10:00
setup-common.c [POWERPC] Fix xmon=off and cleanup xmon initialisation 2006-10-04 14:52:22 +10:00
setup.h [PATCH] powerpc: Make early xmon logic immune to location of early parsing 2006-05-19 15:02:12 +10:00
setup_32.c [POWERPC] Support feature fixups in vdso's 2006-10-25 11:54:07 +10:00
setup_64.c [POWERPC] Support feature fixups in vdso's 2006-10-25 11:54:07 +10:00
signal_32.c Remove obsolete #include <linux/config.h> 2006-06-30 19:25:36 +02:00
signal_64.c Remove obsolete #include <linux/config.h> 2006-06-30 19:25:36 +02:00
smp-tbsync.c [POWERPC] Fix irq enable/disable in smp_generic_take_timebase 2006-08-30 16:10:47 +10:00
smp.c IRQ: Maintain regs pointer globally rather than passing to IRQ handlers 2006-10-05 15:10:12 +01:00
swsusp_32.S [PATCH] Change the name of pagedir_nosave 2006-09-26 08:49:01 -07:00
sys_ppc32.c [PATCH] VFS: Make filldir_t and struct kstat deal in 64-bit inode numbers 2006-10-03 08:03:40 -07:00
syscalls.c [PATCH] namespaces: utsname: switch to using uts namespaces 2006-10-02 07:57:21 -07:00
sysfs.c [POWERPC] Always call cede in pseries dedicated idle loop 2006-09-26 15:24:34 +10:00
systbl.S Remove obsolete #include <linux/config.h> 2006-06-30 19:25:36 +02:00
tau_6xx.c Remove obsolete #include <linux/config.h> 2006-06-30 19:25:36 +02:00
time.c [POWERPC] Simplify stolen time calculation 2006-10-23 18:20:12 +10:00
traps.c [POWERPC] Never panic when taking altivec exceptions from userspace 2006-10-16 15:53:30 +10:00
udbg.c Remove obsolete #include <linux/config.h> 2006-06-30 19:25:36 +02:00
udbg_16550.c [POWERPC] Fix default clock for udbg_16550 2006-07-26 01:27:13 +10:00
vdso.c [POWERPC] Support feature fixups in vdso's 2006-10-25 11:54:07 +10:00
vecemu.c [PATCH] powerpc: Move arch/ppc*/kernel/vecemu.c to arch/powerpc 2005-09-21 19:21:07 +10:00
vector.S Remove obsolete #include <linux/config.h> 2006-06-30 19:25:36 +02:00
vio.c [POWERPC] Constify & voidify get_property() 2006-07-31 15:55:04 +10:00
vmlinux.lds.S [POWERPC] implement BEGIN/END_FW_FTR_SECTION 2006-10-03 16:50:21 +10:00