Skip to content
  1. Sep 12, 2015
    • Linus Torvalds's avatar
      Merge tag 'media/v4.3-2' of git://git.kernel.org/pub/scm/linux/kernel/git/mchehab/linux-media · 06a660ad
      Linus Torvalds authored
      Pull media updates from Mauro Carvalho Chehab:
       "A series of patches that move part of the code used to allocate memory
        from the media subsystem to the mm subsystem"
      
      [ The mm parts have been acked by VM people, and the series was
        apparently in -mm for a while   - Linus ]
      
      * tag 'media/v4.3-2' of git://git.kernel.org/pub/scm/linux/kernel/git/mchehab/linux-media:
        [media] drm/exynos: Convert g2d_userptr_get_dma_addr() to use get_vaddr_frames()
        [media] media: vb2: Remove unused functions
        [media] media: vb2: Convert vb2_dc_get_userptr() to use frame vector
        [media] media: vb2: Convert vb2_vmalloc_get_userptr() to use frame vector
        [media] media: vb2: Convert vb2_dma_sg_get_userptr() to use frame vector
        [media] vb2: Provide helpers for mapping virtual addresses
        [media] media: omap_vout: Convert omap_vout_uservirt_to_phys() to use get_vaddr_pfns()
        [media] mm: Provide new get_vaddr_frames() helper
        [media] vb2: Push mmap_sem down to memops
      06a660ad
    • Linus Torvalds's avatar
      Merge tag 'edac/v4.3-1' of git://git.kernel.org/pub/scm/linux/kernel/git/mchehab/linux-edac · d9b44fe3
      Linus Torvalds authored
      Pull edac updates from Mauro Carvalho Chehab:
       "Two EDAC fixes for Intel systems (Haswell and Ivy Bridge)"
      
      * tag 'edac/v4.3-1' of git://git.kernel.org/pub/scm/linux/kernel/git/mchehab/linux-edac:
        sb_edac: correctly fetch DIMM width on Ivy Bridge and Haswell
        sb_edac: look harder for DDRIO on Haswell systems
      d9b44fe3
    • Linus Torvalds's avatar
      Merge branch 'next' of git://git.kernel.org/pub/scm/linux/kernel/git/rzhang/linux · 9ebd051a
      Linus Torvalds authored
      Pull thermal updates from Zhang Rui:
      
       - use int instead of unsigned long to represent temperature to avoid
         bogus overheat detection when negative temperature reported.  From
         Sascha Hauer.
      
       - export available thermal governors information to user space via
         sysfs.  From Wei Ni.
      
       - introduce new thermal driver for Wildcat Point platform controller
         hub, which uses PCH thermal sensor and associated critical and hot
         trip points.  From Tushar Dave.
      
       - add suuport for Intel Skylake and Denlow platforms in powerclamp
         driver.
      
       - some small cleanups in thermal core.
      
      * 'next' of git://git.kernel.org/pub/scm/linux/kernel/git/rzhang/linux:
        thermal: Add Intel PCH thermal driver
        thermal: Add comment explaining test for critical temperature
        thermal: Use IS_ENABLED instead of #ifdef
        thermal: remove unnecessary call to thermal_zone_device_set_polling
        thermal: trivial: fix typo in comment
        thermal: consistently use int for temperatures
        thermal: add available policies sysfs attribute
        thermal/powerclamp: add cpu id for denlow platform
        thermal/powerclamp: add cpu id for Skylake u/y
        thermal/powerclamp: add cpu id for skylake h/s
      9ebd051a
    • Linus Torvalds's avatar
      Merge git://www.linux-watchdog.org/linux-watchdog · 51a73ba5
      Linus Torvalds authored
      Pull watchdog updates from Wim Van Sebroeck:
       - new driver for NXP LPC18xx Watchdog Timer
       - new driver for SAMA5D4 watchdog timer
       - add support for MCP79 to nv_tco driver
       - clean-up and improvement of the mpc8xxx watchdog driver
       - improvements to gpio-wdt
       - at91sam9_wdt clock improvements
       ... and other small fixes and improvements
      
      * git://www.linux-watchdog.org/linux-watchdog: (25 commits)
        Watchdog: Fix parent of watchdog_devices
        watchdog: at91rm9200: Correct check for syscon_node_to_regmap() errors
        watchdog: at91sam9: get and use slow clock
        Documentation: dt: binding: atmel-sama5d4-wdt: for SAMA5D4 watchdog driver
        watchdog: add a driver to support SAMA5D4 watchdog timer
        watchdog: mpc8xxx: allow to compile for MPC512x
        watchdog: mpc8xxx: use better error code when watchdog cannot be enabled
        watchdog: mpc8xxx: use dynamic memory for device specific data
        watchdog: mpc8xxx: use devm_ioremap_resource to map memory
        watchdog: mpc8xxx: make use of of_device_get_match_data
        watchdog: mpc8xxx: simplify registration
        watchdog: mpc8xxx: remove dead code
        watchdog: lpc18xx_wdt_get_timeleft() can be static
        DT: watchdog: Add NXP LPC18xx Watchdog Timer binding documentation
        watchdog: NXP LPC18xx Watchdog Timer Driver
        watchdog: gpio-wdt: ping already at startup for always running devices
        watchdog: gpio-wdt: be more strict about hw_algo matching
        Documentation: watchdog: at91sam9_wdt: add clocks property
        watchdog: booke_wdt: Use infrastructure to check timeout limits
        watchdog: (nv_tco) add support for MCP79
        ...
      51a73ba5
    • Linus Torvalds's avatar
      Merge branch 'for-linus-4.3' of git://git.kernel.org/pub/scm/linux/kernel/git/mason/linux-btrfs · e91eb620
      Linus Torvalds authored
      Pull btrfs cleanups and fixes from Chris Mason:
       "These are small cleanups, and also some fixes for our async worker
        thread initialization.
      
        I was having some trouble testing these, but it ended up being a
        combination of changing around my test servers and a shiny new
        schedule while atomic from the new start/finish_plug in
        writeback_sb_inodes().
      
        That one only hits on btrfs raid5/6 or MD raid10, and if I wasn't
        changing a bunch of things in my test setup at once it would have been
        really clear.  Fix for writeback_sb_inodes() on the way as well"
      
      * 'for-linus-4.3' of git://git.kernel.org/pub/scm/linux/kernel/git/mason/linux-btrfs:
        Btrfs: cleanup: remove unnecessary check before btrfs_free_path is called
        btrfs: async_thread: Fix workqueue 'max_active' value when initializing
        btrfs: Add raid56 support for updating  num_tolerated_disk_barrier_failures in btrfs_balance
        btrfs: Cleanup for btrfs_calc_num_tolerated_disk_barrier_failures
        btrfs: Remove noused chunk_tree and chunk_objectid from scrub_enumerate_chunks and scrub_chunk
        btrfs: Update out-of-date "skip parity stripe" comment
      e91eb620
    • Linus Torvalds's avatar
      Merge branch 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/sage/ceph-client · e013f74b
      Linus Torvalds authored
      Pull Ceph update from Sage Weil:
       "There are a few fixes for snapshot behavior with CephFS and support
        for the new keepalive protocol from Zheng, a libceph fix that affects
        both RBD and CephFS, a few bug fixes and cleanups for RBD from Ilya,
        and several small fixes and cleanups from Jianpeng and others"
      
      * 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/sage/ceph-client:
        ceph: improve readahead for file holes
        ceph: get inode size for each append write
        libceph: check data_len in ->alloc_msg()
        libceph: use keepalive2 to verify the mon session is alive
        rbd: plug rbd_dev->header.object_prefix memory leak
        rbd: fix double free on rbd_dev->header_name
        libceph: set 'exists' flag for newly up osd
        ceph: cleanup use of ceph_msg_get
        ceph: no need to get parent inode in ceph_open
        ceph: remove the useless judgement
        ceph: remove redundant test of head->safe and silence static analysis warnings
        ceph: fix queuing inode to mdsdir's snaprealm
        libceph: rename con_work() to ceph_con_workfn()
        libceph: Avoid holding the zero page on ceph_msgr_slab_init errors
        libceph: remove the unused macro AES_KEY_SIZE
        ceph: invalidate dirty pages after forced umount
        ceph: EIO all operations after forced umount
      e013f74b
    • Linus Torvalds's avatar
      Merge tag 'gfs2-merge-window' of git://git.kernel.org/pub/scm/linux/kernel/git/gfs2/linux-gfs2 · 01cab554
      Linus Torvalds authored
      Pull GFS2 updates from Bob Peterson:
       "Here is a list of patches we've accumulated for GFS2 for the current
        upstream merge window.  This time we've only got six patches, many of
        which are very small:
      
         - three cleanups from Andreas Gruenbacher, including a nice cleanup
           of the sequence file code for the sbstats debugfs file.
      
         - a patch from Ben Hutchings that changes statistics variables from
           signed to unsigned.
      
         - two patches from me that increase GFS2's glock scalability by
           switching from a conventional hash table to rhashtable"
      
      * tag 'gfs2-merge-window' of git://git.kernel.org/pub/scm/linux/kernel/git/gfs2/linux-gfs2:
        gfs2: A minor "sbstats" cleanup
        gfs2: Fix a typo in a comment
        gfs2: Make statistics unsigned, suitable for use with do_div()
        GFS2: Use resizable hash table for glocks
        GFS2: Move glock superblock pointer to field gl_name
        gfs2: Simplify the seq file code for "sbstats"
      01cab554
    • Linus Torvalds's avatar
      Merge tag 'sound-fix-4.3-rc1' of git://git.kernel.org/pub/scm/linux/kernel/git/tiwai/sound · 64d1def7
      Linus Torvalds authored
      Pull sound fixes from Takashi Iwai:
       "A collection of small fixes since the last update: the HD-audio quirks
        as usual with a USB-audio fix and a trivial fix for the old sparc
        driver"
      
      * tag 'sound-fix-4.3-rc1' of git://git.kernel.org/pub/scm/linux/kernel/git/tiwai/sound:
        ALSA: usb-audio: Change internal PCM order
        ALSA: hda - Fix white noise on Dell M3800
        ALSA: hda - Use ALC880_FIXUP_FUJITSU for FSC Amilo M1437
        ALSA: hda - Enable headphone jack detect on old Fujitsu laptops
        ALSA: sparc: amd7930: Fix module autoload for OF platform driver
        ALSA: hda - Add some FIXUP quirks for white noise on Dell laptop.
      64d1def7
    • Linus Torvalds's avatar
      Merge branch 'drm-fixes' of git://people.freedesktop.org/~airlied/linux · 04d78e39
      Linus Torvalds authored
      Pull drm fixes from Dave Airlie:
       "Just a bunch of fixes to squeeze in before -rc1:
      
         - three nouveau regression fixes
      
         - one qxl regression fix
      
         - a bunch of i915 fixes
      
        ... and some core displayport/atomic fixes"
      
      * 'drm-fixes' of git://people.freedesktop.org/~airlied/linux:
        drm/nouveau/device: enable c800 quirk for tecra w50
        drm/nouveau/clk/gt215: Unbreak engine pausing for GT21x/MCP7x
        drm/nouveau/gr/nv04: fix big endian setting on gr context
        drm/qxl: validate monitors config modes
        drm/i915: Allow DSI dual link to be configured on any pipe
        drm/i915: Don't try to use DDR DVFS on CHV when disabled in the BIOS
        drm/i915: Fix CSR MMIO address check
        drm/i915: Limit the number of loops for reading a split 64bit register
        drm/i915: Fix broken mst get_hw_state.
        drm/i915: Pass hpd_status_i915[] to intel_get_hpd_pins() in pre-g4x
        uapi/drm/i915_drm.h: fix userspace compilation.
        drm/i915: Always mark the object as dirty when used by the GPU
        drm/dp: Add dp_aux_i2c_speed_khz module param to set the assume i2c bus speed
        drm/dp: Adjust i2c-over-aux retry count based on message size and i2c bus speed
        drm/dp: Define AUX_RETRY_INTERVAL as 500 us
        drm/atomic: Fix bookkeeping with TEST_ONLY, v3.
      04d78e39
  2. Sep 11, 2015
    • Dave Airlie's avatar
      Merge branch 'linux-4.3' of git://anongit.freedesktop.org/git/nouveau/linux-2.6 into drm-next · 9fbcc7c0
      Dave Airlie authored
      three nouveau regression fixes.
      * 'linux-4.3' of git://anongit.freedesktop.org/git/nouveau/linux-2.6:
        drm/nouveau/device: enable c800 quirk for tecra w50
        drm/nouveau/clk/gt215: Unbreak engine pausing for GT21x/MCP7x
        drm/nouveau/gr/nv04: fix big endian setting on gr context
      9fbcc7c0
    • Linus Torvalds's avatar
      Merge branch 'for-4.3/blkcg' of git://git.kernel.dk/linux-block · b0a1ea51
      Linus Torvalds authored
      Pull blk-cg updates from Jens Axboe:
       "A bit later in the cycle, but this has been in the block tree for a a
        while.  This is basically four patchsets from Tejun, that improve our
        buffered cgroup writeback.  It was dependent on the other cgroup
        changes, but they went in earlier in this cycle.
      
        Series 1 is set of 5 patches that has cgroup writeback updates:
      
         - bdi_writeback iteration fix which could lead to some wb's being
           skipped or repeated during e.g. sync under memory pressure.
      
         - Simplification of wb work wait mechanism.
      
         - Writeback tracepoints updated to report cgroup.
      
        Series 2 is is a set of updates for the CFQ cgroup writeback handling:
      
           cfq has always charged all async IOs to the root cgroup.  It didn't
           have much choice as writeback didn't know about cgroups and there
           was no way to tell who to blame for a given writeback IO.
           writeback finally grew support for cgroups and now tags each
           writeback IO with the appropriate cgroup to charge it against.
      
           This patchset updates cfq so that it follows the blkcg each bio is
           tagged with.  Async cfq_queues are now shared across cfq_group,
           which is per-cgroup, instead of per-request_queue cfq_data.  This
           makes all IOs follow the weight based IO resource distribution
           implemented by cfq.
      
           - Switched from GFP_ATOMIC to GFP_NOWAIT as suggested by Jeff.
      
           - Other misc review points addressed, acks added and rebased.
      
        Series 3 is the blkcg policy cleanup patches:
      
           This patchset contains assorted cleanups for blkcg_policy methods
           and blk[c]g_policy_data handling.
      
           - alloc/free added for blkg_policy_data.  exit dropped.
      
           - alloc/free added for blkcg_policy_data.
      
           - blk-throttle's async percpu allocation is replaced with direct
             allocation.
      
           - all methods now take blk[c]g_policy_data instead of blkcg_gq or
             blkcg.
      
        And finally, series 4 is a set of patches cleaning up the blkcg stats
        handling:
      
          blkcg's stats have always been somwhat of a mess.  This patchset
          tries to improve the situation a bit.
      
           - The following patches added to consolidate blkcg entry point and
             blkg creation.  This is in itself is an improvement and helps
             colllecting common stats on bio issue.
      
           - per-blkg stats now accounted on bio issue rather than request
             completion so that bio based and request based drivers can behave
             the same way.  The issue was spotted by Vivek.
      
           - cfq-iosched implements custom recursive stats and blk-throttle
             implements custom per-cpu stats.  This patchset make blkcg core
             support both by default.
      
           - cfq-iosched and blk-throttle keep track of the same stats
             multiple times.  Unify them"
      
      * 'for-4.3/blkcg' of git://git.kernel.dk/linux-block: (45 commits)
        blkcg: use CGROUP_WEIGHT_* scale for io.weight on the unified hierarchy
        blkcg: s/CFQ_WEIGHT_*/CFQ_WEIGHT_LEGACY_*/
        blkcg: implement interface for the unified hierarchy
        blkcg: misc preparations for unified hierarchy interface
        blkcg: separate out tg_conf_updated() from tg_set_conf()
        blkcg: move body parsing from blkg_conf_prep() to its callers
        blkcg: mark existing cftypes as legacy
        blkcg: rename subsystem name from blkio to io
        blkcg: refine error codes returned during blkcg configuration
        blkcg: remove unnecessary NULL checks from __cfqg_set_weight_device()
        blkcg: reduce stack usage of blkg_rwstat_recursive_sum()
        blkcg: remove cfqg_stats->sectors
        blkcg: move io_service_bytes and io_serviced stats into blkcg_gq
        blkcg: make blkg_[rw]stat_recursive_sum() to be able to index into blkcg_gq
        blkcg: make blkcg_[rw]stat per-cpu
        blkcg: add blkg_[rw]stat->aux_cnt and replace cfq_group->dead_stats with it
        blkcg: consolidate blkg creation in blkcg_bio_issue_check()
        blk-throttle: improve queue bypass handling
        blkcg: move root blkg lookup optimization from throtl_lookup_tg() to __blkg_lookup()
        blkcg: inline [__]blkg_lookup()
        ...
      b0a1ea51
    • Ben Skeggs's avatar
      778613e5
    • Roy Spliet's avatar
      drm/nouveau/clk/gt215: Unbreak engine pausing for GT21x/MCP7x · c5bf4609
      Roy Spliet authored
      Typo that snuck in with commit 6979c630
      
      
      
      Signed-off-by: default avatarRoy Spliet <rspliet@eclipso.eu>
      Reported-by: default avatarPierre Moreau <pierre.morrow@free.fr>
      Signed-off-by: default avatarBen Skeggs <bskeggs@redhat.com>
      c5bf4609
    • Ilia Mirkin's avatar
      drm/nouveau/gr/nv04: fix big endian setting on gr context · 15ee0058
      Ilia Mirkin authored
      
      
      Broken since "gr: convert user classes to new-style nvkm_object"
      
      Tested on a PPC64 G5 + NV34
      
      Signed-off-by: default avatarIlia Mirkin <imirkin@alum.mit.edu>
      Signed-off-by: default avatarBen Skeggs <bskeggs@redhat.com>
      15ee0058
    • Linus Torvalds's avatar
      Merge branch 'akpm' (patches from Andrew) · 33e247c7
      Linus Torvalds authored
      Merge third patch-bomb from Andrew Morton:
      
       - even more of the rest of MM
      
       - lib/ updates
      
       - checkpatch updates
      
       - small changes to a few scruffy filesystems
      
       - kmod fixes/cleanups
      
       - kexec updates
      
       - a dma-mapping cleanup series from hch
      
      * emailed patches from Andrew Morton <akpm@linux-foundation.org>: (81 commits)
        dma-mapping: consolidate dma_set_mask
        dma-mapping: consolidate dma_supported
        dma-mapping: cosolidate dma_mapping_error
        dma-mapping: consolidate dma_{alloc,free}_noncoherent
        dma-mapping: consolidate dma_{alloc,free}_{attrs,coherent}
        mm: use vma_is_anonymous() in create_huge_pmd() and wp_huge_pmd()
        mm: make sure all file VMAs have ->vm_ops set
        mm, mpx: add "vm_flags_t vm_flags" arg to do_mmap_pgoff()
        mm: mark most vm_operations_struct const
        namei: fix warning while make xmldocs caused by namei.c
        ipc: convert invalid scenarios to use WARN_ON
        zlib_deflate/deftree: remove bi_reverse()
        lib/decompress_unlzma: Do a NULL check for pointer
        lib/decompressors: use real out buf size for gunzip with kernel
        fs/affs: make root lookup from blkdev logical size
        sysctl: fix int -> unsigned long assignments in INT_MIN case
        kexec: export KERNEL_IMAGE_SIZE to vmcoreinfo
        kexec: align crash_notes allocation to make it be inside one physical page
        kexec: remove unnecessary test in kimage_alloc_crash_control_pages()
        kexec: split kexec_load syscall from kexec core code
        ...
      33e247c7
    • Linus Torvalds's avatar
      Merge tag 'armsoc-late' of git://git.kernel.org/pub/scm/linux/kernel/git/arm/arm-soc · d71fc239
      Linus Torvalds authored
      Pull late ARM SoC updates from Kevin Hilman:
       "This is a collection of a few late fixes and other misc stuff that had
        dependencies on things being merged from other trees.
      
        The bulk of the changes are for samsung/exynos SoCs for some changes
        that needed a few minor reworks so ended up a bit late.  The others
        are mainly for qcom SoCs: a couple fixes and some DTS updates"
      
      * tag 'armsoc-late' of git://git.kernel.org/pub/scm/linux/kernel/git/arm/arm-soc: (37 commits)
        ARM: multi_v7_defconfig: Enable PBIAS regulator
        soc: qcom: smd: Correct fBLOCKREADINTR handling
        soc: qcom: smd: Use correct remote processor ID
        soc: qcom: smem: Fix errant private access
        ARM: dts: qcom: msm8974-sony-xperia-honami: Use stdout-path
        ARM: dts: qcom: msm8960-cdp: Use stdout-path
        ARM: dts: qcom: msm8660-surf: Use stdout-path
        ARM: dts: qcom: ipq8064-ap148: Use stdout-path
        ARM: dts: qcom: apq8084-mtp: Use stdout-path
        ARM: dts: qcom: apq8084-ifc6540: Use stdout-path
        ARM: dts: qcom: apq8074-dragonboard: Use stdout-path
        ARM: dts: qcom: apq8064-ifc6410: Use stdout-path
        ARM: dts: qcom: apq8064-cm-qs600: Use stdout-path
        ARM: dts: qcom: Label serial nodes for aliasing and stdout-path
        reset: ath79: Fix missing spin_lock_init
        reset: Add (devm_)reset_control_get stub functions
        ARM: EXYNOS: switch to using generic cpufreq driver for exynos4x12
        cpufreq: exynos: Remove unselectable rule for arm-exynos-cpufreq.o
        ARM: dts: add iommu property to JPEG device for exynos4
        ARM: dts: enable SPI1 for exynos4412-odroidu3
        ...
      d71fc239
    • Dave Airlie's avatar
      Merge tag 'topic/drm-fixes-2015-09-09' of git://anongit.freedesktop.org/drm-intel into drm-next · d1031d57
      Dave Airlie authored
      bunch of drm fixes.
      
      * tag 'topic/drm-fixes-2015-09-09' of git://anongit.freedesktop.org/drm-intel:
        drm/dp: Add dp_aux_i2c_speed_khz module param to set the assume i2c bus speed
        drm/dp: Adjust i2c-over-aux retry count based on message size and i2c bus speed
        drm/dp: Define AUX_RETRY_INTERVAL as 500 us
        drm/atomic: Fix bookkeeping with TEST_ONLY, v3.
      d1031d57
    • Dave Airlie's avatar
      Merge tag 'drm-intel-next-fixes-2015-09-10' of... · 91b6fc02
      Dave Airlie authored
      Merge tag 'drm-intel-next-fixes-2015-09-10' of git://anongit.freedesktop.org/drm-intel into drm-next
      
      Fixes headed for v4.3-rc1, including Maarten's DP MST state checker fix
      you requested.
      
      * tag 'drm-intel-next-fixes-2015-09-10' of git://anongit.freedesktop.org/drm-intel:
        drm/i915: Allow DSI dual link to be configured on any pipe
        drm/i915: Don't try to use DDR DVFS on CHV when disabled in the BIOS
        drm/i915: Fix CSR MMIO address check
        drm/i915: Limit the number of loops for reading a split 64bit register
        drm/i915: Fix broken mst get_hw_state.
        drm/i915: Pass hpd_status_i915[] to intel_get_hpd_pins() in pre-g4x
        uapi/drm/i915_drm.h: fix userspace compilation.
        drm/i915: Always mark the object as dirty when used by the GPU
      91b6fc02
    • Jonathon Jongsma's avatar
      drm/qxl: validate monitors config modes · bd3e1c7c
      Jonathon Jongsma authored
      
      
      Due to some recent changes in
      drm_helper_probe_single_connector_modes_merge_bits(), old custom modes
      were not being pruned properly. In current kernels,
      drm_mode_validate_basic() is called to sanity-check each mode in the
      list. If the sanity-check passes, the mode's status gets set to to
      MODE_OK. In older kernels this check was not done, so old custom modes
      would still have a status of MODE_UNVERIFIED at this point, and would
      therefore be pruned later in the function.
      
      As a result of this new behavior, the list of modes for a device always
      includes every custom mode ever configured for the device, with the
      largest one listed first. Since desktop environments usually choose the
      first preferred mode when a hotplug event is emitted, this had the
      result of making it very difficult for the user to reduce the size of
      the display.
      
      The qxl driver did implement the mode_valid connector function, but it
      was empty. In order to restore the old behavior where old custom modes
      are pruned, we implement a proper mode_valid function for the qxl
      driver. This function now checks each mode against the last configured
      custom mode and the list of standard modes. If the mode doesn't match
      any of these, its status is set to MODE_BAD so that it will be pruned as
      expected.
      
      Signed-off-by: default avatarJonathon Jongsma <jjongsma@redhat.com>
      Cc: stable@vger.kernel.org
      Signed-off-by: default avatarDave Airlie <airlied@redhat.com>
      bd3e1c7c
    • Linus Torvalds's avatar
      Merge tag 'for-linus' of git://git.kernel.org/pub/scm/virt/kvm/kvm · 519f526d
      Linus Torvalds authored
      Pull more kvm updates from Paolo Bonzini:
       "ARM:
         - Full debug support for arm64
         - Active state switching for timer interrupts
         - Lazy FP/SIMD save/restore for arm64
         - Generic ARMv8 target
      
        PPC:
         - Book3S: A few bug fixes
         - Book3S: Allow micro-threading on POWER8
      
        x86:
         - Compiler warnings
      
        Generic:
         - Adaptive polling for guest halt"
      
      * tag 'for-linus' of git://git.kernel.org/pub/scm/virt/kvm/kvm: (49 commits)
        kvm: irqchip: fix memory leak
        kvm: move new trace event outside #ifdef CONFIG_KVM_ASYNC_PF
        KVM: trace kvm_halt_poll_ns grow/shrink
        KVM: dynamic halt-polling
        KVM: make halt_poll_ns per-vCPU
        Silence compiler warning in arch/x86/kvm/emulate.c
        kvm: compile process_smi_save_seg_64() only for x86_64
        KVM: x86: avoid uninitialized variable warning
        KVM: PPC: Book3S: Fix typo in top comment about locking
        KVM: PPC: Book3S: Fix size of the PSPB register
        KVM: PPC: Book3S HV: Exit on H_DOORBELL if HOST_IPI is set
        KVM: PPC: Book3S HV: Fix race in starting secondary threads
        KVM: PPC: Book3S: correct width in XER handling
        KVM: PPC: Book3S HV: Fix preempted vcore stolen time calculation
        KVM: PPC: Book3S HV: Fix preempted vcore list locking
        KVM: PPC: Book3S HV: Implement H_CLEAR_REF and H_CLEAR_MOD
        KVM: PPC: Book3S HV: Fix bug in dirty page tracking
        KVM: PPC: Book3S HV: Fix race in reading change bit when removing HPTE
        KVM: PPC: Book3S HV: Implement dynamic micro-threading on POWER8
        KVM: PPC: Book3S HV: Make use of unused threads when running guests
        ...
      519f526d
    • Linus Torvalds's avatar
      Merge tag 'for-linus-4.3-rc0b-tag' of git://git.kernel.org/pub/scm/linux/kernel/git/xen/tip · 06ab838c
      Linus Torvalds authored
      Pull xen terminology fixes from David Vrabel:
       "Use the correct GFN/BFN terms more consistently"
      
      * tag 'for-linus-4.3-rc0b-tag' of git://git.kernel.org/pub/scm/linux/kernel/git/xen/tip:
        xen/xenbus: Rename the variable xen_store_mfn to xen_store_gfn
        xen/privcmd: Further s/MFN/GFN/ clean-up
        hvc/xen: Further s/MFN/GFN clean-up
        video/xen-fbfront: Further s/MFN/GFN clean-up
        xen/tmem: Use xen_page_to_gfn rather than pfn_to_gfn
        xen: Use correctly the Xen memory terminologies
        arm/xen: implement correctly pfn_to_mfn
        xen: Make clear that swiotlb and biomerge are dealing with DMA address
      06ab838c
    • Linus Torvalds's avatar
      Merge branch 'next' of git://git.monstr.eu/linux-2.6-microblaze · 573c577a
      Linus Torvalds authored
      Pull microblaze update from Michal Simek.
      
      * 'next' of git://git.monstr.eu/linux-2.6-microblaze:
        elf-em.h: move EM_MICROBLAZE to the common header
      573c577a
    • Linus Torvalds's avatar
      Merge branch 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/rkuo/linux-hexagon-kernel · 0cdf5a46
      Linus Torvalds authored
      Pull hexagon updates from Richard Kuo:
       "Just two fixes -- one for a uapi header and one for a timer interface"
      
      * 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/rkuo/linux-hexagon-kernel:
        Revert "Hexagon: fix signal.c compile error"
        hexagon/time: Migrate to new 'set-state' interface
      0cdf5a46
    • Linus Torvalds's avatar
      Merge git://git.kernel.org/pub/scm/linux/kernel/git/davem/net · 65c61bc5
      Linus Torvalds authored
      Pull networking fixes from David Miller:
      
       1) Fix out-of-bounds array access in netfilter ipset, from Jozsef
          Kadlecsik.
      
       2) Use correct free operation on netfilter conntrack templates, from
          Daniel Borkmann.
      
       3) Fix route leak in SCTP, from Marcelo Ricardo Leitner.
      
       4) Fix sizeof(pointer) in mac80211, from Thierry Reding.
      
       5) Fix cache pointer comparison in ip6mr leading to missed unlock of
          mrt_lock.  From Richard Laing.
      
       6) rds_conn_lookup() needs to consider network namespace in key
          comparison, from Sowmini Varadhan.
      
       7) Fix deadlock in TIPC code wrt broadcast link wakeups, from Kolmakov
          Dmitriy.
      
       8) Fix fd leaks in bpf syscall, from Daniel Borkmann.
      
       9) Fix error recovery when installing ipv6 multipath routes, we would
          delete the old route before we would know if we could fully commit
          to the new set of nexthops.  Fix from Roopa Prabhu.
      
      10) Fix run-time suspend problems in r8152, from Hayes Wang.
      
      11) In fec, don't program the MAC address into the chip when the clocks
          are gated off.  From Fugang Duan.
      
      12) Fix poll behavior for netlink sockets when using rx ring mmap, from
          Daniel Borkmann.
      
      13) Don't allocate memory with GFP_KERNEL from get_stats64 in r8169
          driver, from Corinna Vinschen.
      
      14) In TCP Cubic congestion control, handle idle periods better where we
          are application limited, in order to keep cwnd from growing out of
          control.  From Eric Dumzet.
      
      * git://git.kernel.org/pub/scm/linux/kernel/git/davem/net: (65 commits)
        tcp_cubic: better follow cubic curve after idle period
        tcp: generate CA_EVENT_TX_START on data frames
        xen-netfront: respect user provided max_queues
        xen-netback: respect user provided max_queues
        r8169: Fix sleeping function called during get_stats64, v2
        ether: add IEEE 1722 ethertype - TSN
        netlink, mmap: fix edge-case leakages in nf queue zero-copy
        netlink, mmap: don't walk rx ring on poll if receive queue non-empty
        cxgb4: changes for new firmware 1.14.4.0
        net: fec: add netif status check before set mac address
        r8152: fix the runtime suspend issues
        r8152: split DRIVER_VERSION
        ipv6: fix ifnullfree.cocci warnings
        add microchip LAN88xx phy driver
        stmmac: fix check for phydev being open
        net: qlcnic: delete redundant memsets
        net: mv643xx_eth: use kzalloc
        net: jme: use kzalloc() instead of kmalloc+memset
        net: cavium: liquidio: use kzalloc in setup_glist()
        net: ipv6: use common fib_default_rule_pref
        ...
      65c61bc5
    • Christoph Hellwig's avatar
      dma-mapping: consolidate dma_set_mask · 452e06af
      Christoph Hellwig authored
      
      
      Almost everyone implements dma_set_mask the same way, although some time
      that's hidden in ->set_dma_mask methods.
      
      This patch consolidates those into a common implementation that either
      calls ->set_dma_mask if present or otherwise uses the default
      implementation.  Some architectures used to only call ->set_dma_mask
      after the initial checks, and those instance have been fixed to do the
      full work.  h8300 implemented dma_set_mask bogusly as a no-ops and has
      been fixed.
      
      Unfortunately some architectures overload unrelated semantics like changing
      the dma_ops into it so we still need to allow for an architecture override
      for now.
      
      [jcmvbkbc@gmail.com: fix xtensa]
      Signed-off-by: default avatarChristoph Hellwig <hch@lst.de>
      Cc: Arnd Bergmann <arnd@arndb.de>
      Cc: Russell King <linux@arm.linux.org.uk>
      Cc: Catalin Marinas <catalin.marinas@arm.com>
      Cc: Will Deacon <will.deacon@arm.com>
      Cc: Yoshinori Sato <ysato@users.sourceforge.jp>
      Cc: Michal Simek <monstr@monstr.eu>
      Cc: Jonas Bonn <jonas@southpole.se>
      Cc: Chris Metcalf <cmetcalf@ezchip.com>
      Cc: Guan Xuetao <gxt@mprc.pku.edu.cn>
      Cc: Ralf Baechle <ralf@linux-mips.org>
      Cc: Benjamin Herrenschmidt <benh@kernel.crashing.org>
      Cc: Ingo Molnar <mingo@elte.hu>
      Cc: Thomas Gleixner <tglx@linutronix.de>
      Cc: "H. Peter Anvin" <hpa@zytor.com>
      Cc: Andy Shevchenko <andy.shevchenko@gmail.com>
      Signed-off-by: default avatarMax Filippov <jcmvbkbc@gmail.com>
      Signed-off-by: default avatarAndrew Morton <akpm@linux-foundation.org>
      Signed-off-by: default avatarLinus Torvalds <torvalds@linux-foundation.org>
      452e06af
    • Christoph Hellwig's avatar
      dma-mapping: consolidate dma_supported · ee196371
      Christoph Hellwig authored
      
      
      Most architectures just call into ->dma_supported, but some also return 1
      if the method is not present, or 0 if no dma ops are present (although
      that should never happeb). Consolidate this more broad version into
      common code.
      
      Also fix h8300 which inorrectly always returned 0, which would have been
      a problem if it's dma_set_mask implementation wasn't a similarly buggy
      noop.
      
      As a few architectures have much more elaborate implementations, we
      still allow for arch overrides.
      
      [jcmvbkbc@gmail.com: fix xtensa]
      Signed-off-by: default avatarChristoph Hellwig <hch@lst.de>
      Cc: Arnd Bergmann <arnd@arndb.de>
      Cc: Russell King <linux@arm.linux.org.uk>
      Cc: Catalin Marinas <catalin.marinas@arm.com>
      Cc: Will Deacon <will.deacon@arm.com>
      Cc: Yoshinori Sato <ysato@users.sourceforge.jp>
      Cc: Michal Simek <monstr@monstr.eu>
      Cc: Jonas Bonn <jonas@southpole.se>
      Cc: Chris Metcalf <cmetcalf@ezchip.com>
      Cc: Guan Xuetao <gxt@mprc.pku.edu.cn>
      Cc: Ralf Baechle <ralf@linux-mips.org>
      Cc: Benjamin Herrenschmidt <benh@kernel.crashing.org>
      Cc: Ingo Molnar <mingo@elte.hu>
      Cc: Thomas Gleixner <tglx@linutronix.de>
      Cc: "H. Peter Anvin" <hpa@zytor.com>
      Cc: Andy Shevchenko <andy.shevchenko@gmail.com>
      Signed-off-by: default avatarMax Filippov <jcmvbkbc@gmail.com>
      Signed-off-by: default avatarAndrew Morton <akpm@linux-foundation.org>
      Signed-off-by: default avatarLinus Torvalds <torvalds@linux-foundation.org>
      ee196371
    • Christoph Hellwig's avatar
      dma-mapping: cosolidate dma_mapping_error · efa21e43
      Christoph Hellwig authored
      
      
      Currently there are three valid implementations of dma_mapping_error:
      
       (1) call ->mapping_error
       (2) check for a hardcoded error code
       (3) always return 0
      
      This patch provides a common implementation that calls ->mapping_error
      if present, then checks for DMA_ERROR_CODE if defined or otherwise
      returns 0.
      
      [jcmvbkbc@gmail.com: fix xtensa]
      Signed-off-by: default avatarChristoph Hellwig <hch@lst.de>
      Cc: Arnd Bergmann <arnd@arndb.de>
      Cc: Russell King <linux@arm.linux.org.uk>
      Cc: Catalin Marinas <catalin.marinas@arm.com>
      Cc: Will Deacon <will.deacon@arm.com>
      Cc: Yoshinori Sato <ysato@users.sourceforge.jp>
      Cc: Michal Simek <monstr@monstr.eu>
      Cc: Jonas Bonn <jonas@southpole.se>
      Cc: Chris Metcalf <cmetcalf@ezchip.com>
      Cc: Guan Xuetao <gxt@mprc.pku.edu.cn>
      Cc: Ralf Baechle <ralf@linux-mips.org>
      Cc: Benjamin Herrenschmidt <benh@kernel.crashing.org>
      Cc: Ingo Molnar <mingo@elte.hu>
      Cc: Thomas Gleixner <tglx@linutronix.de>
      Cc: "H. Peter Anvin" <hpa@zytor.com>
      Cc: Andy Shevchenko <andy.shevchenko@gmail.com>
      Signed-off-by: default avatarMax Filippov <jcmvbkbc@gmail.com>
      Signed-off-by: default avatarAndrew Morton <akpm@linux-foundation.org>
      Signed-off-by: default avatarLinus Torvalds <torvalds@linux-foundation.org>
      efa21e43
    • Christoph Hellwig's avatar
      dma-mapping: consolidate dma_{alloc,free}_noncoherent · 1e893752
      Christoph Hellwig authored
      
      
      Most architectures do not support non-coherent allocations and either
      define dma_{alloc,free}_noncoherent to their coherent versions or stub
      them out.
      
      Openrisc uses dma_{alloc,free}_attrs to implement them, and only Mips
      implements them directly.
      
      This patch moves the Openrisc version to common code, and handles the
      DMA_ATTR_NON_CONSISTENT case in the mips dma_map_ops instance.
      
      Note that actual non-coherent allocations require a dma_cache_sync
      implementation, so if non-coherent allocations didn't work on
      an architecture before this patch they still won't work after it.
      
      [jcmvbkbc@gmail.com: fix xtensa]
      Signed-off-by: default avatarChristoph Hellwig <hch@lst.de>
      Cc: Arnd Bergmann <arnd@arndb.de>
      Cc: Russell King <linux@arm.linux.org.uk>
      Cc: Catalin Marinas <catalin.marinas@arm.com>
      Cc: Will Deacon <will.deacon@arm.com>
      Cc: Yoshinori Sato <ysato@users.sourceforge.jp>
      Cc: Michal Simek <monstr@monstr.eu>
      Cc: Jonas Bonn <jonas@southpole.se>
      Cc: Chris Metcalf <cmetcalf@ezchip.com>
      Cc: Guan Xuetao <gxt@mprc.pku.edu.cn>
      Cc: Ralf Baechle <ralf@linux-mips.org>
      Cc: Benjamin Herrenschmidt <benh@kernel.crashing.org>
      Cc: Ingo Molnar <mingo@elte.hu>
      Cc: Thomas Gleixner <tglx@linutronix.de>
      Cc: "H. Peter Anvin" <hpa@zytor.com>
      Cc: Andy Shevchenko <andy.shevchenko@gmail.com>
      Signed-off-by: default avatarMax Filippov <jcmvbkbc@gmail.com>
      Signed-off-by: default avatarAndrew Morton <akpm@linux-foundation.org>
      Signed-off-by: default avatarLinus Torvalds <torvalds@linux-foundation.org>
      1e893752
    • Christoph Hellwig's avatar
      dma-mapping: consolidate dma_{alloc,free}_{attrs,coherent} · 6894258e
      Christoph Hellwig authored
      
      
      Since 2009 we have a nice asm-generic header implementing lots of DMA API
      functions for architectures using struct dma_map_ops, but unfortunately
      it's still missing a lot of APIs that all architectures still have to
      duplicate.
      
      This series consolidates the remaining functions, although we still need
      arch opt outs for two of them as a few architectures have very
      non-standard implementations.
      
      This patch (of 5):
      
      The coherent DMA allocator works the same over all architectures supporting
      dma_map operations.
      
      This patch consolidates them and converges the minor differences:
      
       - the debug_dma helpers are now called from all architectures, including
         those that were previously missing them
       - dma_alloc_from_coherent and dma_release_from_coherent are now always
         called from the generic alloc/free routines instead of the ops
         dma-mapping-common.h always includes dma-coherent.h to get the defintions
         for them, or the stubs if the architecture doesn't support this feature
       - checks for ->alloc / ->free presence are removed.  There is only one
         magic instead of dma_map_ops without them (mic_dma_ops) and that one
         is x86 only anyway.
      
      Besides that only x86 needs special treatment to replace a default devices
      if none is passed and tweak the gfp_flags.  An optional arch hook is provided
      for that.
      
      [linux@roeck-us.net: fix build]
      [jcmvbkbc@gmail.com: fix xtensa]
      Signed-off-by: default avatarChristoph Hellwig <hch@lst.de>
      Cc: Arnd Bergmann <arnd@arndb.de>
      Cc: Russell King <linux@arm.linux.org.uk>
      Cc: Catalin Marinas <catalin.marinas@arm.com>
      Cc: Will Deacon <will.deacon@arm.com>
      Cc: Yoshinori Sato <ysato@users.sourceforge.jp>
      Cc: Michal Simek <monstr@monstr.eu>
      Cc: Jonas Bonn <jonas@southpole.se>
      Cc: Chris Metcalf <cmetcalf@ezchip.com>
      Cc: Guan Xuetao <gxt@mprc.pku.edu.cn>
      Cc: Ralf Baechle <ralf@linux-mips.org>
      Cc: Benjamin Herrenschmidt <benh@kernel.crashing.org>
      Cc: Ingo Molnar <mingo@elte.hu>
      Cc: Thomas Gleixner <tglx@linutronix.de>
      Cc: "H. Peter Anvin" <hpa@zytor.com>
      Cc: Andy Shevchenko <andy.shevchenko@gmail.com>
      Signed-off-by: default avatarGuenter Roeck <linux@roeck-us.net>
      Signed-off-by: default avatarMax Filippov <jcmvbkbc@gmail.com>
      Signed-off-by: default avatarAndrew Morton <akpm@linux-foundation.org>
      Signed-off-by: default avatarLinus Torvalds <torvalds@linux-foundation.org>
      6894258e
    • Kirill A. Shutemov's avatar
      mm: use vma_is_anonymous() in create_huge_pmd() and wp_huge_pmd() · fb6dd5fa
      Kirill A. Shutemov authored
      
      
      Let's use helper rather than direct check of vma->vm_ops to distinguish
      anonymous VMA.
      
      Signed-off-by: default avatarKirill A. Shutemov <kirill.shutemov@linux.intel.com>
      Reviewed-by: default avatarOleg Nesterov <oleg@redhat.com>
      Cc: "H. Peter Anvin" <hpa@zytor.com>
      Cc: Andy Lutomirski <luto@amacapital.net>
      Cc: Dave Hansen <dave.hansen@linux.intel.com>
      Cc: Ingo Molnar <mingo@elte.hu>
      Cc: Minchan Kim <minchan@kernel.org>
      Cc: Thomas Gleixner <tglx@linutronix.de>
      Signed-off-by: default avatarAndrew Morton <akpm@linux-foundation.org>
      Signed-off-by: default avatarLinus Torvalds <torvalds@linux-foundation.org>
      fb6dd5fa
    • Kirill A. Shutemov's avatar
      mm: make sure all file VMAs have ->vm_ops set · 6dc296e7
      Kirill A. Shutemov authored
      
      
      We rely on vma->vm_ops == NULL to detect anonymous VMA: see
      vma_is_anonymous(), but some drivers doesn't set ->vm_ops.
      
      As a result we can end up with anonymous page in private file mapping.
      That should not lead to serious misbehaviour, but nevertheless is wrong.
      
      Let's fix by setting up dummy ->vm_ops for file mmapping if f_op->mmap()
      didn't set its own.
      
      The patch also adds sanity check into __vma_link_rb(). It will help
      catch broken VMAs which inserted directly into mm_struct via
      insert_vm_struct().
      
      Signed-off-by: default avatarKirill A. Shutemov <kirill.shutemov@linux.intel.com>
      Reviewed-by: default avatarOleg Nesterov <oleg@redhat.com>
      Cc: "H. Peter Anvin" <hpa@zytor.com>
      Cc: Andy Lutomirski <luto@amacapital.net>
      Cc: Dave Hansen <dave.hansen@linux.intel.com>
      Cc: Ingo Molnar <mingo@elte.hu>
      Cc: Minchan Kim <minchan@kernel.org>
      Cc: Thomas Gleixner <tglx@linutronix.de>
      Signed-off-by: default avatarAndrew Morton <akpm@linux-foundation.org>
      Signed-off-by: default avatarLinus Torvalds <torvalds@linux-foundation.org>
      6dc296e7
    • Oleg Nesterov's avatar
      mm, mpx: add "vm_flags_t vm_flags" arg to do_mmap_pgoff() · 1fcfd8db
      Oleg Nesterov authored
      
      
      Add the additional "vm_flags_t vm_flags" argument to do_mmap_pgoff(),
      rename it to do_mmap(), and re-introduce do_mmap_pgoff() as a simple
      wrapper on top of do_mmap().  Perhaps we should update the callers of
      do_mmap_pgoff() and kill it later.
      
      This way mpx_mmap() can simply call do_mmap(vm_flags => VM_MPX) and do not
      play with vm internals.
      
      After this change mmap_region() has a single user outside of mmap.c,
      arch/tile/mm/elf.c:arch_setup_additional_pages().  It would be nice to
      change arch/tile/ and unexport mmap_region().
      
      [kirill@shutemov.name: fix build]
      [akpm@linux-foundation.org: coding-style fixes]
      Signed-off-by: default avatarOleg Nesterov <oleg@redhat.com>
      Acked-by: default avatarDave Hansen <dave.hansen@linux.intel.com>
      Tested-by: default avatarDave Hansen <dave.hansen@linux.intel.com>
      Signed-off-by: default avatarKirill A. Shutemov <kirill.shutemov@linux.intel.com>
      Cc: "H. Peter Anvin" <hpa@zytor.com>
      Cc: Andy Lutomirski <luto@amacapital.net>
      Cc: Ingo Molnar <mingo@elte.hu>
      Cc: Minchan Kim <minchan@kernel.org>
      Cc: Thomas Gleixner <tglx@linutronix.de>
      Signed-off-by: default avatarAndrew Morton <akpm@linux-foundation.org>
      Signed-off-by: default avatarLinus Torvalds <torvalds@linux-foundation.org>
      1fcfd8db
    • Kirill A. Shutemov's avatar
      mm: mark most vm_operations_struct const · 7cbea8dc
      Kirill A. Shutemov authored
      
      
      With two exceptions (drm/qxl and drm/radeon) all vm_operations_struct
      structs should be constant.
      
      Signed-off-by: default avatarKirill A. Shutemov <kirill.shutemov@linux.intel.com>
      Reviewed-by: default avatarOleg Nesterov <oleg@redhat.com>
      Cc: "H. Peter Anvin" <hpa@zytor.com>
      Cc: Andy Lutomirski <luto@amacapital.net>
      Cc: Dave Hansen <dave.hansen@linux.intel.com>
      Cc: Ingo Molnar <mingo@elte.hu>
      Cc: Minchan Kim <minchan@kernel.org>
      Cc: Thomas Gleixner <tglx@linutronix.de>
      Signed-off-by: default avatarAndrew Morton <akpm@linux-foundation.org>
      Signed-off-by: default avatarLinus Torvalds <torvalds@linux-foundation.org>
      7cbea8dc
    • Masanari Iida's avatar
      namei: fix warning while make xmldocs caused by namei.c · 2a78b857
      Masanari Iida authored
      
      
      Fix the following warnings:
      
      Warning(.//fs/namei.c:2422): No description found for parameter 'nd'
      Warning(.//fs/namei.c:2422): Excess function parameter 'nameidata'
      description in 'path_mountpoint'
      
      Signed-off-by: default avatarMasanari Iida <standby24x7@gmail.com>
      Acked-by: default avatarRandy Dunlap <rdunlap@infradead.org>
      Signed-off-by: default avatarAndrew Morton <akpm@linux-foundation.org>
      Signed-off-by: default avatarLinus Torvalds <torvalds@linux-foundation.org>
      2a78b857
    • Davidlohr Bueso's avatar
      ipc: convert invalid scenarios to use WARN_ON · d0edd852
      Davidlohr Bueso authored
      
      
      Considering Linus' past rants about the (ab)use of BUG in the kernel, I
      took a look at how we deal with such calls in ipc.  Given that any errors
      or corruption in ipc code are most likely contained within the set of
      processes participating in the broken mechanisms, there aren't really many
      strong fatal system failure scenarios that would require a BUG call.
      Also, if something is seriously wrong, ipc might not be the place for such
      a BUG either.
      
      1. For example, recently, a customer hit one of these BUG_ONs in shm
         after failing shm_lock().  A busted ID imho does not merit a BUG_ON,
         and WARN would have been better.
      
      2. MSG_COPY functionality of posix msgrcv(2) for checkpoint/restore.
         I don't see how we can hit this anyway -- at least it should be IS_ERR.
          The 'copy' arg from do_msgrcv is always set by calling prepare_copy()
         first and foremost.  We could also probably drop this check altogether.
          Either way, it does not merit a BUG_ON.
      
      3. No ->fault() callback for the fs getting the corresponding page --
         seems selfish to make the system unusable.
      
      Signed-off-by: default avatarDavidlohr Bueso <dbueso@suse.de>
      Cc: Manfred Spraul <manfred@colorfullife.com>
      Cc: Linus Torvalds <torvalds@linux-foundation.org>
      Signed-off-by: default avatarAndrew Morton <akpm@linux-foundation.org>
      Signed-off-by: default avatarLinus Torvalds <torvalds@linux-foundation.org>
      d0edd852
    • yalin wang's avatar
      zlib_deflate/deftree: remove bi_reverse() · 8b235f2f
      yalin wang authored
      
      
      Remove bi_reverse() and use generic bitrev32() instead - it should have
      better performance on some platforms.
      
      Signed-off-by: default avataryalin wang <yalin.wang2010@gmail.com>
      Signed-off-by: default avatarAndrew Morton <akpm@linux-foundation.org>
      Signed-off-by: default avatarLinus Torvalds <torvalds@linux-foundation.org>
      8b235f2f
    • Fabio Estevam's avatar
      lib/decompress_unlzma: Do a NULL check for pointer · e4e29dc4
      Fabio Estevam authored
      
      
      Compare pointer-typed values to NULL rather than 0.
      
      The semantic patch that makes this change is available
      in scripts/coccinelle/null/badzero.cocci.
      
      Signed-off-by: default avatarFabio Estevam <fabio.estevam@freescale.com>
      Signed-off-by: default avatarAndrew Morton <akpm@linux-foundation.org>
      Signed-off-by: default avatarLinus Torvalds <torvalds@linux-foundation.org>
      e4e29dc4
    • Yinghai Lu's avatar
      lib/decompressors: use real out buf size for gunzip with kernel · 2d3862d2
      Yinghai Lu authored
      When loading x86 64bit kernel above 4GiB with patched grub2, got kernel
      gunzip error.
      
      | early console in decompress_kernel
      | decompress_kernel:
      |       input: [0x807f2143b4-0x807ff61aee]
      |      output: [0x807cc00000-0x807f3ea29b] 0x027ea29c: output_len
      | boot via startup_64
      | KASLR using RDTSC...
      |  new output: [0x46fe000000-0x470138cfff] 0x0338d000: output_run_size
      |  decompress: [0x46fe000000-0x47007ea29b] <=== [0x807f2143b4-0x807ff61aee]
      |
      | Decompressing Linux... gz...
      |
      | uncompression error
      |
      | -- System halted
      
      the new buffer is at 0x46fe000000ULL, decompressor_gzip is using
      0xffffffb901ffffff as out_len.  gunzip in lib/zlib_inflate/inflate.c cap
      that len to 0x01ffffff and decompress fails later.
      
      We could hit this problem with crashkernel booting that uses kexec loading
      kernel above 4GiB.
      
      We have decompress_* support:
          1. inbuf[]/outbuf[] for kernel preboot.
          2. inbuf[]/flush() for initramfs
          3. fill()/flush() for initrd.
      This bug only affect kernel preboot path that use outbuf[].
      
      Add __decompress and take real out_buf_len for gunzip instead of guessing
      wrong buf size.
      
      Fixes: 1431574a
      
       (lib/decompressors: fix "no limit" output buffer length)
      Signed-off-by: default avatarYinghai Lu <yinghai@kernel.org>
      Cc: Alexandre Courbot <acourbot@nvidia.com>
      Cc: Jon Medhurst <tixy@linaro.org>
      Cc: Stephen Warren <swarren@wwwdotorg.org>
      Cc: "H. Peter Anvin" <hpa@zytor.com>
      Cc: Thomas Gleixner <tglx@linutronix.de>
      Cc: Ingo Molnar <mingo@redhat.com>
      Cc: <stable@vger.kernel.org>
      Signed-off-by: default avatarAndrew Morton <akpm@linux-foundation.org>
      Signed-off-by: default avatarLinus Torvalds <torvalds@linux-foundation.org>
      2d3862d2
    • Pranay Kr. Srivastava's avatar
      fs/affs: make root lookup from blkdev logical size · e852d82a
      Pranay Kr. Srivastava authored
      This patch resolves https://bugzilla.kernel.org/show_bug.cgi?id=16531
      
      .
      
      When logical blkdev size > 512 then sector numbers become larger than the
      device can support.
      
      Make affs start lookup based on the device's logical sector size instead
      of 512.
      
      Reported-by: default avatarMark <markk@clara.co.uk>
      Suggested-by: default avatarMark <markk@clara.co.uk>
      Signed-off-by: default avatarAndrew Morton <akpm@linux-foundation.org>
      Signed-off-by: default avatarLinus Torvalds <torvalds@linux-foundation.org>
      e852d82a
    • Ilya Dryomov's avatar
      sysctl: fix int -> unsigned long assignments in INT_MIN case · 9a5bc726
      Ilya Dryomov authored
      
      
      The following
      
          if (val < 0)
              *lvalp = (unsigned long)-val;
      
      is incorrect because the compiler is free to assume -val to be positive
      and use a sign-extend instruction for extending the bit pattern.  This is
      a problem if val == INT_MIN:
      
          # echo -2147483648 >/proc/sys/dev/scsi/logging_level
          # cat /proc/sys/dev/scsi/logging_level
          -18446744071562067968
      
      Cast to unsigned long before negation - that way we first sign-extend and
      then negate an unsigned, which is well defined.  With this:
      
          # cat /proc/sys/dev/scsi/logging_level
          -2147483648
      
      Signed-off-by: default avatarIlya Dryomov <idryomov@gmail.com>
      Cc: Mikulas Patocka <mikulas@twibright.com>
      Cc: Robert Xiao <nneonneo@gmail.com>
      Cc: "Eric W. Biederman" <ebiederm@xmission.com>
      Cc: Kees Cook <keescook@chromium.org>
      Signed-off-by: default avatarAndrew Morton <akpm@linux-foundation.org>
      Signed-off-by: default avatarLinus Torvalds <torvalds@linux-foundation.org>
      9a5bc726