30 Aug, 2013

1 commit

  • * 'kvm-ppc-next' of git://github.com/agraf/linux-2.6:
    KVM: PPC: Book3S PR: Rework kvmppc_mmu_book3s_64_xlate()
    KVM: PPC: Book3S PR: Make instruction fetch fallback work for system calls
    KVM: PPC: Book3S PR: Don't corrupt guest state when kernel uses VMX
    KVM: PPC: Book3S: Fix compile error in XICS emulation
    KVM: PPC: Book3S PR: return appropriate error when allocation fails
    arch: powerpc: kvm: add signed type cast for comparation
    powerpc/kvm: Copy the pvr value after memset
    KVM: PPC: Book3S PR: Load up SPRG3 register with guest value on guest entry
    kvm/ppc/booke: Don't call kvm_guest_enter twice
    kvm/ppc: Call trace_hardirqs_on before entry
    KVM: PPC: Book3S HV: Allow negative offsets to real-mode hcall handlers
    KVM: PPC: Book3S HV: Correct tlbie usage
    powerpc/kvm: Use 256K chunk to track both RMA and hash page table allocation.
    powerpc/kvm: Contiguous memory allocator based RMA allocation
    powerpc/kvm: Contiguous memory allocator based hash page table allocation
    KVM: PPC: Book3S: Ignore DABR register
    mm/cma: Move dma contiguous changes into a seperate config

    Gleb Natapov
     

29 Aug, 2013

2 commits


28 Aug, 2013

5 commits

  • It turns out that if we exit the guest due to a hcall instruction (sc 1),
    and the loading of the instruction in the guest exit path fails for any
    reason, the call to kvmppc_ld() in kvmppc_get_last_inst() fetches the
    instruction after the hcall instruction rather than the hcall itself.
    This in turn means that the instruction doesn't get recognized as an
    hcall in kvmppc_handle_exit_pr() but gets passed to the guest kernel
    as a sc instruction. That usually results in the guest kernel getting
    a return code of 38 (ENOSYS) from an hcall, which often triggers a
    BUG_ON() or other failure.

    This fixes the problem by adding a new variant of kvmppc_get_last_inst()
    called kvmppc_get_last_sc(), which fetches the instruction if necessary
    from pc - 4 rather than pc.

    Signed-off-by: Paul Mackerras
    Signed-off-by: Alexander Graf

    Paul Mackerras
     
  • Currently the code assumes that once we load up guest FP/VSX or VMX
    state into the CPU, it stays valid in the CPU registers until we
    explicitly flush it to the thread_struct. However, on POWER7,
    copy_page() and memcpy() can use VMX. These functions do flush the
    VMX state to the thread_struct before using VMX instructions, but if
    this happens while we have guest state in the VMX registers, and we
    then re-enter the guest, we don't reload the VMX state from the
    thread_struct, leading to guest corruption. This has been observed
    to cause guest processes to segfault.

    To fix this, we check before re-entering the guest that all of the
    bits corresponding to facilities owned by the guest, as expressed
    in vcpu->arch.guest_owned_ext, are set in current->thread.regs->msr.
    Any bits that have been cleared correspond to facilities that have
    been used by kernel code and thus flushed to the thread_struct, so
    for them we reload the state from the thread_struct.

    We also need to check current->thread.regs->msr before calling
    giveup_fpu() or giveup_altivec(), since if the relevant bit is
    clear, the state has already been flushed to the thread_struct and
    to flush it again would corrupt it.

    Signed-off-by: Paul Mackerras
    Signed-off-by: Alexander Graf

    Paul Mackerras
     
  • Commit 8e44ddc3f3 ("powerpc/kvm/book3s: Add support for H_IPOLL and
    H_XIRR_X in XICS emulation") added a call to get_tb() but didn't
    include the header that defines it, and on some configs this means
    book3s_xics.c fails to compile:

    arch/powerpc/kvm/book3s_xics.c: In function ‘kvmppc_xics_hcall’:
    arch/powerpc/kvm/book3s_xics.c:812:3: error: implicit declaration of function ‘get_tb’ [-Werror=implicit-function-declaration]

    Cc: stable@vger.kernel.org [v3.10, v3.11]
    Signed-off-by: Paul Mackerras
    Signed-off-by: Alexander Graf

    Paul Mackerras
     
  • err was overwritten by a previous function call, and checked to be 0. If
    the following page allocation fails, 0 is going to be returned instead
    of -ENOMEM.

    Signed-off-by: Thadeu Lima de Souza Cascardo
    Signed-off-by: Alexander Graf

    Thadeu Lima de Souza Cascardo
     
  • 'rmls' is 'unsigned long', lpcr_rmls() will return negative number when
    failure occurs, so it need a type cast for comparing.

    'lpid' is 'unsigned long', kvmppc_alloc_lpid() return negative number
    when failure occurs, so it need a type cast for comparing.

    Signed-off-by: Chen Gang
    Acked-by: Paul Mackerras
    Signed-off-by: Alexander Graf

    Chen Gang
     

26 Aug, 2013

1 commit

  • KVM uses anon_inode_get() to allocate file descriptors as part
    of some of its ioctls. But those ioctls are lacking a flag argument
    allowing userspace to choose options for the newly opened file descriptor.

    In such case it's advised to use O_CLOEXEC by default so that
    userspace is allowed to choose, without race, if the file descriptor
    is going to be inherited across exec().

    This patch set O_CLOEXEC flag on all file descriptors created
    with anon_inode_getfd() to not leak file descriptors across exec().

    Signed-off-by: Yann Droneaud
    Link: http://lkml.kernel.org/r/cover.1377372576.git.ydroneaud@opteya.com
    Reviewed-by: Alexander Graf
    Signed-off-by: Gleb Natapov

    Yann Droneaud
     

23 Aug, 2013

1 commit


25 Jul, 2013

1 commit

  • Unlike the other general-purpose SPRs, SPRG3 can be read by usermode
    code, and is used in recent kernels to store the CPU and NUMA node
    numbers so that they can be read by VDSO functions. Thus we need to
    load the guest's SPRG3 value into the real SPRG3 register when entering
    the guest, and restore the host's value when exiting the guest. We don't
    need to save the guest SPRG3 value when exiting the guest as usermode
    code can't modify SPRG3.

    Signed-off-by: Paul Mackerras
    Signed-off-by: Alexander Graf

    Paul Mackerras
     

18 Jul, 2013

1 commit

  • This is called right after the memslots is updated, i.e. when the result
    of update_memslots() gets installed in install_new_memslots(). Since
    the memslots needs to be updated twice when we delete or move a memslot,
    kvm_arch_commit_memory_region() does not correspond to this exactly.

    In the following patch, x86 will use this new API to check if the mmio
    generation has reached its maximum value, in which case mmio sptes need
    to be flushed out.

    Signed-off-by: Takuya Yoshikawa
    Acked-by: Alexander Graf
    Reviewed-by: Xiao Guangrong
    Signed-off-by: Paolo Bonzini

    Takuya Yoshikawa
     

14 Jul, 2013

2 commits

  • Pull networking fixes from David Miller:
    "Just a bunch of small fixes and tidy ups:

    1) Finish the "busy_poll" renames, from Eliezer Tamir.

    2) Fix RCU stalls in IFB driver, from Ding Tianhong.

    3) Linearize buffers properly in tun/macvtap zerocopy code.

    4) Don't crash on rmmod in vxlan, from Pravin B Shelar.

    5) Spinlock used before init in alx driver, from Maarten Lankhorst.

    6) A sparse warning fix in bnx2x broke TSO checksums, fix from Dmitry
    Kravkov.

    7) Dummy and ifb driver load failure paths can oops, fixes from Tan
    Xiaojun and Ding Tianhong.

    8) Correct MTU calculations in IP tunnels, from Alexander Duyck.

    9) Account all TCP retransmits in SNMP stats properly, from Yuchung
    Cheng.

    10) atl1e and via-rhine do not handle DMA mapping failures properly,
    from Neil Horman.

    11) Various equal-cost multipath route fixes in ipv6 from Hannes
    Frederic Sowa"

    * git://git.kernel.org/pub/scm/linux/kernel/git/davem/net: (36 commits)
    ipv6: only static routes qualify for equal cost multipathing
    via-rhine: fix dma mapping errors
    atl1e: fix dma mapping warnings
    tcp: account all retransmit failures
    usb/net/r815x: fix cast to restricted __le32
    usb/net/r8152: fix integer overflow in expression
    net: access page->private by using page_private
    net: strict_strtoul is obsolete, use kstrtoul instead
    drivers/net/ieee802154: don't use devm_pinctrl_get_select_default() in probe
    drivers/net/ethernet/cadence: don't use devm_pinctrl_get_select_default() in probe
    drivers/net/can/c_can: don't use devm_pinctrl_get_select_default() in probe
    net/usb: add relative mii functions for r815x
    net/tipc: use %*phC to dump small buffers in hex form
    qlcnic: Adding Maintainers.
    gre: Fix MTU sizing check for gretap tunnels
    pkt_sched: sch_qfq: remove forward declaration of qfq_update_agg_ts
    pkt_sched: sch_qfq: improve efficiency of make_eligible
    gso: Update tunnel segmentation to support Tx checksum offload
    inet: fix spacing in assignment
    ifb: fix oops when loading the ifb failed
    ...

    Linus Torvalds
     
  • Pull perf fixes from Thomas Gleixner:
    - fix for do_div() abuse on x86
    - locking fix in perf core
    - a pile of (build) fixes and cleanups in perf tools

    * 'perf-urgent-for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/tip/tip: (27 commits)
    perf/x86: Fix incorrect use of do_div() in NMI warning
    perf: Fix perf_lock_task_context() vs RCU
    perf: Remove WARN_ON_ONCE() check in __perf_event_enable() for valid scenario
    perf: Clone child context from parent context pmu
    perf script: Fix broken include in Context.xs
    perf tools: Fix -ldw/-lelf link test when static linking
    perf tools: Revert regression in configuration of Python support
    perf tools: Fix perf version generation
    perf stat: Fix per-socket output bug for uncore events
    perf symbols: Fix vdso list searching
    perf evsel: Fix missing increment in sample parsing
    perf tools: Update symbol_conf.nr_events when processing attribute events
    perf tools: Fix new_term() missing free on error path
    perf tools: Fix parse_events_terms() segfault on error path
    perf evsel: Fix count parameter to read call in event_format__new
    perf tools: fix a typo of a Power7 event name
    perf tools: Fix -x/--exclude-other option for report command
    perf evlist: Enhance perf_evlist__start_workload()
    perf record: Remove -f/--force option
    perf record: Remove -A/--append option
    ...

    Linus Torvalds
     

11 Jul, 2013

4 commits

  • Since all architectures have been converted to use vm_unmapped_area(),
    there is no remaining use for the free_area_cache.

    Signed-off-by: Michel Lespinasse
    Acked-by: Rik van Riel
    Cc: "James E.J. Bottomley"
    Cc: "Luck, Tony"
    Cc: Benjamin Herrenschmidt
    Cc: David Howells
    Cc: Helge Deller
    Cc: Ivan Kokshaysky
    Cc: Matt Turner
    Cc: Paul Mackerras
    Cc: Richard Henderson
    Signed-off-by: Andrew Morton
    Signed-off-by: Linus Torvalds

    Michel Lespinasse
     
  • Rename LL_SO to BUSY_POLL_SO
    Rename sysctl_net_ll_{read,poll} to sysctl_busy_{read,poll}
    Fix up users of these variables.
    Fix documentation for sysctl.

    a patch for the socket.7 man page will follow separately,
    because of limitations of my mail setup.

    Signed-off-by: Eliezer Tamir
    Signed-off-by: David S. Miller

    Eliezer Tamir
     
  • kvm_guest_enter() was already called by kvmppc_prepare_to_enter().
    Don't call it again.

    Signed-off-by: Scott Wood
    Signed-off-by: Alexander Graf

    Scott Wood
     
  • Currently this is only being done on 64-bit. Rather than just move it
    out of the 64-bit ifdef, move it to kvm_lazy_ee_enable() so that it is
    consistent with lazy ee state, and so that we don't track more host
    code as interrupts-enabled than necessary.

    Rename kvm_lazy_ee_enable() to kvm_fix_ee_before_entry() to reflect
    that this function now has a role on 32-bit as well.

    Signed-off-by: Scott Wood
    Signed-off-by: Alexander Graf

    Scott Wood
     

10 Jul, 2013

4 commits

  • The table of offsets to real-mode hcall handlers in book3s_hv_rmhandlers.S
    can contain negative values, if some of the handlers end up before the
    table in the vmlinux binary. Thus we need to use a sign-extending load
    to read the values in the table rather than a zero-extending load.
    Without this, the host crashes when the guest does one of the hcalls
    with negative offsets, due to jumping to a bogus address.

    Signed-off-by: Paul Mackerras
    Signed-off-by: Alexander Graf

    Paul Mackerras
     
  • This corrects the usage of the tlbie (TLB invalidate entry) instruction
    in HV KVM. The tlbie instruction changed between PPC970 and POWER7.
    On the PPC970, the bit to select large vs. small page is in the instruction,
    not in the RB register value. This changes the code to use the correct
    form on PPC970.

    On POWER7 we were calculating the AVAL (Abbreviated Virtual Address, Lower)
    field of the RB value incorrectly for 64k pages. This fixes it.

    Since we now have several cases to handle for the tlbie instruction, this
    factors out the code to do a sequence of tlbies into a new function,
    do_tlbies(), and calls that from the various places where the code was
    doing tlbie instructions inline. It also makes kvmppc_h_bulk_remove()
    use the same global_invalidates() function for determining whether to do
    local or global TLB invalidations as is used in other places, for
    consistency, and also to make sure that kvm->arch.need_tlb_flush gets
    updated properly.

    Signed-off-by: Paul Mackerras
    Signed-off-by: Alexander Graf

    Paul Mackerras
     
  • Pull networking updates from David Miller:
    "This is a re-do of the net-next pull request for the current merge
    window. The only difference from the one I made the other day is that
    this has Eliezer's interface renames and the timeout handling changes
    made based upon your feedback, as well as a few bug fixes that have
    trickeled in.

    Highlights:

    1) Low latency device polling, eliminating the cost of interrupt
    handling and context switches. Allows direct polling of a network
    device from socket operations, such as recvmsg() and poll().

    Currently ixgbe, mlx4, and bnx2x support this feature.

    Full high level description, performance numbers, and design in
    commit 0a4db187a999 ("Merge branch 'll_poll'")

    From Eliezer Tamir.

    2) With the routing cache removed, ip_check_mc_rcu() gets exercised
    more than ever before in the case where we have lots of multicast
    addresses. Use a hash table instead of a simple linked list, from
    Eric Dumazet.

    3) Add driver for Atheros CQA98xx 802.11ac wireless devices, from
    Bartosz Markowski, Janusz Dziedzic, Kalle Valo, Marek Kwaczynski,
    Marek Puzyniak, Michal Kazior, and Sujith Manoharan.

    4) Support reporting the TUN device persist flag to userspace, from
    Pavel Emelyanov.

    5) Allow controlling network device VF link state using netlink, from
    Rony Efraim.

    6) Support GRE tunneling in openvswitch, from Pravin B Shelar.

    7) Adjust SOCK_MIN_RCVBUF and SOCK_MIN_SNDBUF for modern times, from
    Daniel Borkmann and Eric Dumazet.

    8) Allow controlling of TCP quickack behavior on a per-route basis,
    from Cong Wang.

    9) Several bug fixes and improvements to vxlan from Stephen
    Hemminger, Pravin B Shelar, and Mike Rapoport. In particular,
    support receiving on multiple UDP ports.

    10) Major cleanups, particular in the area of debugging and cookie
    lifetime handline, to the SCTP protocol code. From Daniel
    Borkmann.

    11) Allow packets to cross network namespaces when traversing tunnel
    devices. From Nicolas Dichtel.

    12) Allow monitoring netlink traffic via AF_PACKET sockets, in a
    manner akin to how we monitor real network traffic via ptype_all.
    From Daniel Borkmann.

    13) Several bug fixes and improvements for the new alx device driver,
    from Johannes Berg.

    14) Fix scalability issues in the netem packet scheduler's time queue,
    by using an rbtree. From Eric Dumazet.

    15) Several bug fixes in TCP loss recovery handling, from Yuchung
    Cheng.

    16) Add support for GSO segmentation of MPLS packets, from Simon
    Horman.

    17) Make network notifiers have a real data type for the opaque
    pointer that's passed into them. Use this to properly handle
    network device flag changes in arp_netdev_event(). From Jiri
    Pirko and Timo Teräs.

    18) Convert several drivers over to module_pci_driver(), from Peter
    Huewe.

    19) tcp_fixup_rcvbuf() can loop 500 times over loopback, just use a
    O(1) calculation instead. From Eric Dumazet.

    20) Support setting of explicit tunnel peer addresses in ipv6, just
    like ipv4. From Nicolas Dichtel.

    21) Protect x86 BPF JIT against spraying attacks, from Eric Dumazet.

    22) Prevent a single high rate flow from overruning an individual cpu
    during RX packet processing via selective flow shedding. From
    Willem de Bruijn.

    23) Don't use spinlocks in TCP md5 signing fast paths, from Eric
    Dumazet.

    24) Don't just drop GSO packets which are above the TBF scheduler's
    burst limit, chop them up so they are in-bounds instead. Also
    from Eric Dumazet.

    25) VLAN offloads are missed when configured on top of a bridge, fix
    from Vlad Yasevich.

    26) Support IPV6 in ping sockets. From Lorenzo Colitti.

    27) Receive flow steering targets should be updated at poll() time
    too, from David Majnemer.

    28) Fix several corner case regressions in PMTU/redirect handling due
    to the routing cache removal, from Timo Teräs.

    29) We have to be mindful of ipv4 mapped ipv6 sockets in
    upd_v6_push_pending_frames(). From Hannes Frederic Sowa.

    30) Fix L2TP sequence number handling bugs, from James Chapman."

    * git://git.kernel.org/pub/scm/linux/kernel/git/davem/net-next: (1214 commits)
    drivers/net: caif: fix wrong rtnl_is_locked() usage
    drivers/net: enic: release rtnl_lock on error-path
    vhost-net: fix use-after-free in vhost_net_flush
    net: mv643xx_eth: do not use port number as platform device id
    net: sctp: confirm route during forward progress
    virtio_net: fix race in RX VQ processing
    virtio: support unlocked queue poll
    net/cadence/macb: fix bug/typo in extracting gem_irq_read_clear bit
    Documentation: Fix references to defunct linux-net@vger.kernel.org
    net/fs: change busy poll time accounting
    net: rename low latency sockets functions to busy poll
    bridge: fix some kernel warning in multicast timer
    sfc: Fix memory leak when discarding scattered packets
    sit: fix tunnel update via netlink
    dt:net:stmmac: Add dt specific phy reset callback support.
    dt:net:stmmac: Add support to dwmac version 3.610 and 3.710
    dt:net:stmmac: Allocate platform data only if its NULL.
    net:stmmac: fix memleak in the open method
    ipv6: rt6_check_neigh should successfully verify neigh if no NUD information are available
    net: ipv6: fix wrong ping_v6_sendmsg return value
    ...

    Linus Torvalds
     
  • This reverts commit 07fa7a0a8a58 ("hw_breakpoints: Fix racy access to
    ptrace breakpoints") and removes ptrace_get/put_breakpoints() added by
    other commits.

    The patch was fine but we can no longer race with SIGKILL after commit
    9899d11f6544 ("ptrace: ensure arch_ptrace/ptrace_request can never race
    with SIGKILL"), the __TASK_TRACED tracee can't be woken up and
    ->ptrace_bps[] can't go away.

    Signed-off-by: Oleg Nesterov
    Acked-by: Michael Neuling
    Cc: Benjamin Herrenschmidt
    Cc: Paul Mackerras
    Cc: Frederic Weisbecker
    Cc: Ingo Molnar
    Cc: Jan Kratochvil
    Cc: Paul Mundt
    Cc: Will Deacon
    Cc: Prasad
    Cc: Russell King
    Signed-off-by: Andrew Morton
    Signed-off-by: Linus Torvalds

    Oleg Nesterov
     

09 Jul, 2013

1 commit

  • In the Power7 PMU guide:
    https://www.power.org/documentation/commonly-used-metrics-for-performance-analysis/
    PM_BRU_MPRED is referred to as PM_BR_MPRED.

    It fixed the typo by changing the name of the event in kernel and
    documentation accordingly.

    This patch changes the ABI, there are some reasons I think it's ok:

    - It is relatively new interface, specific to the Power7 platform.

    - No tools that we know of actually use this interface at this point
    (none are listed near the interface).

    - Users of this interface (eg oprofile users migrating to perf)
    would be more used to the "PM_BR_MPRED" rather than "PM_BRU_MPRED".

    - These are in the ABI/testing at this point rather than ABI/stable,
    so hoping we have some wiggle room.

    Signed-off-by: Runzhen Wang
    Acked-by: Michael Ellerman
    Cc: icycoder@gmail.com
    Cc: linuxppc-dev@lists.ozlabs.org
    Cc: Michael Ellerman
    Cc: Paul Mackerras
    Cc: Runzhen Wang
    Cc: Sukadev Bhattiprolu
    Cc: Xiao Guangrong
    Link: http://lkml.kernel.org/r/1372407297-6996-2-git-send-email-runzhen@linux.vnet.ibm.com
    Signed-off-by: Arnaldo Carvalho de Melo

    Runzhen Wang
     

08 Jul, 2013

4 commits

  • Both RMA and hash page table request will be a multiple of 256K. We can use
    a chunk size of 256K to track the free/used 256K chunk in the bitmap. This
    should help to reduce the bitmap size.

    Signed-off-by: Aneesh Kumar K.V
    Acked-by: Paul Mackerras
    Signed-off-by: Alexander Graf

    Aneesh Kumar K.V
     
  • Older version of power architecture use Real Mode Offset register and Real Mode Limit
    Selector for mapping guest Real Mode Area. The guest RMA should be physically
    contigous since we use the range when address translation is not enabled.

    This patch switch RMA allocation code to use contigous memory allocator. The patch
    also remove the the linear allocator which not used any more

    Acked-by: Paul Mackerras
    Signed-off-by: Aneesh Kumar K.V
    Signed-off-by: Alexander Graf

    Aneesh Kumar K.V
     
  • Powerpc architecture uses a hash based page table mechanism for mapping virtual
    addresses to physical address. The architecture require this hash page table to
    be physically contiguous. With KVM on Powerpc currently we use early reservation
    mechanism for allocating guest hash page table. This implies that we need to
    reserve a big memory region to ensure we can create large number of guest
    simultaneously with KVM on Power. Another disadvantage is that the reserved memory
    is not available to rest of the subsystems and and that implies we limit the total
    available memory in the host.

    This patch series switch the guest hash page table allocation to use
    contiguous memory allocator.

    Signed-off-by: Aneesh Kumar K.V
    Acked-by: Paul Mackerras
    Signed-off-by: Alexander Graf

    Aneesh Kumar K.V
     
  • We don't emulate breakpoints yet, so just ignore reads and writes
    to / from DABR.

    This fixes booting of more recent Linux guest kernels for me.

    Reported-by: Nello Martuscielli
    Tested-by: Nello Martuscielli
    Signed-off-by: Alexander Graf

    Alexander Graf
     

07 Jul, 2013

1 commit

  • Pull irqdomain refactoring from Grant Likely:
    "This is the long awaited simplification of irqdomain. It gets rid of
    the different types of irq domains and instead both linear and tree
    mappings can be supported in a single domain. Doing this removes a
    lot of special case code and makes irq domains simpler to understand
    overall"

    * tag 'irqdomain-for-linus' of git://git.secretlab.ca/git/linux:
    irq: fix checkpatch error
    irqdomain: Include hwirq number in /proc/interrupts
    irqdomain: make irq_linear_revmap() a fast path again
    irqdomain: remove irq_domain_generate_simple()
    irqdomain: Refactor irq_domain_associate_many()
    irqdomain: Beef up debugfs output
    irqdomain: Clean up aftermath of irq_domain refactoring
    irqdomain: Eliminate revmap type
    irqdomain: merge linear and tree reverse mappings.
    irqdomain: Add a name field
    irqdomain: Replace LEGACY mapping with LINEAR
    irqdomain: Relax failure path on setting up mappings

    Linus Torvalds
     

05 Jul, 2013

5 commits

  • Pull device tree updates from Grant Likely:
    "This branch contains the following changes:
    - Removal of CONFIG_OF_DEVICE, it is always enabled by CONFIG_OF
    - Remove #ifdef from linux/of_platform.h to increase compiler syntax
    coverage
    - Bug fix for address decoding on Bimini and js2x powerpc platforms.
    - miscellaneous binding changes

    One note on the above. The binding changes going in from all kinds of
    different trees has gotten rather out of hand. I picked up some
    during this cycle, but even going though my tree isn't a great fit.

    Ian Campbell has prototyped splitting the bindings and .dtb files into
    a separate repository. The plan is to migrate to using that sometime
    in the next few kernel releases which should get rid of a lot of the
    churn on binding docs and .dts files"

    * tag 'devicetree-for-linus' of git://git.secretlab.ca/git/linux:
    of: Fix address decoding on Bimini and js2x machines
    of: remove CONFIG_OF_DEVICE
    usb: chipidea: depend on CONFIG_OF instead of CONFIG_OF_DEVICE
    of: remove of_platform_driver
    ibmebus: convert of_platform_driver to platform_driver
    driver core: move to_platform_driver to platform_device.h
    mfd: DT bindings for the palmas family MFD
    ARM: dts: omap3-devkit8000: fix NAND memory binding
    of/base: fix typos
    of: remove #ifdef from linux/of_platform.h

    Linus Torvalds
     
  • Pull trivial tree updates from Jiri Kosina:
    "The usual stuff from trivial tree"

    * 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/jikos/trivial: (34 commits)
    treewide: relase -> release
    Documentation/cgroups/memory.txt: fix stat file documentation
    sysctl/net.txt: delete reference to obsolete 2.4.x kernel
    spinlock_api_smp.h: fix preprocessor comments
    treewide: Fix typo in printk
    doc: device tree: clarify stuff in usage-model.txt.
    open firmware: "/aliasas" -> "/aliases"
    md: bcache: Fixed a typo with the word 'arithmetic'
    irq/generic-chip: fix a few kernel-doc entries
    frv: Convert use of typedef ctl_table to struct ctl_table
    sgi: xpc: Convert use of typedef ctl_table to struct ctl_table
    doc: clk: Fix incorrect wording
    Documentation/arm/IXP4xx fix a typo
    Documentation/networking/ieee802154 fix a typo
    Documentation/DocBook/media/v4l fix a typo
    Documentation/video4linux/si476x.txt fix a typo
    Documentation/virtual/kvm/api.txt fix a typo
    Documentation/early-userspace/README fix a typo
    Documentation/video4linux/soc-camera.txt fix a typo
    lguest: fix CONFIG_PAE -> CONFIG_x86_PAE in comment
    ...

    Linus Torvalds
     
  • Merge Kconfig menu diet patches from Dave Hansen:
    "I think the "Kernel Hacking" menu has gotten a bit out of hand. It is
    over 120 lines long on my system with everything enabled and options
    are scattered around it haphazardly.

    http://sr71.net/~dave/linux/kconfig-horror.png

    Let's try to introduce some sanity. This set takes that 120 lines
    down to 55 and makes it vastly easier to find some things. It's a
    start.

    This set stands on its own, but there is plenty of room for follow-up
    patches. The arch-specific debug options still end up getting stuck
    in the top-level "kernel hacking" menu. OPTIMIZE_INLINING, for
    instance, could obviously go in to the "compiler options" menu, but
    the fact that it is defined in arch/ in a separate Kconfig file keeps
    it on its own for the moment.

    The Signed-off-by's in here look funky. I changed employers while
    working on this set, so I have signoffs from both email addresses"

    * emailed patches from Dave Hansen :
    hang and lockup detection menu
    kconfig: consolidate printk options
    group locking debugging options
    consolidate compilation option configs
    consolidate runtime testing configs
    order memory debugging Kconfig options
    consolidate per-arch stack overflow debugging options

    Linus Torvalds
     
  • Original posting:

    http://lkml.kernel.org/r/20121214184202.F54094D9@kernel.stglabs.ibm.com

    Several architectures have similar stack debugging config options.
    They all pretty much do the same thing, some with slightly
    differing help text.

    This patch changes the architectures to instead enable a Kconfig
    boolean, and then use that boolean in the generic Kconfig.debug
    to present the actual menu option. This removes a bunch of
    duplication and adds consistency across arches.

    Signed-off-by: Dave Hansen
    Reviewed-by: H. Peter Anvin
    Reviewed-by: James Hogan
    Acked-by: Chris Metcalf [for tile]
    Signed-off-by: Dave Hansen
    Signed-off-by: Linus Torvalds

    Dave Hansen
     
  • Pull powerpc updates from Ben Herrenschmidt:
    "This is the powerpc changes for the 3.11 merge window. In addition to
    the usual bug fixes and small updates, the main highlights are:

    - Support for transparent huge pages by Aneesh Kumar for 64-bit
    server processors. This allows the use of 16M pages as transparent
    huge pages on kernels compiled with a 64K base page size.

    - Base VFIO support for KVM on power by Alexey Kardashevskiy

    - Wiring up of our nvram to the pstore infrastructure, including
    putting compressed oopses in there by Aruna Balakrishnaiah

    - Move, rework and improve our "EEH" (basically PCI error handling
    and recovery) infrastructure. It is no longer specific to pseries
    but is now usable by the new "powernv" platform as well (no
    hypervisor) by Gavin Shan.

    - I fixed some bugs in our math-emu instruction decoding and made it
    usable to emulate some optional FP instructions on processors with
    hard FP that lack them (such as fsqrt on Freescale embedded
    processors).

    - Support for Power8 "Event Based Branch" facility by Michael
    Ellerman. This facility allows what is basically "userspace
    interrupts" for performance monitor events.

    - A bunch of Transactional Memory vs. Signals bug fixes and HW
    breakpoint/watchpoint fixes by Michael Neuling.

    And more ... I appologize in advance if I've failed to highlight
    something that somebody deemed worth it."

    * 'next' of git://git.kernel.org/pub/scm/linux/kernel/git/benh/powerpc: (156 commits)
    pstore: Add hsize argument in write_buf call of pstore_ftrace_call
    powerpc/fsl: add MPIC timer wakeup support
    powerpc/mpic: create mpic subsystem object
    powerpc/mpic: add global timer support
    powerpc/mpic: add irq_set_wake support
    powerpc/85xx: enable coreint for all the 64bit boards
    powerpc/8xx: Erroneous double irq_eoi() on CPM IRQ in MPC8xx
    powerpc/fsl: Enable CONFIG_E1000E in mpc85xx_smp_defconfig
    powerpc/mpic: Add get_version API both for internal and external use
    powerpc: Handle both new style and old style reserve maps
    powerpc/hw_brk: Fix off by one error when validating DAWR region end
    powerpc/pseries: Support compression of oops text via pstore
    powerpc/pseries: Re-organise the oops compression code
    pstore: Pass header size in the pstore write callback
    powerpc/powernv: Fix iommu initialization again
    powerpc/pseries: Inform the hypervisor we are using EBB regs
    powerpc/perf: Add power8 EBB support
    powerpc/perf: Core EBB support for 64-bit book3s
    powerpc/perf: Drop MMCRA from thread_struct
    powerpc/perf: Don't enable if we have zero events
    ...

    Linus Torvalds
     

04 Jul, 2013

7 commits

  • Merge first patch-bomb from Andrew Morton:
    - various misc bits
    - I'm been patchmonkeying ocfs2 for a while, as Joel and Mark have been
    distracted. There has been quite a bit of activity.
    - About half the MM queue
    - Some backlight bits
    - Various lib/ updates
    - checkpatch updates
    - zillions more little rtc patches
    - ptrace
    - signals
    - exec
    - procfs
    - rapidio
    - nbd
    - aoe
    - pps
    - memstick
    - tools/testing/selftests updates

    * emailed patches from Andrew Morton : (445 commits)
    tools/testing/selftests: don't assume the x bit is set on scripts
    selftests: add .gitignore for kcmp
    selftests: fix clean target in kcmp Makefile
    selftests: add .gitignore for vm
    selftests: add hugetlbfstest
    self-test: fix make clean
    selftests: exit 1 on failure
    kernel/resource.c: remove the unneeded assignment in function __find_resource
    aio: fix wrong comment in aio_complete()
    drivers/w1/slaves/w1_ds2408.c: add magic sequence to disable P0 test mode
    drivers/memstick/host/r592.c: convert to module_pci_driver
    drivers/memstick/host/jmb38x_ms: convert to module_pci_driver
    pps-gpio: add device-tree binding and support
    drivers/pps/clients/pps-gpio.c: convert to module_platform_driver
    drivers/pps/clients/pps-gpio.c: convert to devm_* helpers
    drivers/parport/share.c: use kzalloc
    Documentation/accounting/getdelays.c: avoid strncpy in accounting tool
    aoe: update internal version number to v83
    aoe: update copyright date
    aoe: perform I/O completions in parallel
    ...

    Linus Torvalds
     
  • Pull PCI changes from Bjorn Helgaas:
    "PCI device hotplug
    - Add pci_alloc_dev() interface (Gu Zheng)
    - Add pci_bus_get()/put() for reference counting (Jiang Liu)
    - Fix SR-IOV reference count issues (Jiang Liu)
    - Remove unused acpi_pci_roots list (Jiang Liu)

    MSI
    - Conserve interrupt resources on x86 (Alexander Gordeev)

    AER
    - Force fatal severity when component has been reset (Betty Dall)
    - Reset link below Root Port as well as Downstream Port (Betty Dall)
    - Fix "Firmware first" flag setting (Bjorn Helgaas)
    - Don't parse HEST for non-PCIe devices (Bjorn Helgaas)

    ASPM
    - Warn when we can't disable ASPM as driver requests (Bjorn Helgaas)

    Miscellaneous
    - Add CircuitCo PCI IDs (Darren Hart)
    - Add AMD CZ SATA and SMBus PCI IDs (Shane Huang)
    - Work around Ivytown NTB BAR size issue (Jon Mason)
    - Detect invalid initial BAR values (Kevin Hao)
    - Add pcibios_release_device() (Sebastian Ott)
    - Fix powerpc & sparc PCI_UNKNOWN power state usage (Bjorn Helgaas)"

    * tag 'pci-v3.11-changes' of git://git.kernel.org/pub/scm/linux/kernel/git/helgaas/pci: (51 commits)
    MAINTAINERS: Add ACPI folks for ACPI-related things under drivers/pci
    PCI: Add CircuitCo vendor ID and subsystem ID
    PCI: Use pdev->pm_cap instead of pci_find_capability(..,PCI_CAP_ID_PM)
    PCI: Return early on allocation failures to unindent mainline code
    PCI: Simplify IOV implementation and fix reference count races
    PCI: Drop redundant setting of bus->is_added in virtfn_add_bus()
    unicore32/PCI: Remove redundant call of pci_bus_add_devices()
    m68k/PCI: Remove redundant call of pci_bus_add_devices()
    PCI / ACPI / PM: Use correct power state strings in messages
    PCI: Fix comment typo for pcie_pme_remove()
    PCI: Rename pci_release_bus_bridge_dev() to pci_release_host_bridge_dev()
    PCI: Fix refcount issue in pci_create_root_bus() error recovery path
    ia64/PCI: Clean up pci_scan_root_bus() usage
    PCI/AER: Reset link for devices below Root Port or Downstream Port
    ACPI / APEI: Force fatal AER severity when component has been reset
    PCI/AER: Remove "extern" from function declarations
    PCI/AER: Move AER severity defines to aer.h
    PCI/AER: Set dev->__aer_firmware_first only for matching devices
    PCI/AER: Factor out HEST device type matching
    PCI/AER: Don't parse HEST table for non-PCIe devices
    ...

    Linus Torvalds
     
  • saved_max_pfn is used to know the amount of memory that the previous
    kernel used. And for powerpc, we set saved_max_pfn by passing the kernel
    commandline parameter "savemaxmem=".

    The only user of saved_max_pfn in powerpc is read_oldmem interface. Since
    we have removed read_oldmem, we don't need this parameter anymore.

    Signed-off-by: Zhang Yanfei
    Cc: Benjamin Herrenschmidt
    Cc: Paul Mackerras
    Cc: "Eric W. Biederman"
    Cc: "H. Peter Anvin"
    Cc: Dave Hansen
    Cc: Fenghua Yu
    Cc: Heiko Carstens
    Cc: Martin Schwidefsky
    Cc: Matt Fleming
    Cc: Michael Holzheu
    Cc: Ralf Baechle
    Cc: Tony Luck
    Cc: Vivek Goyal
    Signed-off-by: Andrew Morton
    Signed-off-by: Linus Torvalds

    Zhang Yanfei
     
  • Prepare for killing free_all_bootmem_node() by using free_all_bootmem().

    Signed-off-by: Jiang Liu
    Cc: Benjamin Herrenschmidt
    Cc: Paul Mackerras
    Cc: Alexander Graf
    Cc: "Suzuki K. Poulose"
    Signed-off-by: Andrew Morton
    Signed-off-by: Linus Torvalds

    Jiang Liu
     
  • Prepare for removing num_physpages and simplify mem_init().

    Signed-off-by: Jiang Liu
    Cc: Benjamin Herrenschmidt
    Cc: Paul Mackerras
    Signed-off-by: Andrew Morton
    Signed-off-by: Linus Torvalds

    Jiang Liu
     
  • Concentrate code to modify totalram_pages into the mm core, so the arch
    memory initialized code doesn't need to take care of it. With these
    changes applied, only following functions from mm core modify global
    variable totalram_pages: free_bootmem_late(), free_all_bootmem(),
    free_all_bootmem_node(), adjust_managed_page_count().

    With this patch applied, it will be much more easier for us to keep
    totalram_pages and zone->managed_pages in consistence.

    Signed-off-by: Jiang Liu
    Acked-by: David Howells
    Cc: "H. Peter Anvin"
    Cc: "Michael S. Tsirkin"
    Cc:
    Cc: Arnd Bergmann
    Cc: Catalin Marinas
    Cc: Chris Metcalf
    Cc: Geert Uytterhoeven
    Cc: Ingo Molnar
    Cc: Jeremy Fitzhardinge
    Cc: Jianguo Wu
    Cc: Joonsoo Kim
    Cc: Kamezawa Hiroyuki
    Cc: Konrad Rzeszutek Wilk
    Cc: Marek Szyprowski
    Cc: Mel Gorman
    Cc: Michel Lespinasse
    Cc: Minchan Kim
    Cc: Rik van Riel
    Cc: Rusty Russell
    Cc: Tang Chen
    Cc: Tejun Heo
    Cc: Thomas Gleixner
    Cc: Wen Congyang
    Cc: Will Deacon
    Cc: Yasuaki Ishimatsu
    Cc: Yinghai Lu
    Cc: Russell King
    Signed-off-by: Andrew Morton
    Signed-off-by: Linus Torvalds

    Jiang Liu
     
  • Address more review comments from last round of code review.
    1) Enhance free_reserved_area() to support poisoning freed memory with
    pattern '0'. This could be used to get rid of poison_init_mem()
    on ARM64.
    2) A previous patch has disabled memory poison for initmem on s390
    by mistake, so restore to the original behavior.
    3) Remove redundant PAGE_ALIGN() when calling free_reserved_area().

    Signed-off-by: Jiang Liu
    Cc: Geert Uytterhoeven
    Cc: "H. Peter Anvin"
    Cc: "Michael S. Tsirkin"
    Cc:
    Cc: Arnd Bergmann
    Cc: Catalin Marinas
    Cc: Chris Metcalf
    Cc: David Howells
    Cc: Ingo Molnar
    Cc: Jeremy Fitzhardinge
    Cc: Jianguo Wu
    Cc: Joonsoo Kim
    Cc: Kamezawa Hiroyuki
    Cc: Konrad Rzeszutek Wilk
    Cc: Marek Szyprowski
    Cc: Mel Gorman
    Cc: Michel Lespinasse
    Cc: Minchan Kim
    Cc: Rik van Riel
    Cc: Rusty Russell
    Cc: Tang Chen
    Cc: Tejun Heo
    Cc: Thomas Gleixner
    Cc: Wen Congyang
    Cc: Will Deacon
    Cc: Yasuaki Ishimatsu
    Cc: Yinghai Lu
    Cc: Russell King
    Signed-off-by: Andrew Morton
    Signed-off-by: Linus Torvalds

    Jiang Liu