15 Jan, 2008

1 commit

  • Commit 5d2efba64b231a1733c4048d1708d77e07f26426 changed our iommu code
    so that it always uses an iommu page size of 4kB. That means with our
    current code, drivers may do a dma_map_sg() of a 64kB page and obtain
    a dma_addr_t that is only 4k aligned.

    This works fine in most cases except for some infiniband HW it seems,
    where they tell the HW about the page size and it ignores the low bits
    of the DMA address.

    This works around it by making our IOMMU code enforce a PAGE_SIZE alignment
    for mappings of objects that are page aligned in the first place and whose
    size is larger or equal to a page.

    Signed-off-by: Benjamin Herrenschmidt
    Signed-off-by: Paul Mackerras

    Benjamin Herrenschmidt
     

10 Jan, 2008

1 commit

  • The new network driver fec_mpc52xx will not work on efika because the
    firmware does not provide all required properties.
    http://www.powerdeveloper.org/asset/by-id/46 has a Forth script to
    create more properties. But only the phy stuff is required to get a
    working network.

    This should go into the kernel because its appearently
    impossible to boot the script via tftp and then load the real boot
    binary (yaboot or zimage).

    Signed-off-by: Olaf Hering
    Signed-off-by: Grant Likely
    Acked-by: Benjamin Herrenschmidt

    Olaf Hering
     

14 Dec, 2007

1 commit

  • Remove exports of __res and cpm_install_handler/cpm_free_handler. Remove
    cpm_install_handler/cpm_free_handler from the commproc.h as well. Both
    were used for ARCH=ppc and aren't defined for ARCH=powerpc.

    CC arch/powerpc/kernel/ppc_ksyms.o
    arch/powerpc/kernel/ppc_ksyms.c:180: error: '__res' undeclared here (not in a function)
    arch/powerpc/kernel/ppc_ksyms.c:180: warning: type defaults to 'int' in declaration of '__res'
    make[1]: *** [arch/powerpc/kernel/ppc_ksyms.o] Error 1
    make: *** [arch/powerpc/kernel] Error 2

    LD .tmp_vmlinux1
    arch/powerpc/kernel/built-in.o:(__ksymtab+0x198): undefined reference to `cpm_free_handler'
    arch/powerpc/kernel/built-in.o:(__ksymtab+0x1a0): undefined reference to `cpm_install_handler'
    make: *** [.tmp_vmlinux1] Error 1

    Signed-off-by: Jochen Friedrich
    Signed-off-by: Andrew Morton
    Signed-off-by: Vitaly Bordug
    Signed-off-by: Kumar Gala

    Jochen Friedrich
     

07 Dec, 2007

2 commits


06 Dec, 2007

1 commit

  • The commit fa13a5a1f25f671d084d8884be96fc48d9b68275 (sched: restore
    deterministic CPU accounting on powerpc), unconditionally calls
    update_process_tick() in system context. In the deterministic
    accounting case this is the correct thing to do. However, in the
    non-deterministic accounting case we need to not do this, since doing
    this results in the time accounted as hardware irq time being
    artificially elevated.

    Also this collapses 2 consecutive '#ifdef CONFIG_VIRT_CPU_ACCOUNTING'
    checks in time.h into one for neatness.

    Signed-off-by: Tony Breeds
    Signed-off-by: Paul Mackerras

    Tony Breeds
     

03 Dec, 2007

1 commit

  • This reverts commit a2b51812a4dc5db09ab4d4638d4d8ed456e2457e.

    It turns out that this change caused some machines to fail to come
    back up when being rebooted, and generated an error in the hypervisor
    error log on some machines. The platform architecture (PAPR) is a
    little unclear on exactly when the RTAS ibm,os-term function should be
    called. Until that is clarified I'm reverting this commit.

    Signed-off-by: Paul Mackerras

    Paul Mackerras
     

20 Nov, 2007

3 commits

  • If we get no user time and no system time allocated since the last
    account_system_vtime, the system to user time ratio estimate can end
    up dividing by zero.

    This was causing a problem noticed by Balbir Singh.

    Signed-off-by: Michael Neuling
    Signed-off-by: Paul Mackerras

    Michael Neuling
     
  • The rtas_os_term() routine was being called at the wrong time.
    The actual rtas call "os-term" will not ever return, and so
    calling it from the panic notifier is too early. Instead,
    call it from the machine_reset() call.

    This splits the rtas_os_term() routine into two: one part to capture
    the kernel panic message, invoked during the panic notifier, and
    another part that is invoked during machine_reset().

    Prior to this patch, the os-term call was never being made,
    because panic_timeout was always non-zero. Calling os-term
    helps keep the hypervisor happy! We have to keep the hypervisor
    happy to avoid service, dump and error reporting problems.

    Signed-off-by: Linas Vepstas
    Signed-off-by: Paul Mackerras

    Linas Vepstas
     
  • The current VDSO implementation is hardcoded to 128 byte cache blocks,
    which are only used on IBM's 64-bit processors.

    Convert it to get the cache block sizes out of vdso_data instead,
    similar to how the ppc64 in-kernel cache flush does it.

    Signed-off-by: Olof Johansson
    Signed-off-by: Paul Mackerras

    Olof Johansson
     

19 Nov, 2007

1 commit

  • There are several issues with the rtas_ibm_suspend_me code, which
    enables platform-assisted suspension of an LPAR as covered in PAPR
    2.2.

    1.) rtas_ibm_suspend_me uses on_each_cpu() to invoke
    rtas_percpu_suspend_me on all cpus via IPI:

    if (on_each_cpu(rtas_percpu_suspend_me, &data, 1, 0))
    ...

    'data' is on the calling task's stack, but rtas_ibm_suspend_me takes
    no measures to ensure that all instances of rtas_percpu_suspend_me are
    finished accessing 'data' before returning. This can result in the
    IPI'd cpus accessing random stack data and getting stuck in H_JOIN.

    This is addressed by using an atomic count of workers and a completion
    on the stack.

    2.) rtas_percpu_suspend_me is needlessly calling H_JOIN in a loop.
    The only event that can cause a cpu to return from H_JOIN is an H_PROD
    from another cpu or a NMI/system reset. Each cpu need call H_JOIN
    only once per suspend operation.

    Remove the loop and the now unnecessary 'waiting' state variable.

    3.) H_JOIN must be called with MSR[EE] off, but lazy interrupt
    disabling may cause the caller of rtas_ibm_suspend_me to call H_JOIN
    with it on; the local_irq_disable() in on_each_cpu() is not
    sufficient.

    Fix this by explicitly saving the MSR and clearing the EE bit before
    calling H_JOIN.

    4.) H_PROD is being called with the Linux logical cpu number as the
    parameter, not the platform interrupt server value. (It's also being
    called for all possible cpus, which is harmless, but unnecessary.)

    This is fixed by calling H_PROD for each online cpu using
    get_hard_smp_processor_id(cpu) for the argument.

    Signed-off-by: Nathan Lynch
    Signed-off-by: Paul Mackerras

    Nathan Lynch
     

13 Nov, 2007

3 commits

  • The early btext debug wouldn't work on PowerMac when booted from BootX
    due to the code looking for the wrong property name.

    Signed-off-by: Benjamin Herrenschmidt
    Signed-off-by: Paul Mackerras

    Benjamin Herrenschmidt
     
  • These don't need to be seen by everyone on every boot.

    Signed-off-by: Tony Breeds
    Signed-off-by: Paul Mackerras

    Tony Breeds
     
  • The context switch code in the kernel issues a dummy stwcx. to clear the
    reservation, as recommended by the architecture. However, some processors
    can have issues if this stwcx to address A occurs while the reservation
    is already held to a different address B. To avoid this problem, the dummy
    stwcx. needs to be paired with a dummy lwarx to the same address.

    This adds the dummy lwarx, and creates a cpu feature bit to indicate
    which cpus are affected. Tested on mpc8641_hpcn_defconfig in
    arch/powerpc; build tested in arch/ppc.

    Signed-off-by: Becky Bruce
    Signed-off-by: Paul Mackerras

    Becky Bruce
     

10 Nov, 2007

2 commits

  • * git://git.kernel.org/pub/scm/linux/kernel/git/mingo/linux-2.6-sched:
    sched: proper prototype for kernel/sched.c:migration_init()
    sched: avoid large irq-latencies in smp-balancing
    sched: fix copy_namespace() sched_fork() dependency in do_fork
    sched: clean up the wakeup preempt check, #2
    sched: clean up the wakeup preempt check
    sched: wakeup preemption fix
    sched: remove PREEMPT_RESTRICT
    sched: turn off PREEMPT_RESTRICT
    KVM: fix !SMP build error
    x86: make nmi_cpu_busy() always defined
    x86: make ipi_handler() always defined
    sched: cleanup, use NSEC_PER_MSEC and NSEC_PER_SEC
    sched: reintroduce SMP tunings again
    sched: restore deterministic CPU accounting on powerpc
    sched: fix delay accounting regression
    sched: reintroduce the sched_min_granularity tunable
    sched: documentation: place_entity() comments
    sched: fix vslice

    Linus Torvalds
     
  • Since powerpc started using CONFIG_GENERIC_CLOCKEVENTS, the
    deterministic CPU accounting (CONFIG_VIRT_CPU_ACCOUNTING) has been
    broken on powerpc, because we end up counting user time twice: once in
    timer_interrupt() and once in update_process_times().

    This fixes the problem by pulling the code in update_process_times
    that updates utime and stime into a separate function called
    account_process_tick. If CONFIG_VIRT_CPU_ACCOUNTING is not defined,
    there is a version of account_process_tick in kernel/timer.c that
    simply accounts a whole tick to either utime or stime as before. If
    CONFIG_VIRT_CPU_ACCOUNTING is defined, then arch code gets to
    implement account_process_tick.

    This also lets us simplify the s390 code a bit; it means that the s390
    timer interrupt can now call update_process_times even when
    CONFIG_VIRT_CPU_ACCOUNTING is turned on, and can just implement a
    suitable account_process_tick().

    account_process_tick() now takes the task_struct * as an argument.
    Tested both with and without CONFIG_VIRT_CPU_ACCOUNTING.

    Signed-off-by: Paul Mackerras
    Signed-off-by: Ingo Molnar

    Paul Mackerras
     

08 Nov, 2007

8 commits

  • …/powerpc-4xx into merge

    Paul Mackerras
     
  • This makes the altivec code in swsusp_32.S depend on CONFIG_ALTIVEC to
    avoid build failures for systems that don't have altivec. I'm not sure
    whether the code will actually work for other systems, but it was merged
    for just ppc32 rather than powermac a very long time ago.

    Signed-off-by: Johannes Berg
    Signed-off-by: Paul Mackerras

    Johannes Berg
     
  • If the low level MMU hash table insertion returns an error (which
    can happen in some rare circumstances when the hypervisor refuses
    the insertion of a PTE, typically if you try to access junk via
    /dev/mem), the generated signal had an incorrect si_addr value due
    to a bug in the assembly, which was loading it as a 32 bits quantity
    instead of a 64 bits quantity.

    Signed-off-by: Benjamin Herrenschmidt
    Signed-off-by: Paul Mackerras

    Benjamin Herrenschmidt
     
  • The size passing to memset is wrong.

    Signed-off-by Li Zefan
    Acked-by: Benjamin Herrenschmidt

    Signed-off-by: Paul Mackerras

    Li Zefan
     
  • An allyesconfig build creates a .text section that is so big that the
    .text.init.refok and .fixup sections are too far away for the relocations
    to be fixed up correctly. This patch fixes that by linking all the
    relevent text sections for each file together.

    Suggested by Paul Mackerras.

    Signed-off-by: Stephen Rothwell
    Signed-off-by: Paul Mackerras

    Stephen Rothwell
     
  • The decrementer in Book E and 4xx processors interrupts on the
    transition from 1 to 0, rather than on the 0 to -1 transition as on
    64-bit server and 32-bit "classic" (6xx/7xx/7xxx) processors. At the
    moment we subtract 1 from the count of how many decrementer ticks are
    required before the next interrupt before putting it into the
    decrementer, which is correct for server/classic processors, but could
    possibly cause the interrupt to happen too early on Book E and 4xx if
    the timebase/decrementer frequency is low.

    This fixes the problem by making set_dec subtract 1 from the count for
    server and classic processors, instead of having the callers subtract
    1. Since set_dec already had a bunch of ifdefs to handle different
    processor types, there is no net increase in ugliness. :)

    Note that calling set_dec(0) may not generate an interrupt on some
    processors. To make sure that decrementer_set_next_event always calls
    set_dec with an interval of at least 1 tick, we set min_delta_ns of
    the decrementer_clockevent to correspond to 2 ticks (2 rather than 1
    to compensate for truncations in the conversions between ticks and
    ns).

    This also removes a redundant call to set the decrementer to
    0x7fffffff - it was already set to that earlier in timer_interrupt.

    Signed-off-by: Paul Mackerras

    Paul Mackerras
     
  • We had an historical confusion in the kernel between cache line
    and cache block size. The former is an implementation detail of
    the L1 cache which can be useful for performance optimisations,
    the later is the actual size on which the cache control
    instructions operate, which can be different.

    For some reason, we had a weird hack reading the right property
    on powermac and the wrong one on any other 64 bits (32 bits is
    unaffected as it only uses the cputable for cache block size
    infos at this stage).

    This fixes the booting-without-of.txt documentation to mention
    the right properties, and fixes the 64 bits initialization code
    to look for the block size first, with a fallback to the line
    size if the property is missing.

    Signed-off-by: Benjamin Herrenschmidt
    Signed-off-by: Paul Mackerras

    Benjamin Herrenschmidt
     
  • kernel was marked with 0755. Everywhere else it's 0555.

    Signed-off-by: Alexey Dobriyan
    Signed-off-by: Paul Mackerras

    Alexey Dobriyan
     

01 Nov, 2007

3 commits

  • The 44x family has an interesting "feature" which is a virtually
    tagged instruction cache (yuck !). So far, we haven't dealt with
    it properly, which means we've been mostly lucky or people didn't
    report the problems, unless people have been running custom patches
    in their distro...

    This is an attempt at fixing it properly. I chose to do it by
    setting a global flag whenever we change a PTE that was previously
    marked executable, and flush the entire instruction cache upon
    return to user space when that happens.

    This is a bit heavy handed, but it's hard to do more fine grained
    flushes as the icbi instruction, on those processor, for some very
    strange reasons (since the cache is virtually mapped) still requires
    a valid TLB entry for reading in the target address space, which
    isn't something I want to deal with.

    Signed-off-by: Benjamin Herrenschmidt
    Signed-off-by: Josh Boyer

    Benjamin Herrenschmidt
     
  • On 4xx CPUs, the current implementation of flush_tlb_page() uses
    a low level _tlbie() assembly function that only works for the
    current PID. Thus, invalidations caused by, for example, a COW
    fault triggered by get_user_pages() from a different context will
    not work properly, causing among other things, gdb breakpoints
    to fail.

    This patch adds a "pid" argument to _tlbie() on 4xx processors,
    and uses it to flush entries in the right context. FSL BookE
    also gets the argument but it seems they don't need it (their
    tlbivax form ignores the PID when invalidating according to the
    document I have).

    Signed-off-by: Benjamin Herrenschmidt
    Acked-by: Kumar Gala
    Signed-off-by: Josh Boyer

    Benjamin Herrenschmidt
     
  • PowerPC 440EP(x) 440GR(x) processors have the same PVR values, since
    they have identical cores. However, FPU is not supported on GR(x) and
    enabling APU instruction broadcast in the CCR0 register (to enable FPU)
    may cause unpredictable results. There's no safe way to detect FPU
    support at runtime. This patch provides a workarund for the issue.

    We use a POWER6 "logical PVR approach". First, we identify all EP(x)
    and GR(x) processors as GR(x) ones (which is safe). Then we check
    the device tree cpu path. If we have a EP(x) processor entry,
    we call identify_cpu again with PVR | 0x8. This bit is always 0
    in the real PVR. This way we enable FPU only for 440EP(x).

    Signed-off-by: Valentine Barshak
    Signed-off-by: Josh Boyer

    Valentine Barshak
     

23 Oct, 2007

1 commit


20 Oct, 2007

5 commits

  • From: Jean Delvare

    Signed-off-by: Jean Delvare
    Signed-off-by: Adrian Bunk

    Jean Delvare
     
  • * Convert files to UTF-8.

    * Also correct some people's names
    (one example is Eißfeldt, which was found in a source file.
    Given that the author used an ß at all in a source file
    indicates that the real name has in fact a 'ß' and not an 'ss',
    which is commonly used as a substitute for 'ß' when limited to
    7bit.)

    * Correct town names (Goettingen -> Göttingen)

    * Update Eberhard Mönkeberg's address (http://lkml.org/lkml/2007/1/8/313)

    Signed-off-by: Jan Engelhardt
    Signed-off-by: Adrian Bunk

    Jan Engelhardt
     
  • This patch adapts the ppc64 code to use the generic parse_crashkernel()
    function introduced in the generic patch of that series.

    Signed-off-by: Bernhard Walle
    Cc: Paul Mackerras
    Cc: Benjamin Herrenschmidt
    Cc: Vivek Goyal
    Cc: "Eric W. Biederman"
    Signed-off-by: Andrew Morton
    Signed-off-by: Linus Torvalds

    Bernhard Walle
     
  • One of the easiest things to isolate is the pid printed in kernel log.
    There was a patch, that made this for arch-independent code, this one makes
    so for arch/xxx files.

    It took some time to cross-compile it, but hopefully these are all the
    printks in arch code.

    Signed-off-by: Alexey Dobriyan
    Signed-off-by: Pavel Emelyanov
    Cc:
    Signed-off-by: Andrew Morton
    Signed-off-by: Linus Torvalds

    Alexey Dobriyan
     
  • is_init() is an ambiguous name for the pid==1 check. Split it into
    is_global_init() and is_container_init().

    A cgroup init has it's tsk->pid == 1.

    A global init also has it's tsk->pid == 1 and it's active pid namespace
    is the init_pid_ns. But rather than check the active pid namespace,
    compare the task structure with 'init_pid_ns.child_reaper', which is
    initialized during boot to the /sbin/init process and never changes.

    Changelog:

    2.6.22-rc4-mm2-pidns1:
    - Use 'init_pid_ns.child_reaper' to determine if a given task is the
    global init (/sbin/init) process. This would improve performance
    and remove dependence on the task_pid().

    2.6.21-mm2-pidns2:

    - [Sukadev Bhattiprolu] Changed is_container_init() calls in {powerpc,
    ppc,avr32}/traps.c for the _exception() call to is_global_init().
    This way, we kill only the cgroup if the cgroup's init has a
    bug rather than force a kernel panic.

    [akpm@linux-foundation.org: fix comment]
    [sukadev@us.ibm.com: Use is_global_init() in arch/m32r/mm/fault.c]
    [bunk@stusta.de: kernel/pid.c: remove unused exports]
    [sukadev@us.ibm.com: Fix capability.c to work with threaded init]
    Signed-off-by: Serge E. Hallyn
    Signed-off-by: Sukadev Bhattiprolu
    Acked-by: Pavel Emelianov
    Cc: Eric W. Biederman
    Cc: Cedric Le Goater
    Cc: Dave Hansen
    Cc: Herbert Poetzel
    Cc: Kirill Korotaev
    Signed-off-by: Andrew Morton
    Signed-off-by: Linus Torvalds

    Serge E. Hallyn
     

19 Oct, 2007

1 commit

  • This adds POWERPC specific hooks for scaled time accounting.

    POWER6 includes a SPURR register. The SPURR is based off the PURR register
    but is scaled based on CPU frequency and issue rates. This gives a more
    accurate account of the instructions used per task. The PURR and timebase
    will be constant relative to the wall clock, irrespective of the CPU
    frequency.

    This implementation reads the SPURR register in account_system_vtime which
    is only call called on context witch and hard and soft irq entry and exit.
    The percentage of user and system time is then estimated using the ratio of
    these accounted by the PURR. If the SPURR is not present, the PURR read.

    An earlier implementation of this patch read the SPURR whenever the PURR
    was read, which included the system call entry and exit path.
    Unfortunately this showed a performance regression on lmbench runs, so was
    re-implemented.

    I've included the lmbench results here when run bare metal on POWER6. 1st
    column is the unpatch results. 2nd column is the results using the below
    patch and the 3rd is the % diff of these results from the base. 4th and
    5th columns are the results and % differnce from the base using the older
    patch (SPURR read in syscall entry/exit path).

    Base Scaled-Acct SPURR-in-syscall
    Result Result % diff Result % diff
    Simple syscall: 0.3086 0.3086 0.0000 0.3452 11.8600
    Simple read: 0.4591 0.4671 1.7425 0.5044 9.86713
    Simple write: 0.4364 0.4366 0.0458 0.4731 8.40971
    Simple stat: 2.0055 2.0295 1.1967 2.0669 3.06158
    Simple fstat: 0.5962 0.5876 -1.442 0.6368 6.80979
    Simple open/close: 3.1283 3.1009 -0.875 3.2088 2.57328
    Select on 10 fd's: 0.8554 0.8457 -1.133 0.8667 1.32101
    Select on 100 fd's: 3.5292 3.6329 2.9383 3.6664 3.88756
    Select on 250 fd's: 7.9097 8.1881 3.5197 8.2242 3.97613
    Select on 500 fd's: 15.2659 15.836 3.7357 15.873 3.97814
    Select on 10 tcp fd's: 0.9576 0.9416 -1.670 0.9752 1.83792
    Select on 100 tcp fd's: 7.248 7.2254 -0.311 7.2685 0.28283
    Select on 250 tcp fd's: 17.7742 17.707 -0.375 17.749 -0.1406
    Select on 500 tcp fd's: 35.4258 35.25 -0.496 35.286 -0.3929
    Signal handler installation: 0.6131 0.6075 -0.913 0.647 5.52927
    Signal handler overhead: 2.0919 2.1078 0.7600 2.1831 4.35967
    Protection fault: 0.7345 0.7478 1.8107 0.8031 9.33968
    Pipe latency: 33.006 16.398 -50.31 33.475 1.42368
    AF_UNIX sock stream latency: 14.5093 30.910 113.03 30.715 111.692
    Process fork+exit: 219.8 222.8 1.3648 229.37 4.35623
    Process fork+execve: 876.14 873.28 -0.32 868.66 -0.8533
    Process fork+/bin/sh -c: 2830 2876.5 1.6431 2958 4.52296
    File /var/tmp/XXX write bw: 1193497 1195536 0.1708 118657 -0.5799
    Pagefaults on /var/tmp/XXX: 3.1272 3.2117 2.7020 3.2521 3.99398

    Also, kernel compile times show no difference with this patch applied.

    [pbadari@us.ibm.com: Avoid unnecessary PURR reading]
    Signed-off-by: Michael Neuling
    Cc: Balbir Singh
    Cc: Jay Lan
    Cc: Paul Mackerras
    Cc: Benjamin Herrenschmidt
    Signed-off-by: Badari Pulavarty
    Signed-off-by: Andrew Morton
    Signed-off-by: Linus Torvalds

    Michael Neuling
     

18 Oct, 2007

1 commit

  • * 'merge' of git://git.kernel.org/pub/scm/linux/kernel/git/paulus/powerpc: (24 commits)
    [POWERPC] Fix vmemmap warning in init_64.c
    [POWERPC] Fix 64 bits vDSO DWARF info for CR register
    [POWERPC] Add 1TB workaround for PA6T
    [POWERPC] Enable NO_HZ and high res timers for pseries and ppc64 configs
    [POWERPC] Quieten cache information at boot
    [POWERPC] Quieten clockevent printk
    [POWERPC] Enable SLUB in *_defconfig
    [POWERPC] Fix 1TB segment detection
    [POWERPC] Fix iSeries_hpte_insert prototype
    [POWERPC] Fix copyright symbol
    [POWERPC] ibmebus: Move to of_device and of_platform_driver, match eHCA and eHEA drivers
    [POWERPC] ibmebus: Add device creation and bus probing based on of_device
    [POWERPC] ibmebus: Remove bus match/probe/remove functions
    [POWERPC] Move of_device allocation into of_device.[ch]
    [POWERPC] mpc52xx: device tree changes for FEC and MDIO
    [POWERPC] bestcomm: GenBD task support
    [POWERPC] bestcomm: FEC task support
    [POWERPC] bestcomm: ATA task support
    [POWERPC] bestcomm: core bestcomm support for Freescale MPC5200
    [POWERPC] mpc52xx: Update mpc52xx_psc structure with B revision changes
    ...

    Linus Torvalds
     

17 Oct, 2007

5 commits

  • All asm/ipc.h files do only #include .

    This patch therefore removes all include/asm-*/ipc.h files and moves the
    contents of include/asm-generic/ipc.h to include/linux/ipc.h.

    Signed-off-by: Adrian Bunk
    Cc:
    Signed-off-by: Andrew Morton
    Signed-off-by: Linus Torvalds

    Adrian Bunk
     
  • This makes powerpc64's compat code use the new linux/elfcore-compat.h,
    reducing some hand-copied duplication.

    Signed-off-by: Roland McGrath
    Cc: Benjamin Herrenschmidt
    Cc: Paul Mackerras
    Cc: Andi Kleen
    Cc: "Luck, Tony"
    Signed-off-by: Andrew Morton
    Signed-off-by: Linus Torvalds

    Roland McGrath
     
  • Slab constructors currently have a flags parameter that is never used. And
    the order of the arguments is opposite to other slab functions. The object
    pointer is placed before the kmem_cache pointer.

    Convert

    ctor(void *object, struct kmem_cache *s, unsigned long flags)

    to

    ctor(struct kmem_cache *s, void *object)

    throughout the kernel

    [akpm@linux-foundation.org: coupla fixes]
    Signed-off-by: Christoph Lameter
    Signed-off-by: Andrew Morton
    Signed-off-by: Linus Torvalds

    Christoph Lameter
     
  • Update dump_task_altivec() (which has so far never been put to use) so that
    it dumps the Altivec/VMX registers (VR[0] - VR[31], VSCR and VRSAVE) in the
    same format as the ptrace get_vrregs(), and add the appropriate glue
    typedef and #defines to make it work.

    A new note type of NT_PPC_VMX was chosen to be 0x100 (arbitrarily) because
    it allows the low range values to be used for more generic purposes and
    0x100 seems an adequate starting point for PowerPC extensions.

    Signed-off-by: Mark Nelson
    Signed-off-by: Paul Mackerras
    Cc: Thomas Gleixner
    Cc: Ingo Molnar
    Cc: Andi Kleen
    Cc:
    Signed-off-by: Andrew Morton
    Signed-off-by: Linus Torvalds

    Mark Nelson
     
  • The current DWARF info for CR are incorrect, causing the gcc unwinder to
    go to lunch if we take a segfault in the vdso. This fixes it.

    Problem identified by Andrew Haley, and fix provided by Jakub Jelinek
    (thanks !).

    Unfortunately, a bug in gcc cause it to not quite work either, but that
    is being fixed separately with something around the lines of:

    linux-unwind.h:

    fs->regs.reg[R_CR2].loc.offset = (long) ®s->ccr - new_cfa;
    + /* CR? regs are just 32-bit and PPC is big-endian. */
    + fs->regs.reg[R_CR2].loc.offset += sizeof (long) - 4;

    (According to Jakub)

    Signed-off-by: Benjamin Herrenschmidt
    Signed-off-by: Paul Mackerras

    Benjamin Herrenschmidt