22 Jul, 2007

1 commit

  • The recent signal rework broke ARCH=ppc builds with the following
    error:

    CC arch/powerpc/kernel/signal.o
    arch/powerpc/kernel/signal.c: In function ‘do_signal’:
    arch/powerpc/kernel/signal.c:142: error: implicit declaration of
    function ‘set_dabr’
    make[1]: *** [arch/powerpc/kernel/signal.o] Error 1

    This fixes it by including a function prototype in asm-ppc/system.h.

    Acked-by: Kumar Gala
    Signed-off-by: Josh Boyer
    Signed-off-by: Paul Mackerras

    Josh Boyer
     

20 Jul, 2007

1 commit


18 Jul, 2007

1 commit


17 Jul, 2007

1 commit

  • Kill pte_rdprotect(), pte_exprotect(), pte_mkread(), pte_mkexec(), pte_read(),
    pte_exec(), and pte_user() except where arch-specific code is making use of
    them.

    Signed-off-by: Jan Beulich
    Cc: Andi Kleen
    Cc: Christoph Hellwig
    Signed-off-by: Andrew Morton
    Signed-off-by: Linus Torvalds

    Jan Beulich
     

12 Jul, 2007

2 commits

  • Based on replies to a respective query, remove the pci_dac_dma_...() APIs
    (except for pci_dac_dma_supported() on Alpha, where this function is used
    in non-DAC PCI DMA code).

    Signed-off-by: Jan Beulich
    Cc: Andi Kleen
    Cc: Jesse Barnes
    Cc: Christoph Hellwig
    Acked-by: David Miller
    Cc: Jeff Garzik
    Cc:
    Signed-off-by: Andrew Morton
    Signed-off-by: Greg Kroah-Hartman

    Jan Beulich
     
  • I'm not sure if this is going to fly, weak symbols work on the compilers I'm
    using, but whether they work for all of the affected architectures I can't say.
    I've cc'ed as many arch maintainers/lists as I could find.

    But assuming they do, we can use a weak empty definition of
    pcibios_add_platform_entries() to avoid having an empty definition on every
    arch.

    Signed-off-by: Michael Ellerman
    Signed-off-by: Greg Kroah-Hartman

    Michael Ellerman
     

17 Jun, 2007

1 commit

  • Some changes done a while ago to avoid pounding on ptep_set_access_flags and
    update_mmu_cache in some race situations break sun4c which requires
    update_mmu_cache() to always be called on minor faults.

    This patch reworks ptep_set_access_flags() semantics, implementations and
    callers so that it's now responsible for returning whether an update is
    necessary or not (basically whether the PTE actually changed). This allow
    fixing the sparc implementation to always return 1 on sun4c.

    [akpm@linux-foundation.org: fixes, cleanups]
    Signed-off-by: Benjamin Herrenschmidt
    Cc: Hugh Dickins
    Cc: David Miller
    Cc: Mark Fortescue
    Acked-by: William Lee Irwin III
    Cc: "Luck, Tony"
    Signed-off-by: Andrew Morton
    Signed-off-by: Linus Torvalds

    Benjamin Herrenschmidt
     

10 May, 2007

3 commits

  • Paul Mackerras
     
  • Removed rheap in arch/ppc/lib and changed build system to use the
    one in arch/powerpc/lib.

    Signed-off-by: Kumar Gala

    Kumar Gala
     
  • The rheap allocation functions return a pointer, but the actual value is based
    on how the heap was initialized, and so it can be anything, e.g. an offset
    into a buffer. A ulong is a better representation of the value returned by
    the allocation functions.

    This patch changes all of the relevant rheap functions to use a unsigned long
    integers instead of a pointer. In case of an error, the value returned is
    a negative error code that has been cast to an unsigned long. The caller can
    use the IS_ERR_VALUE() macro to check for this.

    All code which calls the rheap functions is updated accordingly. Macros
    IS_MURAM_ERR() and IS_DPERR(), have been deleted in favor of IS_ERR_VALUE().

    Also added error checking to rh_attach_region().

    Signed-off-by: Timur Tabi
    Signed-off-by: Kumar Gala

    Timur Tabi
     

09 May, 2007

5 commits

  • Convert the "include" subdirectory to UTF-8.

    Signed-off-by: John Anthony Kazos Jr.
    Signed-off-by: Adrian Bunk

    John Anthony Kazos Jr
     
  • tas() has no users, so get rid of it.

    Signed-off-by: Jeff Dike
    Cc:
    Cc: Paolo 'Blaisorblade' Giarrusso
    Signed-off-by: Andrew Morton
    Signed-off-by: Linus Torvalds

    Jeff Dike
     
  • atomic_add_unless as inline. Remove system.h atomic.h circular dependency.
    I agree (with Andi Kleen) this typeof is not needed and more error
    prone. All the original atomic.h code that uses cmpxchg (which includes
    the atomic_add_unless) uses defines instead of inline functions,
    probably to circumvent a circular dependency between system.h and
    atomic.h on powerpc (which my patch addresses). Therefore, it makes
    sense to use inline functions that will provide type checking.

    atomic_add_unless as inline. Remove system.h atomic.h circular dependency.
    Digging into the FRV architecture shows me that it is also affected by
    such a circular dependency. Here is the diff applying this against the
    rest of my atomic.h patches.

    It applies over the atomic.h standardization patches.

    Signed-off-by: Mathieu Desnoyers
    Signed-off-by: Andrew Morton
    Signed-off-by: Linus Torvalds

    Mathieu Desnoyers
     
  • Most architectures defined three macros, MK_IOSPACE_PFN(), GET_IOSPACE()
    and GET_PFN() in pgtable.h. However, the only callers of any of these
    macros are in Sparc specific code, either in arch/sparc, arch/sparc64 or
    drivers/sbus.

    This patch removes the redundant macros from all architectures except
    sparc and sparc64.

    Signed-off-by: David Gibson
    Cc:
    Signed-off-by: Andrew Morton
    Signed-off-by: Linus Torvalds

    David Gibson
     
  • This patch moves the die notifier handling to common code. Previous
    various architectures had exactly the same code for it. Note that the new
    code is compiled unconditionally, this should be understood as an appel to
    the other architecture maintainer to implement support for it aswell (aka
    sprinkling a notify_die or two in the proper place)

    arm had a notifiy_die that did something totally different, I renamed it to
    arm_notify_die as part of the patch and made it static to the file it's
    declared and used at. avr32 used to pass slightly less information through
    this interface and I brought it into line with the other architectures.

    [akpm@linux-foundation.org: build fix]
    [akpm@linux-foundation.org: fix vmalloc_sync_all bustage]
    [bryan.wu@analog.com: fix vmalloc_sync_all in nommu]
    Signed-off-by: Christoph Hellwig
    Cc:
    Cc: Russell King
    Signed-off-by: Bryan Wu
    Signed-off-by: Andrew Morton
    Signed-off-by: Linus Torvalds

    Christoph Hellwig
     

03 May, 2007

1 commit

  • Add hooks to allow a paravirt implementation to track the lifetime of
    an mm. Paravirtualization requires three hooks, but only two are
    needed in common code. They are:

    arch_dup_mmap, which is called when a new mmap is created at fork

    arch_exit_mmap, which is called when the last process reference to an
    mm is dropped, which typically happens on exit and exec.

    The third hook is activate_mm, which is called from the arch-specific
    activate_mm() macro/function, and so doesn't need stub versions for
    other architectures. It's called when an mm is first used.

    Signed-off-by: Jeremy Fitzhardinge
    Signed-off-by: Andi Kleen
    Cc: linux-arch@vger.kernel.org
    Cc: James Bottomley
    Acked-by: Ingo Molnar

    Jeremy Fitzhardinge
     

30 Apr, 2007

2 commits


13 Apr, 2007

1 commit


13 Feb, 2007

1 commit

  • This patch adds support for the AMCC Taishan PPC440GX evaluation
    board.

    This is still an arch/ppc port. I'm aware that the move of
    4xx to arch/powerpc is making good progress right now. So this
    patch is mainly intended to make the Taishan support available
    for the community right now.

    Signed-off-by: Stefan Roese
    Signed-off-by: Paul Mackerras

    Stefan Roese
     

10 Feb, 2007

1 commit

  • On all targets that sucker boils down to memcpy_fromio(sbk->data, from, len).
    The function name is highly misguiding (it _never_ does any checksums), the
    last argument is just a noise and simply expanding the call to memcpy_fromio()
    gives shorter and more readable source. For a lot of reasons it has almost
    no remaining users, so it's better to just outright kill it.

    Signed-off-by: Al Viro
    Signed-off-by: Linus Torvalds

    Al Viro
     

07 Feb, 2007

2 commits


24 Jan, 2007

1 commit


11 Dec, 2006

2 commits


08 Dec, 2006

3 commits

  • The powerpc version of pci_resource_to_user() and associated hooks
    used by /proc/bus/pci and /sys/bus/pci mmap have been broken for some
    time on machines that don't have a 1:1 mapping of devices (basically
    on non-PowerMacs) and have PCI devices above 32 bits.

    This attempts to fix it as well as possible.

    The rule is supposed to be that pci_resource_to_user() always converts
    the resources back into a BAR values since that's what the /proc
    interface was supposed to deal with. However, for X to work on
    platforms where PCI MMIO is not mapped 1:1, it became a habit of
    platforms like powerpc to pass "fixed up" values there since X expects
    to be able to use values from /proc/bus/pci/devices as offsets to mmap
    of /dev/mem...

    So we keep that contraption here, causing also /sys/*/resource to
    expose fully absolute MMIO addresses instead of BAR values, which is
    ugly, but should still work as long as those are only used to calculate
    alignment within a page.

    X is still broken when built 32 bits on machines where PCI MMIO can be
    above 32-bit space unfortunately.

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

    Benjamin Herrenschmidt
     
  • The current PowerPC code makes pci_unmap_addr(), pci_unmap_addr_set(),
    and friends trivial for all 32-bit kernels. This is reasonable, since
    for those kernels it is true that pci_unmap_single() does not need the
    DMA address from the original DMA mapping -- in fact, it is a NOP.

    However, I recently tried the tg3 driver on a PowerPC 440SPe machine,
    which runs a 32-bit kernel and has non-cache-coherent PCI DMA. I
    found that the tg3 driver crashed in pci_dma_sync_single_for_cpu(),
    since for non-coherent systems, that function must invalidate the
    cache for the DMA address range requested, and therefore it does use
    the address passed in. tg3 uses a DMA address it stashes away with
    pci_unmap_addr_set() and retrieves with pci_unmap_addr(). Of course,
    since pci_unmap_addr() is defined to (0) right now, this doesn't work.

    It seems to me that the tg3 driver is using pci_unmap_addr() in a
    legitimate way -- I wouldn't want to have to teach all drivers that
    they should use pci_unmap_addr() if they only need the address for
    unmapping functions, but if they want the pci_dma_sync functions, then
    they have to store the DMA address without the helper macros.
    The right fix therefore seems to be in the definition of the macros in
    -- we should use the trivial versions only for 32-bit
    kernels for coherent systems, and the real versions for both 64-bit
    kernels and non-coherent systems.

    Signed-off-by: Roland Dreier
    Signed-off-by: Paul Mackerras

    Roland Dreier
     
  • Introduce pagefault_{disable,enable}() and use these where previously we did
    manual preempt increments/decrements to make the pagefault handler do the
    atomic thing.

    Currently they still rely on the increased preempt count, but do not rely on
    the disabled preemption, this might go away in the future.

    (NOTE: the extra barrier() in pagefault_disable might fix some holes on
    machines which have too many registers for their own good)

    [heiko.carstens@de.ibm.com: s390 fix]
    Signed-off-by: Peter Zijlstra
    Acked-by: Nick Piggin
    Cc: Martin Schwidefsky
    Signed-off-by: Heiko Carstens
    Signed-off-by: Andrew Morton
    Signed-off-by: Linus Torvalds

    Peter Zijlstra
     

04 Dec, 2006

5 commits

  • Add missing bracket in definition for m48t35 RTC chip.

    Signed-off-by: Mariusz Kozlowski
    Signed-off-by: Paul Mackerras

    Mariusz Kozlowski
     
  • The recent IO accessor changes broke IDE on arch/ppc due to the IDE
    stream IO macros using the new reads/writes{b,w,l} accessors that
    are only defined for arch/powerpc. This adds them to arch/ppc.

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

    Benjamin Herrenschmidt
     
  • This patch reworks the way iSeries hooks on PCI IO operations (both MMIO
    and PIO) and provides a generic way for other platforms to do so (we
    have need to do that for various other platforms).

    While reworking the IO ops, I ended up doing some spring cleaning in
    io.h and eeh.h which I might want to split into 2 or 3 patches (among
    others, eeh.h had a lot of useless stuff in it).

    A side effect is that EEH for PIO should work now (it used to pass IO
    ports down to the eeh address check functions which is bogus).

    Also, new are MMIO "repeat" ops, which other archs like ARM already had,
    and that we have too now: readsb, readsw, readsl, writesb, writesw,
    writesl.

    In the long run, I might also make EEH use the hooks instead
    of wrapping at the toplevel, which would make things even cleaner and
    relegate EEH completely in platforms/iseries, but we have to measure the
    performance impact there (though it's really only on MMIO reads)

    Since I also need to hook on ioremap, I shuffled the functions a bit
    there. I introduced ioremap_flags() to use by drivers who want to pass
    explicit flags to ioremap (and it can be hooked). The old __ioremap() is
    still there as a low level and cannot be hooked, thus drivers who use it
    should migrate unless they know they want the low level version.

    The patch "arch provides generic iomap missing accessors" (should be
    number 4 in this series) is a pre-requisite to provide full iomap
    API support with this patch.

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

    Benjamin Herrenschmidt
     
  • Add a "parent" struct device to our PCI host bridge data structure so that
    PCI can be rooted off another device in sysfs.

    Note that arch/ppc doesn't use it, only arch/powerpc, though it's available
    for both 32 and 64 bits.

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

    Benjamin Herrenschmidt
     
  • Paul Mackerras
     

02 Dec, 2006

1 commit

  • Add arch specific dev_archdata to struct device

    Adds an arch specific struct dev_arch to struct device. This enables
    architecture to add specific fields to every device in the system, like
    DMA operation pointers, NUMA node ID, firmware specific data, etc...

    Signed-off-by: Benjamin Herrenschmidt
    Acked-by: Andi Kleen
    Acked-By: David Howells
    Signed-off-by: Greg Kroah-Hartman

    Benjamin Herrenschmidt
     

13 Nov, 2006

1 commit


12 Oct, 2006

1 commit

  • There's nothing arch-specific about check_signature(), so move it to
    . Use a cross between the Alpha and i386 implementations as
    the generic one.

    Signed-off-by: Matthew Wilcox
    Acked-by: Alan Cox
    Signed-off-by: Andrew Morton
    Signed-off-by: Linus Torvalds

    Matthew Wilcox
     

10 Oct, 2006

1 commit


07 Oct, 2006

2 commits