04 Dec, 2007

3 commits

  • The previous commit ("uml: keep UML Kconfig in sync with x86") is not
    enough, unfortunately. If we go that way, we need to add dependencies
    on !UML for several options.

    Signed-off-by: Al Viro
    Signed-off-by: Jeff Dike
    Signed-off-by: Andrew Morton
    Signed-off-by: Linus Torvalds

    Al Viro
     
  • Fix a UML build breakage introduced by commit
    1032c0ba9da5c5b53173ad2dcf8b2a2da78f8b17 - it introduces X86_32, with many
    things which UML needs depending on it.

    This patch adds definitions of X86_32 and RWSEM_XCHGADD_ALGORITHM to
    the UML/i386 Kconfig.

    Signed-off-by: Jeff Dike
    Signed-off-by: Andrew Morton
    Signed-off-by: Linus Torvalds

    Jeff Dike
     
  • Fix possible memory overrun issue in the isdn ioctl code.

    Found by ADLAB

    Signed-off-by: Karsten Keil
    Cc: ADLAB
    Cc:
    Signed-off-by: Andrew Morton
    Signed-off-by: Linus Torvalds

    Karsten Keil
     

01 Dec, 2007

7 commits

  • * 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/roland/infiniband:
    IB/ehca: Fix static rate if path faster than link
    IPoIB: Fix oops if xmit is called when priv->broadcast is NULL

    Linus Torvalds
     
  • * 'upstream' of git://ftp.linux-mips.org/pub/scm/upstream-linus:
    [MIPS] Fix build.
    [MIPS] Fix use of smp_processor_id() in preemptible code.

    Linus Torvalds
     
  • Signed-off-by: Ralf Baechle

    Ralf Baechle
     
  • Freeing prom memory: 956kb freed
    Freeing firmware memory: 978944k freed
    Freeing unused kernel memory: 180k freed
    BUG: using smp_processor_id() in preemptible [00000000] code: swapper/1
    caller is r4k_dma_cache_wback_inv+0x144/0x2a0
    Call Trace:
    [] r4k_dma_cache_wback_inv+0x144/0x2a0
    [] debug_smp_processor_id+0xd4/0xf0
    [] debug_smp_processor_id+0xcc/0xf0
    ...
    CONFIG_DEBUG_PREEMPT is enabled.
    --
    Bug cause is blast_dcache_range() in preemptible code [in
    r4k_dma_cache_wback_inv()].
    blast_dcache_range() is constructed via __BUILD_BLAST_CACHE_RANGE that
    uses cpu_dcache_line_size(). It uses current_cpu_data that use
    smp_processor_id() in turn. In case of CONFIG_DEBUG_PREEMPT
    smp_processor_id emits BUG if we are executing with preemption
    enabled.

    Cpu options of cpu0 are assumed to be the superset of all processors.

    Can I make the same assumptions for cache line size and fix this
    issue the following way:

    Signed-off-by: Ralf Baechle

    Pavel Kiryukhin
     
  • The formula would yield -1 if the path is faster than the link, which
    is wrong in a bad way (max throttling). Clamp to 0, which is the
    correct value.

    Signed-off-by: Joachim Fenkes
    Signed-off-by: Roland Dreier

    Joachim Fenkes
     
  • * 'for-linus' of master.kernel.org:/home/rmk/linux-2.6-arm:
    [ARM] 4680/1: parentheses around NR_IRQS definition
    [ARM] 4679/1: AT91: Change maintainer email address
    [ARM] 4675/1: pxa: fix mfp address definition error for pxa320
    [ARM] 4674/1: pxa: increase LCD PCLK drive strength to fast 2mA for PXA300/PXA310
    [ARM] 4673/1: pxa: add missing IRQ_SSP4 definitions for PXA3xx
    [ARM] 4672/1: pxa: fix DRCMR(n) to support PXA27x and later processors
    [ARM] 4665/1: fix __und_usr wrt accessing the undefined insn in user space
    [ARM] 4659/1: remove possibilities for spurious false negative with __kuser_cmpxchg
    [ARM] 4661/1: fix do_undefinstr wrt the enabling of IRQs
    [ARM] uengine: fix memset size error
    [ARM] 4648/1: i.MX/MX1 ensure more complete AITC initialization
    [ARM] 4611/2: AT91: Fix GPIO buttons pins on SAM9261-EK.
    [ARM] 4650/1: AT91: New-style init of I2C, support for i2c-gpio
    [ARM] 4604/2: AT91: Master clock divistor on SAM9
    [ARM] 4662/1: Fix PXA serial driver compilation if SERIAL_PXA_CONSOLE is disabled
    [ARM] PXA ssp: unlock when ssp tries to close an invalid port
    [ARM] 4654/1: pxa: update default MFP register value
    [ARM] 4653/1: pxa: fix a gpio typo in mfp-pxa320.h
    [ARM] 4652/1: pxa: fix a typo of pxa27x usb host clk definition
    [ARM] 4651/1: pxa: add PXA3xx specific IRQ definitions

    Linus Torvalds
     
  • The database performance group have found that half the cycles spent
    in kmem_cache_free are spent in this one call to BUG_ON. Moving it
    into the CONFIG_SLAB_DEBUG-only function cache_free_debugcheck() is a
    performance win of almost 0.5% on their particular benchmark.

    The call was added as part of commit ddc2e812d592457747c4367fb73edcaa8e1e49ff
    with the comment that "overhead should be minimal". It may have been
    minimal at the time, but it isn't now.

    [ Quoth Pekka Enberg: "I don't think the BUG_ON per se caused the
    performance regression but rather the virt_to_head_page() changes to
    virt_to_cache() that were added later." ]

    Signed-off-by: Matthew Wilcox
    Acked-by: Pekka J Enberg
    Signed-off-by: Linus Torvalds

    Matthew Wilcox
     

30 Nov, 2007

30 commits

  • * 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/hpa/linux-2.6-x86setup:
    x86 setup: don't recalculate ss:esp unless really necessary

    Linus Torvalds
     
  • Russell King
     
  • If NR_IRQS is defined as a sum without surrounding parentheses, this may
    lead to problems when used in multiplications. This may lead to problems
    in:
    arch/ia64/sn/kernel/irq.c:516
    arch/x86/kernel/io_apic_32.c:693, 694, 699, 700
    fs/proc/proc_misc.c:464

    Signed-off-by: Roel Kluin
    Acked-by: Lennert Buytenhek
    Signed-off-by: Russell King

    Roel Kluin
     
  • Change email address of AT91 maintainer.

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

    Andrew Victor
     
  • Signed-off-by: bridge wu
    Signed-off-by: eric miao
    Signed-off-by: Russell King

    eric miao
     
  • Some platforms (e.g. Littleton) requires LCD PCLK drive strength to be
    higher than default to cope with the fast PCLK frequency.

    Signed-off-by: eric miao
    Signed-off-by: Russell King

    eric miao
     
  • Signed-off-by: eric miao
    Signed-off-by: Russell King

    eric miao
     
  • Signed-off-by: eric miao
    Signed-off-by: Russell King

    eric miao
     
  • * 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/drzeus/mmc:
    sdio_uart: fix sign of paramter status in sdio_uart_receive_chars()

    Linus Torvalds
     
  • This also fixes a sparse warning about different signedness.
    Only compile tested, because i do not have the hardware.

    Signed-off-by: Andre Haupt
    Acked-by: Nicolas Pitre
    Signed-off-by: Pierre Ossman

    Andre Haupt
     
  • Subdividing the paravirt_ops structure caused a regression in certain
    non-GPL modules which try to use mmu_ops and cpu_ops. This restores the
    old behaviour, and makes it consistent with the non-CONFIG_PARAVIRT case.

    Takashi Iwai adds:
    > I took at this problem (as I have an nvidia card on one of my
    > workstations), and found out that the following suffer from
    > EXPORT_SYMBOL_GPL changes:
    >
    > * local_disable_irq(), local_irq_save*(), etc.
    > * MSR-related macros like rdmsr(), wrmsr(), read_cr0(), etc.
    > wbinvd(), too.
    > * pmd_val(), pgd_val(), etc are all involved with pv_mm_ops.
    > pmd_large() and pmd_bad() is also indirectly involved.
    > __flush_tlb() and friends suffer, too.

    Christoph Hellwig objects to this patch on the grounds that modules
    shouldn't be using these operations anyway. I don't think this is a
    particularly good reason to reject the patch, for several reasons:

    1. These operations are still available to modules when not using
    CONFIG_PARAVIRT, since they are implicitly exported as inline
    functions via the kernel headers. Exporting the same functionality as
    GPL-only symbols just adds a gratuitious difference between
    CONFIG_PARAVIRT and non-CONFIG_PARAVIRT configurations. If we really
    think these operations are not for module use (or non-GPL module use),
    then we should solve the problem in a general way.

    2. It's a regression from previous kernels, which would work these
    modules even with CONFIG_PARAVIRT enabled.

    3. The operations in question seem pretty reasonable for modules to
    use. The control registers/MSRs can be accessed directly anyway, so there's
    no benefit in preventing modules from using standard interfaces. And it seems
    reasonable to allow a graphics driver to create its own mappings if it wants.

    Therefore, I think this patch should go in for 2.6.24. If people
    really think that these operations should not be available to modules,
    then we can address that separately.

    Signed-off-by: Jeremy Fitzhardinge
    Cc: Tobias Powalowski
    Cc: Christoph Hellwig
    Cc: Takashi Iwai
    Cc: Zachary Amsden
    Signed-off-by: Andrew Morton
    Signed-off-by: Linus Torvalds

    Jeremy Fitzhardinge
     
  • Keep lguest from being enabled on VISWS or VOYAGER configs, just as is
    already done for VMI and XEN. Otherwise randconfigs with VISWS and LGUEST
    have this problem:

    In file included from arch/x86/kernel/setup_32.c:61:
    include/asm-x86/mach-visws/setup_arch.h:8:1: warning: "ARCH_SETUP" redefined
    In file included from include/asm/msr.h:80,
    from include/asm/processor_32.h:17,
    from include/asm/processor.h:2,
    from include/asm/thread_info_32.h:16,
    from include/asm/thread_info.h:2,
    from include/linux/thread_info.h:21,
    from include/linux/preempt.h:9,
    from include/linux/spinlock.h:49,
    from include/linux/seqlock.h:29,
    from include/linux/time.h:8,
    from include/linux/timex.h:57,
    from include/linux/sched.h:53,
    from arch/x86/kernel/setup_32.c:24:
    include/asm/paravirt.h:458:1: warning: this is the location of the previous definition

    (and of course, this happens because kconfig does not follow dependencies
    when [evil] select is used...)

    Signed-off-by: Randy Dunlap
    Cc: Rusty Russell
    Signed-off-by: Andrew Morton
    Signed-off-by: Linus Torvalds

    Randy Dunlap
     
  • ACPI uses NR_CPUS in various loops and in some it accesses per cpu data of
    processors that are not present(!) and that will never be present.

    The pointers to per cpu data are typically not initialized for processors
    that are not present. So we seem to be reading something here from offset
    0 in memory.

    Make ACPI use nr_cpu_ids instead. That stops at the end of the possible
    processors.

    Convert one loop to NR_CPUS to use the cpu_possible map instead. That way
    ranges of processor that can never be brought online are skipped during the
    loop.

    Signed-off-by: Christoph Lameter
    Cc: Len Brown
    Acked-by: Andi Kleen
    Signed-off-by: Andrew Morton
    Signed-off-by: Linus Torvalds

    Christoph Lameter
     
  • Make them depend on TCGETS2. If that one is implemented the rest should be
    there as well.

    Acked-by: Alan Cox
    Signed-off-by: Heiko Carstens
    Signed-off-by: Andrew Morton
    Signed-off-by: Linus Torvalds

    Heiko Carstens
     
  • In wait_task_stopped() exit_code already contains the right value for the
    si_status member of siginfo, and this is simply set in the non WNOWAIT
    case.

    If you call waitid() with a stopped or traced process, you'll get the signal
    in siginfo.si_status as expected -- however if you call waitid(WNOWAIT) at the
    same time, you'll get the signal << 8 | 0x7f

    Pass it unchanged to wait_noreap_copyout(); we would only need to shift it
    and add 0x7f if we were returning it in the user status field and that
    isn't used for any function that permits WNOWAIT.

    Signed-off-by: Scott James Remnant
    Signed-off-by: Oleg Nesterov
    Cc: Roland McGrath
    Cc:
    Signed-off-by: Andrew Morton
    Signed-off-by: Linus Torvalds

    Scott James Remnant
     
  • Signed-off-by: Mike Christie
    Signed-off-by: Andrew Morton
    Signed-off-by: Linus Torvalds

    Mike Christie
     
  • Arrange the sections in the FRV arch so that a BRA instruction with a
    16-bit displacement can always reach from the trap table to entry.S,
    tlb-miss.S and break.S.

    The problem otherwise is that the linker can insert sufficient code between
    the slots in the trap table and the targets of the branch instructions in
    those slots that the displacement field in the instruction isn't
    sufficiently large. This is because the branch targets were in the .text
    section along with most of the other code in the kernel.

    Signed-off-by: David Howells
    Signed-off-by: Andrew Morton
    Signed-off-by: Linus Torvalds

    David Howells
     
  • Fix the extern declaration of kallsyms_num_syms to indicate that the symbol
    does not reside in the small-data storage space, and so may not be accessed
    relative to the small data base register.

    Signed-off-by: David Howells
    Signed-off-by: Andrew Morton
    Signed-off-by: Linus Torvalds

    David Howells
     
  • RTC code is using mutex to assure exclusive access to /dev/rtc. This is
    however wrong usage, as it leaves the mutex locked when returning into
    userspace, which is unacceptable.

    Convert rtc->char_lock into bit operation.

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

    Jiri Kosina
     
  • Invalidate attributes on rename, since some filesystems may update
    st_ctime. Reported by Szabolcs Szakacsits

    Signed-off-by: Miklos Szeredi
    Signed-off-by: Andrew Morton
    Signed-off-by: Linus Torvalds

    Miklos Szeredi
     
  • I found problems accessing (executing) previously existing files, until
    I did chmod on them (or setattr).

    If the fi->attr_version is not initialized, then it could be
    larger than fc->attr_version until a setattr is executed, and as a
    result the inode attributes would never be set.

    Signed-off-by: Miklos Szeredi
    Signed-off-by: Andrew Morton
    Signed-off-by: Linus Torvalds

    John Muir
     
  • FUSE_FILE_OPS is meant to signal that the kernel will send the open file to to
    the userspace filesystem for operations on open files, so that sillyrenaming
    unlinked files becomes unnecessary.

    However this needs VFS changes, which won't make it into 2.6.24.

    Signed-off-by: Miklos Szeredi
    Signed-off-by: Andrew Morton
    Signed-off-by: Linus Torvalds

    Miklos Szeredi
     
  • Some open flags (O_APPEND, O_DIRECT) can be changed with fcntl(F_SETFL, ...)
    after open, but fuse currently only sends the flags to userspace in open.

    To make it possible to correcly handle changing flags, send the
    current value to userspace in each read and write.

    Signed-off-by: Miklos Szeredi
    Signed-off-by: Andrew Morton
    Signed-off-by: Linus Torvalds

    Miklos Szeredi
     
  • Extract repeated code into helper function, as suggested by Akpm.

    Signed-off-by: Miklos Szeredi
    Signed-off-by: Andrew Morton
    Signed-off-by: Linus Torvalds

    Miklos Szeredi
     
  • Currently reading a fuse file will stop at cached i_size and return
    EOF, even though the file might have grown since the attributes were
    last updated.

    So detect if trying to read past EOF, and refresh the attributes
    before continuing with the read.

    Thanks to mpb for the report.

    Signed-off-by: Miklos Szeredi
    Signed-off-by: Andrew Morton
    Signed-off-by: Linus Torvalds

    Miklos Szeredi
     
  • Changes __meminit to __init_refok.

    WARNING: vmlinux.o(.text+0x1d07c): Section mismatch: reference to
    .init.text:find_e820_area (between 'init_memory_mapping' and 'arch_add_memory')

    Signed-off-by: KAMEZAWA Hiroyuki
    Cc: Ingo Molnar
    Cc: Thomas Gleixner
    Signed-off-by: Andrew Morton
    Signed-off-by: Linus Torvalds

    KAMEZAWA Hiroyuki
     
  • Fixes section mismatch below.

    WARNING: vmlinux.o(.text+0x946b5): Section mismatch: reference to .init.text:'
    __alloc_bootmem_node (between 'vmemmap_alloc_block' and 'vmemmap_pgd_populate')

    Signed-off-by: KAMEZAWA Hiroyuki
    Cc: Kamalesh Babulal
    Cc: Andy Whitcroft
    Signed-off-by: Andrew Morton
    Signed-off-by: Linus Torvalds

    KAMEZAWA Hiroyuki
     
  • This patch adds document for EFI x86_64 boot support. The setup and operation
    guide of EFI based system is documented in Documentation/x86_64/uefi.txt.

    Signed-off-by: Chandramouli Narayanan
    Signed-off-by: Huang Ying
    Cc: "H. Peter Anvin"
    Cc: Thomas Gleixner
    Cc: Ingo Molnar
    Cc: Andi Kleen
    Signed-off-by: Andrew Morton
    Signed-off-by: Linus Torvalds

    Huang, Ying
     
  • This patch adds Graphics Output Protocol support to the kernel. UEFI2.0 spec
    deprecates Universal Graphics Adapter (UGA) protocol and only Graphics Output
    Protocol (GOP) is produced. Therefore, the boot loader needs to query the
    UEFI firmware with appropriate Output Protocol and pass the video information
    to the kernel. As a result of GOP protocol, an EFI framebuffer driver is
    needed for displaying console messages. The patch adds a EFI framebuffer
    driver. The EFI frame buffer driver in this patch is based on the Intel Mac
    framebuffer driver.

    The ELILO bootloader takes care of passing the video information as
    appropriate for EFI firmware.

    The framebuffer driver has been tested in i386 kernel and x86_64 kernel on EFI
    platform.

    Signed-off-by: Chandramouli Narayanan
    Signed-off-by: Huang Ying
    Cc: "H. Peter Anvin"
    Cc: Thomas Gleixner
    Cc: Ingo Molnar
    Cc: Andi Kleen
    Cc: "Antonino A. Daplas"
    Signed-off-by: Andrew Morton
    Signed-off-by: Linus Torvalds

    Huang, Ying
     
  • Revert 7eea436433b7b18045f272562e256976f593f7c0.

    Lucy said:

    This patch will work with the 19HS but WILL BREAK all other Keyspan
    adapters. It will take me a few days to get to looking at a correct fix but
    that keyspan_send_setup(port, 1) (and the '1' is the important part) must
    happen once when the port is first opened. The cflag can just be set to
    whatever the normal default is for your serial environment.

    So revert this again pending the proper fix.

    Cc: Borislav Petkov
    Cc: Greg KH
    Cc: Alan Cox
    Cc: Lucy McCoy
    Signed-off-by: Andrew Morton
    Signed-off-by: Linus Torvalds

    Andrew Morton