09 Dec, 2006

1 commit

  • This facility provides three entry points:

    ilog2() Log base 2 of unsigned long
    ilog2_u32() Log base 2 of u32
    ilog2_u64() Log base 2 of u64

    These facilities can either be used inside functions on dynamic data:

    int do_something(long q)
    {
    ...;
    y = ilog2(x)
    ...;
    }

    Or can be used to statically initialise global variables with constant values:

    unsigned n = ilog2(27);

    When performing static initialisation, the compiler will report "error:
    initializer element is not constant" if asked to take a log of zero or of
    something not reducible to a constant. They treat negative numbers as
    unsigned.

    When not dealing with a constant, they fall back to using fls() which permits
    them to use arch-specific log calculation instructions - such as BSR on
    x86/x86_64 or SCAN on FRV - if available.

    [akpm@osdl.org: MMC fix]
    Signed-off-by: David Howells
    Cc: Benjamin Herrenschmidt
    Cc: Paul Mackerras
    Cc: Herbert Xu
    Cc: David Howells
    Cc: Wojtek Kaniewski
    Signed-off-by: Andrew Morton
    Signed-off-by: Linus Torvalds

    David Howells
     

08 Dec, 2006

25 commits

  • * 'for-linus' of master.kernel.org:/home/rmk/linux-2.6-arm: (76 commits)
    [ARM] 4002/1: S3C24XX: leave parent IRQs unmasked
    [ARM] 4001/1: S3C24XX: shorten reboot time
    [ARM] 3983/2: remove unused argument to __bug()
    [ARM] 4000/1: Osiris: add third serial port in
    [ARM] 3999/1: RX3715: suspend to RAM support
    [ARM] 3998/1: VR1000: LED platform devices
    [ARM] 3995/1: iop13xx: add iop13xx support
    [ARM] 3968/1: iop13xx: add iop13xx_defconfig
    [ARM] Update mach-types
    [ARM] Allow gcc to optimise arm_add_memory a little more
    [ARM] 3991/1: i.MX/MX1 high resolution time source
    [ARM] 3990/1: i.MX/MX1 more precise PLL decode
    [ARM] 3986/1: H1940: suspend to RAM support
    [ARM] 3985/1: ixp4xx clocksource cleanup
    [ARM] 3984/1: ixp4xx/nslu2: Fix disk LED numbering (take 2)
    [ARM] 3994/1: ixp23xx: fix handling of pci master aborts
    [ARM] 3981/1: sched_clock for PXA2xx
    [ARM] 3980/1: extend the ARM Versatile sched_clock implementation from 32 to 63 bit
    [ARM] 3979/1: extend the SA11x0 sched_clock implementation from 32 to 63 bit period
    [ARM] 3978/1: macro to provide a 63-bit value from a 32-bit hardware counter
    ...

    Linus Torvalds
     
  • Merge:
    Atmel AT91RM9200 and AT91SAM9260 changes
    General ARM developments
    Disconfiguous memory cleanups
    64-bit/32-bit division and sched_clock extension patches
    EP93xx support changes
    IOP support changes

    Signed-off-by: Russell King

    Russell King
     
  • Do not bother masking/unmasking the parent IRQ
    for the mulitplexed EINT irqs, as masking the
    leaf seems to be fine.

    Signed-off-by: Ben Dooks
    Signed-off-by: Russell King

    Ben Dooks
     
  • It appears that include/asm-arm/bug.h requires include/linux/stddef.h
    for the definition of NULL. It seems that stddef.h was always included
    indirectly in most cases, and that issue was properly fixed a while ago.

    Then commit 5047f09b56d0bc3c21aec9cb16de60283da645c6 incorrectly reverted
    change from commit ff10952a547dad934d9ed9afc5cf579ed1ccb53a (bad dwmw2)
    and the problem recently resurfaced.

    Because the third argument to __bug() is never used anyway, RMK suggested
    getting rid of it entirely instead of readding #include
    which this patch does.

    Signed-off-by: Nicolas Pitre
    Signed-off-by: Russell King

    Nicolas Pitre
     
  • Add the mapping for the third S3C2440 serial
    port into the default serial devices for the
    Osiris.

    Signed-off-by: Ben Dooks
    Signed-off-by: Russell King

    Ben Dooks
     
  • The RX3715 is similar to the H1940 in the way
    that suspend to RAM works, so we can use most
    of the extant support for the H1940 with only
    a few modifictions

    Signed-off-by: Ben Dooks
    Signed-off-by: Russell King

    Ben Dooks
     
  • Support for the GPIO attached LEDs on the VR1000

    Signed-off-by: Ben Dooks
    Signed-off-by: Russell King

    Ben Dooks
     
  • The iop348 processor integrates an Xscale (XSC3 512KB L2 Cache) core with a
    Serial Attached SCSI (SAS) controller, multi-ported DDR2 memory
    controller, 3 Application Direct Memory Access (DMA) controllers, a 133Mhz
    PCI-X interface, a x8 PCI-Express interface, and other peripherals to form
    a system-on-a-chip RAID subsystem engine.

    The iop342 processor replaces the SAS controller with a second Xscale core
    for dual core embedded applications.

    The iop341 processor is the single core version of iop342.

    This patch supports the two Intel customer reference platforms iq81340mc
    for external storage and iq81340sc for direct attach (HBA) development.

    The developer's manual is available here:
    ftp://download.intel.com/design/iio/docs/31503701.pdf

    Changelog:
    * removed virtual addresses from resource definitions
    * cleaned up some unnecessary #include's

    Signed-off-by: Dan Williams
    Signed-off-by: Russell King

    Dan Williams
     
  • Signed-off-by: Dan Williams
    Signed-off-by: Russell King

    Dan Williams
     
  • Signed-off-by: Russell King

    Russell King
     
  • This creates a new RTC-framework driver for the RTC/calendar module found
    in various OMAP1 chips. (OMAP2 and OMAP3 use external RTCs, like those in
    TI's multifunction PM companion chips.) It's been in the Linux-OMAP tree
    for several months now, and other trees before that, so it's quite stable.
    The most notable issue is that the OMAP IRQ code doesn't yet support the
    RTC IRQ as a wakeup event. Once that's fixed, a patch will be needed.

    Signed-off-by: David Brownell
    Acked-by: Alessandro Zummo
    Signed-off-by: Andrew Morton
    Signed-off-by: Linus Torvalds

    David Brownell
     
  • Move process freezing functions from include/linux/sched.h to freezer.h, so
    that modifications to the freezer or the kernel configuration don't require
    recompiling just about everything.

    [akpm@osdl.org: fix ueagle driver]
    Signed-off-by: Nigel Cunningham
    Cc: "Rafael J. Wysocki"
    Cc: Pavel Machek
    Signed-off-by: Andrew Morton
    Signed-off-by: Linus Torvalds

    Nigel Cunningham
     
  • Replace all uses of kmem_cache_t with struct kmem_cache.

    The patch was generated using the following script:

    #!/bin/sh
    #
    # Replace one string by another in all the kernel sources.
    #

    set -e

    for file in `find * -name "*.c" -o -name "*.h"|xargs grep -l $1`; do
    quilt add $file
    sed -e "1,\$s/$1/$2/g" $file >/tmp/$$
    mv /tmp/$$ $file
    quilt refresh
    done

    The script was run like this

    sh replace kmem_cache_t "struct kmem_cache"

    Signed-off-by: Christoph Lameter
    Signed-off-by: Andrew Morton
    Signed-off-by: Linus Torvalds

    Christoph Lameter
     
  • In light of the recent pagefault and filemap_copy_from_user work I've gone
    through all the arch pagefault handlers to make sure the inc_preempt_count()
    'feature' works as expected.

    Several sections of code (including the new filemap_copy_from_user) rely on
    the fact that faults do not take locks under increased preempt count.

    arch/x86_64 - good
    arch/powerpc - good
    arch/cris - fixed
    arch/i386 - good
    arch/parisc - fixed
    arch/sh - good
    arch/sparc - good
    arch/s390 - good
    arch/m68k - fixed
    arch/ppc - good
    arch/alpha - fixed
    arch/mips - good
    arch/sparc64 - good
    arch/ia64 - good
    arch/arm - fixed
    arch/um - good
    arch/avr32 - good
    arch/h8300 - NA
    arch/m32r - good
    arch/v850 - good
    arch/frv - fixed
    arch/m68knommu - NA
    arch/arm26 - fixed
    arch/sh64 - fixed
    arch/xtensa - good

    Signed-off-by: Peter Zijlstra
    Acked-by: Nick Piggin
    Signed-off-by: Andrew Morton
    Signed-off-by: Linus Torvalds

    Peter Zijlstra
     
  • For some reason, gcc was calculating meminfo.bank[meminfo.nr_banks]
    repeatedly. Use a pointer to it instead.

    Signed-off-by: Russell King

    Russell King
     
  • Enhanced resolution for time measurement functions.

    Signed-off-by: Pavel Pisa
    Signed-off-by: Sascha Hauer
    Signed-off-by: Russell King

    Pavel Pisa
     
  • The future high resolution support inclusion utilizes
    imx_decode_pll() in timer base frequency computation.
    This use requires more precise computation without
    discarding 10 bits by shifting left.

    Signed-off-by: Pavel Pisa
    Acked-by: Sascha Hauer
    Signed-off-by: Russell King

    Pavel Pisa
     
  • Add support to suspend and resume, using the
    H1940's bootloader

    Signed-off-by: Ben Dooks
    Signed-off-by: Arnaud Patard
    Signed-off-by: Russell King

    Ben Dooks
     
  • Rather than using a device_initcall() for the clocksource initialization, just call the init from the sys_timer init function.

    Signed-off-by: Kevin Hilman
    Signed-off-by: Russell King

    Kevin Hilman
     
  • The PCI master abort handling issue that affected ixp2000 also
    affects ixp23xx.

    Signed-off-by: Lennert Buytenhek
    Signed-off-by: Russell King

    Lennert Buytenhek
     
  • Here's a 63-bit implementation of shed_clock() for PXA2xx. The actual
    period depends on the value of CLOCK_TICK_RATE and whether or not
    reduced scaling factors were provided for it.

    Signed-off-by: Nicolas Pitre
    Signed-off-by: Russell King

    Nicolas Pitre
     
  • period

    This provides a 63 bit clock counter guaranteed to be monotonic over a
    period of 35583 days instead of a clock wrap every 179 seconds, as long
    as sched_clock() is called at least once every 89 seconds. This should
    not be a problem in practice, although a kernel timer could be scheduled
    every 80 seconds for example simply to call sched_clock() making sure
    top bits are always synchronized if need be.

    Signed-off-by: Nicolas Pitre
    Signed-off-by: Russell King

    Nicolas Pitre
     
  • This provides a 63 bit clock counter guaranteed to be monotonic over a
    period of 370 days instead of a clock wrap every 19.4 minutes, as long
    as sched_clock() is called at least once every 9.7 minutes which
    shouldn't be a problem in practice.

    Signed-off-by: Nicolas Pitre
    Signed-off-by: Russell King

    Nicolas Pitre
     
  • Add support for the Cirrus Logic EDB9302A Evaluation Board. Confirmed
    to work by Chase Douglas.

    Signed-off-by: Lennert Buytenhek
    Signed-off-by: Russell King

    Lennert Buytenhek
     
  • Do not assume that the ARM GCC toolchain defaults to building for the
    32-bit ARM ISA (-marm) case. Instead, explicitly select -marm in CFLAGS
    since the toolchain default can be for the 16-bit Thumb ISA (-mthumb) in
    some odd/rare cases.

    Signed-off-by: George G. Davis
    Signed-off-by: Russell King

    George G. Davis
     

06 Dec, 2006

1 commit


04 Dec, 2006

2 commits

  • Replace the 'is_b' variable with 'slot_b' in at91_mmc_data.
    Also add the new 'chipselect' variable for CF/PCMCIA and 'bus_width_16'
    variable for NAND.

    This (and previous patches) will unfortunately break the current MMC,
    USB Gadget and PCMCIA drivers. Updates and fixes for those drivers will
    be submitted to the various subsystem maintainers.

    Signed-off-by: Andrew Victor
    Signed-off-by: Russell King

    Andrew Victor
     
  • XScale cores either have a DSP coprocessor (which contains a single
    40 bit accumulator register), or an iWMMXt coprocessor (which contains
    eight 64 bit registers.)

    Because of the small amount of state in the DSP coprocessor, access to
    the DSP coprocessor (CP0) is always enabled, and DSP context switching
    is done unconditionally on every task switch. Access to the iWMMXt
    coprocessor (CP0/CP1) is enabled only when an iWMMXt instruction is
    first issued, and iWMMXt context switching is done lazily.

    CONFIG_IWMMXT is supposed to mean 'the cpu we will be running on will
    have iWMMXt support', but boards are supposed to select this config
    symbol by hand, and at least one pxa27x board doesn't get this right,
    so on that board, proc-xscale.S will incorrectly assume that we have a
    DSP coprocessor, enable CP0 on boot, and we will then only save the
    first iWMMXt register (wR0) on context switches, which is Bad.

    This patch redefines CONFIG_IWMMXT as 'the cpu we will be running on
    might have iWMMXt support, and we will enable iWMMXt context switching
    if it does.' This means that with this patch, running a CONFIG_IWMMXT=n
    kernel on an iWMMXt-capable CPU will no longer potentially corrupt iWMMXt
    state over context switches, and running a CONFIG_IWMMXT=y kernel on a
    non-iWMMXt capable CPU will still do DSP context save/restore.

    These changes should make iWMMXt work on PXA3xx, and as a side effect,
    enable proper acc0 save/restore on non-iWMMXt capable xsc3 cores such
    as IOP13xx and IXP23xx (which will not have CONFIG_CPU_XSCALE defined),
    as well as setting and using HWCAP_IWMMXT properly.

    Signed-off-by: Lennert Buytenhek
    Acked-by: Dan Williams
    Signed-off-by: Russell King

    Lennert Buytenhek
     

02 Dec, 2006

9 commits


01 Dec, 2006

2 commits

  • This patch includes a number of small changes for integrating the
    AT91SAM9261 and AT91SAM0260 support.

    * Can only select support for one AT91 processor at a time.
    * Remove most of the remaining static memory mapping for the
    AT91RM9200.
    * Reserve 1Mb of memory below the IO for mapping the internal SRAM
    and any custom board-specific devices (ie, FPGA).
    * The SAM9260 has more serial ports, so increase the maximum to 7.
    * Define the standard chipselect addresses, and define other
    addresses relative to those.
    * CLOCK_TICK_RATE is different on the SAM926x's.

    Signed-off-by: Andrew Victor
    Signed-off-by: Russell King

    Andrew Victor
     
  • The bits used to select the USB clocks are different on the SAM9's.
    Add support for the HCK clocks on the AT91SAM9261.

    Patch from Patrice Vilchez & Nicolas Ferre

    Signed-off-by: Andrew Victor
    Signed-off-by: Russell King

    Andrew Victor