02 Aug, 2012

6 commits


01 Aug, 2012

3 commits

  • Merge Andrew's second set of patches:
    - MM
    - a few random fixes
    - a couple of RTC leftovers

    * emailed patches from Andrew Morton : (120 commits)
    rtc/rtc-88pm80x: remove unneed devm_kfree
    rtc/rtc-88pm80x: assign ret only when rtc_register_driver fails
    mm: hugetlbfs: close race during teardown of hugetlbfs shared page tables
    tmpfs: distribute interleave better across nodes
    mm: remove redundant initialization
    mm: warn if pg_data_t isn't initialized with zero
    mips: zero out pg_data_t when it's allocated
    memcg: gix memory accounting scalability in shrink_page_list
    mm/sparse: remove index_init_lock
    mm/sparse: more checks on mem_section number
    mm/sparse: optimize sparse_index_alloc
    memcg: add mem_cgroup_from_css() helper
    memcg: further prevent OOM with too many dirty pages
    memcg: prevent OOM with too many dirty pages
    mm: mmu_notifier: fix freed page still mapped in secondary MMU
    mm: memcg: only check anon swapin page charges for swap cache
    mm: memcg: only check swap cache pages for repeated charging
    mm: memcg: split swapin charge function into private and public part
    mm: memcg: remove needless !mm fixup to init_mm when charging
    mm: memcg: remove unneeded shmem charge type
    ...

    Linus Torvalds
     
  • Pull random subsystem patches from Ted Ts'o:
    "This patch series contains a major revamp of how we collect entropy
    from interrupts for /dev/random and /dev/urandom.

    The goal is to addresses weaknesses discussed in the paper "Mining
    your Ps and Qs: Detection of Widespread Weak Keys in Network Devices",
    by Nadia Heninger, Zakir Durumeric, Eric Wustrow, J. Alex Halderman,
    which will be published in the Proceedings of the 21st Usenix Security
    Symposium, August 2012. (See https://factorable.net for more
    information and an extended version of the paper.)"

    Fix up trivial conflicts due to nearby changes in
    drivers/{mfd/ab3100-core.c, usb/gadget/omap_udc.c}

    * tag 'random_for_linus' of git://git.kernel.org/pub/scm/linux/kernel/git/tytso/random: (33 commits)
    random: mix in architectural randomness in extract_buf()
    dmi: Feed DMI table to /dev/random driver
    random: Add comment to random_initialize()
    random: final removal of IRQF_SAMPLE_RANDOM
    um: remove IRQF_SAMPLE_RANDOM which is now a no-op
    sparc/ldc: remove IRQF_SAMPLE_RANDOM which is now a no-op
    [ARM] pxa: remove IRQF_SAMPLE_RANDOM which is now a no-op
    board-palmz71: remove IRQF_SAMPLE_RANDOM which is now a no-op
    isp1301_omap: remove IRQF_SAMPLE_RANDOM which is now a no-op
    pxa25x_udc: remove IRQF_SAMPLE_RANDOM which is now a no-op
    omap_udc: remove IRQF_SAMPLE_RANDOM which is now a no-op
    goku_udc: remove IRQF_SAMPLE_RANDOM which was commented out
    uartlite: remove IRQF_SAMPLE_RANDOM which is now a no-op
    drivers: hv: remove IRQF_SAMPLE_RANDOM which is now a no-op
    xen-blkfront: remove IRQF_SAMPLE_RANDOM which is now a no-op
    n2_crypto: remove IRQF_SAMPLE_RANDOM which is now a no-op
    pda_power: remove IRQF_SAMPLE_RANDOM which is now a no-op
    i2c-pmcmsp: remove IRQF_SAMPLE_RANDOM which is now a no-op
    input/serio/hp_sdc.c: remove IRQF_SAMPLE_RANDOM which is now a no-op
    mfd: remove IRQF_SAMPLE_RANDOM which is now a no-op
    ...

    Linus Torvalds
     
  • Sanity:

    CONFIG_CGROUP_MEM_RES_CTLR -> CONFIG_MEMCG
    CONFIG_CGROUP_MEM_RES_CTLR_SWAP -> CONFIG_MEMCG_SWAP
    CONFIG_CGROUP_MEM_RES_CTLR_SWAP_ENABLED -> CONFIG_MEMCG_SWAP_ENABLED
    CONFIG_CGROUP_MEM_RES_CTLR_KMEM -> CONFIG_MEMCG_KMEM

    [mhocko@suse.cz: fix missed bits]
    Cc: Glauber Costa
    Acked-by: Michal Hocko
    Cc: Johannes Weiner
    Cc: KAMEZAWA Hiroyuki
    Cc: Hugh Dickins
    Cc: Tejun Heo
    Cc: Aneesh Kumar K.V
    Cc: David Rientjes
    Cc: KOSAKI Motohiro
    Signed-off-by: Andrew Morton
    Signed-off-by: Linus Torvalds

    Andrew Morton
     

28 Jul, 2012

8 commits


24 Jul, 2012

1 commit


20 Jul, 2012

1 commit


19 Jul, 2012

1 commit

  • With the changes in the random tree, IRQF_SAMPLE_RANDOM is now a
    no-op; interrupt randomness is now collected unconditionally in a very
    low-overhead fashion; see commit 775f4b297b. The IRQF_SAMPLE_RANDOM
    flag was scheduled to be removed in 2009 on the
    feature-removal-schedule, so this patch is preparation for the final
    removal of this flag.

    Signed-off-by: "Theodore Ts'o"
    Cc: Jeff Dike
    Cc: Richard Weinberger

    Theodore Ts'o
     

17 Jul, 2012

1 commit


03 Jul, 2012

1 commit

  • This reverts commit 616c310e83b872024271c915c1b9ab505b9efad9.
    (Move PREEMPT_RCU preemption to switch_to() invocation).
    Testing by Sasha Levin showed that this
    can result in deadlock due to invoking the scheduler when one of
    the runqueue locks is held. Because this commit was simply a
    performance optimization, revert it.

    Reported-by: Sasha Levin
    Signed-off-by: Paul E. McKenney
    Tested-by: Sasha Levin

    Paul E. McKenney
     

02 Jun, 2012

5 commits


01 Jun, 2012

5 commits

  • Pull second pile of signal handling patches from Al Viro:
    "This one is just task_work_add() series + remaining prereqs for it.

    There probably will be another pull request from that tree this
    cycle - at least for helpers, to get them out of the way for per-arch
    fixes remaining in the tree."

    Fix trivial conflict in kernel/irq/manage.c: the merge of Andrew's pile
    had brought in commit 97fd75b7b8e0 ("kernel/irq/manage.c: use the
    pr_foo() infrastructure to prefix printks") which changed one of the
    pr_err() calls that this merge moves around.

    * 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/viro/signal:
    keys: kill task_struct->replacement_session_keyring
    keys: kill the dummy key_replace_session_keyring()
    keys: change keyctl_session_to_parent() to use task_work_add()
    genirq: reimplement exit_irq_thread() hook via task_work_add()
    task_work_add: generic process-context callbacks
    avr32: missed _TIF_NOTIFY_RESUME on one of do_notify_resume callers
    parisc: need to check NOTIFY_RESUME when exiting from syscall
    move key_repace_session_keyring() into tracehook_notify_resume()
    TIF_NOTIFY_RESUME is defined on all targets now

    Linus Torvalds
     
  • kill_off_processes() might miss a valid process, this is because checking
    for process->mm is not enough. Process' main thread may exit or detach
    its mm via use_mm(), but other threads may still have a valid mm.

    To catch this we use find_lock_task_mm(), which walks up all threads and
    returns an appropriate task (with task lock held).

    Suggested-by: Oleg Nesterov
    Signed-off-by: Anton Vorontsov
    Cc: Richard Weinberger
    Signed-off-by: Andrew Morton
    Signed-off-by: Linus Torvalds

    Anton Vorontsov
     
  • Checking for task->mm is dangerous as ->mm might disappear (exit_mm()
    assigns NULL under task_lock(), so tasklist lock is not enough).

    We can't use get_task_mm()/mmput() pair as mmput() might sleep, so let's
    take the task lock while we care about its mm.

    Note that we should also use find_lock_task_mm() to check all process'
    threads for a valid mm, but for uml we'll do it in a separate patch.

    Signed-off-by: Anton Vorontsov
    Cc: Richard Weinberger
    Cc: Oleg Nesterov
    Signed-off-by: Andrew Morton
    Signed-off-by: Linus Torvalds

    Anton Vorontsov
     
  • Traversing the tasks requires holding tasklist_lock, otherwise it is
    unsafe.

    p.s. However, I'm not sure that calling os_kill_ptraced_process() in the
    atomic context is correct. It seem to work, but please take a closer
    look.

    Signed-off-by: Anton Vorontsov
    Cc: Richard Weinberger
    Cc: Oleg Nesterov
    Signed-off-by: Andrew Morton
    Signed-off-by: Linus Torvalds

    Anton Vorontsov
     
  • Commit d065bd810b6d ("mm: retry page fault when blocking on disk
    transfer") and commit 37b23e0525d3 ("x86,mm: make pagefault killable")
    introduced changes into the x86 pagefault handler for making the page
    fault handler retryable as well as killable.

    These changes reduce the mmap_sem hold time, which is crucial during OOM
    killer invocation.

    Port these changes to um.

    Signed-off-by: Kautuk Consul
    Cc: Jeff Dike
    Cc: Richard Weinberger
    Signed-off-by: Andrew Morton
    Signed-off-by: Linus Torvalds

    Kautuk Consul
     

29 May, 2012

1 commit

  • Pull kbuild updates from Michal Marek.

    Fixed up nontrivial merge conflict in Makefile as per Stephen Rothwell
    and linux-next (and trivial arch/sparc/Makefile changes due to removed
    sparc32 logic).

    * 'kbuild' of git://git.kernel.org/pub/scm/linux/kernel/git/mmarek/kbuild:
    mips: Fix KBUILD_CPPFLAGS definition
    kbuild: fix ia64 link
    kbuild: document KBUILD_LDS, KBUILD_VMLINUX_{INIT,MAIN} and LDFLAGS_vmlinux
    kbuild: link of vmlinux moved to a script
    kbuild: refactor final link of sparc32
    kbuild: drop unused KBUILD_VMLINUX_OBJS from top-level Makefile
    kbuild: Makefile: remove unnecessary check for m68knommu ARCH

    Linus Torvalds
     

25 May, 2012

2 commits

  • Pull KVM changes from Avi Kivity:
    "Changes include additional instruction emulation, page-crossing MMIO,
    faster dirty logging, preventing the watchdog from killing a stopped
    guest, module autoload, a new MSI ABI, and some minor optimizations
    and fixes. Outside x86 we have a small s390 and a very large ppc
    update.

    Regarding the new (for kvm) rebaseless workflow, some of the patches
    that were merged before we switch trees had to be rebased, while
    others are true pulls. In either case the signoffs should be correct
    now."

    Fix up trivial conflicts in Documentation/feature-removal-schedule.txt
    arch/powerpc/kvm/book3s_segment.S and arch/x86/include/asm/kvm_para.h.

    I suspect the kvm_para.h resolution ends up doing the "do I have cpuid"
    check effectively twice (it was done differently in two different
    commits), but better safe than sorry ;)

    * 'next' of git://git.kernel.org/pub/scm/virt/kvm/kvm: (125 commits)
    KVM: make asm-generic/kvm_para.h have an ifdef __KERNEL__ block
    KVM: s390: onereg for timer related registers
    KVM: s390: epoch difference and TOD programmable field
    KVM: s390: KVM_GET/SET_ONEREG for s390
    KVM: s390: add capability indicating COW support
    KVM: Fix mmu_reload() clash with nested vmx event injection
    KVM: MMU: Don't use RCU for lockless shadow walking
    KVM: VMX: Optimize %ds, %es reload
    KVM: VMX: Fix %ds/%es clobber
    KVM: x86 emulator: convert bsf/bsr instructions to emulate_2op_SrcV_nobyte()
    KVM: VMX: unlike vmcs on fail path
    KVM: PPC: Emulator: clean up SPR reads and writes
    KVM: PPC: Emulator: clean up instruction parsing
    kvm/powerpc: Add new ioctl to retreive server MMU infos
    kvm/book3s: Make kernel emulated H_PUT_TCE available for "PR" KVM
    KVM: PPC: bookehv: Fix r8/r13 storing in level exception handler
    KVM: PPC: Book3S: Enable IRQs during exit handling
    KVM: PPC: Fix PR KVM on POWER7 bare metal
    KVM: PPC: Fix stbux emulation
    KVM: PPC: bookehv: Use lwz/stw instead of PPC_LL/PPC_STL for 32-bit fields
    ...

    Linus Torvalds
     
  • Pull timer updates from Thomas Gleixner.

    Various trivial conflict fixups in arch Kconfig due to addition of
    unrelated entries nearby. And one slightly more subtle one for sparc32
    (new user of GENERIC_CLOCKEVENTS), fixed up as per Thomas.

    * 'timers-core-for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/tip/tip: (31 commits)
    timekeeping: Fix a few minor newline issues.
    time: remove obsolete declaration
    ntp: Fix a stale comment and a few stray newlines.
    ntp: Correct TAI offset during leap second
    timers: Fixup the Kconfig consolidation fallout
    x86: Use generic time config
    unicore32: Use generic time config
    um: Use generic time config
    tile: Use generic time config
    sparc: Use: generic time config
    sh: Use generic time config
    score: Use generic time config
    s390: Use generic time config
    openrisc: Use generic time config
    powerpc: Use generic time config
    mn10300: Use generic time config
    mips: Use generic time config
    microblaze: Use generic time config
    m68k: Use generic time config
    m32r: Use generic time config
    ...

    Linus Torvalds
     

24 May, 2012

4 commits

  • Signed-off-by: Al Viro

    Al Viro
     
  • Pull first series of signal handling cleanups from Al Viro:
    "This is just the first part of the queue (about a half of it);
    assorted fixes all over the place in signal handling.

    This one ends with all sigsuspend() implementations switched to
    generic one (->saved_sigmask-based).

    With this, a bunch of assorted old buglets are fixed and most of the
    missing bits of NOTIFY_RESUME hookup are in place. Two more fixes sit
    in arm and um trees respectively, and there's a couple of broken ones
    that need obvious fixes - parisc and avr32 check TIF_NOTIFY_RESUME
    only on one of two codepaths; fixes for that will happen in the next
    series"

    * 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/viro/signal: (55 commits)
    unicore32: if there's no handler we need to restore sigmask, syscall or no syscall
    xtensa: add handling of TIF_NOTIFY_RESUME
    microblaze: drop 'oldset' argument of do_notify_resume()
    microblaze: handle TIF_NOTIFY_RESUME
    score: add handling of NOTIFY_RESUME to do_notify_resume()
    m68k: add TIF_NOTIFY_RESUME and handle it.
    sparc: kill ancient comment in sparc_sigaction()
    h8300: missing checks of __get_user()/__put_user() return values
    frv: missing checks of __get_user()/__put_user() return values
    cris: missing checks of __get_user()/__put_user() return values
    powerpc: missing checks of __get_user()/__put_user() return values
    sh: missing checks of __get_user()/__put_user() return values
    sparc: missing checks of __get_user()/__put_user() return values
    avr32: struct old_sigaction is never used
    m32r: struct old_sigaction is never used
    xtensa: xtensa_sigaction doesn't exist
    alpha: tidy signal delivery up
    score: don't open-code force_sigsegv()
    cris: don't open-code force_sigsegv()
    blackfin: don't open-code force_sigsegv()
    ...

    Linus Torvalds
     
  • Pull fpu state cleanups from Ingo Molnar:
    "This tree streamlines further aspects of FPU handling by eliminating
    the prepare_to_copy() complication and moving that logic to
    arch_dup_task_struct().

    It also fixes the FPU dumps in threaded core dumps, removes and old
    (and now invalid) assumption plus micro-optimizes the exit path by
    avoiding an FPU save for dead tasks."

    Fixed up trivial add-add conflict in arch/sh/kernel/process.c that came
    in because we now do the FPU handling in arch_dup_task_struct() rather
    than the legacy (and now gone) prepare_to_copy().

    * 'x86-fpu-for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/tip/tip:
    x86, fpu: drop the fpu state during thread exit
    x86, xsave: remove thread_has_fpu() bug check in __sanitize_i387_state()
    coredump: ensure the fpu state is flushed for proper multi-threaded core dump
    fork: move the real prepare_to_copy() users to arch_dup_task_struct()

    Linus Torvalds
     
  • Pull UML updates from Richard Weinberger:
    "Most changes are bug fixes and cleanups"

    * 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/rw/uml:
    um: missing checks of __put_user()/__get_user() return values
    um: stub_rt_sigsuspend isn't needed these days anymore
    um/x86: merge (and trim) 32- and 64-bit variants of ptrace.h
    irq: Remove irq_chip->release()
    um: Remove CONFIG_IRQ_RELEASE_METHOD
    um: Remove usage of irq_chip->release()
    um: Implement um_free_irq()
    um: Fix __swp_type()
    um: Implement a custom pte_same() function
    um: Add BUG() to do_ops()'s error path
    um: Remove unused variables
    um: bury unused _TIF_RESTORE_SIGMASK
    um: wrong sigmask saved in case of multiple sigframes
    um: add TIF_NOTIFY_RESUME
    um: ->restart_block.fn needs to be reset on sigreturn

    Linus Torvalds
     

22 May, 2012

1 commit