android_kernel_xiaomi_sm8350/arch/sparc64/kernel
David S. Miller f088258966 [SPARC64]: Fix several kprobes bugs.
- relbranch_fixup(), for non-branches, would end up setting
  regs->tnpc incorrectly, in fact it would set it equal to
  regs->tpc which would cause that instruction to execute twice

  Also, if this is not a PC-relative branch, we should just
  leave regs->tnpc as-is.  This covers cases like 'jmpl' which
  branch to absolute values.

- To be absolutely %100 safe, we need to flush the instruction
  cache for all assignments to kprobe->ainsn.insn[], including
  cases like add_aggr_kprobe()

- prev_kprobe's status field needs to be 'unsigned long' to match
  the type of the value it is saving

- jprobes were totally broken:
  = jprobe_return() can run in the stack frame of the jprobe handler,
    or in an even deeper stack frame, thus we'll be in the wrong
    register window than the one from the original probe state.

    So unwind using 'restore' instructions, if necessary, right
    before we do the jprobe_return() breakpoint trap.

  = There is no reason to save/restore the register window saved
    at %sp at jprobe trigger time.  Those registers cannot be
    modified by the jprobe handler.  Also, this code was saving
    and restoring "sizeof (struct sparc_stackf)" bytes.  Depending
    upon the caller, this could clobber unrelated stack frame
    pieces if there is only a basic 128-byte register window
    stored on the stack, without the argument save area.

    So just saving and restoring struct pt_regs is sufficient.

  = Kill the "jprobe_saved_esp", totally unused.

    Also, delete "jprobe_saved_regs_location", with the stack frame
    unwind now done explicitly by jprobe_return(), this check is
    superfluous.

Signed-off-by: David S. Miller <davem@davemloft.net>
2006-12-10 02:42:03 -08:00
..
asm-offsets.c kbuild: frv,m32r,sparc64 introduce fake asm-offsets.h file 2005-09-09 22:47:53 +02:00
audit.c [PATCH] sparc64 audit syscall classes hookup 2006-09-12 03:05:05 -04:00
auxio.c Remove all inclusions of <linux/config.h> 2006-10-04 03:38:54 -04:00
binfmt_aout32.c [PATCH] struct path: convert sparc64 2006-12-08 08:28:50 -08:00
binfmt_elf32.c [PATCH] elf: Always define elf_addr_t in linux/elf.h 2006-12-07 08:39:38 -08:00
central.c [SPARC64]: Fix central/FHC bus handling on Ex000 systems. 2006-10-25 22:39:15 -07:00
chmc.c [SPARC64]: Replace kmalloc+memset with kzalloc 2006-12-10 02:40:18 -08:00
compat_audit.c [PATCH] sparc64 audit syscall classes hookup 2006-09-12 03:05:05 -04:00
cpu.c Remove obsolete #include <linux/config.h> 2006-06-30 19:25:36 +02:00
devices.c [SPARC]: Simplify and correct __cpu_find_by() 2006-07-21 14:18:15 -07:00
dtlb_miss.S [SPARC64]: More TLB/TSB handling fixes. 2006-03-20 01:13:34 -08:00
dtlb_prot.S [SPARC64]: Fix boot failures on SunBlade-150 2005-10-12 12:22:46 -07:00
ebus.c [SPARC]: Fix bus_id[] string overflow. 2006-10-27 01:03:31 -07:00
entry.S [SPARC64]: Add irqtrace/stacktrace/lockdep support. 2006-12-10 02:39:09 -08:00
etrap.S Remove obsolete #include <linux/config.h> 2006-06-30 19:25:36 +02:00
head.S [SPARC64]: Add irqtrace/stacktrace/lockdep support. 2006-12-10 02:39:09 -08:00
idprom.c Linux-2.6.12-rc2 2005-04-16 15:20:36 -07:00
init_task.c [PATCH] nsproxy: move init_nsproxy into kernel/nsproxy.c 2006-10-02 07:57:20 -07:00
iommu_common.c Linux-2.6.12-rc2 2005-04-16 15:20:36 -07:00
iommu_common.h Linux-2.6.12-rc2 2005-04-16 15:20:36 -07:00
irq.c [PATCH] sparc64 irq pt_regs fallout 2006-10-09 14:19:07 -07:00
isa.c [SPARC64]: Replace kmalloc+memset with kzalloc 2006-12-10 02:40:18 -08:00
itlb_miss.S [SPARC64]: Fix _PAGE_EXEC handling. 2006-03-20 01:14:13 -08:00
kprobes.c [SPARC64]: Fix several kprobes bugs. 2006-12-10 02:42:03 -08:00
ktlb.S Remove obsolete #include <linux/config.h> 2006-06-30 19:25:36 +02:00
Makefile [SPARC64]: Add irqtrace/stacktrace/lockdep support. 2006-12-10 02:39:09 -08:00
module.c [SPARC]: Handle UNWIND_INFO properly. 2006-05-12 12:45:50 -07:00
of_device.c [SPARC64]: Replace kmalloc+memset with kzalloc 2006-12-10 02:40:18 -08:00
pci_common.c [SPARC64]: Fix PCI memory space root resource on Hummingbird. 2006-10-17 19:28:50 -07:00
pci_impl.h [SPARC64]: Convert sparc64 PCI layer to in-kernel device tree. 2006-06-23 23:15:26 -07:00
pci_iommu.c [SPARC64]: Fix memory corruption in pci_4u_free_consistent(). 2006-10-25 22:39:16 -07:00
pci_psycho.c [PATCH] sparc64 pt_regs fixes 2006-10-08 12:32:35 -07:00
pci_sabre.c [SPARC64]: Compute dma_end argument to sabre_pbm_init() correctly. 2006-10-19 17:20:30 -07:00
pci_schizo.c [PATCH] sparc64 pt_regs fixes 2006-10-08 12:32:35 -07:00
pci_sun4v_asm.S [SPARC64]: Remove PGLIST_NENTS PCI IOMMU mapping limitation on SUN4V. 2006-03-20 01:13:41 -08:00
pci_sun4v.c [SPARC64]: Replace kmalloc+memset with kzalloc 2006-12-10 02:40:18 -08:00
pci_sun4v.h [SPARC64]: Remove PGLIST_NENTS PCI IOMMU mapping limitation on SUN4V. 2006-03-20 01:13:41 -08:00
pci.c PCI: Use pci_generic_prep_mwi on sparc64 2006-12-01 14:36:57 -08:00
power.c [PATCH] sparc64 pt_regs fixes 2006-10-08 12:32:35 -07:00
process.c Remove obsolete #include <linux/config.h> 2006-06-30 19:25:36 +02:00
prom.c [SPARC64]: Fix Tomatillo/Schizo IRQ handling. 2006-10-30 19:33:33 -08:00
ptrace.c [SPARC{32,64}]: Propagate ptrace_traceme() return value. 2006-12-10 02:40:27 -08:00
rtrap.S [SPARC64]: Add irqtrace/stacktrace/lockdep support. 2006-12-10 02:39:09 -08:00
sbus.c [PATCH] sparc64 pt_regs fixes 2006-10-08 12:32:35 -07:00
semaphore.c [SPARC64]: Avoid membar instructions in delay slots. 2005-06-27 15:42:04 -07:00
setup.c [SPARC]: Kill BOOTME_SINGLE. 2006-10-17 19:28:49 -07:00
signal32.c [SPARC64]: Move signal compat bits to new header file. 2006-10-02 14:24:18 -07:00
signal.c Remove obsolete #include <linux/config.h> 2006-06-30 19:25:36 +02:00
smp.c [PATCH] sparc64 pt_regs fixes 2006-10-08 12:32:35 -07:00
sparc64_ksyms.c [SPARC]: Kill prom_getname, unused and not implemented properly. 2006-07-21 14:17:55 -07:00
stacktrace.c [SPARC64]: Add irqtrace/stacktrace/lockdep support. 2006-12-10 02:39:09 -08:00
starfire.c [SPARC64]: Kill starfire_cookie from SBUS/PCI. 2006-06-29 16:37:08 -07:00
sun4v_ivec.S [SPARC64]: Add irqtrace/stacktrace/lockdep support. 2006-12-10 02:39:09 -08:00
sun4v_tlb_miss.S [SPARC64]: Add a secondary TSB for hugepage mappings. 2006-03-22 01:15:14 -08:00
sunos_ioctl32.c [SPARC]: Kill remaining kbio.h references. 2005-11-07 14:12:21 -08:00
sys32.S Remove obsolete #include <linux/config.h> 2006-06-30 19:25:36 +02:00
sys_sparc32.c Merge master.kernel.org:/pub/scm/linux/kernel/git/davem/sparc-2.6 2006-10-03 08:53:26 -07:00
sys_sparc.c [PATCH] provide kernel_execve on all architectures 2006-10-02 07:57:23 -07:00
sys_sunos32.c [PATCH] struct path: convert sparc64 2006-12-08 08:28:50 -08:00
systbls.S [SPARC]: Fix robust futex syscalls and wire up migrate_pages. 2006-11-05 16:51:03 -08:00
time.c [PATCH] sparc64 irq pt_regs fallout 2006-10-09 14:19:07 -07:00
trampoline.S [SPARC64]: Get SUN4V SMP working. 2006-03-20 01:13:22 -08:00
traps.c [SPARC64]: Run ctrl-alt-del action for sun4v powerdown request. 2006-12-10 02:39:51 -08:00
tsb.S Remove obsolete #include <linux/config.h> 2006-06-30 19:25:36 +02:00
ttable.S Remove obsolete #include <linux/config.h> 2006-06-30 19:25:36 +02:00
una_asm.S [SPARC64]: Mark __ex_table section correctly. 2006-03-04 23:23:56 -08:00
unaligned.c [SPARC64]: Unaligned accesses to userspace are hard errors. 2006-12-10 02:39:39 -08:00
us2e_cpufreq.c [SPARC64]: kzalloc() conversion 2006-03-20 01:14:19 -08:00
us3_cpufreq.c [SPARC64]: kzalloc() conversion 2006-03-20 01:14:19 -08:00
visemul.c [SPARC64]: Call do_mathemu on illegal instruction traps too. 2006-12-10 02:39:32 -08:00
vmlinux.lds.S [PATCH] relocatable kernel: Kallsyms generate relocatable symbols 2006-12-07 02:14:04 +01:00
winfixup.S [SPARC64]: Fix unaligned access winfxup handling on SUN4V. 2006-03-20 01:13:39 -08:00