summaryrefslogtreecommitdiff
path: root/mm
AgeCommit message (Collapse)Author
2016-11-10Merge "debug-pagealloc: Panic on pagealloc corruption"Linux Build Service Account
2016-10-28Merge remote-tracking branch 'msm4.4/tmp-da9a92f' into msm-4.4Runmin Wang
* origin/tmp-da9a92f: arm64: kaslr: increase randomization granularity arm64: relocatable: deal with physically misaligned kernel images arm64: don't map TEXT_OFFSET bytes below the kernel if we can avoid it arm64: kernel: replace early 64-bit literal loads with move-immediates arm64: introduce mov_q macro to move a constant into a 64-bit register arm64: kernel: perform relocation processing from ID map arm64: kernel: use literal for relocated address of __secondary_switched arm64: kernel: don't export local symbols from head.S arm64: simplify kernel segment mapping granularity arm64: cover the .head.text section in the .text segment mapping arm64: move early boot code to the .init segment arm64: use 'segment' rather than 'chunk' to describe mapped kernel regions arm64: mm: Mark .rodata as RO Linux 4.4.16 ovl: verify upper dentry before unlink and rename drm/i915: Revert DisplayPort fast link training feature tmpfs: fix regression hang in fallocate undo tmpfs: don't undo fallocate past its last page crypto: qat - make qat_asym_algs.o depend on asn1 headers xen/acpi: allow xen-acpi-processor driver to load on Xen 4.7 File names with trailing period or space need special case conversion cifs: dynamic allocation of ntlmssp blob Fix reconnect to not defer smb3 session reconnect long after socket reconnect 53c700: fix BUG on untagged commands s390: fix test_fp_ctl inline assembly contraints scsi: fix race between simultaneous decrements of ->host_failed ovl: verify upper dentry in ovl_remove_and_whiteout() ovl: Copy up underlying inode's ->i_mode to overlay inode ARM: mvebu: fix HW I/O coherency related deadlocks ARM: dts: armada-38x: fix MBUS_ID for crypto SRAM on Armada 385 Linksys ARM: sunxi/dt: make the CHIP inherit from allwinner,sun5i-a13 ALSA: hda: add AMD Stoney PCI ID with proper driver caps ALSA: hda - fix use-after-free after module unload ALSA: ctl: Stop notification after disconnection ALSA: pcm: Free chmap at PCM free callback, too ALSA: hda/realtek - add new pin definition in alc225 pin quirk table ALSA: hda - fix read before array start ALSA: hda - Add PCI ID for Kabylake-H ALSA: hda/realtek: Add Lenovo L460 to docking unit fixup ALSA: timer: Fix negative queue usage by racy accesses ALSA: echoaudio: Fix memory allocation ALSA: au88x0: Fix calculation in vortex_wtdma_bufshift() ALSA: hda / realtek - add two more Thinkpad IDs (5050,5053) for tpt460 fixup ALSA: hda - Fix the headset mic jack detection on Dell machine ALSA: dummy: Fix a use-after-free at closing hwmon: (dell-smm) Cache fan_type() calls and change fan detection hwmon: (dell-smm) Disallow fan_type() calls on broken machines hwmon: (dell-smm) Restrict fan control and serial number to CAP_SYS_ADMIN by default tty/vt/keyboard: fix OOB access in do_compute_shiftstate() tty: vt: Fix soft lockup in fbcon cursor blink timer. iio:ad7266: Fix probe deferral for vref iio:ad7266: Fix support for optional regulators iio:ad7266: Fix broken regulator error handling iio: accel: kxsd9: fix the usage of spi_w8r8() staging: iio: accel: fix error check iio: hudmidity: hdc100x: fix incorrect shifting and scaling iio: humidity: hdc100x: fix IIO_TEMP channel reporting iio: humidity: hdc100x: correct humidity integration time mask iio: proximity: as3935: fix buffer stack trashing iio: proximity: as3935: remove triggered buffer processing iio: proximity: as3935: correct IIO_CHAN_INFO_RAW output iio: light apds9960: Add the missing dev.parent iio:st_pressure: fix sampling gains (bring inline with ABI) iio: Fix error handling in iio_trigger_attach_poll_func xen/balloon: Fix declared-but-not-defined warning perf/x86: Fix undefined shift on 32-bit kernels memory: omap-gpmc: Fix omap gpmc EXTRADELAY timing drm/vmwgfx: Fix error paths when mapping framebuffer drm/vmwgfx: Delay pinning fbdev framebuffer until after mode set drm/vmwgfx: Check pin count before attempting to move a buffer drm/vmwgfx: Work around mode set failure in 2D VMs drm/vmwgfx: Add an option to change assumed FB bpp drm/ttm: Make ttm_bo_mem_compat available drm: atmel-hlcdc: actually disable scaling when no scaling is required drm: make drm_atomic_set_mode_prop_for_crtc() more reliable drm: add missing drm_mode_set_crtcinfo call drm/i915: Update CDCLK_FREQ register on BDW after changing cdclk frequency drm/i915: Update ifdeffery for mutex->owner drm/i915: Refresh cached DP port register value on resume drm/i915/ilk: Don't disable SSC source if it's in use drm/nouveau/disp/sor/gf119: select correct sor when poking training pattern drm/nouveau: fix for disabled fbdev emulation drm/nouveau/fbcon: fix out-of-bounds memory accesses drm/nouveau/gr/gf100-: update sm error decoding from gk20a nvgpu headers drm/nouveau/disp/sor/gf119: both links use the same training register virtio_balloon: fix PFN format for virtio-1 drm/dp/mst: Always clear proposed vcpi table for port. drm/amdkfd: destroy dbgmgr in notifier release drm/amdkfd: unbind only existing processes ubi: Make recover_peb power cut aware drm/amdgpu/gfx7: fix broken condition check drm/radeon: fix asic initialization for virtualized environments btrfs: account for non-CoW'd blocks in btrfs_abort_transaction percpu: fix synchronization between synchronous map extension and chunk destruction percpu: fix synchronization between chunk->map_extend_work and chunk destruction af_unix: fix hard linked sockets on overlay vfs: add d_real_inode() helper arm64: Rework valid_user_regs ipmi: Remove smi_msg from waiting_rcv_msgs list before handle_one_recv_msg() drm/mgag200: Black screen fix for G200e rev 4 iommu/amd: Fix unity mapping initialization race iommu/vt-d: Enable QI on all IOMMUs before setting root entry iommu/arm-smmu: Wire up map_sg for arm-smmu-v3 base: make module_create_drivers_dir race-free tracing: Handle NULL formats in hold_module_trace_bprintk_format() HID: multitouch: enable palm rejection for Windows Precision Touchpad HID: hiddev: validate num_values for HIDIOCGUSAGES, HIDIOCSUSAGES commands HID: elo: kill not flush the work KVM: nVMX: VMX instructions: fix segment checks when L1 is in long mode. kvm: Fix irq route entries exceeding KVM_MAX_IRQ_ROUTES KEYS: potential uninitialized variable ARCv2: LLSC: software backoff is NOT needed starting HS2.1c ARCv2: Check for LL-SC livelock only if LLSC is enabled ipv6: Fix mem leak in rt6i_pcpu cdc_ncm: workaround for EM7455 "silent" data interface net_sched: fix mirrored packets checksum packet: Use symmetric hash for PACKET_FANOUT_HASH. sched/fair: Fix cfs_rq avg tracking underflow UBIFS: Implement ->migratepage() mm: Export migrate_page_move_mapping and migrate_page_copy MIPS: KVM: Fix modular KVM under QEMU ARM: 8579/1: mm: Fix definition of pmd_mknotpresent ARM: 8578/1: mm: ensure pmd_present only checks the valid bit ARM: imx6ul: Fix Micrel PHY mask NFS: Fix another OPEN_DOWNGRADE bug make nfs_atomic_open() call d_drop() on all ->open_context() errors. nfsd: check permissions when setting ACLs posix_acl: Add set_posix_acl nfsd: Extend the mutex holding region around in nfsd4_process_open2() nfsd: Always lock state exclusively. nfsd4/rpc: move backchannel create logic into rpc code writeback: use higher precision calculation in domain_dirty_limits() thermal: cpu_cooling: fix improper order during initialization uvc: Forward compat ioctls to their handlers directly Revert "gpiolib: Split GPIO flags parsing and GPIO configuration" x86/amd_nb: Fix boot crash on non-AMD systems kprobes/x86: Clear TF bit in fault on single-stepping x86, build: copy ldlinux.c32 to image.iso locking/static_key: Fix concurrent static_key_slow_inc() locking/qspinlock: Fix spin_unlock_wait() some more locking/ww_mutex: Report recursive ww_mutex locking early of: irq: fix of_irq_get[_byname]() kernel-doc of: fix autoloading due to broken modalias with no 'compatible' mnt: If fs_fully_visible fails call put_filesystem. mnt: Account for MS_RDONLY in fs_fully_visible mnt: fs_fully_visible test the proper mount for MNT_LOCKED usb: common: otg-fsm: add license to usb-otg-fsm USB: EHCI: declare hostpc register as zero-length array usb: dwc2: fix regression on big-endian PowerPC/ARM systems powerpc/tm: Always reclaim in start_thread() for exec() class syscalls powerpc/pseries: Fix IBM_ARCH_VEC_NRCORES_OFFSET since POWER8NVL was added powerpc/pseries: Fix PCI config address for DDW powerpc/iommu: Remove the dependency on EEH struct in DDW mechanism IB/mlx4: Properly initialize GRH TClass and FlowLabel in AHs IB/cm: Fix a recently introduced locking bug EDAC, sb_edac: Fix rank lookup on Broadwell mac80211: Fix mesh estab_plinks counting in STA removal case mac80211_hwsim: Add missing check for HWSIM_ATTR_SIGNAL mac80211: mesh: flush mesh paths unconditionally mac80211: fix fast_tx header alignment Linux 4.4.15 usb: dwc3: exynos: Fix deferred probing storm. usb: host: ehci-tegra: Grab the correct UTMI pads reset usb: gadget: fix spinlock dead lock in gadgetfs USB: mos7720: delete parport xhci: Fix handling timeouted commands on hosts in weird states. USB: xhci: Add broken streams quirk for Frescologic device id 1009 usb: xhci-plat: properly handle probe deferral for devm_clk_get() xhci: Cleanup only when releasing primary hcd usb: musb: host: correct cppi dma channel for isoch transfer usb: musb: Ensure rx reinit occurs for shared_fifo endpoints usb: musb: Stop bulk endpoint while queue is rotated usb: musb: only restore devctl when session was set in backup usb: quirks: Add no-lpm quirk for Acer C120 LED Projector usb: quirks: Fix sorting USB: uas: Fix slave queue_depth not being set crypto: user - re-add size check for CRYPTO_MSG_GETALG crypto: ux500 - memmove the right size crypto: vmx - Increase priority of aes-cbc cipher AX.25: Close socket connection on session completion bpf: try harder on clones when writing into skb net: alx: Work around the DMA RX overflow issue net: macb: fix default configuration for GMAC on AT91 neigh: Explicitly declare RCU-bh read side critical section in neigh_xmit() bpf, perf: delay release of BPF prog after grace period sock_diag: do not broadcast raw socket destruction Bridge: Fix ipv6 mc snooping if bridge has no ipv6 address ipmr/ip6mr: Initialize the last assert time of mfc entries. netem: fix a use after free esp: Fix ESN generation under UDP encapsulation sit: correct IP protocol used in ipip6_err net: Don't forget pr_fmt on net_dbg_ratelimited for CONFIG_DYNAMIC_DEBUG net_sched: fix pfifo_head_drop behavior vs backlog sdcardfs: Truncate packages_gid.list on overflow UPSTREAM: cdc_ncm: do not call usbnet_link_change from cdc_ncm_bind BACKPORT: proc: add /proc/<pid>/timerslack_ns interface BACKPORT: timer: convert timer_slack_ns from unsigned long to u64 netfilter: xt_quota2: make quota2_log work well Revert "usb: gadget: prevent change of Host MAC address of 'usb0' interface" BACKPORT: PM / sleep: Go direct_complete if driver has no callbacks ANDROID: base-cfg: enable UID_CPUTIME UPSTREAM: USB: usbfs: fix potential infoleak in devio UPSTREAM: ALSA: timer: Fix leak in events via snd_timer_user_ccallback UPSTREAM: ALSA: timer: Fix leak in events via snd_timer_user_tinterrupt UPSTREAM: ALSA: timer: Fix leak in SNDRV_TIMER_IOCTL_PARAMS ANDROID: configs: remove unused configs ANDROID: cpu: send KOBJ_ONLINE event when enabling cpus ANDROID: dm verity fec: initialize recursion level ANDROID: dm verity fec: fix RS block calculation Linux 4.4.14 netfilter: x_tables: introduce and use xt_copy_counters_from_user netfilter: x_tables: do compat validation via translate_table netfilter: x_tables: xt_compat_match_from_user doesn't need a retval netfilter: ip6_tables: simplify translate_compat_table args netfilter: ip_tables: simplify translate_compat_table args netfilter: arp_tables: simplify translate_compat_table args netfilter: x_tables: don't reject valid target size on some architectures netfilter: x_tables: validate all offsets and sizes in a rule netfilter: x_tables: check for bogus target offset netfilter: x_tables: check standard target size too netfilter: x_tables: add compat version of xt_check_entry_offsets netfilter: x_tables: assert minimum target size netfilter: x_tables: kill check_entry helper netfilter: x_tables: add and use xt_check_entry_offsets netfilter: x_tables: validate targets of jumps netfilter: x_tables: don't move to non-existent next rule drm/core: Do not preserve framebuffer on rmfb, v4. crypto: qat - fix adf_ctl_drv.c:undefined reference to adf_init_pf_wq netfilter: x_tables: fix unconditional helper netfilter: x_tables: make sure e->next_offset covers remaining blob size netfilter: x_tables: validate e->target_offset early MIPS: Fix 64k page support for 32 bit kernels. sparc64: Fix return from trap window fill crashes. sparc: Harden signal return frame checks. sparc64: Take ctx_alloc_lock properly in hugetlb_setup(). sparc64: Reduce TLB flushes during hugepte changes sparc/PCI: Fix for panic while enabling SR-IOV sparc64: Fix sparc64_set_context stack handling. sparc64: Fix numa node distance initialization sparc64: Fix bootup regressions on some Kconfig combinations. sparc: Fix system call tracing register handling. fix d_walk()/non-delayed __d_free() race sched: panic on corrupted stack end proc: prevent stacking filesystems on top x86/entry/traps: Don't force in_interrupt() to return true in IST handlers wext: Fix 32 bit iwpriv compatibility issue with 64 bit Kernel ecryptfs: forbid opening files without mmap handler memcg: add RCU locking around css_for_each_descendant_pre() in memcg_offline_kmem() parisc: Fix pagefault crash in unaligned __get_user() call pinctrl: mediatek: fix dual-edge code defect powerpc/pseries: Add POWER8NVL support to ibm,client-architecture-support call powerpc: Use privileged SPR number for MMCR2 powerpc: Fix definition of SIAR and SDAR registers powerpc/pseries/eeh: Handle RTAS delay requests in configure_bridge arm64: mm: always take dirty state from new pte in ptep_set_access_flags arm64: Provide "model name" in /proc/cpuinfo for PER_LINUX32 tasks crypto: ccp - Fix AES XTS error for request sizes above 4096 crypto: public_key: select CRYPTO_AKCIPHER irqchip/gic-v3: Fix ICC_SGI1R_EL1.INTID decoding mask s390/bpf: reduce maximum program size to 64 KB s390/bpf: fix recache skb->data/hlen for skb_vlan_push/pop gpio: bcm-kona: fix bcm_kona_gpio_reset() warnings ARM: fix PTRACE_SETVFPREGS on SMP systems ALSA: hda/realtek: Add T560 docking unit fixup ALSA: hda/realtek - Add support for new codecs ALC700/ALC701/ALC703 ALSA: hda/realtek - ALC256 speaker noise issue ALSA: hda - Fix headset mic detection problem for Dell machine ALSA: hda - Add PCI ID for Kabylake KVM: irqfd: fix NULL pointer dereference in kvm_irq_map_gsi KVM: x86: fix OOPS after invalid KVM_SET_DEBUGREGS vxlan, gre, geneve: Set a large MTU on ovs-created tunnel devices geneve: Relax MTU constraints vxlan: Relax MTU constraints ipv6: Skip XFRM lookup if dst_entry in socket cache is valid l2tp: fix configuration passed to setup_udp_tunnel_sock() bridge: Don't insert unnecessary local fdb entry on changing mac address tcp: record TLP and ER timer stats in v6 stats vxlan: Accept user specified MTU value when create new vxlan link team: don't call netdev_change_features under team->lock sfc: on MC reset, clear PIO buffer linkage in TXQs bpf, inode: disallow userns mounts uapi glibc compat: fix compilation when !__USE_MISC in glibc udp: prevent skbs lingering in tunnel socket queues bpf: Use mount_nodev not mount_ns to mount the bpf filesystem tuntap: correctly wake up process during uninit switchdev: pass pointer to fib_info instead of copy tipc: fix nametable publication field in nl compat netlink: Fix dump skb leak/double free tipc: check nl sock before parsing nested attributes scsi: Add QEMU CD-ROM to VPD Inquiry Blacklist scsi_lib: correctly retry failed zero length REQ_TYPE_FS commands cs-etm: associating output packet with CPU they executed on cs-etm: removing unecessary structure field cs-etm: account for each trace buffer in the queue cs-etm: avoid casting variable perf tools: fixing Makefile problems perf tools: new naming convention for openCSD perf scripts: Add python scripts for CoreSight traces perf tools: decoding capailitity for CoreSight traces perf symbols: Check before overwriting build_id perf tools: pushing driver configuration down to the kernel perf tools: add infrastructure for PMU specific configuration coresight: etm-perf: incorporating sink definition from the cmd line coresight: adding sink parameter to function coresight_build_path() perf: passing struct perf_event to function setup_aux() perf/core: adding PMU driver specific configuration perf tools: adding coresight etm PMU record capabilities perf tools: making coresight PMU listable coresight: tmc: implementing TMC-ETR AUX space API coresight: Add support for Juno platform coresight: Handle build path error coresight: Fix erroneous memset in tmc_read_unprepare_etr coresight: Fix tmc_read_unprepare_etr coresight: Fix NULL pointer dereference in _coresight_build_path ANDROID: dm verity fec: add missing release from fec_ktype ANDROID: dm verity fec: limit error correction recursion ANDROID: restrict access to perf events FROMLIST: security,perf: Allow further restriction of perf_event_open BACKPORT: perf tools: Document the perf sysctls Revert "armv6 dcc tty driver" Revert "arm: dcc_tty: fix armv6 dcc tty build failure" ARM64: Ignore Image-dtb from git point of view arm64: add option to build Image-dtb ANDROID: usb: gadget: f_midi: set fi->f to NULL when free f_midi function Linux 4.4.13 xfs: handle dquot buffer readahead in log recovery correctly xfs: print name of verifier if it fails xfs: skip stale inodes in xfs_iflush_cluster xfs: fix inode validity check in xfs_iflush_cluster xfs: xfs_iflush_cluster fails to abort on error xfs: Don't wrap growfs AGFL indexes xfs: disallow rw remount on fs with unknown ro-compat features gcov: disable tree-loop-im to reduce stack usage scripts/package/Makefile: rpmbuild add support of RPMOPTS dma-debug: avoid spinlock recursion when disabling dma-debug PM / sleep: Handle failures in device_suspend_late() consistently ext4: silence UBSAN in ext4_mb_init() ext4: address UBSAN warning in mb_find_order_for_block() ext4: fix oops on corrupted filesystem ext4: clean up error handling when orphan list is corrupted ext4: fix hang when processing corrupted orphaned inode list drm/imx: Match imx-ipuv3-crtc components using device node in platform data drm/i915: Don't leave old junk in ilk active watermarks on readout drm/atomic: Verify connector->funcs != NULL when clearing states drm/fb_helper: Fix references to dev->mode_config.num_connector drm/i915/fbdev: Fix num_connector references in intel_fb_initial_config() drm/amdgpu: Fix hdmi deep color support. drm/amdgpu: use drm_mode_vrefresh() rather than mode->vrefresh drm/vmwgfx: Fix order of operation drm/vmwgfx: use vmw_cmd_dx_cid_check for query commands. drm/vmwgfx: Enable SVGA_3D_CMD_DX_SET_PREDICATION drm/gma500: Fix possible out of bounds read sunrpc: fix stripping of padded MIC tokens xen: use same main loop for counting and remapping pages xen/events: Don't move disabled irqs powerpc/eeh: Restore initial state in eeh_pe_reset_and_recover() Revert "powerpc/eeh: Fix crash in eeh_add_device_early() on Cell" powerpc/eeh: Don't report error in eeh_pe_reset_and_recover() powerpc/book3s64: Fix branching to OOL handlers in relocatable kernel pipe: limit the per-user amount of pages allocated in pipes QE-UART: add "fsl,t1040-ucc-uart" to of_device_id wait/ptrace: assume __WALL if the child is traced mm: use phys_addr_t for reserve_bootmem_region() arguments media: v4l2-compat-ioctl32: fix missing reserved field copy in put_v4l2_create32 PCI: Disable all BAR sizing for devices with non-compliant BARs pinctrl: exynos5440: Use off-stack memory for pinctrl_gpio_range clk: bcm2835: divider value has to be 1 or more clk: bcm2835: pll_off should only update CM_PLL_ANARST clk: at91: fix check of clk_register() returned value clk: bcm2835: Fix PLL poweron cpuidle: Fix cpuidle_state_is_coupled() argument in cpuidle_enter() cpuidle: Indicate when a device has been unregistered PM / Runtime: Fix error path in pm_runtime_force_resume() mfd: intel_soc_pmic_core: Terminate panel control GPIO lookup table correctly mfd: intel-lpss: Save register context on suspend hwmon: (ads7828) Enable internal reference aacraid: Fix for KDUMP driver hang aacraid: Fix for aac_command_thread hang aacraid: Relinquish CPU during timeout wait rtlwifi: pci: use dev_kfree_skb_irq instead of kfree_skb in rtl_pci_reset_trx_ring rtlwifi: Fix logic error in enter/exit power-save mode rtlwifi: btcoexist: Implement antenna selection rtlwifi: rtl8723be: Add antenna select module parameter hwrng: exynos - Fix unbalanced PM runtime put on timeout error path ath5k: Change led pin configuration for compaq c700 laptop ath10k: fix kernel panic, move arvifs list head init before htt init ath10k: fix rx_channel during hw reconfigure ath10k: fix firmware assert in monitor mode ath10k: fix debugfs pktlog_filter write ath9k: Fix LED polarity for some Mini PCI AR9220 MB92 cards. ath9k: Add a module parameter to invert LED polarity. ARM: dts: imx35: restore existing used clock enumeration ARM: dts: exynos: Add interrupt line to MAX8997 PMIC on exynos4210-trats ARM: dts: at91: fix typo in sama5d2 PIN_PD24 description ARM: mvebu: fix GPIO config on the Linksys boards Input: uinput - handle compat ioctl for UI_SET_PHYS ASoC: ak4642: Enable cache usage to fix crashes on resume affs: fix remount failure when there are no options changed MIPS: VDSO: Build with `-fno-strict-aliasing' MIPS: lib: Mark intrinsics notrace MIPS: Build microMIPS VDSO for microMIPS kernels MIPS: Fix sigreturn via VDSO on microMIPS kernel MIPS: ptrace: Prevent writes to read-only FCSR bits MIPS: ptrace: Fix FP context restoration FCSR regression MIPS: Disable preemption during prctl(PR_SET_FP_MODE, ...) MIPS: Prevent "restoration" of MSA context in non-MSA kernels MIPS: Fix MSA ld_*/st_* asm macros to use PTR_ADDU MIPS: Use copy_s.fmt rather than copy_u.fmt MIPS: Loongson-3: Reserve 32MB for RS780E integrated GPU MIPS: Reserve nosave data for hibernation MIPS: ath79: make bootconsole wait for both THRE and TEMT MIPS: Sync icache & dcache in set_pte_at MIPS: Handle highmem pages in __update_cache MIPS: Flush highmem pages in __flush_dcache_page MIPS: Fix watchpoint restoration MIPS: Fix uapi include in exported asm/siginfo.h MIPS: Fix siginfo.h to use strict posix types MIPS: Avoid using unwind_stack() with usermode MIPS: Don't unwind to user mode with EVA MIPS: MSA: Fix a link error on `_init_msa_upper' with older GCC MIPS: math-emu: Fix jalr emulation when rd == $0 MIPS64: R6: R2 emulation bugfix coresight: etb10: adjust read pointer only when needed coresight: configuring ETF in FIFO mode when acting as link coresight: tmc: implementing TMC-ETF AUX space API coresight: moving struct cs_buffers to header file coresight: tmc: keep track of memory width coresight: tmc: make sysFS and Perf mode mutually exclusive coresight: tmc: dump system memory content only when needed coresight: tmc: adding mode of operation for link/sinks coresight: tmc: getting rid of multiple read access coresight: tmc: allocating memory when needed coresight: tmc: making prepare/unprepare functions generic coresight: tmc: splitting driver in ETB/ETF and ETR components coresight: tmc: cleaning up header file coresight: tmc: introducing new header file coresight: tmc: clearly define number of transfers per burst coresight: tmc: re-implementing tmc_read_prepare/unprepare() functions coresight: tmc: waiting for TMCReady bit before programming coresight: tmc: modifying naming convention coresight: tmc: adding sysFS management entries coresight: etm4x: add tracer ID for A72 Maia processor. coresight: etb10: fixing the right amount of words to read coresight: stm: adding driver for CoreSight STM component coresight: adding path for STM device coresight: etm4x: modify q_support type coresight: no need to do the forced type conversion coresight: removing gratuitous boot time log messages coresight: etb10: splitting sysFS "status" entry coresight: moving coresight_simple_func() to header file coresight: etm4x: implementing the perf PMU API coresight: etm4x: implementing user/kernel mode tracing coresight: etm4x: moving etm_drvdata::enable to atomic field coresight: etm4x: unlocking tracers in default arch init coresight: etm4x: splitting etmv4 default configuration coresight: etm4x: splitting struct etmv4_drvdata coresight: etm4x: adding config and traceid registers coresight: etm4x: moving sysFS entries to a dedicated file stm class: Support devices that override software assigned masters stm class: Remove unnecessary pointer increment stm class: Fix stm device initialization order stm class: Do not leak the chrdev in error path stm class: Remove a pointless line stm class: stm_heartbeat: Make nr_devs parameter read-only stm class: dummy_stm: Make nr_dummies parameter read-only MAINTAINERS: Add a git tree for the stm class perf/ring_buffer: Document AUX API usage perf/core: Free AUX pages in unmap path perf/ring_buffer: Refuse to begin AUX transaction after rb->aux_mmap_count drops perf auxtrace: Add perf_evlist pointer to *info_priv_size() perf session: Simplify tool stubs perf inject: Hit all DSOs for AUX data in JIT and other cases perf tools: tracepoint_error() can receive e=NULL, robustify it perf evlist: Make perf_evlist__open() open evsels with their cpus and threads (like perf record does) perf evsel: Introduce disable() method perf cpumap: Auto initialize cpu__max_{node,cpu} drivers/hwtracing: make coresight-etm-perf.c explicitly non-modular drivers/hwtracing: make coresight-* explicitly non-modular coresight: introducing a global trace ID function coresight: etm-perf: new PMU driver for ETM tracers coresight: etb10: implementing AUX API coresight: etb10: adding operation mode for sink->enable() coresight: etb10: moving to local atomic operations coresight: etm3x: implementing perf_enable/disable() API coresight: etm3x: implementing user/kernel mode tracing coresight: etm3x: consolidating initial config coresight: etm3x: changing default trace configuration coresight: etm3x: set progbit to stop trace collection coresight: etm3x: adding operation mode for etm_enable() coresight: etm3x: splitting struct etm_drvdata coresight: etm3x: unlocking tracers in default arch init coresight: etm3x: moving sysFS entries to dedicated file coresight: etm3x: moving etm_readl/writel to header file coresight: moving PM runtime operations to core framework coresight: add API to get sink from path coresight: associating path with session rather than tracer coresight: etm4x: Check every parameter used by dma_xx_coherent. coresight: "DEVICE_ATTR_RO" should defined as static. coresight: implementing 'cpu_id()' API coresight: removing bind/unbind options from sysfs coresight: remove csdev's link from topology coresight: release reference taken by 'bus_find_device()' coresight: coresight_unregister() function cleanup coresight: fixing lockdep error coresight: fixing indentation problem coresight: Fix a typo in Kconfig coresight: checking for NULL string in coresight_name_match() perf/core: Disable the event on a truncated AUX record perf/core: Don't leak event in the syscall error path perf/core: Fix perf_sched_count derailment stm class: dummy_stm: Add link callback for fault injection stm class: Plug stm device's unlink callback stm class: Fix a race in unlinking stm class: Fix unbalanced module/device refcounting stm class: Guard output assignment against concurrency stm class: Fix unlocking braino in the error path stm class: Add heartbeat stm source device stm class: dummy_stm: Create multiple devices stm class: Support devices with multiple instances stm class: Use driver's packet callback return value stm class: Prevent user-controllable allocations stm class: Fix link list locking stm class: Fix locking in unbinding policy path stm class: Select CONFIG_SRCU stm class: Hide STM-specific options if STM is disabled perf: Synchronously free aux pages in case of allocation failure Linux 4.4.12 kbuild: move -Wunused-const-variable to W=1 warning level Revert "scsi: fix soft lockup in scsi_remove_target() on module removal" scsi: Add intermediate STARGET_REMOVE state to scsi_target_state hpfs: implement the show_options method hpfs: fix remount failure when there are no options changed UBI: Fix static volume checks when Fastmap is used SIGNAL: Move generic copy_siginfo() to signal.h thunderbolt: Fix double free of drom buffer IB/srp: Fix a debug kernel crash ALSA: hda - Fix headset mic detection problem for one Dell machine ALSA: hda/realtek - Add support for ALC295/ALC3254 ALSA: hda - Fix headphone noise on Dell XPS 13 9360 ALSA: hda/realtek - New codecs support for ALC234/ALC274/ALC294 mcb: Fixed bar number assignment for the gdd clk: bcm2835: add locking to pll*_on/off methods locking,qspinlock: Fix spin_is_locked() and spin_unlock_wait() serial: samsung: Reorder the sequence of clock control when call s3c24xx_serial_set_termios() serial: 8250_mid: recognize interrupt source in handler serial: 8250_mid: use proper bar for DNV platform serial: 8250_pci: fix divide error bug if baud rate is 0 Fix OpenSSH pty regression on close tty/serial: atmel: fix hardware handshake selection TTY: n_gsm, fix false positive WARN_ON tty: vt, return error when con_startup fails xen/x86: actually allocate legacy interrupts on PV guests KVM: x86: mask CPUID(0xD,0x1).EAX against host value MIPS: KVM: Fix timer IRQ race when writing CP0_Compare MIPS: KVM: Fix timer IRQ race when freezing timer KVM: x86: fix ordering of cr0 initialization code in vmx_cpu_reset KVM: MTRR: remove MSR 0x2f8 staging: comedi: das1800: fix possible NULL dereference usb: gadget: udc: core: Fix argument of dev_err() in usb_gadget_map_request() USB: leave LPM alone if possible when binding/unbinding interface drivers usb: misc: usbtest: fix pattern tests for scatterlists. usb: f_mass_storage: test whether thread is running before starting another usb: gadget: f_fs: Fix EFAULT generation for async read operations USB: serial: option: add even more ZTE device ids USB: serial: option: add more ZTE device ids USB: serial: option: add support for Cinterion PH8 and AHxx USB: serial: io_edgeport: fix memory leaks in probe error path USB: serial: io_edgeport: fix memory leaks in attach error path USB: serial: quatech2: fix use-after-free in probe error path USB: serial: keyspan: fix use-after-free in probe error path USB: serial: mxuport: fix use-after-free in probe error path mei: bus: call mei_cl_read_start under device lock mei: amthif: discard not read messages mei: fix NULL dereferencing during FW initiated disconnection Bluetooth: vhci: Fix race at creating hci device Bluetooth: vhci: purge unhandled skbs Bluetooth: vhci: fix open_timeout vs. hdev race mmc: sdhci-pci: Remove MMC_CAP_BUS_WIDTH_TEST for Intel controllers mmc: longer timeout for long read time quirk dell-rbtn: Ignore ACPI notifications if device is suspended ACPI / osi: Fix an issue that acpi_osi=!* cannot disable ACPICA internal strings mmc: sdhci-acpi: Remove MMC_CAP_BUS_WIDTH_TEST for Intel controllers mmc: mmc: Fix partition switch timeout for some eMMCs can: fix handling of unmodifiable configuration options irqchip/gic-v3: Configure all interrupts as non-secure Group-1 irqchip/gic: Ensure ordering between read of INTACK and shared data Input: pwm-beeper - fix - scheduling while atomic mfd: omap-usb-tll: Fix scheduling while atomic BUG sched/loadavg: Fix loadavg artifacts on fully idle and on fully loaded systems clk: qcom: msm8916: Fix crypto clock flags crypto: sun4i-ss - Replace spinlock_bh by spin_lock_irq{save|restore} crypto: talitos - fix ahash algorithms registration crypto: caam - fix caam_jr_alloc() ret code ring-buffer: Prevent overflow of size in ring_buffer_resize() ring-buffer: Use long for nr_pages to avoid overflow failures asix: Fix offset calculation in asix_rx_fixup() causing slow transmissions fs/cifs: correctly to anonymous authentication for the NTLM(v2) authentication fs/cifs: correctly to anonymous authentication for the NTLM(v1) authentication fs/cifs: correctly to anonymous authentication for the LANMAN authentication fs/cifs: correctly to anonymous authentication via NTLMSSP remove directory incorrectly tries to set delete on close on non-empty directories kvm: arm64: Fix EC field in inject_abt64 arm/arm64: KVM: Enforce Break-Before-Make on Stage-2 page tables arm64: cpuinfo: Missing NULL terminator in compat_hwcap_str arm64: Implement pmdp_set_access_flags() for hardware AF/DBM arm64: Implement ptep_set_access_flags() for hardware AF/DBM arm64: Ensure pmd_present() returns false after pmd_mknotpresent() arm64: Fix typo in the pmdp_huge_get_and_clear() definition ext4: iterate over buffer heads correctly in move_extent_per_page() perf test: Fix build of BPF and LLVM on older glibc libraries perf/core: Fix perf_event_open() vs. execve() race perf/x86/intel/pt: Generate PMI in the STOP region as well Btrfs: don't use src fd for printk UPSTREAM: mac80211: fix "warning: ‘target_metric’ may be used uninitialized" Revert "drivers: power: use 'current' instead of 'get_current()'" cpufreq: interactive: drop cpufreq_{get,put}_global_kobject func calls Revert "cpufreq: interactive: build fixes for 4.4" xt_qtaguid: Fix panic caused by processing non-full socket. fiq_debugger: Add fiq_debugger.disable option UPSTREAM: procfs: fixes pthread cross-thread naming if !PR_DUMPABLE FROMLIST: wlcore: Disable filtering in AP role Revert "drivers: power: Add watchdog timer to catch drivers which lockup during suspend." fiq_debugger: Add option to apply uart overlay by FIQ_DEBUGGER_UART_OVERLAY Revert "Recreate asm/mach/mmc.h include file" Revert "ARM: Add 'card_present' state to mmc_platfrom_data" usb: dual-role: make stub functions inline Revert "mmc: Add status IRQ and status callback function to mmc platform data" quick selinux support for tracefs Revert "hid-multitouch: Filter collections by application usage." Revert "HID: steelseries: validate output report details" xt_qtaguid: Fix panic caused by synack processing Revert "mm: vmscan: Add a debug file for shrinkers" Revert "SELinux: Enable setting security contexts on rootfs inodes." Revert "SELinux: build fix for 4.1" fuse: Add support for d_canonical_path vfs: change d_canonical_path to take two paths android: recommended.cfg: remove CONFIG_UID_STAT netfilter: xt_qtaguid: seq_printf fixes Revert "misc: uidstat: Adding uid stat driver to collect network statistics." Revert "net: activity_stats: Add statistics for network transmission activity" Revert "net: activity_stats: Stop using obsolete create_proc_read_entry api" Revert "misc: uidstat: avoid create_stat() race and blockage." Revert "misc: uidstat: Remove use of obsolete create_proc_read_entry api" Revert "misc seq_printf fixes for 4.4" Revert "misc: uid_stat: Include linux/atomic.h instead of asm/atomic.h" Revert "net: socket ioctl to reset connections matching local address" Revert "net: fix iterating over hashtable in tcp_nuke_addr()" Revert "net: fix crash in tcp_nuke_addr()" Revert "Don't kill IPv4 sockets when killing IPv6 sockets was requested." Revert "tcp: Fix IPV6 module build errors" android: base-cfg: remove CONFIG_SWITCH Revert "switch: switch class and GPIO drivers." Revert "drivers: switch: remove S_IWUSR from dev_attr" ANDROID: base-cfg: enable CONFIG_IP_NF_NAT BACKPORT: selinux: restrict kernel module loading android: base-cfg: enable CONFIG_QUOTA Conflicts: Documentation/sysctl/kernel.txt drivers/cpufreq/cpufreq_interactive.c drivers/hwtracing/coresight/Kconfig drivers/hwtracing/coresight/Makefile drivers/hwtracing/coresight/coresight-etm4x.c drivers/hwtracing/coresight/coresight-etm4x.h drivers/hwtracing/coresight/coresight-priv.h drivers/hwtracing/coresight/coresight-stm.c drivers/hwtracing/coresight/coresight-tmc.c drivers/mmc/core/core.c include/linux/coresight-stm.h include/linux/coresight.h include/linux/msm_mdp.h include/uapi/linux/coresight-stm.h kernel/events/core.c kernel/sched/fair.c net/Makefile net/ipv4/netfilter/arp_tables.c net/ipv4/netfilter/ip_tables.c net/ipv4/tcp.c net/ipv6/netfilter/ip6_tables.c net/netfilter/xt_quota2.c sound/core/pcm.c Change-Id: I17aa0002815014e9bddc47e67769a53c15768a99 Signed-off-by: Runmin Wang <runminw@codeaurora.org>
2016-10-28debug-pagealloc: Panic on pagealloc corruptionPrasad Sodagudi
Instead of just printing warning on pagealloc corruption, collect the device state for first pagealloc error. CRs-Fixed: 1035111 Change-Id: I19fbc8c608acc623a68f9a686391a7ecd8437a4a Signed-off-by: Prasad Sodagudi <psodagud@codeaurora.org>
2016-10-21Merge remote-tracking branch 'msm-4.4/tmp-510d0a3f' into msm-4.4Runmin Wang
* msm-4.4/tmp-510d0a3f: Linux 4.4.11 nf_conntrack: avoid kernel pointer value leak in slab name drm/radeon: fix DP link training issue with second 4K monitor drm/i915/bdw: Add missing delay during L3 SQC credit programming drm/i915: Bail out of pipe config compute loop on LPT drm/radeon: fix PLL sharing on DCE6.1 (v2) Revert "[media] videobuf2-v4l2: Verify planes array in buffer dequeueing" Input: max8997-haptic - fix NULL pointer dereference get_rock_ridge_filename(): handle malformed NM entries tools lib traceevent: Do not reassign parg after collapse_tree() qla1280: Don't allocate 512kb of host tags atomic_open(): fix the handling of create_error regulator: axp20x: Fix axp22x ldo_io voltage ranges regulator: s2mps11: Fix invalid selector mask and voltages for buck9 workqueue: fix rebind bound workers warning ARM: dts: at91: sam9x5: Fix the memory range assigned to the PMC vfs: rename: check backing inode being equal vfs: add vfs_select_inode() helper perf/core: Disable the event on a truncated AUX record regmap: spmi: Fix regmap_spmi_ext_read in multi-byte case pinctrl: at91-pio4: fix pull-up/down logic spi: spi-ti-qspi: Handle truncated frames properly spi: spi-ti-qspi: Fix FLEN and WLEN settings if bits_per_word is overridden spi: pxa2xx: Do not detect number of enabled chip selects on Intel SPT ALSA: hda - Fix broken reconfig ALSA: hda - Fix white noise on Asus UX501VW headset ALSA: hda - Fix subwoofer pin on ASUS N751 and N551 ALSA: usb-audio: Yet another Phoneix Audio device quirk ALSA: usb-audio: Quirk for yet another Phoenix Audio devices (v2) crypto: testmgr - Use kmalloc memory for RSA input crypto: hash - Fix page length clamping in hash walk crypto: qat - fix invalid pf2vf_resp_wq logic s390/mm: fix asce_bits handling with dynamic pagetable levels zsmalloc: fix zs_can_compact() integer overflow ocfs2: fix posix_acl_create deadlock ocfs2: revert using ocfs2_acl_chmod to avoid inode cluster lock hang net/route: enforce hoplimit max value tcp: refresh skb timestamp at retransmit time net: thunderx: avoid exposing kernel stack net: fix a kernel infoleak in x25 module uapi glibc compat: fix compile errors when glibc net/if.h included before linux/if.h MIME-Version: 1.0 bridge: fix igmp / mld query parsing net: bridge: fix old ioctl unlocked net device walk VSOCK: do not disconnect socket when peer has shutdown SEND only net/mlx4_en: Fix endianness bug in IPV6 csum calculation net: fix infoleak in rtnetlink net: fix infoleak in llc net: fec: only clear a queue's work bit if the queue was emptied netem: Segment GSO packets on enqueue sch_dsmark: update backlog as well sch_htb: update backlog as well net_sched: update hierarchical backlog too net_sched: introduce qdisc_replace() helper gre: do not pull header in ICMP error processing net: Implement net_dbg_ratelimited() for CONFIG_DYNAMIC_DEBUG case samples/bpf: fix trace_output example bpf: fix check_map_func_compatibility logic bpf: fix refcnt overflow bpf: fix double-fdput in replace_map_fd_with_map_ptr() net/mlx4_en: fix spurious timestamping callbacks ipv4/fib: don't warn when primary address is missing if in_dev is dead net/mlx5e: Fix minimum MTU net/mlx5e: Device's mtu field is u16 and not int openvswitch: use flow protocol when recalculating ipv6 checksums atl2: Disable unimplemented scatter/gather feature vlan: pull on __vlan_insert_tag error path and fix csum correction net: use skb_postpush_rcsum instead of own implementations cdc_mbim: apply "NDP to end" quirk to all Huawei devices bpf/verifier: reject invalid LD_ABS | BPF_DW instruction net: sched: do not requeue a NULL skb packet: fix heap info leak in PACKET_DIAG_MCLIST sock_diag interface route: do not cache fib route info on local routes with oif decnet: Do not build routes to devices without decnet private data. parisc: Use generic extable search and sort routines arm64: kasan: Use actual memory node when populating the kernel image shadow arm64: mm: treat memstart_addr as a signed quantity arm64: lse: deal with clobbered IP registers after branch via PLT arm64: mm: check at build time that PAGE_OFFSET divides the VA space evenly arm64: kasan: Fix zero shadow mapping overriding kernel image shadow arm64: consistently use p?d_set_huge arm64: fix KASLR boot-time I-cache maintenance arm64: hugetlb: partial revert of 66b3923a1a0f arm64: make irq_stack_ptr more robust arm64: efi: invoke EFI_RNG_PROTOCOL to supply KASLR randomness efi: stub: use high allocation for converted command line efi: stub: add implementation of efi_random_alloc() efi: stub: implement efi_get_random_bytes() based on EFI_RNG_PROTOCOL arm64: kaslr: randomize the linear region arm64: add support for kernel ASLR arm64: add support for building vmlinux as a relocatable PIE binary arm64: switch to relative exception tables extable: add support for relative extables to search and sort routines scripts/sortextable: add support for ET_DYN binaries arm64: futex.h: Add missing PAN toggling arm64: make asm/elf.h available to asm files arm64: avoid dynamic relocations in early boot code arm64: avoid R_AARCH64_ABS64 relocations for Image header fields arm64: add support for module PLTs arm64: move brk immediate argument definitions to separate header arm64: mm: use bit ops rather than arithmetic in pa/va translations arm64: mm: only perform memstart_addr sanity check if DEBUG_VM arm64: User die() instead of panic() in do_page_fault() arm64: allow kernel Image to be loaded anywhere in physical memory arm64: defer __va translation of initrd_start and initrd_end arm64: move kernel image to base of vmalloc area arm64: kvm: deal with kernel symbols outside of linear mapping arm64: decouple early fixmap init from linear mapping arm64: pgtable: implement static [pte|pmd|pud]_offset variants arm64: introduce KIMAGE_VADDR as the virtual base of the kernel region arm64: add support for ioremap() block mappings arm64: prevent potential circular header dependencies in asm/bug.h of/fdt: factor out assignment of initrd_start/initrd_end of/fdt: make memblock minimum physical address arch configurable arm64: Remove the get_thread_info() function arm64: kernel: Don't toggle PAN on systems with UAO arm64: cpufeature: Test 'matches' pointer to find the end of the list arm64: kernel: Add support for User Access Override arm64: add ARMv8.2 id_aa64mmfr2 boiler plate arm64: cpufeature: Change read_cpuid() to use sysreg's mrs_s macro arm64: use local label prefixes for __reg_num symbols arm64: vdso: Mark vDSO code as read-only arm64: ubsan: select ARCH_HAS_UBSAN_SANITIZE_ALL arm64: ptdump: Indicate whether memory should be faulting arm64: Add support for ARCH_SUPPORTS_DEBUG_PAGEALLOC arm64: Drop alloc function from create_mapping arm64: prefetch: add missing #include for spin_lock_prefetch arm64: lib: patch in prfm for copy_page if requested arm64: lib: improve copy_page to deal with 128 bytes at a time arm64: prefetch: add alternative pattern for CPUs without a prefetcher arm64: prefetch: don't provide spin_lock_prefetch with LSE arm64: allow vmalloc regions to be set with set_memory_* arm64: kernel: implement ACPI parking protocol arm64: mm: create new fine-grained mappings at boot arm64: ensure _stext and _etext are page-aligned arm64: mm: allow passing a pgdir to alloc_init_* arm64: mm: allocate pagetables anywhere arm64: mm: use fixmap when creating page tables arm64: mm: add functions to walk tables in fixmap arm64: mm: add __{pud,pgd}_populate arm64: mm: avoid redundant __pa(__va(x)) arm64: mm: add functions to walk page tables by PA arm64: mm: move pte_* macros arm64: kasan: avoid TLB conflicts arm64: mm: add code to safely replace TTBR1_EL1 arm64: add function to install the idmap arm64: unmap idmap earlier arm64: unify idmap removal arm64: mm: place empty_zero_page in bss arm64: mm: specialise pagetable allocators asm-generic: Fix local variable shadow in __set_fixmap_offset Eliminate the .eh_frame sections from the aarch64 vmlinux and kernel modules arm64: Fix an enum typo in mm/dump.c arm64: kasan: ensure that the KASAN zero page is mapped read-only arch/arm64/include/asm/pgtable.h: add pmd_mkclean for THP arm64: hide __efistub_ aliases from kallsyms Linux 4.4.10 drm/i915/skl: Fix DMC load on Skylake J0 and K0 lib/test-string_helpers.c: fix and improve string_get_size() tests ACPI / processor: Request native thermal interrupt handling via _OSC drm/i915: Fake HDMI live status drm/i915: Make RPS EI/thresholds multiple of 25 on SNB-BDW drm/i915: Fix eDP low vswing for Broadwell drm/i915/ddi: Fix eDP VDD handling during booting and suspend/resume drm/radeon: make sure vertical front porch is at least 1 iio: ak8975: fix maybe-uninitialized warning iio: ak8975: Fix NULL pointer exception on early interrupt drm/amdgpu: set metadata pointer to NULL after freeing. drm/amdgpu: make sure vertical front porch is at least 1 gpu: ipu-v3: Fix imx-ipuv3-crtc module autoloading nvmem: mxs-ocotp: fix buffer overflow in read USB: serial: cp210x: add Straizona Focusers device ids USB: serial: cp210x: add ID for Link ECU ata: ahci-platform: Add ports-implemented DT bindings. libahci: save port map for forced port map powerpc: Fix bad inline asm constraint in create_zero_mask() ACPICA: Dispatcher: Update thread ID for recursive method calls x86/sysfb_efi: Fix valid BAR address range check ARC: Add missing io barriers to io{read,write}{16,32}be() ARM: cpuidle: Pass on arm_cpuidle_suspend()'s return value propogate_mnt: Handle the first propogated copy being a slave fs/pnode.c: treat zero mnt_group_id-s as unequal x86/tsc: Read all ratio bits from MSR_PLATFORM_INFO MAINTAINERS: Remove asterisk from EFI directory names writeback: Fix performance regression in wb_over_bg_thresh() batman-adv: Reduce refcnt of removed router when updating route batman-adv: Fix broadcast/ogm queue limit on a removed interface batman-adv: Check skb size before using encapsulated ETH+VLAN header batman-adv: fix DAT candidate selection (must use vid) mm: update min_free_kbytes from khugepaged after core initialization proc: prevent accessing /proc/<PID>/environ until it's ready Input: zforce_ts - fix dual touch recognition HID: Fix boot delay for Creative SB Omni Surround 5.1 with quirk HID: wacom: Add support for DTK-1651 xen/evtchn: fix ring resize when binding new events xen/balloon: Fix crash when ballooning on x86 32 bit PAE xen: Fix page <-> pfn conversion on 32 bit systems ARM: SoCFPGA: Fix secondary CPU startup in thumb2 kernel ARM: EXYNOS: Properly skip unitialized parent clock in power domain on mm/zswap: provide unique zpool name mm, cma: prevent nr_isolated_* counters from going negative Minimal fix-up of bad hashing behavior of hash_64() MD: make bio mergeable tracing: Don't display trigger file for events that can't be enabled mac80211: fix statistics leak if dev_alloc_name() fails ath9k: ar5008_hw_cmn_spur_mitigate: add missing mask_m & mask_p initialisation lpfc: fix misleading indentation clk: qcom: msm8960: Fix ce3_src register offset clk: versatile: sp810: support reentrance clk: qcom: msm8960: fix ce3_core clk enable register clk: meson: Fix meson_clk_register_clks() signature type mismatch clk: rockchip: free memory in error cases when registering clock branches soc: rockchip: power-domain: fix err handle while probing clk-divider: make sure read-only dividers do not write to their register CNS3xxx: Fix PCI cns3xxx_write_config() mwifiex: fix corner case association failure ata: ahci_xgene: dereferencing uninitialized pointer in probe nbd: ratelimit error msgs after socket close mfd: intel-lpss: Remove clock tree on error path ipvs: drop first packet to redirect conntrack ipvs: correct initial offset of Call-ID header search in SIP persistence engine ipvs: handle ip_vs_fill_iph_skb_off failure RDMA/iw_cxgb4: Fix bar2 virt addr calculation for T4 chips Revert: "powerpc/tm: Check for already reclaimed tasks" arm64: head.S: use memset to clear BSS efi: stub: define DISABLE_BRANCH_PROFILING for all architectures arm64: entry: remove pointless SPSR mode check arm64: mm: move pgd_cache initialisation to pgtable_cache_init arm64: module: avoid undefined shift behavior in reloc_data() arm64: module: fix relocation of movz instruction with negative immediate arm64: traps: address fallout from printk -> pr_* conversion arm64: ftrace: fix a stack tracer's output under function graph tracer arm64: pass a task parameter to unwind_frame() arm64: ftrace: modify a stack frame in a safe way arm64: remove irq_count and do_softirq_own_stack() arm64: hugetlb: add support for PTE contiguous bit arm64: Use PoU cache instr for I/D coherency arm64: Defer dcache flush in __cpu_copy_user_page arm64: reduce stack use in irq_handler arm64: Documentation: add list of software workarounds for errata arm64: mm: place __cpu_setup in .text arm64: cmpxchg: Don't incldue linux/mmdebug.h arm64: mm: fold alternatives into .init arm64: Remove redundant padding from linker script arm64: mm: remove pointless PAGE_MASKing arm64: don't call C code with el0's fp register arm64: when walking onto the task stack, check sp & fp are in current->stack arm64: Add this_cpu_ptr() assembler macro for use in entry.S arm64: irq: fix walking from irq stack to task stack arm64: Add do_softirq_own_stack() and enable irq_stacks arm64: Modify stack trace and dump for use with irq_stack arm64: Store struct thread_info in sp_el0 arm64: Add trace_hardirqs_off annotation in ret_to_user arm64: ftrace: fix the comments for ftrace_modify_code arm64: ftrace: stop using kstop_machine to enable/disable tracing arm64: spinlock: serialise spin_unlock_wait against concurrent lockers arm64: enable HAVE_IRQ_TIME_ACCOUNTING arm64: fix COMPAT_SHMLBA definition for large pages arm64: add __init/__initdata section marker to some functions/variables arm64: pgtable: implement pte_accessible() arm64: mm: allow sections for unaligned bases arm64: mm: detect bad __create_mapping uses Linux 4.4.9 extcon: max77843: Use correct size for reading the interrupt register stm class: Select CONFIG_SRCU megaraid_sas: add missing curly braces in ioctl handler sunrpc/cache: drop reference when sunrpc_cache_pipe_upcall() detects a race thermal: rockchip: fix a impossible condition caused by the warning unbreak allmodconfig KCONFIG_ALLCONFIG=... jme: Fix device PM wakeup API usage jme: Do not enable NIC WoL functions on S0 bus: imx-weim: Take the 'status' property value into account ARM: dts: pxa: fix dma engine node to pxa3xx-nand ARM: dts: armada-375: use armada-370-sata for SATA ARM: EXYNOS: select THERMAL_OF ARM: prima2: always enable reset controller ARM: OMAP3: Add cpuidle parameters table for omap3430 ext4: fix races of writeback with punch hole and zero range ext4: fix races between buffered IO and collapse / insert range ext4: move unlocked dio protection from ext4_alloc_file_blocks() ext4: fix races between page faults and hole punching perf stat: Document --detailed option perf tools: handle spaces in file names obtained from /proc/pid/maps perf hists browser: Only offer symbol scripting when a symbol is under the cursor mtd: nand: Drop mtd.owner requirement in nand_scan mtd: brcmnand: Fix v7.1 register offsets mtd: spi-nor: remove micron_quad_enable() serial: sh-sci: Remove cpufreq notifier to fix crash/deadlock ext4: fix NULL pointer dereference in ext4_mark_inode_dirty() x86/mm/kmmio: Fix mmiotrace for hugepages perf evlist: Reference count the cpu and thread maps at set_maps() drivers/misc/ad525x_dpot: AD5274 fix RDAC read back errors rtc: max77686: Properly handle regmap_irq_get_virq() error code rtc: rx8025: remove rv8803 id rtc: ds1685: passing bogus values to irq_restore rtc: vr41xx: Wire up alarm_irq_enable rtc: hym8563: fix invalid year calculation PM / Domains: Fix removal of a subdomain PM / OPP: Initialize u_volt_min/max to a valid value misc: mic/scif: fix wrap around tests misc/bmp085: Enable building as a module lib/mpi: Endianness fix fbdev: da8xx-fb: fix videomodes of lcd panels scsi_dh: force modular build if SCSI is a module paride: make 'verbose' parameter an 'int' again regulator: s5m8767: fix get_register() error handling irqchip/mxs: Fix error check of of_io_request_and_map() irqchip/sunxi-nmi: Fix error check of of_io_request_and_map() spi/rockchip: Make sure spi clk is on in rockchip_spi_set_cs locking/mcs: Fix mcs_spin_lock() ordering regulator: core: Fix nested locking of supplies regulator: core: Ensure we lock all regulators regulator: core: fix regulator_lock_supply regression Revert "regulator: core: Fix nested locking of supplies" videobuf2-v4l2: Verify planes array in buffer dequeueing videobuf2-core: Check user space planes array in dqbuf USB: usbip: fix potential out-of-bounds write cgroup: make sure a parent css isn't freed before its children mm/hwpoison: fix wrong num_poisoned_pages accounting mm: vmscan: reclaim highmem zone if buffer_heads is over limit numa: fix /proc/<pid>/numa_maps for THP mm/huge_memory: replace VM_NO_THP VM_BUG_ON with actual VMA check memcg: relocate charge moving from ->attach to ->post_attach cgroup, cpuset: replace cpuset_post_attach_flush() with cgroup_subsys->post_attach callback slub: clean up code for kmem cgroup support to kmem_cache_free_bulk workqueue: fix ghost PENDING flag while doing MQ IO x86/apic: Handle zero vector gracefully in clear_vector_irq() efi: Expose non-blocking set_variable() wrapper to efivars efi: Fix out-of-bounds read in variable_matches() IB/security: Restrict use of the write() interface IB/mlx5: Expose correct max_sge_rd limit cxl: Keep IRQ mappings on context teardown v4l2-dv-timings.h: fix polarity for 4k formats vb2-memops: Fix over allocation of frame vectors ASoC: rt5640: Correct the digital interface data select ASoC: dapm: Make sure we have a card when displaying component widgets ASoC: ssm4567: Reset device before regcache_sync() ASoC: s3c24xx: use const snd_soc_component_driver pointer EDAC: i7core, sb_edac: Don't return NOTIFY_BAD from mce_decoder callback toshiba_acpi: Fix regression caused by hotkey enabling value i2c: exynos5: Fix possible ABBA deadlock by keeping I2C clock prepared i2c: cpm: Fix build break due to incompatible pointer types perf intel-pt: Fix segfault tracing transactions drm/i915: Use fw_domains_put_with_fifo() on HSW drm/i915: Fixup the free space logic in ring_prepare drm/amdkfd: uninitialized variable in dbgdev_wave_control_set_registers() drm/i915: skl_update_scaler() wants a rotation bitmask instead of bit number drm/i915: Cleanup phys status page too pwm: brcmstb: Fix check of devm_ioremap_resource() return code drm/dp/mst: Get validated port ref in drm_dp_update_payload_part1() drm/dp/mst: Restore primary hub guid on resume drm/dp/mst: Validate port in drm_dp_payload_send_msg() drm/nouveau/gr/gf100: select a stream master to fixup tfb offset queries drm: Loongson-3 doesn't fully support wc memory drm/radeon: fix vertical bars appear on monitor (v2) drm/radeon: forbid mapping of userptr bo through radeon device file drm/radeon: fix initial connector audio value drm/radeon: add a quirk for a XFX R9 270X drm/amdgpu: fix regression on CIK (v2) amdgpu/uvd: add uvd fw version for amdgpu drm/amdgpu: bump the afmt limit for CZ, ST, Polaris drm/amdgpu: use defines for CRTCs and AMFT blocks drm/amdgpu: when suspending, if uvd/vce was running. need to cancel delay work. iommu/dma: Restore scatterlist offsets correctly iommu/amd: Fix checking of pci dma aliases pinctrl: single: Fix pcs_parse_bits_in_pinctrl_entry to use __ffs than ffs pinctrl: mediatek: correct debounce time unit in mtk_gpio_set_debounce xen kconfig: don't "select INPUT_XEN_KBDDEV_FRONTEND" Input: pmic8xxx-pwrkey - fix algorithm for converting trigger delay Input: gtco - fix crash on detecting device without endpoints netlink: don't send NETLINK_URELEASE for unbound sockets nl80211: check netlink protocol in socket release notification powerpc: Update TM user feature bits in scan_features() powerpc: Update cpu_user_features2 in scan_features() powerpc: scan_features() updates incorrect bits for REAL_LE crypto: talitos - fix AEAD tcrypt tests crypto: talitos - fix crash in talitos_cra_init() crypto: sha1-mb - use corrcet pointer while completing jobs crypto: ccp - Prevent information leakage on export iwlwifi: mvm: fix memory leak in paging iwlwifi: pcie: lower the debug level for RSA semaphore access s390/pci: add extra padding to function measurement block cpufreq: intel_pstate: Fix processing for turbo activation ratio Revert "drm/amdgpu: disable runtime pm on PX laptops without dGPU power control" Revert "drm/radeon: disable runtime pm on PX laptops without dGPU power control" drm/i915: Fix race condition in intel_dp_destroy_mst_connector() drm/qxl: fix cursor position with non-zero hotspot drm/nouveau/core: use vzalloc for allocating ramht futex: Acknowledge a new waiter in counter before plist futex: Handle unlock_pi race gracefully asm-generic/futex: Re-enable preemption in futex_atomic_cmpxchg_inatomic() ALSA: hda - Add dock support for ThinkPad X260 ALSA: pcxhr: Fix missing mutex unlock ALSA: hda - add PCI ID for Intel Broxton-T ALSA: hda - Keep powering up ADCs on Cirrus codecs ALSA: hda/realtek - Add ALC3234 headset mode for Optiplex 9020m ALSA: hda - Don't trust the reported actual power state x86 EDAC, sb_edac.c: Repair damage introduced when "fixing" channel address x86/mm/xen: Suppress hugetlbfs in PV guests arm64: Update PTE_RDONLY in set_pte_at() for PROT_NONE permission arm64: Honour !PTE_WRITE in set_pte_at() for kernel mappings sched/cgroup: Fix/cleanup cgroup teardown/init dmaengine: pxa_dma: fix the maximum requestor line dmaengine: hsu: correct use of channel status register dmaengine: dw: fix master selection debugfs: Make automount point inodes permanently empty lib: lz4: fixed zram with lz4 on big endian machines dm cache metadata: fix cmd_read_lock() acquiring write lock dm cache metadata: fix READ_LOCK macros and cleanup WRITE_LOCK macros usb: gadget: f_fs: Fix use-after-free usb: hcd: out of bounds access in for_each_companion xhci: fix 10 second timeout on removal of PCI hotpluggable xhci controllers usb: xhci: fix wild pointers in xhci_mem_cleanup xhci: resume USB 3 roothub first usb: xhci: applying XHCI_PME_STUCK_QUIRK to Intel BXT B0 host assoc_array: don't call compare_object() on a node ARM: OMAP2+: hwmod: Fix updating of sysconfig register ARM: OMAP2: Fix up interconnect barrier initialization for DRA7 ARM: mvebu: Correct unit address for linksys ARM: dts: AM43x-epos: Fix clk parent for synctimer KVM: arm/arm64: Handle forward time correction gracefully kvm: x86: do not leak guest xcr0 into host interrupt handlers x86/mce: Avoid using object after free in genpool block: loop: fix filesystem corruption in case of aio/dio block: partition: initialize percpuref before sending out KOBJ_ADD Conflicts: arch/arm64/Kconfig arch/arm64/include/asm/cputype.h arch/arm64/include/asm/hardirq.h arch/arm64/include/asm/irq.h arch/arm64/include/asm/mmu_context.h arch/arm64/kernel/cpu_errata.c arch/arm64/kernel/cpuinfo.c arch/arm64/kernel/setup.c arch/arm64/kernel/smp.c arch/arm64/kernel/stacktrace.c arch/arm64/mm/init.c arch/arm64/mm/mmu.c arch/arm64/mm/pageattr.c mm/memcontrol.c CRs-Fixed: 1069136 Signed-off-by: Bryan Huntsman <bryanh@codeaurora.org> Signed-off-by: Runmin Wang <runminw@codeaurora.org> Change-Id: Ie9a16debd0578331a66947376f3b787a7bb54d65
2016-09-24vmstat: Add cpu isolation awarenessOlav Haugan
Ensure vmstat updates do not run on isolated cpus. Change-Id: I401de0b52fa6d20573187265ee56edd543b1419e Signed-off-by: Olav Haugan <ohaugan@codeaurora.org>
2016-09-12Merge branch 'tmp-bab1564' into msm-4.4Runmin Wang
* tmp-bab1564: ANDROID: mmc: Add CONFIG_MMC_SIMULATE_MAX_SPEED android: base-cfg: Add CONFIG_INET_DIAG_DESTROY cpufreq: interactive: only apply interactive boost when enabled cpufreq: interactive: fix policy locking ANDROID: dm verity fec: add sysfs attribute fec/corrected ANDROID: android: base-cfg: enable CONFIG_DM_VERITY_FEC UPSTREAM: dm verity: add ignore_zero_blocks feature UPSTREAM: dm verity: add support for forward error correction UPSTREAM: dm verity: factor out verity_for_bv_block() UPSTREAM: dm verity: factor out structures and functions useful to separate object UPSTREAM: dm verity: move dm-verity.c to dm-verity-target.c UPSTREAM: dm verity: separate function for parsing opt args UPSTREAM: dm verity: clean up duplicate hashing code UPSTREAM: dm: don't save and restore bi_private mm: Export do_munmap sdcardfs: remove unneeded __init and __exit sdcardfs: Remove unused code fs: Export d_absolute_path sdcardfs: remove effectless config option inotify: Fix erroneous update of bit count fs: sdcardfs: Declare LOOKUP_CASE_INSENSITIVE unconditionally trace: cpufreq: fix typo in min/max cpufreq sdcardfs: Add support for d_canonical_path vfs: add d_canonical_path for stacked filesystem support sdcardfs: Bring up to date with Android M permissions: Changed type-casting in packagelist management Port of sdcardfs to 4.4 Included sdcardfs source code for kernel 3.0 ANDROID: usb: gadget: Add support for MTP OS desc CHROMIUM: usb: gadget: f_accessory: add .raw_request callback CHROMIUM: usb: gadget: audio_source: add .free_func callback CHROMIUM: usb: gadget: f_mtp: fix usb_ss_ep_comp_descriptor CHROMIUM: usb: gadget: f_mtp: Add SuperSpeed support FROMLIST: mmc: block: fix ABI regression of mmc_blk_ioctl FROMLIST: mm: ASLR: use get_random_long() FROMLIST: drivers: char: random: add get_random_long() FROMLIST: pstore-ram: fix NULL reference when used with pdata usb: u_ether: Add missing rx_work init ANDROID: dm-crypt: run in a WQ_HIGHPRI workqueue misc: uid_stat: Include linux/atomic.h instead of asm/atomic.h hid-sensor-hub.c: fix wrong do_div() usage power: Provide dummy log_suspend_abort_reason() if SUSPEND is disabled PM / suspend: Add dependency on RTC_LIB drivers: power: use 'current' instead of 'get_current()' video: adf: Set ADF_MEMBLOCK to boolean video: adf: Fix modular build net: ppp: Fix modular build for PPPOLAC and PPPOPNS net: pppolac/pppopns: Replace msg.msg_iov with iov_iter_kvec() ANDROID: mmc: sdio: Disable retuning in sdio_reset_comm() ANDROID: mmc: Move tracepoint creation and export symbols ANDROID: kernel/watchdog: fix unused variable warning ANDROID: usb: gadget: f_mtp: don't use le16 for u8 field ANDROID: lowmemorykiller: fix declaration order warnings ANDROID: net: fix 'const' warnings net: diag: support v4mapped sockets in inet_diag_find_one_icsk() net: tcp: deal with listen sockets properly in tcp_abort. tcp: diag: add support for request sockets to tcp_abort() net: diag: Support destroying TCP sockets. net: diag: Support SOCK_DESTROY for inet sockets. net: diag: Add the ability to destroy a socket. net: diag: split inet_diag_dump_one_icsk into two Revert "mmc: Extend wakelock if bus is dead" Revert "mmc: core: Hold a wake lock accross delayed work + mmc rescan" ANDROID: mmc: move to a SCHED_FIFO thread Conflicts: drivers/cpufreq/cpufreq_interactive.c drivers/misc/uid_stat.c drivers/mmc/card/block.c drivers/mmc/card/queue.c drivers/mmc/card/queue.h drivers/mmc/core/core.c drivers/mmc/core/sdio.c drivers/staging/android/lowmemorykiller.c drivers/usb/gadget/function/f_mtp.c kernel/watchdog.c Signed-off-by: Runmin Wang <runminw@codeaurora.org> Change-Id: Ibb4db11c57395f67dee86211a110c462e6181552
2016-08-29Merge "Revert "Merge remote-tracking branch 'msm-4.4/tmp-510d0a3f' into ↵Linux Build Service Account
msm-4.4""
2016-08-26Revert "Merge remote-tracking branch 'msm-4.4/tmp-510d0a3f' into msm-4.4"Trilok Soni
This reverts commit 9d6fd2c3e9fcfb ("Merge remote-tracking branch 'msm-4.4/tmp-510d0a3f' into msm-4.4"), because it breaks the dump parsing tools due to kernel can be loaded anywhere in the memory now and not fixed at linear mapping. Change-Id: Id416f0a249d803442847d09ac47781147b0d0ee6 Signed-off-by: Trilok Soni <tsoni@codeaurora.org>
2016-08-25mm: zbud: fix the locking scenarios with zcacheVinayak Menon
With zcache using zbud, strange locking scenarios are observed. The first problem seen is: Core 2 waiting on mapping->tree_lock which is taken by core 6 do_raw_spin_lock raw_spin_lock_irq atomic_cmpxchg page_freeze_refs __remove_mapping shrink_page_list Core 6 after taking mapping->tree_lock is waiting on zbud pool lock which is held by core 5 zbud_alloc zcache_store_page __cleancache_put_page cleancache_put_page __delete_from_page_cache spin_unlock_irq __remove_mapping shrink_page_list shrink_inactive_list Core 5 after taking zbud pool lock from zbud_free received an IRQ, and after IRQ exit, softirqs were scheduled and end_page_writeback tried to lock on mapping->tree_lock which is already held by Core 6. Deadlock. do_raw_spin_lock raw_spin_lock_irqsave test_clear_page_writeba end_page_writeback ext4_finish_bio ext4_end_bio bio_endio blk_update_request end_clone_bio bio_endio blk_update_request blk_update_bidi_request blk_end_bidi_request blk_end_request mmc_blk_cmdq_complete_r mmc_cmdq_softirq_done blk_done_softirq static_key_count static_key_false trace_softirq_exit __do_softirq() tick_irq_exit irq_exit() set_irq_regs __handle_domain_irq gic_handle_irq el1_irq exception __list_del_entry list_del zbud_free zcache_load_page __cleancache_get_page(? This shows that allowing softirqs while holding zbud pool lock can result in deadlocks. To fix this, 'commit 6a1fdaa36272 ("mm: zbud: prevent softirq during zbud alloc, free and reclaim")' decided to take spin_lock_bh during zbud_free, zbud_alloc and zbud_reclaim. But this resulted in another deadlock. spin_bug() do_raw_spin_lock() _raw_spin_lock_irqsave() test_clear_page_writeback() end_page_writeback() ext4_finish_bio() ext4_end_bio() bio_endio() blk_update_request() end_clone_bio() bio_endio() blk_update_request() blk_update_bidi_request() blk_end_request() mmc_blk_cmdq_complete_rq() mmc_cmdq_softirq_done() blk_done_softirq() __do_softirq() do_softirq() __local_bh_enable_ip() _raw_spin_unlock_bh() zbud_alloc() zcache_store_page() __cleancache_put_page() __delete_from_page_cache() __remove_mapping() shrink_page_list() Here, the spin_unlock_bh resulted in explicit invocation of do_sofirq, which resulted in the acquisition of mapping->tree_lock which was already taken by __remove_mapping. The new fix considers the following facts. 1) zcache_store_page is always be called from __delete_from_page_cache with mapping->tree_lock held and interrupts disabled. Thus zbud_alloc which is called only from zcache_store_page is always called with interrupts disabled. 2) zbud_free and zbud_reclaim_page can be called from zcache with or without interrupts disabled. So an interrupt while holding zbud pool lock can result in do_softirq and acquisition of mapping->tree_lock. (1) implies zbud_alloc need not explicitly disable bh. But disable interrupts to make sure zbud_alloc is safe with zcache, irrespective of future changes. This will fix the second scenario. (2) implies zbud_free and zbud_reclaim_page should use spin_lock_irqsave, so that interrupts will not be triggered and inturn softirqs. spin_lock_bh can't be used because a spin_unlock_bh can triger a softirq even in interrupt context. This will fix the first scenario. Change-Id: Ibc810525dddf97614db41643642fec7472bd6a2c Signed-off-by: Vinayak Menon <vinmenon@codeaurora.org>
2016-08-18Merge remote-tracking branch 'msm-4.4/tmp-510d0a3f' into msm-4.4Trilok Soni
* msm-4.4/tmp-510d0a3f: Linux 4.4.11 nf_conntrack: avoid kernel pointer value leak in slab name drm/radeon: fix DP link training issue with second 4K monitor drm/i915/bdw: Add missing delay during L3 SQC credit programming drm/i915: Bail out of pipe config compute loop on LPT drm/radeon: fix PLL sharing on DCE6.1 (v2) Revert "[media] videobuf2-v4l2: Verify planes array in buffer dequeueing" Input: max8997-haptic - fix NULL pointer dereference get_rock_ridge_filename(): handle malformed NM entries tools lib traceevent: Do not reassign parg after collapse_tree() qla1280: Don't allocate 512kb of host tags atomic_open(): fix the handling of create_error regulator: axp20x: Fix axp22x ldo_io voltage ranges regulator: s2mps11: Fix invalid selector mask and voltages for buck9 workqueue: fix rebind bound workers warning ARM: dts: at91: sam9x5: Fix the memory range assigned to the PMC vfs: rename: check backing inode being equal vfs: add vfs_select_inode() helper perf/core: Disable the event on a truncated AUX record regmap: spmi: Fix regmap_spmi_ext_read in multi-byte case pinctrl: at91-pio4: fix pull-up/down logic spi: spi-ti-qspi: Handle truncated frames properly spi: spi-ti-qspi: Fix FLEN and WLEN settings if bits_per_word is overridden spi: pxa2xx: Do not detect number of enabled chip selects on Intel SPT ALSA: hda - Fix broken reconfig ALSA: hda - Fix white noise on Asus UX501VW headset ALSA: hda - Fix subwoofer pin on ASUS N751 and N551 ALSA: usb-audio: Yet another Phoneix Audio device quirk ALSA: usb-audio: Quirk for yet another Phoenix Audio devices (v2) crypto: testmgr - Use kmalloc memory for RSA input crypto: hash - Fix page length clamping in hash walk crypto: qat - fix invalid pf2vf_resp_wq logic s390/mm: fix asce_bits handling with dynamic pagetable levels zsmalloc: fix zs_can_compact() integer overflow ocfs2: fix posix_acl_create deadlock ocfs2: revert using ocfs2_acl_chmod to avoid inode cluster lock hang net/route: enforce hoplimit max value tcp: refresh skb timestamp at retransmit time net: thunderx: avoid exposing kernel stack net: fix a kernel infoleak in x25 module uapi glibc compat: fix compile errors when glibc net/if.h included before linux/if.h MIME-Version: 1.0 bridge: fix igmp / mld query parsing net: bridge: fix old ioctl unlocked net device walk VSOCK: do not disconnect socket when peer has shutdown SEND only net/mlx4_en: Fix endianness bug in IPV6 csum calculation net: fix infoleak in rtnetlink net: fix infoleak in llc net: fec: only clear a queue's work bit if the queue was emptied netem: Segment GSO packets on enqueue sch_dsmark: update backlog as well sch_htb: update backlog as well net_sched: update hierarchical backlog too net_sched: introduce qdisc_replace() helper gre: do not pull header in ICMP error processing net: Implement net_dbg_ratelimited() for CONFIG_DYNAMIC_DEBUG case samples/bpf: fix trace_output example bpf: fix check_map_func_compatibility logic bpf: fix refcnt overflow bpf: fix double-fdput in replace_map_fd_with_map_ptr() net/mlx4_en: fix spurious timestamping callbacks ipv4/fib: don't warn when primary address is missing if in_dev is dead net/mlx5e: Fix minimum MTU net/mlx5e: Device's mtu field is u16 and not int openvswitch: use flow protocol when recalculating ipv6 checksums atl2: Disable unimplemented scatter/gather feature vlan: pull on __vlan_insert_tag error path and fix csum correction net: use skb_postpush_rcsum instead of own implementations cdc_mbim: apply "NDP to end" quirk to all Huawei devices bpf/verifier: reject invalid LD_ABS | BPF_DW instruction net: sched: do not requeue a NULL skb packet: fix heap info leak in PACKET_DIAG_MCLIST sock_diag interface route: do not cache fib route info on local routes with oif decnet: Do not build routes to devices without decnet private data. parisc: Use generic extable search and sort routines arm64: kasan: Use actual memory node when populating the kernel image shadow arm64: mm: treat memstart_addr as a signed quantity arm64: lse: deal with clobbered IP registers after branch via PLT arm64: mm: check at build time that PAGE_OFFSET divides the VA space evenly arm64: kasan: Fix zero shadow mapping overriding kernel image shadow arm64: consistently use p?d_set_huge arm64: fix KASLR boot-time I-cache maintenance arm64: hugetlb: partial revert of 66b3923a1a0f arm64: make irq_stack_ptr more robust arm64: efi: invoke EFI_RNG_PROTOCOL to supply KASLR randomness efi: stub: use high allocation for converted command line efi: stub: add implementation of efi_random_alloc() efi: stub: implement efi_get_random_bytes() based on EFI_RNG_PROTOCOL arm64: kaslr: randomize the linear region arm64: add support for kernel ASLR arm64: add support for building vmlinux as a relocatable PIE binary arm64: switch to relative exception tables extable: add support for relative extables to search and sort routines scripts/sortextable: add support for ET_DYN binaries arm64: futex.h: Add missing PAN toggling arm64: make asm/elf.h available to asm files arm64: avoid dynamic relocations in early boot code arm64: avoid R_AARCH64_ABS64 relocations for Image header fields arm64: add support for module PLTs arm64: move brk immediate argument definitions to separate header arm64: mm: use bit ops rather than arithmetic in pa/va translations arm64: mm: only perform memstart_addr sanity check if DEBUG_VM arm64: User die() instead of panic() in do_page_fault() arm64: allow kernel Image to be loaded anywhere in physical memory arm64: defer __va translation of initrd_start and initrd_end arm64: move kernel image to base of vmalloc area arm64: kvm: deal with kernel symbols outside of linear mapping arm64: decouple early fixmap init from linear mapping arm64: pgtable: implement static [pte|pmd|pud]_offset variants arm64: introduce KIMAGE_VADDR as the virtual base of the kernel region arm64: add support for ioremap() block mappings arm64: prevent potential circular header dependencies in asm/bug.h of/fdt: factor out assignment of initrd_start/initrd_end of/fdt: make memblock minimum physical address arch configurable arm64: Remove the get_thread_info() function arm64: kernel: Don't toggle PAN on systems with UAO arm64: cpufeature: Test 'matches' pointer to find the end of the list arm64: kernel: Add support for User Access Override arm64: add ARMv8.2 id_aa64mmfr2 boiler plate arm64: cpufeature: Change read_cpuid() to use sysreg's mrs_s macro arm64: use local label prefixes for __reg_num symbols arm64: vdso: Mark vDSO code as read-only arm64: ubsan: select ARCH_HAS_UBSAN_SANITIZE_ALL arm64: ptdump: Indicate whether memory should be faulting arm64: Add support for ARCH_SUPPORTS_DEBUG_PAGEALLOC arm64: Drop alloc function from create_mapping arm64: prefetch: add missing #include for spin_lock_prefetch arm64: lib: patch in prfm for copy_page if requested arm64: lib: improve copy_page to deal with 128 bytes at a time arm64: prefetch: add alternative pattern for CPUs without a prefetcher arm64: prefetch: don't provide spin_lock_prefetch with LSE arm64: allow vmalloc regions to be set with set_memory_* arm64: kernel: implement ACPI parking protocol arm64: mm: create new fine-grained mappings at boot arm64: ensure _stext and _etext are page-aligned arm64: mm: allow passing a pgdir to alloc_init_* arm64: mm: allocate pagetables anywhere arm64: mm: use fixmap when creating page tables arm64: mm: add functions to walk tables in fixmap arm64: mm: add __{pud,pgd}_populate arm64: mm: avoid redundant __pa(__va(x)) arm64: mm: add functions to walk page tables by PA arm64: mm: move pte_* macros arm64: kasan: avoid TLB conflicts arm64: mm: add code to safely replace TTBR1_EL1 arm64: add function to install the idmap arm64: unmap idmap earlier arm64: unify idmap removal arm64: mm: place empty_zero_page in bss arm64: mm: specialise pagetable allocators asm-generic: Fix local variable shadow in __set_fixmap_offset Eliminate the .eh_frame sections from the aarch64 vmlinux and kernel modules arm64: Fix an enum typo in mm/dump.c arm64: kasan: ensure that the KASAN zero page is mapped read-only arch/arm64/include/asm/pgtable.h: add pmd_mkclean for THP arm64: hide __efistub_ aliases from kallsyms Linux 4.4.10 drm/i915/skl: Fix DMC load on Skylake J0 and K0 lib/test-string_helpers.c: fix and improve string_get_size() tests ACPI / processor: Request native thermal interrupt handling via _OSC drm/i915: Fake HDMI live status drm/i915: Make RPS EI/thresholds multiple of 25 on SNB-BDW drm/i915: Fix eDP low vswing for Broadwell drm/i915/ddi: Fix eDP VDD handling during booting and suspend/resume drm/radeon: make sure vertical front porch is at least 1 iio: ak8975: fix maybe-uninitialized warning iio: ak8975: Fix NULL pointer exception on early interrupt drm/amdgpu: set metadata pointer to NULL after freeing. drm/amdgpu: make sure vertical front porch is at least 1 gpu: ipu-v3: Fix imx-ipuv3-crtc module autoloading nvmem: mxs-ocotp: fix buffer overflow in read USB: serial: cp210x: add Straizona Focusers device ids USB: serial: cp210x: add ID for Link ECU ata: ahci-platform: Add ports-implemented DT bindings. libahci: save port map for forced port map powerpc: Fix bad inline asm constraint in create_zero_mask() ACPICA: Dispatcher: Update thread ID for recursive method calls x86/sysfb_efi: Fix valid BAR address range check ARC: Add missing io barriers to io{read,write}{16,32}be() ARM: cpuidle: Pass on arm_cpuidle_suspend()'s return value propogate_mnt: Handle the first propogated copy being a slave fs/pnode.c: treat zero mnt_group_id-s as unequal x86/tsc: Read all ratio bits from MSR_PLATFORM_INFO MAINTAINERS: Remove asterisk from EFI directory names writeback: Fix performance regression in wb_over_bg_thresh() batman-adv: Reduce refcnt of removed router when updating route batman-adv: Fix broadcast/ogm queue limit on a removed interface batman-adv: Check skb size before using encapsulated ETH+VLAN header batman-adv: fix DAT candidate selection (must use vid) mm: update min_free_kbytes from khugepaged after core initialization proc: prevent accessing /proc/<PID>/environ until it's ready Input: zforce_ts - fix dual touch recognition HID: Fix boot delay for Creative SB Omni Surround 5.1 with quirk HID: wacom: Add support for DTK-1651 xen/evtchn: fix ring resize when binding new events xen/balloon: Fix crash when ballooning on x86 32 bit PAE xen: Fix page <-> pfn conversion on 32 bit systems ARM: SoCFPGA: Fix secondary CPU startup in thumb2 kernel ARM: EXYNOS: Properly skip unitialized parent clock in power domain on mm/zswap: provide unique zpool name mm, cma: prevent nr_isolated_* counters from going negative Minimal fix-up of bad hashing behavior of hash_64() MD: make bio mergeable tracing: Don't display trigger file for events that can't be enabled mac80211: fix statistics leak if dev_alloc_name() fails ath9k: ar5008_hw_cmn_spur_mitigate: add missing mask_m & mask_p initialisation lpfc: fix misleading indentation clk: qcom: msm8960: Fix ce3_src register offset clk: versatile: sp810: support reentrance clk: qcom: msm8960: fix ce3_core clk enable register clk: meson: Fix meson_clk_register_clks() signature type mismatch clk: rockchip: free memory in error cases when registering clock branches soc: rockchip: power-domain: fix err handle while probing clk-divider: make sure read-only dividers do not write to their register CNS3xxx: Fix PCI cns3xxx_write_config() mwifiex: fix corner case association failure ata: ahci_xgene: dereferencing uninitialized pointer in probe nbd: ratelimit error msgs after socket close mfd: intel-lpss: Remove clock tree on error path ipvs: drop first packet to redirect conntrack ipvs: correct initial offset of Call-ID header search in SIP persistence engine ipvs: handle ip_vs_fill_iph_skb_off failure RDMA/iw_cxgb4: Fix bar2 virt addr calculation for T4 chips Revert: "powerpc/tm: Check for already reclaimed tasks" arm64: head.S: use memset to clear BSS efi: stub: define DISABLE_BRANCH_PROFILING for all architectures arm64: entry: remove pointless SPSR mode check arm64: mm: move pgd_cache initialisation to pgtable_cache_init arm64: module: avoid undefined shift behavior in reloc_data() arm64: module: fix relocation of movz instruction with negative immediate arm64: traps: address fallout from printk -> pr_* conversion arm64: ftrace: fix a stack tracer's output under function graph tracer arm64: pass a task parameter to unwind_frame() arm64: ftrace: modify a stack frame in a safe way arm64: remove irq_count and do_softirq_own_stack() arm64: hugetlb: add support for PTE contiguous bit arm64: Use PoU cache instr for I/D coherency arm64: Defer dcache flush in __cpu_copy_user_page arm64: reduce stack use in irq_handler arm64: Documentation: add list of software workarounds for errata arm64: mm: place __cpu_setup in .text arm64: cmpxchg: Don't incldue linux/mmdebug.h arm64: mm: fold alternatives into .init arm64: Remove redundant padding from linker script arm64: mm: remove pointless PAGE_MASKing arm64: don't call C code with el0's fp register arm64: when walking onto the task stack, check sp & fp are in current->stack arm64: Add this_cpu_ptr() assembler macro for use in entry.S arm64: irq: fix walking from irq stack to task stack arm64: Add do_softirq_own_stack() and enable irq_stacks arm64: Modify stack trace and dump for use with irq_stack arm64: Store struct thread_info in sp_el0 arm64: Add trace_hardirqs_off annotation in ret_to_user arm64: ftrace: fix the comments for ftrace_modify_code arm64: ftrace: stop using kstop_machine to enable/disable tracing arm64: spinlock: serialise spin_unlock_wait against concurrent lockers arm64: enable HAVE_IRQ_TIME_ACCOUNTING arm64: fix COMPAT_SHMLBA definition for large pages arm64: add __init/__initdata section marker to some functions/variables arm64: pgtable: implement pte_accessible() arm64: mm: allow sections for unaligned bases arm64: mm: detect bad __create_mapping uses Linux 4.4.9 extcon: max77843: Use correct size for reading the interrupt register stm class: Select CONFIG_SRCU megaraid_sas: add missing curly braces in ioctl handler sunrpc/cache: drop reference when sunrpc_cache_pipe_upcall() detects a race thermal: rockchip: fix a impossible condition caused by the warning unbreak allmodconfig KCONFIG_ALLCONFIG=... jme: Fix device PM wakeup API usage jme: Do not enable NIC WoL functions on S0 bus: imx-weim: Take the 'status' property value into account ARM: dts: pxa: fix dma engine node to pxa3xx-nand ARM: dts: armada-375: use armada-370-sata for SATA ARM: EXYNOS: select THERMAL_OF ARM: prima2: always enable reset controller ARM: OMAP3: Add cpuidle parameters table for omap3430 ext4: fix races of writeback with punch hole and zero range ext4: fix races between buffered IO and collapse / insert range ext4: move unlocked dio protection from ext4_alloc_file_blocks() ext4: fix races between page faults and hole punching perf stat: Document --detailed option perf tools: handle spaces in file names obtained from /proc/pid/maps perf hists browser: Only offer symbol scripting when a symbol is under the cursor mtd: nand: Drop mtd.owner requirement in nand_scan mtd: brcmnand: Fix v7.1 register offsets mtd: spi-nor: remove micron_quad_enable() serial: sh-sci: Remove cpufreq notifier to fix crash/deadlock ext4: fix NULL pointer dereference in ext4_mark_inode_dirty() x86/mm/kmmio: Fix mmiotrace for hugepages perf evlist: Reference count the cpu and thread maps at set_maps() drivers/misc/ad525x_dpot: AD5274 fix RDAC read back errors rtc: max77686: Properly handle regmap_irq_get_virq() error code rtc: rx8025: remove rv8803 id rtc: ds1685: passing bogus values to irq_restore rtc: vr41xx: Wire up alarm_irq_enable rtc: hym8563: fix invalid year calculation PM / Domains: Fix removal of a subdomain PM / OPP: Initialize u_volt_min/max to a valid value misc: mic/scif: fix wrap around tests misc/bmp085: Enable building as a module lib/mpi: Endianness fix fbdev: da8xx-fb: fix videomodes of lcd panels scsi_dh: force modular build if SCSI is a module paride: make 'verbose' parameter an 'int' again regulator: s5m8767: fix get_register() error handling irqchip/mxs: Fix error check of of_io_request_and_map() irqchip/sunxi-nmi: Fix error check of of_io_request_and_map() spi/rockchip: Make sure spi clk is on in rockchip_spi_set_cs locking/mcs: Fix mcs_spin_lock() ordering regulator: core: Fix nested locking of supplies regulator: core: Ensure we lock all regulators regulator: core: fix regulator_lock_supply regression Revert "regulator: core: Fix nested locking of supplies" videobuf2-v4l2: Verify planes array in buffer dequeueing videobuf2-core: Check user space planes array in dqbuf USB: usbip: fix potential out-of-bounds write cgroup: make sure a parent css isn't freed before its children mm/hwpoison: fix wrong num_poisoned_pages accounting mm: vmscan: reclaim highmem zone if buffer_heads is over limit numa: fix /proc/<pid>/numa_maps for THP mm/huge_memory: replace VM_NO_THP VM_BUG_ON with actual VMA check memcg: relocate charge moving from ->attach to ->post_attach cgroup, cpuset: replace cpuset_post_attach_flush() with cgroup_subsys->post_attach callback slub: clean up code for kmem cgroup support to kmem_cache_free_bulk workqueue: fix ghost PENDING flag while doing MQ IO x86/apic: Handle zero vector gracefully in clear_vector_irq() efi: Expose non-blocking set_variable() wrapper to efivars efi: Fix out-of-bounds read in variable_matches() IB/security: Restrict use of the write() interface IB/mlx5: Expose correct max_sge_rd limit cxl: Keep IRQ mappings on context teardown v4l2-dv-timings.h: fix polarity for 4k formats vb2-memops: Fix over allocation of frame vectors ASoC: rt5640: Correct the digital interface data select ASoC: dapm: Make sure we have a card when displaying component widgets ASoC: ssm4567: Reset device before regcache_sync() ASoC: s3c24xx: use const snd_soc_component_driver pointer EDAC: i7core, sb_edac: Don't return NOTIFY_BAD from mce_decoder callback toshiba_acpi: Fix regression caused by hotkey enabling value i2c: exynos5: Fix possible ABBA deadlock by keeping I2C clock prepared i2c: cpm: Fix build break due to incompatible pointer types perf intel-pt: Fix segfault tracing transactions drm/i915: Use fw_domains_put_with_fifo() on HSW drm/i915: Fixup the free space logic in ring_prepare drm/amdkfd: uninitialized variable in dbgdev_wave_control_set_registers() drm/i915: skl_update_scaler() wants a rotation bitmask instead of bit number drm/i915: Cleanup phys status page too pwm: brcmstb: Fix check of devm_ioremap_resource() return code drm/dp/mst: Get validated port ref in drm_dp_update_payload_part1() drm/dp/mst: Restore primary hub guid on resume drm/dp/mst: Validate port in drm_dp_payload_send_msg() drm/nouveau/gr/gf100: select a stream master to fixup tfb offset queries drm: Loongson-3 doesn't fully support wc memory drm/radeon: fix vertical bars appear on monitor (v2) drm/radeon: forbid mapping of userptr bo through radeon device file drm/radeon: fix initial connector audio value drm/radeon: add a quirk for a XFX R9 270X drm/amdgpu: fix regression on CIK (v2) amdgpu/uvd: add uvd fw version for amdgpu drm/amdgpu: bump the afmt limit for CZ, ST, Polaris drm/amdgpu: use defines for CRTCs and AMFT blocks drm/amdgpu: when suspending, if uvd/vce was running. need to cancel delay work. iommu/dma: Restore scatterlist offsets correctly iommu/amd: Fix checking of pci dma aliases pinctrl: single: Fix pcs_parse_bits_in_pinctrl_entry to use __ffs than ffs pinctrl: mediatek: correct debounce time unit in mtk_gpio_set_debounce xen kconfig: don't "select INPUT_XEN_KBDDEV_FRONTEND" Input: pmic8xxx-pwrkey - fix algorithm for converting trigger delay Input: gtco - fix crash on detecting device without endpoints netlink: don't send NETLINK_URELEASE for unbound sockets nl80211: check netlink protocol in socket release notification powerpc: Update TM user feature bits in scan_features() powerpc: Update cpu_user_features2 in scan_features() powerpc: scan_features() updates incorrect bits for REAL_LE crypto: talitos - fix AEAD tcrypt tests crypto: talitos - fix crash in talitos_cra_init() crypto: sha1-mb - use corrcet pointer while completing jobs crypto: ccp - Prevent information leakage on export iwlwifi: mvm: fix memory leak in paging iwlwifi: pcie: lower the debug level for RSA semaphore access s390/pci: add extra padding to function measurement block cpufreq: intel_pstate: Fix processing for turbo activation ratio Revert "drm/amdgpu: disable runtime pm on PX laptops without dGPU power control" Revert "drm/radeon: disable runtime pm on PX laptops without dGPU power control" drm/i915: Fix race condition in intel_dp_destroy_mst_connector() drm/qxl: fix cursor position with non-zero hotspot drm/nouveau/core: use vzalloc for allocating ramht futex: Acknowledge a new waiter in counter before plist futex: Handle unlock_pi race gracefully asm-generic/futex: Re-enable preemption in futex_atomic_cmpxchg_inatomic() ALSA: hda - Add dock support for ThinkPad X260 ALSA: pcxhr: Fix missing mutex unlock ALSA: hda - add PCI ID for Intel Broxton-T ALSA: hda - Keep powering up ADCs on Cirrus codecs ALSA: hda/realtek - Add ALC3234 headset mode for Optiplex 9020m ALSA: hda - Don't trust the reported actual power state x86 EDAC, sb_edac.c: Repair damage introduced when "fixing" channel address x86/mm/xen: Suppress hugetlbfs in PV guests arm64: Update PTE_RDONLY in set_pte_at() for PROT_NONE permission arm64: Honour !PTE_WRITE in set_pte_at() for kernel mappings sched/cgroup: Fix/cleanup cgroup teardown/init dmaengine: pxa_dma: fix the maximum requestor line dmaengine: hsu: correct use of channel status register dmaengine: dw: fix master selection debugfs: Make automount point inodes permanently empty lib: lz4: fixed zram with lz4 on big endian machines dm cache metadata: fix cmd_read_lock() acquiring write lock dm cache metadata: fix READ_LOCK macros and cleanup WRITE_LOCK macros usb: gadget: f_fs: Fix use-after-free usb: hcd: out of bounds access in for_each_companion xhci: fix 10 second timeout on removal of PCI hotpluggable xhci controllers usb: xhci: fix wild pointers in xhci_mem_cleanup xhci: resume USB 3 roothub first usb: xhci: applying XHCI_PME_STUCK_QUIRK to Intel BXT B0 host assoc_array: don't call compare_object() on a node ARM: OMAP2+: hwmod: Fix updating of sysconfig register ARM: OMAP2: Fix up interconnect barrier initialization for DRA7 ARM: mvebu: Correct unit address for linksys ARM: dts: AM43x-epos: Fix clk parent for synctimer KVM: arm/arm64: Handle forward time correction gracefully kvm: x86: do not leak guest xcr0 into host interrupt handlers x86/mce: Avoid using object after free in genpool block: loop: fix filesystem corruption in case of aio/dio block: partition: initialize percpuref before sending out KOBJ_ADD Conflicts: arch/arm64/Kconfig arch/arm64/include/asm/cputype.h arch/arm64/include/asm/hardirq.h arch/arm64/include/asm/irq.h arch/arm64/kernel/cpu_errata.c arch/arm64/kernel/cpuinfo.c arch/arm64/kernel/setup.c arch/arm64/kernel/smp.c arch/arm64/kernel/stacktrace.c arch/arm64/mm/init.c arch/arm64/mm/mmu.c arch/arm64/mm/pageattr.c mm/memcontrol.c CRs-Fixed: 1054234 Signed-off-by: Trilok Soni <tsoni@codeaurora.org> Change-Id: I2a7a34631ffee36ce18b9171f16d023be777392f
2016-08-15Revert "arm64: Add support for app specific settings"Satya Durga Srinivasu Prabhala
This reverts commit 7ab05c20ad43 ("arm64: Add support for app specific settings"). Feature is not applicable to msmcobalt and only applicable to MSM8996. CRs-Fixed: 1054373 Change-Id: I12d3a22362b965c7d302976c83ab0e757c98d3c6 Signed-off-by: Satya Durga Srinivasu Prabhala <satyap@codeaurora.org>
2016-07-29Merge branch 'linux-linaro-lsk-v4.4' into linux-linaro-lsk-v4.4-androidMark Brown
2016-07-27tmpfs: fix regression hang in fallocate undoHugh Dickins
commit 7f556567036cb7f89aabe2f0954b08566b4efb53 upstream. The well-spotted fallocate undo fix is good in most cases, but not when fallocate failed on the very first page. index 0 then passes lend -1 to shmem_undo_range(), and that has two bad effects: (a) that it will undo every fallocation throughout the file, unrestricted by the current range; but more importantly (b) it can cause the undo to hang, because lend -1 is treated as truncation, which makes it keep on retrying until every page has gone, but those already fully instantiated will never go away. Big thank you to xfstests generic/269 which demonstrates this. Fixes: b9b4bb26af01 ("tmpfs: don't undo fallocate past its last page") Signed-off-by: Hugh Dickins <hughd@google.com> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2016-07-27tmpfs: don't undo fallocate past its last pageAnthony Romano
commit b9b4bb26af017dbe930cd4df7f9b2fc3a0497bfe upstream. When fallocate is interrupted it will undo a range that extends one byte past its range of allocated pages. This can corrupt an in-use page by zeroing out its first byte. Instead, undo using the inclusive byte range. Fixes: 1635f6a74152f1d ("tmpfs: undo fallocation on failure") Link: http://lkml.kernel.org/r/1462713387-16724-1-git-send-email-anthony.romano@coreos.com Signed-off-by: Anthony Romano <anthony.romano@coreos.com> Cc: Vlastimil Babka <vbabka@suse.cz> Cc: Hugh Dickins <hughd@google.com> Cc: Brandon Philips <brandon@ifup.co> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2016-07-27percpu: fix synchronization between synchronous map extension and chunk ↵Tejun Heo
destruction commit 6710e594f71ccaad8101bc64321152af7cd9ea28 upstream. For non-atomic allocations, pcpu_alloc() can try to extend the area map synchronously after dropping pcpu_lock; however, the extension wasn't synchronized against chunk destruction and the chunk might get freed while extension is in progress. This patch fixes the bug by putting most of non-atomic allocations under pcpu_alloc_mutex to synchronize against pcpu_balance_work which is responsible for async chunk management including destruction. Signed-off-by: Tejun Heo <tj@kernel.org> Reported-and-tested-by: Alexei Starovoitov <alexei.starovoitov@gmail.com> Reported-by: Vlastimil Babka <vbabka@suse.cz> Reported-by: Sasha Levin <sasha.levin@oracle.com> Fixes: 1a4d76076cda ("percpu: implement asynchronous chunk population") Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2016-07-27percpu: fix synchronization between chunk->map_extend_work and chunk destructionTejun Heo
commit 4f996e234dad488e5d9ba0858bc1bae12eff82c3 upstream. Atomic allocations can trigger async map extensions which is serviced by chunk->map_extend_work. pcpu_balance_work which is responsible for destroying idle chunks wasn't synchronizing properly against chunk->map_extend_work and may end up freeing the chunk while the work item is still in flight. This patch fixes the bug by rolling async map extension operations into pcpu_balance_work. Signed-off-by: Tejun Heo <tj@kernel.org> Reported-and-tested-by: Alexei Starovoitov <alexei.starovoitov@gmail.com> Reported-by: Vlastimil Babka <vbabka@suse.cz> Reported-by: Sasha Levin <sasha.levin@oracle.com> Fixes: 9c824b6a172c ("percpu: make sure chunk->map array has available space") Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2016-07-27mm: Export migrate_page_move_mapping and migrate_page_copyRichard Weinberger
commit 1118dce773d84f39ebd51a9fe7261f9169cb056e upstream. Export these symbols such that UBIFS can implement ->migratepage. Signed-off-by: Richard Weinberger <richard@nod.at> Acked-by: Christoph Hellwig <hch@lst.de> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2016-07-27writeback: use higher precision calculation in domain_dirty_limits()Tejun Heo
commit 62a584fe05eef1f80ed49a286a29328f1a224fb9 upstream. As vm.dirty_[background_]bytes can't be applied verbatim to multiple cgroup writeback domains, they get converted to percentages in domain_dirty_limits() and applied the same way as vm.dirty_[background]ratio. However, if the specified bytes is lower than 1% of available memory, the calculated ratios become zero and the writeback domain gets throttled constantly. Fix it by using per-PAGE_SIZE instead of percentage for ratio calculations. Also, the updated DIV_ROUND_UP() usages now should yield 1/4096 (0.0244%) as the minimum ratio as long as the specified bytes are above zero. Signed-off-by: Tejun Heo <tj@kernel.org> Reported-by: Miao Xie <miaoxie@huawei.com> Link: http://lkml.kernel.org/g/57333E75.3080309@huawei.com Fixes: 9fc3a43e1757 ("writeback: separate out domain_dirty_limits()") Reviewed-by: Jan Kara <jack@suse.cz> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> Adjusted comment based on Jan's suggestion. Signed-off-by: Jens Axboe <axboe@fb.com>
2016-07-22Merge remote-tracking branch 'msm-4.4/tmp-2bf7955' into msm-4.4Trilok Soni
* msm-4.4/tmp-2bf7955: Linux 4.4.8 Revert "usb: hub: do not clear BOS field during reset device" usbvision: fix crash on detecting device with invalid configuration staging: android: ion: Set the length of the DMA sg entries in buffer Revert "PCI, x86: Implement pcibios_alloc_irq() and pcibios_free_irq()" Revert "PCI: Add helpers to manage pci_dev->irq and pci_dev->irq_managed" Revert "x86/PCI: Don't alloc pcibios-irq when MSI is enabled" HID: usbhid: fix inconsistent reset/resume/reset-resume behavior HID: wacom: fix Bamboo ONE oops ALSA: usb-audio: Skip volume controls triggers hangup on Dell USB Dock ALSA: usb-audio: Add a quirk for Plantronics BT300 ALSA: usb-audio: Add a sample rate quirk for Phoenix Audio TMX320 ALSA: hda/realtek - Enable the ALC292 dock fixup on the Thinkpad T460s ALSA: hda - fix front mic problem for a HP desktop ALSA: hda - Fix headset support and noise on HP EliteBook 755 G2 ALSA: hda - Fixup speaker pass-through control for nid 0x14 on ALC225 mmc: sdhci-pci: Add support and PCI IDs for more Broxton host controllers perf: Cure event->pending_disable race perf: Do not double free arm64: replace read_lock to rcu lock in call_step_hook Btrfs: fix file/data loss caused by fsync after rename and new inode iommu: Don't overwrite domain pointer when there is no default_domain ext4: ignore quota mount options if the quota feature is enabled ext4: add lockdep annotations for i_data_sem btrfs: fix crash/invalid memory access on fsync when using overlayfs nfs: use file_dentry() fs: add file_dentry() sd: Fix excessive capacity printing on devices with blocks bigger than 512 bytes iio: gyro: bmg160: fix endianness when reading axes iio: gyro: bmg160: fix buffer read values iio: accel: bmc150: fix endianness when reading axes iio: st_magn: always define ST_MAGN_TRIGGER_SET_STATE usb: renesas_usbhs: fix to avoid using a disabled ep in usbhsg_queue_done() usb: renesas_usbhs: disable TX IRQ before starting TX DMAC transfer usb: renesas_usbhs: avoid NULL pointer derefernce in usbhsf_pkt_handler() mac80211: fix txq queue related crashes mac80211: fix unnecessary frame drops in mesh fwding mac80211: fix ibss scan parameters mac80211: avoid excessive stack usage in sta_info mac80211: properly deal with station hashtable insert errors virtio: virtio 1.0 cs04 spec compliance for reset rbd: use GFP_NOIO consistently for request allocations pcmcia: db1xxx_ss: fix last irq_to_gpio user v4l: vsp1: Set the SRU CTRL0 register when starting the stream coda: fix error path in case of missing pdata on non-DT platform au0828: Fix dev_state handling au0828: fix au0828_v4l2_close() dev_state race condition pinctrl: freescale: imx: fix bogus check of of_iomap() return value pinctrl: nomadik: fix pull debug print inversion pinctrl: sunxi: Fix A33 external interrupts not working pinctrl: sh-pfc: only use dummy states for non-DT platforms pinctrl: pistachio: fix mfio84-89 function description and pinmux. MIPS: Fix MSA ld unaligned failure cases KVM: x86: reduce default value of halt_poll_ns parameter KVM: x86: Inject pending interrupt even if pending nmi exist cdc-acm: fix NULL pointer reference USB: uas: Add a new NO_REPORT_LUNS quirk USB: uas: Limit qdepth at the scsi-host level mpls: find_outdev: check for err ptr in addition to NULL check ipv6: Count in extension headers in skb->network_header ip6_tunnel: set rtnl_link_ops before calling register_netdevice ipv6: l2tp: fix a potential issue in l2tp_ip6_recv ipv4: l2tp: fix a potential issue in l2tp_ip_recv tuntap: restore default qdisc tun, bpf: fix suspicious RCU usage in tun_{attach, detach}_filter rtnl: fix msg size calculation in if_nlmsg_size() bridge: Allow set bridge ageing time when switchdev disabled ipv6: udp: fix UDP_MIB_IGNOREDMULTI updates qmi_wwan: add "D-Link DWM-221 B1" device id xfrm: Fix crash observed during device unregistration and decryption ppp: take reference on channels netns ipv4: initialize flowi4_flags before calling fib_lookup() ipv4: fix broadcast packets reception bonding: fix bond_get_stats() net: bcmgenet: fix dma api length mismatch qlge: Fix receive packets drop. tcp/dccp: remove obsolete WARN_ON() in icmp handlers ppp: ensure file->private_data can't be overridden ath9k: fix buffer overrun for ar9287 farsync: fix off-by-one bug in fst_add_one mlx4: add missing braces in verify_qp_parameters net: Fix use after free in the recvmmsg exit path ipv4: Don't do expensive useless work during inetdev destroy. bridge: allow zero ageing time rocker: set FDB cleanup timer according to lowest ageing time mlxsw: spectrum: Check requested ageing time is valid macvtap: always pass ethernet header in linear qlcnic: Fix mailbox completion handling during spurious interrupt qlcnic: Remove unnecessary usage of atomic_t sh_eth: advance 'rxdesc' later in sh_eth_ring_format() sh_eth: fix NULL pointer dereference in sh_eth_ring_format() bpf: avoid copying junk bytes in bpf_get_current_comm() packet: validate variable length ll headers ax25: add link layer header validation function net: validate variable length ll headers ppp: release rtnl mutex when interface creation fails tcp: fix tcpi_segs_in after connection establishment udp6: fix UDP/IPv6 encap resubmit path usbnet: cleanup after bind() in probe() cdc_ncm: toggle altsetting to force reset before setup vxlan: fix missing options_len update on RX with collect metadata ipv6: re-enable fragment header matching in ipv6_find_hdr qmi_wwan: add Sierra Wireless EM74xx device ID tipc: Revert "tipc: use existing sk_write_queue for outgoing packet chain" mld, igmp: Fix reserved tailroom calculation sctp: lack the check for ports in sctp_v6_cmp_addr net: fix bridge multicast packet checksum validation net: qca_spi: clear IFF_TX_SKB_SHARING net: qca_spi: Don't clear IFF_BROADCAST net: vrf: Remove direct access to skb->data net: jme: fix suspend/resume on JMC260 ipv4: only create late gso-skb if skb is already set up with CHECKSUM_PARTIAL tunnel: Clear IPCB(skb)->opt before dst_link_failure called tcp: convert cached rtt from usec to jiffies when feeding initial rto xen/events: Mask a moving irq drm/amdgpu/gmc: use proper register for vram type on Fiji drm/amdgpu/gmc: move vram type fetching into sw_init drm/radeon: add a dpm quirk for all R7 370 parts drm/radeon: add another R7 370 quirk drm/radeon: add a dpm quirk for sapphire Dual-X R7 370 2G D5 drm/udl: Use unlocked gem unreferencing drm/dp: move hw_mutex up the call stack arm64: opcodes.h: Add arm big-endian config options before including arm header compiler-gcc: disable -ftracer for __noclone functions libnvdimm, pfn: fix uuid validation libnvdimm: fix smart data retrieval powerpc/mm: Fixup preempt underflow with huge pages mm: fix invalid node in alloc_migrate_target() ALSA: hda - Apply fix for white noise on Asus N550JV, too ALSA: hda - Fix white noise on Asus N750JV headphone ALSA: hda - Asus N750JV external subwoofer fixup ALSA: timer: Use mod_timer() for rearming the system timer parisc: Unbreak handling exceptions from kernel modules parisc: Fix kernel crash with reversed copy_from_user() parisc: Avoid function pointers for kernel exception routines PKCS#7: pkcs7_validate_trust(): initialize the _trusted output argument hwmon: (max1111) Return -ENODEV from max1111_read_channel if not instantiated Linux 4.4.7 perf/x86/intel: Fix PEBS data source interpretation on Nehalem/Westmere perf/x86/intel: Use PAGE_SIZE for PEBS buffer size on Core2 perf/x86/intel: Fix PEBS warning by only restoring active PMU in pmi perf/x86/pebs: Add workaround for broken OVFL status on HSW+ sched/cputime: Fix steal time accounting vs. CPU hotplug scsi_common: do not clobber fixed sense information PM / sleep: Clear pm_suspend_global_flags upon hibernate intel_idle: prevent SKL-H boot failure when C8+C9+C10 enabled mtd: onenand: fix deadlock in onenand_block_markbad mm/page_alloc: prevent merging between isolated and other pageblocks ocfs2/dlm: fix BUG in dlm_move_lockres_to_recovery_list ocfs2/dlm: fix race between convert and recovery Input: ati_remote2 - fix crashes on detecting device with invalid descriptor Input: ims-pcu - sanity check against missing interfaces Input: synaptics - handle spurious release of trackstick buttons, again writeback, cgroup: fix use of the wrong bdi_writeback which mismatches the inode writeback, cgroup: fix premature wb_put() in locked_inode_to_wb_and_lock_list() ACPI / PM: Runtime resume devices when waking from hibernate ARM: dts: at91: sama5d4 Xplained: don't disable hsmci regulator ARM: dts: at91: sama5d3 Xplained: don't disable hsmci regulator nfsd: fix deadlock secinfo+readdir compound nfsd4: fix bad bounds checking iser-target: Rework connection termination iser-target: Separate flows for np listeners and connections cma events iser-target: Add new state ISER_CONN_BOUND to isert_conn iser-target: Fix identification of login rx descriptor type target: Fix target_release_cmd_kref shutdown comp leak clk: bcm2835: Fix setting of PLL divider clock rates clk: rockchip: add hclk_cpubus to the list of rk3188 critical clocks clk: rockchip: rk3368: fix hdmi_cec gate-register clk: rockchip: rk3368: fix parents of video encoder/decoder clk: rockchip: rk3368: fix cpuclk core dividers clk: rockchip: rk3368: fix cpuclk mux bit of big cpu-cluster mmc: sdhci: Fix override of timeout clk wrt max_busy_timeout mmc: sdhci: fix data timeout (part 2) mmc: sdhci: fix data timeout (part 1) mmc: mmc_spi: Add Card Detect comments and fix CD GPIO case mmc: block: fix ABI regression of mmc_blk_ioctl ideapad-laptop: Add ideapad Y700 (15) to the no_hw_rfkill DMI list MAINTAINERS: Update mailing list and web page for hwmon subsystem kbuild/mkspec: fix grub2 installkernel issue scripts/kconfig: allow building with make 3.80 again scripts/coccinelle: modernize & bitops: Do not default to __clear_bit() for __clear_bit_unlock() tracing: Fix trace_printk() to print when not using bprintk() tracing: Fix crash from reading trace_pipe with sendfile tracing: Have preempt(irqs)off trace preempt disabled functions IB/ipoib: fix for rare multicast join race condition drm/amdgpu: include the right version of gmc header files for iceland drm/amdgpu: disable runtime pm on PX laptops without dGPU power control drm/radeon: Don't drop DP 2.7 Ghz link setup on some cards. drm/radeon: disable runtime pm on PX laptops without dGPU power control iwlwifi: mvm: Fix paging memory leak ipr: Fix regression when loading firmware ipr: Fix out-of-bounds null overwrite rapidio/rionet: fix deadlock on SMP fs/coredump: prevent fsuid=0 dumps into user-controlled directories fuse: Add reference counting for fuse_io_priv fuse: do not use iocb after it may have been freed md: multipath: don't hardcopy bio in .make_request path md/raid5: preserve STRIPE_PREREAD_ACTIVE in break_stripe_batch_list raid10: include bio_end_io_list in nr_queued to prevent freeze_array hang RAID5: revert e9e4c377e2f563 to fix a livelock RAID5: check_reshape() shouldn't call mddev_suspend md/raid5: Compare apples to apples (or sectors to sectors) raid1: include bio_end_io_list in nr_queued to prevent freeze_array hang xfs: fix two memory leaks in xfs_attr_list.c error paths quota: Fix possible GPF due to uninitialised pointers ARC: bitops: Remove non relevant comments ARC: [BE] readl()/writel() to work in Big Endian CPU configuration xtensa: clear all DBREAKC registers on start xtensa: fix preemption in {clear,copy}_user_highpage xtensa: ISS: don't hang if stdin EOF is reached splice: handle zero nr_pages in splice_to_pipe() vfs: show_vfsstat: do not ignore errors from show_devname method of: alloc anywhere from memblock if range not specified net: mvneta: enable change MAC address when interface is up cgroup: ignore css_sets associated with dead cgroups during migration Bluetooth: Fix potential buffer overflow with Add Advertising Bluetooth: Add new AR3012 ID 0489:e095 watchdog: rc32434_wdt: fix ioctl error handling watchdog: don't run proc_watchdog_update if new value is same as old ia64: define ioremap_uc() mm: memcontrol: reclaim and OOM kill when shrinking memory.max below usage mm: memcontrol: reclaim when shrinking memory.high below usage bcache: fix cache_set_flush() NULL pointer dereference on OOM bcache: fix race of writeback thread starting before complete initialization bcache: cleaned up error handling around register_cache() IB/srpt: Simplify srpt_handle_tsk_mgmt() brd: Fix discard request processing jbd2: fix FS corruption possibility in jbd2_journal_destroy() on umount path tools/hv: Use include/uapi with __EXPORTED_HEADERS__ ALSA: hda - Fix unconditional GPIO toggle via automute ALSA: hda - fix the mic mute button and led problem for a Lenovo AIO ALSA: hda - Don't handle ELD notify from invalid port ALSA: intel8x0: Add clock quirk entry for AD1981B on IBM ThinkPad X41. ALSA: pcm: Avoid "BUG:" string for warnings again ALSA: hda - Apply reboot D3 fix for CX20724 codec, too mtip32xx: Cleanup queued requests after surprise removal mtip32xx: Implement timeout handler mtip32xx: Handle FTL rebuild failure state during device initialization mtip32xx: Handle safe removal during IO mtip32xx: Fix for rmmod crash when drive is in FTL rebuild mtip32xx: Print exact time when an internal command is interrupted mtip32xx: Remove unwanted code from taskfile error handler mtip32xx: Fix broken service thread handling mtip32xx: Avoid issuing standby immediate cmd during FTL rebuild media: v4l2-compat-ioctl32: fix missing length copy in put_v4l2_buffer32 coda: fix first encoded frame payload bttv: Width must be a multiple of 16 when capturing planar formats adv7511: TX_EDID_PRESENT is still 1 after a disconnect saa7134: Fix bytesperline not being set correctly for planar formats 8250: use callbacks to access UART_DLL/UART_DLM net: irda: Fix use-after-free in irtty_open() tty: Fix GPF in flush_to_ldisc(), part 2 staging: comedi: ni_mio_common: fix the ni_write[blw]() functions staging: android: ion_test: fix check of platform_device_register_simple() error code staging: comedi: ni_tiocmd: change mistaken use of start_src for start_arg HID: fix hid_ignore_special_drivers module parameter HID: multitouch: force retrieving of Win8 signature blob HID: i2c-hid: fix OOB write in i2c_hid_set_or_send_report() HID: logitech: fix Dual Action gamepad support tpm: fix the cleanup of struct tpm_chip tpm_eventlog.c: fix binary_bios_measurements tpm_crb: tpm2_shutdown() must be called before tpm_chip_unregister() tpm: fix the rollback in tpm_chip_register() mei: bus: check if the device is enabled before data transfer X.509: Fix leap year handling again crypto: marvell/cesa - forward devm_ioremap_resource() error code crypto: ux500 - fix checks of error code returned by devm_ioremap_resource() crypto: atmel - fix checks of error code returned by devm_ioremap_resource() crypto: keywrap - memzero the correct memory crypto: ccp - memset request context to zero during import crypto: ccp - Don't assume export/import areas are aligned crypto: ccp - Limit the amount of information exported crypto: ccp - Add hash state import and export support Bluetooth: btusb: Add a new AR3012 ID 13d3:3472 Bluetooth: btusb: Add a new AR3012 ID 04ca:3014 Bluetooth: btusb: Add new AR3012 ID 13d3:3395 ALSA: usb-audio: Fix double-free in error paths after snd_usb_add_audio_stream() call ALSA: usb-audio: Minor code cleanup in create_fixed_stream_quirk() ALSA: usb-audio: add Microsoft HD-5001 to quirks ALSA: usb-audio: Add sanity checks for endpoint accesses ALSA: usb-audio: Fix NULL dereference in create_fixed_stream_quirk() Input: powermate - fix oops with malicious USB descriptors pwc: Add USB id for Philips Spc880nc webcam USB: option: add "D-Link DWM-221 B1" device id USB: serial: ftdi_sio: Add support for ICP DAS I-756xU devices USB: serial: cp210x: Adding GE Healthcare Device ID USB: cypress_m8: add endpoint sanity check USB: digi_acceleport: do sanity checking for the number of ports USB: mct_u232: add sanity checking in probe USB: usb_driver_claim_interface: add sanity checking USB: iowarrior: fix oops with malicious USB descriptors USB: cdc-acm: more sanity checking USB: uas: Reduce can_queue to MAX_CMNDS usb: hub: fix a typo in hub_port_init() leading to wrong logic usb: retry reset if a device times out dm: fix rq_end_stats() NULL pointer in dm_requeue_original_request() dm cache: make sure every metadata function checks fail_io dm thin metadata: don't issue prefetches if a transaction abort has failed dm: fix excessive dm-mq context switching dm snapshot: disallow the COW and origin devices from being identical libnvdimm: Fix security issue with DSM IOCTL. aic7xxx: Fix queue depth handling be2iscsi: set the boot_kset pointer to NULL in case of failure scsi: storvsc: fix SRB_STATUS_ABORTED handling sd: Fix discard granularity when LBPRZ=1 aacraid: Set correct msix count for EEH recovery aacraid: Fix memory leak in aac_fib_map_free aacraid: Fix RRQ overload sg: fix dxferp in from_to case x86/mm: TLB_REMOTE_SEND_IPI should count pages x86/iopl: Fix iopl capability check on Xen PV x86/iopl/64: Properly context-switch IOPL on Xen PV x86/apic: Fix suspicious RCU usage in smp_trace_call_function_interrupt() x86/irq: Cure live lock in fixup_irqs() PCI: ACPI: IA64: fix IO port generic range check PCI: Disable IO/MEM decoding for devices with non-compliant BARs pinctrl-bcm2835: Fix cut-and-paste error in "pull" parsing s390/pci: enforce fmb page boundary rule s390/cpumf: add missing lpp magic initialization s390: fix floating pointer register corruption (again) EDAC, amd64_edac: Shift wrapping issue in f1x_get_norm_dct_addr() EDAC/sb_edac: Fix computation of channel address sched/preempt, sh: kmap_coherent relies on disabled preemption sched/cputime: Fix steal_account_process_tick() to always return jiffies Thermal: Ignore invalid trip points perf tools: Fix python extension build perf tools: Fix checking asprintf return value perf tools: Dont stop PMU parsing on alias parse error perf/core: Fix perf_sched_count derailment KVM: VMX: fix nested vpid for old KVM guests KVM: VMX: avoid guest hang on invalid invvpid instruction KVM: VMX: avoid guest hang on invalid invept instruction KVM: fix spin_lock_init order on x86 KVM: i8254: change PIT discard tick policy KVM: x86: fix missed hardware breakpoints x86/PCI: Mark Broadwell-EP Home Agent & PCU as having non-compliant BARs perf/x86/intel: Add definition for PT PMI bit x86/entry/compat: Keep TS_COMPAT set during signal delivery x86/microcode: Untangle from BLK_DEV_INITRD x86/microcode/intel: Make early loader look for builtin microcode too mmc: sh_mmcif: Correct TX DMA channel allocation mmc: sh_mmcif: rework dma channel handling ASoC: samsung: pass DMA channels as pointers regulator: core: Fix nested locking of supplies regulator: core: avoid unused variable warning s390/cpumf: Fix lpp detection cpufreq: dt: No need to allocate resources anymore cpufreq: dt: No need to fetch voltage-tolerance cpufreq: dt: Use dev_pm_opp_set_rate() to switch frequency cpufreq: dt: Reuse dev_pm_opp_get_max_transition_latency() cpufreq: dt: Unsupported OPPs are already disabled cpufreq: dt: Pass regulator name to the OPP core cpufreq: dt: OPP layers handles clock-latency for V1 bindings as well cpufreq: dt: Rename 'need_update' to 'opp_v1' cpufreq: dt: Convert few pr_debug/err() calls to dev_dbg/err() cpufreq-dt: fix handling regulator_get_voltage() result cpufreq-dt: Supply power coefficient when registering cooling devices PM / OPP: Rename structures for clarity PM / OPP: Fix incorrect comments PM / OPP: Initialize regulator pointer to an error value PM / OPP: Initialize u_volt_min/max to a valid value PM / OPP: Fix NULL pointer dereference crash when disabling OPPs PM / OPP: Add dev_pm_opp_set_rate() PM / OPP: Manage device clk PM / OPP: Parse clock-latency and voltage-tolerance for v1 bindings PM / OPP: Introduce dev_pm_opp_get_max_transition_latency() PM / OPP: Introduce dev_pm_opp_get_max_volt_latency() PM / OPP: Disable OPPs that aren't supported by the regulator PM / OPP: get/put regulators from OPP core cpufreq: cpufreq-dt: avoid uninitialized variable warnings: PM / OPP: Use snprintf() instead of sprintf() PM / OPP: Set cpu_dev->id in cpumask first PM / OPP: Fix parsing of opp-microvolt and opp-microamp properties PM / OPP: Parse 'opp-<prop>-<name>' bindings PM / OPP: Parse 'opp-supported-hw' binding PM / OPP: Add missing doc comments PM / OPP: Rename OPP nodes as opp@<opp-hz> PM / OPP: Remove 'operating-points-names' binding PM / OPP: Add {opp-microvolt|opp-microamp}-<name> binding PM / OPP: Add "opp-supported-hw" binding PM / OPP: Add debugfs support arm64: vdso: Mark vDSO code as read-only Conflicts: drivers/staging/android/ion/ion.c mm/page_alloc.c CRs-Fixed: 1010239 Change-Id: Id59539cad642885e1e41340cebae4159ba1f7eaf Signed-off-by: Trilok Soni <tsoni@codeaurora.org>
2016-07-12Merge remote-tracking branch 'origin/tmp-917a9a9133a6' into lskRunmin Wang
* tmp-917a9: ARM/vdso: Mark the vDSO code read-only after init x86/vdso: Mark the vDSO code read-only after init lkdtm: Verify that '__ro_after_init' works correctly arch: Introduce post-init read-only memory x86/mm: Always enable CONFIG_DEBUG_RODATA and remove the Kconfig option mm/init: Add 'rodata=off' boot cmdline parameter to disable read-only kernel mappings asm-generic: Consolidate mark_rodata_ro() Linux 4.4.6 ld-version: Fix awk regex compile failure target: Drop incorrect ABORT_TASK put for completed commands block: don't optimize for non-cloned bio in bio_get_last_bvec() MIPS: smp.c: Fix uninitialised temp_foreign_map MIPS: Fix build error when SMP is used without GIC ovl: fix getcwd() failure after unsuccessful rmdir ovl: copy new uid/gid into overlayfs runtime inode userfaultfd: don't block on the last VM updates at exit time powerpc/powernv: Fix OPAL_CONSOLE_FLUSH prototype and usages powerpc/powernv: Add a kmsg_dumper that flushes console output on panic powerpc: Fix dedotify for binutils >= 2.26 Revert "drm/radeon/pm: adjust display configuration after powerstate" drm/radeon: Fix error handling in radeon_flip_work_func. drm/amdgpu: Fix error handling in amdgpu_flip_work_func. Revert "drm/radeon: call hpd_irq_event on resume" x86/mm: Fix slow_virt_to_phys() for X86_PAE again gpu: ipu-v3: Do not bail out on missing optional port nodes mac80211: Fix Public Action frame RX in AP mode mac80211: check PN correctly for GCMP-encrypted fragmented MPDUs mac80211: minstrel_ht: fix a logic error in RTS/CTS handling mac80211: minstrel_ht: set default tx aggregation timeout to 0 mac80211: fix use of uninitialised values in RX aggregation mac80211: minstrel: Change expected throughput unit back to Kbps iwlwifi: mvm: inc pending frames counter also when txing non-sta can: gs_usb: fixed disconnect bug by removing erroneous use of kfree() cfg80211/wext: fix message ordering wext: fix message delay/ordering ovl: fix working on distributed fs as lower layer ovl: ignore lower entries when checking purity of non-directory entries ASoC: wm8958: Fix enum ctl accesses in a wrong type ASoC: wm8994: Fix enum ctl accesses in a wrong type ASoC: samsung: Use IRQ safe spin lock calls ASoC: dapm: Fix ctl value accesses in a wrong type ncpfs: fix a braino in OOM handling in ncp_fill_cache() jffs2: reduce the breakage on recovery from halfway failed rename() dmaengine: at_xdmac: fix residue computation tracing: Fix check for cpu online when event is disabled s390/dasd: fix diag 0x250 inline assembly s390/mm: four page table levels vs. fork KVM: MMU: fix reserved bit check for ept=0/CR0.WP=0/CR4.SMEP=1/EFER.NX=0 KVM: MMU: fix ept=0/pte.u=1/pte.w=0/CR0.WP=0/CR4.SMEP=1/EFER.NX=0 combo KVM: PPC: Book3S HV: Sanitize special-purpose register values on guest exit KVM: s390: correct fprs on SIGP (STOP AND) STORE STATUS KVM: VMX: disable PEBS before a guest entry kvm: cap halt polling at exactly halt_poll_ns PCI: Allow a NULL "parent" pointer in pci_bus_assign_domain_nr() ARM: OMAP2+: hwmod: Introduce ti,no-idle dt property ARM: dts: dra7: do not gate cpsw clock due to errata i877 ARM: mvebu: fix overlap of Crypto SRAM with PCIe memory window arm64: account for sparsemem section alignment when choosing vmemmap offset Linux 4.4.5 drm/amdgpu: fix topaz/tonga gmc assignment in 4.4 stable modules: fix longstanding /proc/kallsyms vs module insertion race. drm/i915: refine qemu south bridge detection drm/i915: more virtual south bridge detection block: get the 1st and last bvec via helpers block: check virt boundary in bio_will_gap() drm/amdgpu: Use drm_calloc_large for VM page_tables array thermal: cpu_cooling: fix out of bounds access in time_in_idle i2c: brcmstb: allocate correct amount of memory for regmap ubi: Fix out of bounds write in volume update code cxl: Fix PSL timebase synchronization detection MIPS: traps: Fix SIGFPE information leak from `do_ov' and `do_trap_or_bp' MIPS: scache: Fix scache init with invalid line size. USB: serial: option: add support for Quectel UC20 USB: serial: option: add support for Telit LE922 PID 0x1045 USB: qcserial: add Sierra Wireless EM74xx device ID USB: qcserial: add Dell Wireless 5809e Gobi 4G HSPA+ (rev3) USB: cp210x: Add ID for Parrot NMEA GPS Flight Recorder usb: chipidea: otg: change workqueue ci_otg as freezable ALSA: timer: Fix broken compat timer user status ioctl ALSA: hdspm: Fix zero-division ALSA: hdsp: Fix wrong boolean ctl value accesses ALSA: hdspm: Fix wrong boolean ctl value accesses ALSA: seq: oss: Don't drain at closing a client ALSA: pcm: Fix ioctls for X32 ABI ALSA: timer: Fix ioctls for X32 ABI ALSA: rawmidi: Fix ioctls X32 ABI ALSA: hda - Fix mic issues on Acer Aspire E1-472 ALSA: ctl: Fix ioctls for X32 ABI ALSA: usb-audio: Add a quirk for Plantronics DA45 adv7604: fix tx 5v detect regression dmaengine: pxa_dma: fix cyclic transfers Fix directory hardlinks from deleted directories jffs2: Fix page lock / f->sem deadlock Revert "jffs2: Fix lock acquisition order bug in jffs2_write_begin" Btrfs: fix loading of orphan roots leading to BUG_ON pata-rb532-cf: get rid of the irq_to_gpio() call tracing: Do not have 'comm' filter override event 'comm' field ata: ahci: don't mark HotPlugCapable Ports as external/removable PM / sleep / x86: Fix crash on graph trace through x86 suspend arm64: vmemmap: use virtual projection of linear region Adding Intel Lewisburg device IDs for SATA writeback: flush inode cgroup wb switches instead of pinning super_block block: bio: introduce helpers to get the 1st and last bvec libata: Align ata_device's id on a cacheline libata: fix HDIO_GET_32BIT ioctl drm/amdgpu: return from atombios_dp_get_dpcd only when error drm/amdgpu/gfx8: specify which engine to wait before vm flush drm/amdgpu: apply gfx_v8 fixes to gfx_v7 as well drm/amdgpu/pm: update current crtc info after setting the powerstate drm/radeon/pm: update current crtc info after setting the powerstate drm/ast: Fix incorrect register check for DRAM width target: Fix WRITE_SAME/DISCARD conversion to linux 512b sectors iommu/vt-d: Use BUS_NOTIFY_REMOVED_DEVICE in hotplug path iommu/amd: Fix boot warning when device 00:00.0 is not iommu covered iommu/amd: Apply workaround for ATS write permission check arm/arm64: KVM: Fix ioctl error handling KVM: x86: fix root cause for missed hardware breakpoints vfio: fix ioctl error handling Fix cifs_uniqueid_to_ino_t() function for s390x CIFS: Fix SMB2+ interim response processing for read requests cifs: fix out-of-bounds access in lease parsing fbcon: set a default value to blink interval kvm: x86: Update tsc multiplier on change. mips/kvm: fix ioctl error handling parisc: Fix ptrace syscall number and return value modification PCI: keystone: Fix MSI code that retrieves struct pcie_port pointer block: Initialize max_dev_sectors to 0 drm/amdgpu: mask out WC from BO on unsupported arches btrfs: async-thread: Fix a use-after-free error for trace btrfs: Fix no_space in write and rm loop Btrfs: fix deadlock running delayed iputs at transaction commit time drivers: sh: Restore legacy clock domain on SuperH platforms use ->d_seq to get coherency between ->d_inode and ->d_flags Linux 4.4.4 iwlwifi: mvm: don't allow sched scans without matches to be started iwlwifi: update and fix 7265 series PCI IDs iwlwifi: pcie: properly configure the debug buffer size for 8000 iwlwifi: dvm: fix WoWLAN security: let security modules use PTRACE_MODE_* with bitmasks IB/cma: Fix RDMA port validation for iWarp x86/irq: Plug vector cleanup race x86/irq: Call irq_force_move_complete with irq descriptor x86/irq: Remove outgoing CPU from vector cleanup mask x86/irq: Remove the cpumask allocation from send_cleanup_vector() x86/irq: Clear move_in_progress before sending cleanup IPI x86/irq: Remove offline cpus from vector cleanup x86/irq: Get rid of code duplication x86/irq: Copy vectormask instead of an AND operation x86/irq: Check vector allocation early x86/irq: Reorganize the search in assign_irq_vector x86/irq: Reorganize the return path in assign_irq_vector x86/irq: Do not use apic_chip_data.old_domain as temporary buffer x86/irq: Validate that irq descriptor is still active x86/irq: Fix a race in x86_vector_free_irqs() x86/irq: Call chip->irq_set_affinity in proper context x86/entry/compat: Add missing CLAC to entry_INT80_32 x86/mpx: Fix off-by-one comparison with nr_registers hpfs: don't truncate the file when delete fails do_last(): ELOOP failure exit should be done after leaving RCU mode should_follow_link(): validate ->d_seq after having decided to follow xen/pcifront: Fix mysterious crashes when NUMA locality information was extracted. xen/pciback: Save the number of MSI-X entries to be copied later. xen/pciback: Check PF instead of VF for PCI_COMMAND_MEMORY xen/scsiback: correct frontend counting xen/arm: correctly handle DMA mapping of compound pages ARM: at91/dt: fix typo in sama5d2 pinmux descriptions ARM: OMAP2+: Fix onenand initialization to avoid filesystem corruption do_last(): don't let a bogus return value from ->open() et.al. to confuse us kernel/resource.c: fix muxed resource handling in __request_region() sunrpc/cache: fix off-by-one in qword_get() tracing: Fix showing function event in available_events powerpc/eeh: Fix partial hotplug criterion KVM: x86: MMU: fix ubsan index-out-of-range warning KVM: x86: fix conversion of addresses to linear in 32-bit protected mode KVM: x86: fix missed hardware breakpoints KVM: arm/arm64: vgic: Ensure bitmaps are long enough KVM: async_pf: do not warn on page allocation failures of/irq: Fix msi-map calculation for nonzero rid-base NFSv4: Fix a dentry leak on alias use nfs: fix nfs_size_to_loff_t block: fix use-after-free in dio_bio_complete bio: return EINTR if copying to user space got interrupted i2c: i801: Adding Intel Lewisburg support for iTCO phy: core: fix wrong err handle for phy_power_on writeback: keep superblock pinned during cgroup writeback association switches cgroup: make sure a parent css isn't offlined before its children cpuset: make mm migration asynchronous PCI/AER: Flush workqueue on device remove to avoid use-after-free ARCv2: SMP: Emulate IPI to self using software triggered interrupt ARCv2: STAR 9000950267: Handle return from intr to Delay Slot #2 libata: fix sff host state machine locking while polling qla2xxx: Fix stale pointer access. spi: atmel: fix gpio chip-select in case of non-DT platform target: Fix race with SCF_SEND_DELAYED_TAS handling target: Fix remote-port TMR ABORT + se_cmd fabric stop target: Fix TAS handling for multi-session se_node_acls target: Fix LUN_RESET active TMR descriptor handling target: Fix LUN_RESET active I/O handling for ACK_KREF ALSA: hda - Fixing background noise on Dell Inspiron 3162 ALSA: hda - Apply clock gate workaround to Skylake, too Revert "workqueue: make sure delayed work run in local cpu" workqueue: handle NUMA_NO_NODE for unbound pool_workqueue lookup mac80211: Requeue work after scan complete for all VIF types. rfkill: fix rfkill_fop_read wait_event usage tick/nohz: Set the correct expiry when switching to nohz/lowres mode perf stat: Do not clean event's private stats cdc-acm:exclude Samsung phone 04e8:685d Revert "Staging: panel: usleep_range is preferred over udelay" Staging: speakup: Fix getting port information sd: Optimal I/O size is in bytes, not sectors libceph: don't spam dmesg with stray reply warnings libceph: use the right footer size when skipping a message libceph: don't bail early from try_read() when skipping a message libceph: fix ceph_msg_revoke() seccomp: always propagate NO_NEW_PRIVS on tsync cpufreq: Fix NULL reference crash while accessing policy->governor_data cpufreq: pxa2xx: fix pxa_cpufreq_change_voltage prototype hwmon: (ads1015) Handle negative conversion values correctly hwmon: (gpio-fan) Remove un-necessary speed_index lookup for thermal hook hwmon: (dell-smm) Blacklist Dell Studio XPS 8000 Thermal: do thermal zone update after a cooling device registered Thermal: handle thermal zone device properly during system sleep Thermal: initialize thermal zone device correctly IB/mlx5: Expose correct maximum number of CQE capacity IB/qib: Support creating qps with GFP_NOIO flag IB/qib: fix mcast detach when qp not attached IB/cm: Fix a recently introduced deadlock dmaengine: dw: disable BLOCK IRQs for non-cyclic xfer dmaengine: at_xdmac: fix resume for cyclic transfers dmaengine: dw: fix cyclic transfer callbacks dmaengine: dw: fix cyclic transfer setup nfit: fix multi-interface dimm handling, acpi6.1 compatibility ACPI / PCI / hotplug: unlock in error path in acpiphp_enable_slot() ACPI: Revert "ACPI / video: Add Dell Inspiron 5737 to the blacklist" ACPI / video: Add disable_backlight_sysfs_if quirk for the Toshiba Satellite R830 ACPI / video: Add disable_backlight_sysfs_if quirk for the Toshiba Portege R700 lib: sw842: select crc32 uapi: update install list after nvme.h rename ideapad-laptop: Add Lenovo Yoga 700 to no_hw_rfkill dmi list ideapad-laptop: Add Lenovo ideapad Y700-17ISK to no_hw_rfkill dmi list toshiba_acpi: Fix blank screen at boot if transflective backlight is supported make sure that freeing shmem fast symlinks is RCU-delayed drm/radeon/pm: adjust display configuration after powerstate drm/radeon: Don't hang in radeon_flip_work_func on disabled crtc. (v2) drm: Fix treatment of drm_vblank_offdelay in drm_vblank_on() (v2) drm: Fix drm_vblank_pre/post_modeset regression from Linux 4.4 drm: Prevent vblank counter bumps > 1 with active vblank clients. (v2) drm: No-Op redundant calls to drm_vblank_off() (v2) drm/radeon: use post-decrement in error handling drm/qxl: use kmalloc_array to alloc reloc_info in qxl_process_single_command drm/i915: fix error path in intel_setup_gmbus() drm/i915/dsi: don't pass arbitrary data to sideband drm/i915/dsi: defend gpio table against out of bounds access drm/i915/skl: Don't skip mst encoders in skl_ddi_pll_select() drm/i915: Don't reject primary plane windowing with color keying enabled on SKL+ drm/i915/dp: fall back to 18 bpp when sink capability is unknown drm/i915: Make sure DC writes are coherent on flush. drm/i915: Init power domains early in driver load drm/i915: intel_hpd_init(): Fix suspend/resume reprobing drm/i915: Restore inhibiting the load of the default context drm: fix missing reference counting decrease drm/radeon: hold reference to fences in radeon_sa_bo_new drm/radeon: mask out WC from BO on unsupported arches drm: add helper to check for wc memory support drm/radeon: fix DP audio support for APU with DCE4.1 display engine drm/radeon: Add a common function for DFS handling drm/radeon: cleaned up VCO output settings for DP audio drm/radeon: properly byte swap vce firmware setup drm/radeon: clean up fujitsu quirks drm/radeon: Fix "slow" audio over DP on DCE8+ drm/radeon: call hpd_irq_event on resume drm/radeon: Fix off-by-one errors in radeon_vm_bo_set_addr drm/dp/mst: deallocate payload on port destruction drm/dp/mst: Reverse order of MST enable and clearing VC payload table. drm/dp/mst: move GUID storage from mgr, port to only mst branch drm/dp/mst: Calculate MST PBN with 31.32 fixed point drm: Add drm_fixp_from_fraction and drm_fixp2int_ceil drm/dp/mst: fix in RAD element access drm/dp/mst: fix in MSTB RAD initialization drm/dp/mst: always send reply for UP request drm/dp/mst: process broadcast messages correctly drm/nouveau: platform: Fix deferred probe drm/nouveau/disp/dp: ensure sink is powered up before attempting link training drm/nouveau/display: Enable vblank irqs after display engine is on again. drm/nouveau/kms: take mode_config mutex in connector hotplug path drm/amdgpu/pm: adjust display configuration after powerstate drm/amdgpu: Don't hang in amdgpu_flip_work_func on disabled crtc. drm/amdgpu: use post-decrement in error handling drm/amdgpu: fix issue with overlapping userptrs drm/amdgpu: hold reference to fences in amdgpu_sa_bo_new (v2) drm/amdgpu: remove unnecessary forward declaration drm/amdgpu: fix s4 resume drm/amdgpu: remove exp hardware support from iceland drm/amdgpu: don't load MEC2 on topaz drm/amdgpu: drop topaz support from gmc8 module drm/amdgpu: pull topaz gmc bits into gmc_v7 drm/amdgpu: The VI specific EXE bit should only apply to GMC v8.0 above drm/amdgpu: iceland use CI based MC IP drm/amdgpu: move gmc7 support out of CIK dependency drm/amdgpu: no need to load MC firmware on fiji drm/amdgpu: fix amdgpu_bo_pin_restricted VRAM placing v2 drm/amdgpu: fix tonga smu resume drm/amdgpu: fix lost sync_to if scheduler is enabled. drm/amdgpu: call hpd_irq_event on resume drm/amdgpu: Fix off-by-one errors in amdgpu_vm_bo_map drm/vmwgfx: respect 'nomodeset' drm/vmwgfx: Fix a width / pitch mismatch on framebuffer updates drm/vmwgfx: Fix an incorrect lock check virtio_pci: fix use after free on release virtio_balloon: fix race between migration and ballooning virtio_balloon: fix race by fill and leak regulator: mt6311: MT6311_REGULATOR needs to select REGMAP_I2C regulator: axp20x: Fix GPIO LDO enable value for AXP22x clk: exynos: use irqsave version of spin_lock to avoid deadlock with irqs cxl: use correct operator when writing pcie config space values sparc64: fix incorrect sign extension in sys_sparc64_personality EDAC, mc_sysfs: Fix freeing bus' name EDAC: Robustify workqueues destruction MIPS: Fix buffer overflow in syscall_get_arguments() MIPS: Fix some missing CONFIG_CPU_MIPSR6 #ifdefs MIPS: hpet: Choose a safe value for the ETIME check MIPS: Loongson-3: Fix SMP_ASK_C0COUNT IPI handler Revert "MIPS: Fix PAGE_MASK definition" cputime: Prevent 32bit overflow in time[val|spec]_to_cputime() time: Avoid signed overflow in timekeeping_get_ns() Bluetooth: 6lowpan: Fix handling of uncompressed IPv6 packets Bluetooth: 6lowpan: Fix kernel NULL pointer dereferences Bluetooth: Fix incorrect removing of IRKs Bluetooth: Add support of Toshiba Broadcom based devices Bluetooth: Use continuous scanning when creating LE connections Drivers: hv: vmbus: Fix a Host signaling bug tools: hv: vss: fix the write()'s argument: error -> vss_msg mmc: sdhci: Allow override of get_cd() called from sdhci_request() mmc: sdhci: Allow override of mmc host operations mmc: sdhci-pci: Fix card detect race for Intel BXT/APL mmc: pxamci: fix again read-only gpio detection polarity mmc: sdhci-acpi: Fix card detect race for Intel BXT/APL mmc: mmci: fix an ages old detection error mmc: core: Enable tuning according to the actual timing mmc: sdhci: Fix sdhci_runtime_pm_bus_on/off() mmc: mmc: Fix incorrect use of driver strength switching HS200 and HS400 mmc: sdio: Fix invalid vdd in voltage switch power cycle mmc: sdhci: Fix DMA descriptor with zero data length mmc: sdhci-pci: Do not default to 33 Ohm driver strength for Intel SPT mmc: usdhi6rol0: handle NULL data in timeout clockevents/tcb_clksrc: Prevent disabling an already disabled clock posix-clock: Fix return code on the poll method's error path irqchip/gic-v3-its: Fix double ICC_EOIR write for LPI in EOImode==1 irqchip/atmel-aic: Fix wrong bit operation for IRQ priority irqchip/mxs: Add missing set_handle_irq() irqchip/omap-intc: Add support for spurious irq handling coresight: checking for NULL string in coresight_name_match() dm: fix dm_rq_target_io leak on faults with .request_fn DM w/ blk-mq paths dm snapshot: fix hung bios when copy error occurs dm space map metadata: remove unused variable in brb_pop() tda1004x: only update the frontend properties if locked vb2: fix a regression in poll() behavior for output,streams gspca: ov534/topro: prevent a division by 0 si2157: return -EINVAL if firmware blob is too big media: dvb-core: Don't force CAN_INVERSION_AUTO in oneshot mode rc: sunxi-cir: Initialize the spinlock properly namei: ->d_inode of a pinned dentry is stable only for positives mei: validate request value in client notify request ioctl mei: fix fasync return value on error rtlwifi: rtl8723be: Fix module parameter initialization rtlwifi: rtl8188ee: Fix module parameter initialization rtlwifi: rtl8192se: Fix module parameter initialization rtlwifi: rtl8723ae: Fix initialization of module parameters rtlwifi: rtl8192de: Fix incorrect module parameter descriptions rtlwifi: rtl8192ce: Fix handling of module parameters rtlwifi: rtl8192cu: Add missing parameter setup rtlwifi: rtl_pci: Fix kernel panic locks: fix unlock when fcntl_setlk races with a close um: link with -lpthread uml: fix hostfs mknod() uml: flush stdout before forking s390/fpu: signals vs. floating point control register s390/compat: correct restore of high gprs on signal return s390/dasd: fix performance drop s390/dasd: fix refcount for PAV reassignment s390/dasd: prevent incorrect length error under z/VM after PAV changes s390: fix normalization bug in exception table sorting btrfs: initialize the seq counter in struct btrfs_device Btrfs: Initialize btrfs_root->highest_objectid when loading tree root and subvolume roots Btrfs: fix transaction handle leak on failure to create hard link Btrfs: fix number of transaction units required to create symlink Btrfs: send, don't BUG_ON() when an empty symlink is found btrfs: statfs: report zero available if metadata are exhausted Btrfs: igrab inode in writepage Btrfs: add missing brelse when superblock checksum fails KVM: s390: fix memory overwrites when vx is disabled s390/kvm: remove dependency on struct save_area definition clocksource/drivers/vt8500: Increase the minimum delta genirq: Validate action before dereferencing it in handle_irq_event_percpu() mm: numa: quickly fail allocations for NUMA balancing on full nodes mm: thp: fix SMP race condition between THP page fault and MADV_DONTNEED ocfs2: unlock inode if deleting inode from orphan fails drm/i915: shut up gen8+ SDE irq dmesg noise iw_cxgb3: Fix incorrectly returning error on success spi: omap2-mcspi: Prevent duplicate gpio_request drivers: android: correct the size of struct binder_uintptr_t for BC_DEAD_BINDER_DONE USB: option: add "4G LTE usb-modem U901" USB: option: add support for SIM7100E USB: cp210x: add IDs for GE B650V3 and B850V3 boards usb: dwc3: Fix assignment of EP transfer resources can: ems_usb: Fix possible tx overflow dm thin: fix race condition when destroying thin pool workqueue bcache: Change refill_dirty() to always scan entire disk if necessary bcache: prevent crash on changing writeback_running bcache: allows use of register in udev to avoid "device_busy" error. bcache: unregister reboot notifier if bcache fails to unregister device bcache: fix a leak in bch_cached_dev_run() bcache: clear BCACHE_DEV_UNLINK_DONE flag when attaching a backing device bcache: Add a cond_resched() call to gc bcache: fix a livelock when we cause a huge number of cache misses lib/ucs2_string: Correct ucs2 -> utf8 conversion efi: Add pstore variables to the deletion whitelist efi: Make efivarfs entries immutable by default efi: Make our variable validation list include the guid efi: Do variable name validation tests in utf8 efi: Use ucs2_as_utf8 in efivarfs instead of open coding a bad version lib/ucs2_string: Add ucs2 -> utf8 helper functions ARM: 8457/1: psci-smp is built only for SMP drm/gma500: Use correct unref in the gem bo create function devm_memremap: Fix error value when memremap failed KVM: s390: fix guest fprs memory leak arm64: errata: Add -mpc-relative-literal-loads to build flags ARM: debug-ll: fix BCM63xx entry for multiplatform ext4: fix bh->b_state corruption sctp: Fix port hash table size computation unix_diag: fix incorrect sign extension in unix_lookup_by_ino tipc: unlock in error path rtnl: RTM_GETNETCONF: fix wrong return value IFF_NO_QUEUE: Fix for drivers not calling ether_setup() tcp/dccp: fix another race at listener dismantle route: check and remove route cache when we get route net_sched fix: reclassification needs to consider ether protocol changes pppoe: fix reference counting in PPPoE proxy l2tp: Fix error creating L2TP tunnels net/mlx4_en: Avoid changing dev->features directly in run-time net/mlx4_en: Choose time-stamping shift value according to HW frequency net/mlx4_en: Count HW buffer overrun only once qmi_wwan: add "4G LTE usb-modem U901" tcp: md5: release request socket instead of listener tipc: fix premature addition of node to lookup table af_unix: Guard against other == sk in unix_dgram_sendmsg af_unix: Don't set err in unix_stream_read_generic unless there was an error ipv4: fix memory leaks in ip_cmsg_send() callers bonding: Fix ARP monitor validation bpf: fix branch offset adjustment on backjumps after patching ctx expansion flow_dissector: Fix unaligned access in __skb_flow_dissector when used by eth_get_headlen net: Copy inner L3 and L4 headers as unaligned on GRE TEB sctp: translate network order to host order when users get a hmacid enic: increment devcmd2 result ring in case of timeout tg3: Fix for tg3 transmit queue 0 timed out when too many gso_segs net:Add sysctl_max_skb_frags tcp: do not drop syn_recv on all icmp reports unix: correctly track in-flight fds in sending process user_struct ipv6: fix a lockdep splat ipv6: addrconf: Fix recursive spin lock call ipv6/udp: use sticky pktinfo egress ifindex on connect() ipv6: enforce flowi6_oif usage in ip6_dst_lookup_tail() tcp: beware of alignments in tcp_get_info() switchdev: Require RTNL mutex to be held when sending FDB notifications inet: frag: Always orphan skbs inside ip_defrag() tipc: fix connection abort during subscription cancel net: dsa: fix mv88e6xxx switches sctp: allow setting SCTP_SACK_IMMEDIATELY by the application pptp: fix illegal memory access caused by multiple bind()s af_unix: fix struct pid memory leak tcp: fix NULL deref in tcp_v4_send_ack() lwt: fix rx checksum setting for lwt devices tunneling over ipv6 tunnels: Allow IPv6 UDP checksums to be correctly controlled. net: dp83640: Fix tx timestamp overflow handling. gro: Make GRO aware of lightweight tunnels. af_iucv: Validate socket address length in iucv_sock_bind() Conflicts: arch/arm64/Makefile arch/arm64/include/asm/cacheflush.h drivers/mmc/host/sdhci.c drivers/usb/dwc3/ep0.c drivers/usb/dwc3/gadget.c kernel/module.c sound/core/pcm_compat.c CRs-Fixed: 1010239 Signed-off-by: Runmin Wang <runminw@codeaurora.org> Change-Id: I41a28636fc9ad91f9d979b191784609476294cdf
2016-06-29mm: ksm: avoid trageted reclaim of ksm pagesVinayak Menon
Per Process Reclaim tries to avoid reclaiming of shared pages by passing the target VMA. For anon and file pages this works, but not for KSM. This is because vma_address(page) will not return the intended value resulting in crashes like this [From 3.10 kernel] kernel BUG at kernel/mm/rmap.c:534! (vma_address+0x28/0x2c) from [<c01eff94>] (try_to_unmap_ksm+0x4c/0x170) (try_to_unmap_ksm+0x4c/0x170) from [<c01e4834>] (try_to_unmap+0x34/0xa4) (try_to_unmap+0x34/0xa4) from [<c01c8e64>] (shrink_page_list+0x3f0/0xa34) (shrink_page_list+0x3f0/0xa34) from [<c01c9688>] (reclaim_pages_from_list) (reclaim_pages_from_list+0xb0/0x100) from [<c0240ed0>] (reclaim_pte_range) (reclaim_pte_range+0xf0/0x164) from [<c01e79a4>] (walk_page_range+0x1d0) (walk_page_range+0x1d0/0x260) from [<c0241ccc>] (reclaim_task_anon+0xb0) (reclaim_task_anon+0xb0/0x114) from [<c01f8d98>] (swap_fn+0x220/0x460) (swap_fn+0x220/0x460) from [<c0133a38>] (process_one_work+0x294/0x430) (process_one_work+0x294/0x430) from [<c0134720>] (worker_thread) (worker_thread+0x224/0x358) from [<c01390d4>] (kthread+0xa0/0xac) (kthread+0xa0/0xac) from [<c0105f38>] (ret_from_fork+0x14/0x3c) CRs-Fixed: 984947 Change-Id: I5208fb68372f7af72868e39399bf545fb7b774f3 Signed-off-by: Vinayak Menon <vinmenon@codeaurora.org>
2016-06-29mm: process_reclaim: use unbounded cpu workqueueShiraz Hashim
It is observed that in some cases process reclaim work doesn't get chance to run due to presence of RT scheduled on the same CPU. This is leading to user space freeze and a live-lock situation where RT itself is looping for a page to be present in swap cache while process reclaim work is unable to schedule and do the same. Schedule process reclaim work on unbounded cpu workqueue so that the work has opportunity to be scheduled on to other cpu. Change-Id: I6852f7e8d0a344ab5631b188627263f11414f27e Signed-off-by: Shiraz Hashim <shashim@codeaurora.org> Signed-off-by: Vinayak Menon <vinmenon@codeaurora.org>
2016-06-29mm: process_reclaim: do not iterate over stale task structsVinayak Menon
swap_fn iterates through the threads of selected tasks after a rcu_read_unlock which is wrong. But we can't extend the rcu_read_lock since it will result in severe performance issues. So better avoid iterating over the threads. Just lock the group leader and use it further. Change-Id: I36269b1b6619315f33f6f3b49ec73571a66796f2 Signed-off-by: Vinayak Menon <vinmenon@codeaurora.org>
2016-06-29mm: process_reclaim: fix reclaim skip on low efficiencyVinayak Menon
The logic used to skip reclaim on low efficiency results in process reclaim not triggering at all. Fix it by properly handling the skip_reclaim atomic variable. Change-Id: I119097bb9b1baf8f3e8d4afa0a6dc2c30c0de6e7 Signed-off-by: Vinayak Menon <vinmenon@codeaurora.org>
2016-06-29mm: process reclaim: vmpressure based process reclaimVinayak Menon
With this patch, anon pages of inactive tasks can be reclaimed, depending on memory pressure. Memory pressure is detected using vmpressure events. 'N' best tasks in terms of anon size is selected and pages proportional to their tasksize is reclaimed. The total number of pages reclaimed at each run of the swap work, can be tuned from userspace, the default being SWAP_CLUSTER_MAX * 32. The patch also adds tracepoints to debug and tune the feature. echo 1 > /sys/module/process_reclaim/parameters/enable_process_reclaim to enable the feature. echo <pages> > /sys/module/process_reclaim/parameters/per_swap_size, to set the number of pages reclaimed in each scan. /sys/module/process_reclaim/parameters/reclaim_avg_efficiency, provides the average efficiency (scan to reclaim ratio) of the algorithm. /sys/module/process_reclaim/parameters/swap_eff_win, to set the window period (in unit of number of times reclaim is triggered) to detect low efficiency runs. /sys/module/process_reclaim/parameters/swap_opt_eff, to set the optimal efficiency threshold for low efficiency detection. Change-Id: I895986f10c997d1715761eaaadc4bbbee60db9d2 Signed-off-by: Vinayak Menon <vinmenon@codeaurora.org>
2016-06-27Merge branch 'linux-linaro-lsk-v4.4' into linux-linaro-lsk-v4.4-androidAlex Shi
2016-06-24mm, sl[au]b: add __GFP_ATOMIC to the GFP reclaim maskMel Gorman
Commit d0164adc89f6 ("mm, page_alloc: distinguish between being unable to sleep, unwilling to sleep and avoiding waking kswapd") modified __GFP_WAIT to explicitly identify the difference between atomic callers and those that were unwilling to sleep. Later the definition was removed entirely. The GFP_RECLAIM_MASK is the set of flags that affect watermark checking and reclaim behaviour but __GFP_ATOMIC was never added. Without it, atomic users of the slab allocator strip the __GFP_ATOMIC flag and cannot access the page allocator atomic reserves. This patch addresses the problem. The user-visible impact depends on the workload but potentially atomic allocations unnecessarily fail without this path. Change-Id: Ieac0932d146f7fd992db9fd834b0e9aa3822f891 Link: http://lkml.kernel.org/r/20160610093832.GK2527@techsingularity.net Signed-off-by: Mel Gorman <mgorman@techsingularity.net> Reported-by: Marcin Wojtas <mw@semihalf.com> Acked-by: Vlastimil Babka <vbabka@suse.cz> Acked-by: Michal Hocko <mhocko@suse.com> Cc: <stable@vger.kernel.org> [4.4+] Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Git-Commit: 843f65ccbb2273430b57ae135ccd26dddee05be7 Git-repo: git://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git Signed-off-by: Vinayak Menon <vinmenon@codeaurora.org>
2016-06-24memcg: add RCU locking around css_for_each_descendant_pre() in ↵Tejun Heo
memcg_offline_kmem() commit 3a06bb78ceeceacc86a1e31133a7944013f9775b upstream. memcg_offline_kmem() may be called from memcg_free_kmem() after a css init failure. memcg_free_kmem() is a ->css_free callback which is called without cgroup_mutex and memcg_offline_kmem() ends up using css_for_each_descendant_pre() without any locking. Fix it by adding rcu read locking around it. mkdir: cannot create directory `65530': No space left on device =============================== [ INFO: suspicious RCU usage. ] 4.6.0-work+ #321 Not tainted ------------------------------- kernel/cgroup.c:4008 cgroup_mutex or RCU read lock required! [ 527.243970] other info that might help us debug this: [ 527.244715] rcu_scheduler_active = 1, debug_locks = 0 2 locks held by kworker/0:5/1664: #0: ("cgroup_destroy"){.+.+..}, at: [<ffffffff81060ab5>] process_one_work+0x165/0x4a0 #1: ((&css->destroy_work)#3){+.+...}, at: [<ffffffff81060ab5>] process_one_work+0x165/0x4a0 [ 527.248098] stack backtrace: CPU: 0 PID: 1664 Comm: kworker/0:5 Not tainted 4.6.0-work+ #321 Hardware name: QEMU Standard PC (i440FX + PIIX, 1996), BIOS 1.9.1-1.fc24 04/01/2014 Workqueue: cgroup_destroy css_free_work_fn Call Trace: dump_stack+0x68/0xa1 lockdep_rcu_suspicious+0xd7/0x110 css_next_descendant_pre+0x7d/0xb0 memcg_offline_kmem.part.44+0x4a/0xc0 mem_cgroup_css_free+0x1ec/0x200 css_free_work_fn+0x49/0x5e0 process_one_work+0x1c5/0x4a0 worker_thread+0x49/0x490 kthread+0xea/0x100 ret_from_fork+0x1f/0x40 Link: http://lkml.kernel.org/r/20160526203018.GG23194@mtj.duckdns.org Signed-off-by: Tejun Heo <tj@kernel.org> Acked-by: Vladimir Davydov <vdavydov@virtuozzo.com> Acked-by: Johannes Weiner <hannes@cmpxchg.org> Cc: Michal Hocko <mhocko@kernel.org> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2016-06-22mm: Support address range reclaimMinchan Kim
This patch adds address range reclaim of a process. The requirement is following as, Like webkit1, it uses a address space for handling multi tabs. IOW, it uses *one* process model so all tabs shares address space of the process. In such scenario, per-process reclaim is rather coarse-grained so this patch supports more fine-grained reclaim for being able to reclaim target address range of the process. For reclaim target range, you should use following format. echo [addr] [size-byte] > /proc/pid/reclaim The addr should be page-aligned. So now reclaim konb's interface is following as. echo file > /proc/pid/reclaim reclaim file-backed pages only echo anon > /proc/pid/reclaim reclaim anonymous pages only echo all > /proc/pid/reclaim reclaim all pages echo 0x100000 8K > /proc/pid/reclaim reclaim pages in (0x100000 - 0x102000) Change-Id: I111131d31be1cfcfa246617b634a9a8bc4078098 Signed-off-by: Minchan Kim <minchan@kernel.org> Patch-mainline: linux-mm @ 9 May 2013 08:39:01 [vinmenon@codeaurora.org: trivial merge conflict fixes] Signed-off-by: Vinayak Menon <vinmenon@codeaurora.org>
2016-06-22mm: Enhance per process reclaim to consider shared pagesMinchan Kim
Some pages could be shared by several processes. (ex, libc) In case of that, it's too bad to reclaim them from the beginnig. This patch causes VM to keep them on memory until last task try to reclaim them so shared pages will be reclaimed only if all of task has gone swapping out. This feature doesn't handle non-linear mapping on ramfs because it's very time-consuming and doesn't make sure of reclaiming and not common. Change-Id: I7e5f34f2e947f5db6d405867fe2ad34863ca40f7 Signed-off-by: Sangseok Lee <sangseok.lee@lge.com> Signed-off-by: Minchan Kim <minchan@kernel.org> Patch-mainline: linux-mm @ 9 May 2013 16:21:27 [vinmenon@codeaurora.org: trivial merge conflict fixes + changes to make the patch work with 3.18 kernel] Signed-off-by: Vinayak Menon <vinmenon@codeaurora.org>
2016-06-22mm: Remove shrink_pageMinchan Kim
By previous patch, shrink_page_list can handle pages from multiple zone so let's remove shrink_page. Change-Id: I3526377aa6ee6142b8f3ec63396e7ada1e442505 Signed-off-by: Minchan Kim <minchan@kernel.org> Patch-mainline: linux-mm @ 22 Apr 2013 17:45:03 [vinmenon@codeaurora.org: trivial merge conflict fixes] Signed-off-by: Vinayak Menon <vinmenon@codeaurora.org>
2016-06-22mm: make shrink_page_list with pages work from multiple zonesMinchan Kim
Shrink_page_list expects all pages come from a same zone but it's too limited to use. This patch removes the dependency so next patch can use shrink_page_list with pages from multiple zones. Change-Id: I34469b7f0a79f2b79e30e40033ba8b3e1dd5f2d0 Signed-off-by: Minchan Kim <minchan@kernel.org> Patch-mainline: linux-mm @ 9 May 2013 16:21:25 [vinmenon@codeaurora.org: trivial merge conflict fixes] Signed-off-by: Vinayak Menon <vinmenon@codeaurora.org>
2016-06-22mm: Per process reclaimMinchan Kim
These day, there are many platforms avaiable in the embedded market and they are smarter than kernel which has very limited information about working set so they want to involve memory management more heavily like android's lowmemory killer and ashmem or recent many lowmemory notifier. One of the simple imagine scenario about userspace's intelligence is that platform can manage tasks as forground and backgroud so it would be better to reclaim background's task pages for end-user's *responsibility* although it has frequent referenced pages. This patch adds new knob "reclaim under proc/<pid>/" so task manager can reclaim any target process anytime, anywhere. It could give another method to platform for using memory efficiently. It can avoid process killing for getting free memory, which was really terrible experience because I lost my best score of game I had ever after I switch the phone call while I enjoyed the game. Reclaim file-backed pages only. echo file > /proc/PID/reclaim Reclaim anonymous pages only. echo anon > /proc/PID/reclaim Reclaim all pages echo all > /proc/PID/reclaim Change-Id: Iabdb7bc2ef3dc4d94e3ea005fbe18f4cd06739ab Signed-off-by: Minchan Kim <minchan@kernel.org> Patch-mainline: linux-mm @ 9 May 2013 16:21:24 [vinmenon@codeaurora.org: trivial merge conflict fixes, and minor tweak of the commit msg] Signed-off-by: Vinayak Menon <vinmenon@codeaurora.org>
2016-06-22mm: prevent to write out dirty page in CMA by may_writepageMinchan Kim
Now, local variable references in shrink_page_list is PAGEREF_RECLAIM_CLEAN as default. It is for preventing to reclaim dirty pages when CMA try to migrate pages. Strictly speaking, we don't need it because CMA already didn't allow to write out by .may_writepage = 0 in reclaim_clean_pages_from_list. Morever, it has a problem to prevent anonymous pages's swap out when we use force_reclaim = true in shrink_page_list(ex, per process reclaim can do it) So this patch makes references's default value to PAGEREF_RECLAIM and declare .may_writepage = 0 of scan_control in CMA part to make code more clear. Change-Id: I5edc3c955d106ecebc4949ce27daf5b7b7a18089 Cc: Marek Szyprowski <m.szyprowski@samsung.com> Cc: Mel Gorman <mgorman@suse.de> Reported-by: Minkyung Kim <minkyung88@lge.com> Signed-off-by: Minchan Kim <minchan@kernel.org> Patch-mainline: linux-mm @ 9 May 2013 16:21:23 [vinmenon@codeaurora.org: trivial merge conflict fixes] Signed-off-by: Vinayak Menon <vinmenon@codeaurora.org>
2016-06-14Merge branch 'linux-linaro-lsk-v4.4' into linux-linaro-lsk-v4.4-androidAlex Shi
2016-06-13mm: fix cma accounting in zone_watermark_okVinayak Menon
Some cases were reported on 3.18 where atomic unmovable allocations of order 2 fails, but kswapd does not wakeup. And in such cases it was seen that, when zone_watermark_ok check is performed to decide whether to wake up kswapd, there were lot of CMA pages of order 2 and above. This makes the watermark check succeed resulting in kswapd not being woken up. But since these atomic unmovable allocations can't come from CMA region, further atomic allocations keeps failing, without kswapd trying to reclaim. Usually concurrent movable allocations result in reclaim and improves the situtation, but the case reported was from a network test which was resulting in only atomic skb allocations being attempted. On 3.18 this was fixed by adding a cma free page counter and accouting the cma free pages properly in watermark calculations. Later this issue was indirectly fixed by the commit "mm, page_alloc: only enforce watermarks for order-0 allocations". But the commit "mm: add cma pcp list" brought the problem back because it includes MIGRATE_CMA within MIGRATE_PCPTYPES, and thus watermark check erroneously returns success for !ALLOC_CMA by finding free pages in cma free list. Change-Id: Id0e48b5c2f9deea93c5875c10d5ec72bd360df5f Signed-off-by: Vinayak Menon <vinmenon@codeaurora.org>
2016-06-07mm: use phys_addr_t for reserve_bootmem_region() argumentsStefan Bader
commit 4b50bcc7eda4d3cc9e3f2a0aa60e590fedf728c5 upstream. Since commit 92923ca3aace ("mm: meminit: only set page reserved in the memblock region") the reserved bit is set on reserved memblock regions. However start and end address are passed as unsigned long. This is only 32bit on i386, so it can end up marking the wrong pages reserved for ranges at 4GB and above. This was observed on a 32bit Xen dom0 which was booted with initial memory set to a value below 4G but allowing to balloon in memory (dom0_mem=1024M for example). This would define a reserved bootmem region for the additional memory (for example on a 8GB system there was a reverved region covering the 4GB-8GB range). But since the addresses were passed on as unsigned long, this was actually marking all pages from 0 to 4GB as reserved. Fixes: 92923ca3aacef63 ("mm: meminit: only set page reserved in the memblock region") Link: http://lkml.kernel.org/r/1463491221-10573-1-git-send-email-stefan.bader@canonical.com Signed-off-by: Stefan Bader <stefan.bader@canonical.com> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2016-06-07mm/page_alloc: prevent merging between isolated and other pageblocksVlastimil Babka
Hanjun Guo has reported that a CMA stress test causes broken accounting of CMA and free pages: > Before the test, I got: > -bash-4.3# cat /proc/meminfo | grep Cma > CmaTotal: 204800 kB > CmaFree: 195044 kB > > > After running the test: > -bash-4.3# cat /proc/meminfo | grep Cma > CmaTotal: 204800 kB > CmaFree: 6602584 kB > > So the freed CMA memory is more than total.. > > Also the the MemFree is more than mem total: > > -bash-4.3# cat /proc/meminfo > MemTotal: 16342016 kB > MemFree: 22367268 kB > MemAvailable: 22370528 kB Laura Abbott has confirmed the issue and suspected the freepage accounting rewrite around 3.18/4.0 by Joonsoo Kim. Joonsoo had a theory that this is caused by unexpected merging between MIGRATE_ISOLATE and MIGRATE_CMA pageblocks: > CMA isolates MAX_ORDER aligned blocks, but, during the process, > partialy isolated block exists. If MAX_ORDER is 11 and > pageblock_order is 9, two pageblocks make up MAX_ORDER > aligned block and I can think following scenario because pageblock > (un)isolation would be done one by one. > > (each character means one pageblock. 'C', 'I' means MIGRATE_CMA, > MIGRATE_ISOLATE, respectively. > > CC -> IC -> II (Isolation) > II -> CI -> CC (Un-isolation) > > If some pages are freed at this intermediate state such as IC or CI, > that page could be merged to the other page that is resident on > different type of pageblock and it will cause wrong freepage count. This was supposed to be prevented by CMA operating on MAX_ORDER blocks, but since it doesn't hold the zone->lock between pageblocks, a race window does exist. It's also likely that unexpected merging can occur between MIGRATE_ISOLATE and non-CMA pageblocks. This should be prevented in __free_one_page() since commit 3c605096d315 ("mm/page_alloc: restrict max order of merging on isolated pageblock"). However, we only check the migratetype of the pageblock where buddy merging has been initiated, not the migratetype of the buddy pageblock (or group of pageblocks) which can be MIGRATE_ISOLATE. Joonsoo has suggested checking for buddy migratetype as part of page_is_buddy(), but that would add extra checks in allocator hotpath and bloat-o-meter has shown significant code bloat (the function is inline). This patch reduces the bloat at some expense of more complicated code. The buddy-merging while-loop in __free_one_page() is initially bounded to pageblock_border and without any migratetype checks. The checks are placed outside, bumping the max_order if merging is allowed, and returning to the while-loop with a statement which can't be possibly considered harmful. This fixes the accounting bug and also removes the arguably weird state in the original commit 3c605096d315 where buddies could be left unmerged. Fixes: 3c605096d315 ("mm/page_alloc: restrict max order of merging on isolated pageblock") Link: https://lkml.org/lkml/2016/3/2/280 Signed-off-by: Vlastimil Babka <vbabka@suse.cz> Reported-by: Hanjun Guo <guohanjun@huawei.com> Tested-by: Hanjun Guo <guohanjun@huawei.com> Acked-by: Joonsoo Kim <iamjoonsoo.kim@lge.com> Debugged-by: Laura Abbott <labbott@redhat.com> Debugged-by: Joonsoo Kim <iamjoonsoo.kim@lge.com> Cc: Mel Gorman <mgorman@techsingularity.net> Cc: "Kirill A. Shutemov" <kirill@shutemov.name> Cc: Johannes Weiner <hannes@cmpxchg.org> Cc: Minchan Kim <minchan@kernel.org> Cc: Yasuaki Ishimatsu <isimatu.yasuaki@jp.fujitsu.com> Cc: Zhang Yanfei <zhangyanfei@cn.fujitsu.com> Cc: Michal Nazarewicz <mina86@mina86.com> Cc: Naoya Horiguchi <n-horiguchi@ah.jp.nec.com> Cc: "Aneesh Kumar K.V" <aneesh.kumar@linux.vnet.ibm.com> Cc: <stable@vger.kernel.org> [3.18+] Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org> Change-Id: I768a9c4886aa3fe2e827aba682f67bac2dba6f71 Git-commit: d9dddbf556674bf125ecd925b24e43a5cf2a568a Git-repo: git://git.kernel.org/pub/scm/linux/kernel/git/next/linux-next.git [vinemenon@codeaurora.org: fix trivial merge conflicts] Signed-off-by: Vinayak Menon <vinmenon@codeaurora.org> Signed-off-by: Shiraz Hashim <shashim@codeaurora.org>
2016-06-07mm: zcache: fix merge issuesVinayak Menon
Fix 4.4 merge issues in zero page support, and add the missing label. Change-Id: I4bed7add011e0c9b0e148d1b44132ba1873cf607 Signed-off-by: Vinayak Menon <vinmenon@codeaurora.org>
2016-06-07arm64: Add support for app specific settingsSarangdhar Joshi
Add support to provide an interface that can be used from userspace to decide whether app specific settings need to be applied / cleared when particular processes are running. CRs-Fixed: 981519 997757 Change-Id: Id81f8b70de64f291a8586150f4d2c7c8f8b4420f Signed-off-by: Sarangdhar Joshi <spjoshi@codeaurora.org> [satyap@codeaurora.org: trivial merge conflict resolution and pull fixes for CR: 997757] Signed-off-by: Satya Durga Srinivasu Prabhala <satyap@codeaurora.org>
2016-06-02Merge branch 'lsk-v4.4-android' of ↵Alex Shi
git://android.git.linaro.org/kernel/linaro-android into linux-linaro-lsk-v4.4-android
2016-05-31mm: zcache: remove __GFP_NO_KSWAPDVinayak Menon
Remove __GFP_NO_KSWAPD. It no longer exist. Change-Id: I8b50a06bdae050b3a3c47b80e21d0d2edf18b7c5 Signed-off-by: Vinayak Menon <vinmenon@codeaurora.org>
2016-05-31mm: add WasActive page flagBob Liu
Zcache could be ineffective if the compressed memory pool is full with compressed inactive file pages and most of them will be never used again. So we pick up pages from active file list only, those pages would probably be accessed again. Compress them in memory can reduce the latency significantly compared with rereading from disk. When a file page is shrunk from active file list to inactive file list, PageActive flag is also cleared. So adding an extra WasActive page flag for zcache to know whether the file page was shrunk from the active list. Change-Id: Ida1f4db17075d1f6f825ef7ce2b3bae4eb799e3f Signed-off-by: Bob Liu <bob.liu@oracle.com> Patch-mainline: linux-mm @ 2013-08-06 11:36:17 [vinmenon@codeaurora.org: trivial merge conflict fixes, checkpatch fixes, fix the definitions of was_active page flag so that it does not create compile time errors with CONFIG_CLEANCACHE disabled. Also remove the unnecessary use of PG_was_active in PAGE_FLAGS_CHECK_AT_PREP. Since was_active is a requirement for zcache, make the definitions dependent on CONFIG_ZCACHE rather than CONFIG_CLEANCACHE.] Signed-off-by: Vinayak Menon <vinmenon@codeaurora.org>
2016-05-31mm/memblock: disable local irqs while late memblock changesShiraz Hashim
There is a possibility of deadlock while doing late memblock configuration as only preemption is disabled and irq can be serviced while seqlock is held and in turn memblock_is_memory can be called from irq context thus trying to claim seqlock again. Following call stack was observed, [<c02136d4>] memblock_search+0x1c [<c021487c>] memblock_is_memory+0x10 [<c01e4684>] free_kmem_pages+0x44 [<c0121c04>] free_task+0x28 [<c0178b30>] rcu_process_callbacks+0x488 [<c0127e30>] __do_softirq+0x150 [<c0128284>] irq_exit+0x84 [<c010c11c>] handle_IPI+0x12c [<c0100588>] gic_handle_irq+0x70 [<c0e9efc0>] __irq_svc+0x40 [<c0214a8c>] memblock_region_resize_late_end+0xc [<c057010c>] removed_alloc+0x110 [<c04ab2c4>] pil_boot+0x2b0 [<c04b7700>] __subsystem_get+0xe0 [<c04b79cc>] subsys_device_open+0x74 [<c0229f20>] chrdev_open+0x12c [<c02246e4>] do_dentry_open+0x280 [<c0232698>] do_last+0x9a4 [<c0232b8c>] path_openat+0x23c [<c0233bf0>] do_filp_open+0x2c Fix it by disabling irqs during late memblock configuration. It is a one time operation which changes memblock related data structures and doesn't carry performance impact. CRs-Fixed: 1003890 Change-Id: I3ff1894f0c80580920b1971cda357915665b5054 Signed-off-by: Shiraz Hashim <shashim@codeaurora.org>
2016-05-31mm: swap_ratio: bail out if there aren't any other swap deviceVinayak Menon
It is pointless to calculate the swap ratio when there is only one swap device in the group. Moreover the existing code would result in a spinlock recursion because of not taking this into consideration. Interestingly, this check is already performed in swap_ratio_slow by this piece of code if (&(*si)->avail_list == plist_last(&swap_avail_head)) { /* just to make skip work */ n = *si; ret = -ENODEV; goto skip; } But there is window where we drop the swap_avail_lock before invoking swap_ratio() and take it back again in swap_ratio_slow. In this period the si can get removed from swap_avail_head, resulting in the failure of above logic. So recheck again. Similarly, bail out from swap_ratio() if the sysctl is disabled, and thus avoiding overhead of taking unnecessary locks. Change-Id: I81a9dd61d24b7da55d5341c48a1f71d2b4b1978d Signed-off-by: Vinayak Menon <vinmenon@codeaurora.org>
2016-05-31mm: vmscan: fix the page state calculation in too_many_isolatedVinayak Menon
It is observed that sometimes multiple tasks get blocked in the congestion_wait loop below, in shrink_inactive_list. (__schedule) from [<c0a03328>] (schedule_timeout) from [<c0a04940>] (io_schedule_timeout) from [<c01d585c>] (congestion_wait) from [<c01cc9d8>] (shrink_inactive_list) from [<c01cd034>] (shrink_zone) from [<c01cdd08>] (try_to_free_pages) from [<c01c442c>] (__alloc_pages_nodemask) from [<c01f1884>] (new_slab) from [<c09fcf60>] (__slab_alloc) from [<c01f1a6c>] In one such instance, zone_page_state(zone, NR_ISOLATED_FILE) had returned 14, zone_page_state(zone, NR_INACTIVE_FILE) returned 92, and the gfp_flag was GFP_KERNEL which resulted in too_many_isolated to return true. But one of the CPU pageset vmstat diff had NR_ISOLATED_FILE as -14. As there weren't any more update to per cpu pageset, the threshold wasn't met, and the tasks were blocked in the congestion wait. This patch uses zone_page_state_snapshot instead, but restricts its usage to avoid performance penalty. Change-Id: Iec767a548e524729c7ed79a92fe4718cdd08ce69 Signed-off-by: Vinayak Menon <vinmenon@codeaurora.org>
2016-05-20Merge branch 'linux-linaro-lsk-v4.4' into linux-linaro-lsk-v4.4-androidAlex Shi
2016-05-19Revert "mm: vmscan: Add a debug file for shrinkers"Dmitry Shmidt
Kernel panic when type "cat /sys/kernel/debug/shrinker" Unable to handle kernel paging request at virtual address 0af37d40 pgd = d4dec000 [0af37d40] *pgd=00000000 Internal error: Oops: 5 [#1] PREEMPT SMP ARM [<c0bb8f24>] (_raw_spin_lock) from [<c020aa08>] (list_lru_count_one+0x14/0x28) [<c020aa08>] (list_lru_count_one) from [<c02309a8>] (super_cache_count+0x40/0xa0) [<c02309a8>] (super_cache_count) from [<c01f6ab0>] (debug_shrinker_show+0x50/0x90) [<c01f6ab0>] (debug_shrinker_show) from [<c024fa5c>] (seq_read+0x1ec/0x48c) [<c024fa5c>] (seq_read) from [<c022e8f8>] (__vfs_read+0x20/0xd0) [<c022e8f8>] (__vfs_read) from [<c022f0d0>] (vfs_read+0x7c/0x104) [<c022f0d0>] (vfs_read) from [<c022f974>] (SyS_read+0x44/0x9c) [<c022f974>] (SyS_read) from [<c0107580>] (ret_fast_syscall+0x0/0x3c) Code: e1a04000 e3a00001 ebd66b39 f594f000 (e1943f9f) ---[ end trace 60c74014a63a9688 ]--- Kernel panic - not syncing: Fatal exception shrink_control.nid is used but not initialzed, same for shrink_control.memcg. This reverts commit b0e7a582b2264cdf75874dcd8df915b6b4427755. Change-Id: I108de88fa4baaef99a53c4e4c6a1d8c4b4804157 Reported-by: Xiaowen Liu <xiaowen.liu@freescale.com> Signed-off-by: Dmitry Shmidt <dimitrysh@google.com>
2016-05-18zsmalloc: fix zs_can_compact() integer overflowSergey Senozhatsky
commit 44f43e99fe70833058482d183e99fdfd11220996 upstream. zs_can_compact() has two race conditions in its core calculation: unsigned long obj_wasted = zs_stat_get(class, OBJ_ALLOCATED) - zs_stat_get(class, OBJ_USED); 1) classes are not locked, so the numbers of allocated and used objects can change by the concurrent ops happening on other CPUs 2) shrinker invokes it from preemptible context Depending on the circumstances, thus, OBJ_ALLOCATED can become less than OBJ_USED, which can result in either very high or negative `total_scan' value calculated later in do_shrink_slab(). do_shrink_slab() has some logic to prevent those cases: vmscan: shrink_slab: zs_shrinker_scan+0x0/0x28 [zsmalloc] negative objects to delete nr=-62 vmscan: shrink_slab: zs_shrinker_scan+0x0/0x28 [zsmalloc] negative objects to delete nr=-62 vmscan: shrink_slab: zs_shrinker_scan+0x0/0x28 [zsmalloc] negative objects to delete nr=-64 vmscan: shrink_slab: zs_shrinker_scan+0x0/0x28 [zsmalloc] negative objects to delete nr=-62 vmscan: shrink_slab: zs_shrinker_scan+0x0/0x28 [zsmalloc] negative objects to delete nr=-62 vmscan: shrink_slab: zs_shrinker_scan+0x0/0x28 [zsmalloc] negative objects to delete nr=-62 However, due to the way `total_scan' is calculated, not every shrinker->count_objects() overflow can be spotted and handled. To demonstrate the latter, I added some debugging code to do_shrink_slab() (x86_64) and the results were: vmscan: OVERFLOW: shrinker->count_objects() == -1 [18446744073709551615] vmscan: but total_scan > 0: 92679974445502 vmscan: resulting total_scan: 92679974445502 [..] vmscan: OVERFLOW: shrinker->count_objects() == -1 [18446744073709551615] vmscan: but total_scan > 0: 22634041808232578 vmscan: resulting total_scan: 22634041808232578 Even though shrinker->count_objects() has returned an overflowed value, the resulting `total_scan' is positive, and, what is more worrisome, it is insanely huge. This value is getting used later on in shrinker->scan_objects() loop: while (total_scan >= batch_size || total_scan >= freeable) { unsigned long ret; unsigned long nr_to_scan = min(batch_size, total_scan); shrinkctl->nr_to_scan = nr_to_scan; ret = shrinker->scan_objects(shrinker, shrinkctl); if (ret == SHRINK_STOP) break; freed += ret; count_vm_events(SLABS_SCANNED, nr_to_scan); total_scan -= nr_to_scan; cond_resched(); } `total_scan >= batch_size' is true for a very-very long time and 'total_scan >= freeable' is also true for quite some time, because `freeable < 0' and `total_scan' is large enough, for example, 22634041808232578. The only break condition, in the given scheme of things, is shrinker->scan_objects() == SHRINK_STOP test, which is a bit too weak to rely on, especially in heavy zsmalloc-usage scenarios. To fix the issue, take a pool stat snapshot and use it instead of racy zs_stat_get() calls. Link: http://lkml.kernel.org/r/20160509140052.3389-1-sergey.senozhatsky@gmail.com Signed-off-by: Sergey Senozhatsky <sergey.senozhatsky@gmail.com> Cc: Minchan Kim <minchan@kernel.org> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2016-05-18mm: cma: sleep between retries in cma_allocLiam Mark
Port support from 3.10 for retrying cma allocations to 3.18 to help resolve cma allocation failures. It was observed that CMA pages are sometimes getting pinned down by BG processes scheduled out in their exit path. Since BG processes have lower priority they end up getting less time slice by scheduler there by consuming more time to free up CMA pages. Also when a process is being forked copy_one_pte may create copy-on-write mappings, when this is done the page _count and page _mapcount are each incremented sequentially. If the process is context switched out after incrementing the _count but before incrementing the _mapcount then the page will appear temporarily pinned. So instead of failing to allocate and directly returning an error on the CMA allocation path we do 2 retries, with sleeps, to give the system an opportunity to unpin any pinned pages. Change-Id: I022a9341f8ee44f281c7cb34769695843e97d684 Signed-off-by: Susheel Khiani <skhiani@codeaurora.org> Signed-off-by: Liam Mark <lmark@codeaurora.org>