[PATCH AUTOSEL 4.19 096/192] cgroup, rstat: Don't flush subtree root unless necessary

2019-03-27 Thread Sasha Levin
From: Tejun Heo [ Upstream commit b4ff1b44bcd384d22fcbac6ebaf9cc0d33debe50 ] cgroup_rstat_cpu_pop_updated() is used to traverse the updated cgroups on flush. While it was only visiting updated ones in the subtree, it was visiting @root unconditionally. We can easily check whether @root is

Re: [PATCH 1/2] efi: add a function for transferring status to string

2019-03-27 Thread Mimi Zohar
On Wed, 2019-03-27 at 19:58 +0100, Ard Biesheuvel wrote: > On Sun, 24 Mar 2019 at 01:26, Lee, Chun-Yi wrote: > > > > This function can be used to transfer EFI status code to string > > for printing out debug message. Using this function can improve > > the readability of log. Maybe instead of

[PATCH AUTOSEL 4.19 095/192] HID: intel-ish-hid: avoid binding wrong ishtp_cl_device

2019-03-27 Thread Sasha Levin
From: Hong Liu [ Upstream commit 0d28f49412405d87d3aae83da255070a46e67627 ] When performing a warm reset in ishtp bus driver, the ishtp_cl_device will not be removed, its fw_client still points to the already freed ishtp_device.fw_clients array. Later after driver finishing ishtp client

[PATCH AUTOSEL 4.19 099/192] perf report: Add s390 diagnosic sampling descriptor size

2019-03-27 Thread Sasha Levin
From: Thomas Richter [ Upstream commit 2187d87eacd46f6214ce3dc9cfd7a558375a4153 ] On IBM z13 machine types 2964 and 2965 the descriptor sizes for sampling and diagnostic sampling entries might be missing in the trailer entry and are set to zero. This leads to a perf report failure when

[PATCH AUTOSEL 4.19 097/192] jbd2: fix race when writing superblock

2019-03-27 Thread Sasha Levin
From: Theodore Ts'o [ Upstream commit 538bcaa6261b77e71d37f5596c33127c1a3ec3f7 ] The jbd2 superblock is lockless now, so there is probably a race condition between writing it so disk and modifing contents of it, which may lead to checksum error. The following race is the one case that we have

[PATCH AUTOSEL 4.19 101/192] ACPI / video: Refactor and fix dmi_is_desktop()

2019-03-27 Thread Sasha Levin
From: Hans de Goede [ Upstream commit cecf3e3e0803462335e25d083345682518097334 ] This commit refactors the chassis-type detection introduced by commit 53fa1f6e8a59 ("ACPI / video: Only default only_lcd to true on Win8-ready _desktops_") (where desktop means anything without a builtin screen).

[PATCH v2 2/2] arm64: dts: imx8qxp: Add EDMA0/EDMA1 nodes

2019-03-27 Thread Daniel Baluta
i.MX8QXP contains a total of 4 EDMA controllers of which two are primarily for audio components and the other two are for non-audio periperhals. This patch adds the EDMA0/EDMA1 nodes used by audio peripherals. EDMA0 contains channels for: * ASRC0 * ESAI0 * SPDIF0

[PATCH v2 1/2] bindings: fsl-edma: Document fsl,imx8qxp-edma compatbile string

2019-03-27 Thread Daniel Baluta
Add imx8qxp edma support. Signed-off-by: Daniel Baluta --- Documentation/devicetree/bindings/dma/fsl-edma.txt | 1 + 1 file changed, 1 insertion(+) diff --git a/Documentation/devicetree/bindings/dma/fsl-edma.txt b/Documentation/devicetree/bindings/dma/fsl-edma.txt index

[PATCH v2 0/2] Add EDMA0/EDMA1 nodes on i.MX8QXP

2019-03-27 Thread Daniel Baluta
First patch documents the fsl,imx8qxp-edma string while the second adds the two EDMA nodes used by Audio peripherals on i.MX8QXP Changes since v1: * use "fsl,imx8qxp-edma" compatbile instead of "fsl,imx8qm-edma" because this patch adds support for imx8QXP. eDMA driver is similar

[PATCH AUTOSEL 4.19 108/192] ARM: dts: meson8b: fix the Ethernet data line signals in eth_rgmii_pins

2019-03-27 Thread Sasha Levin
From: Martin Blumenstingl [ Upstream commit 29f0023d01f063feacfc404f0446905aee4f82ee ] According to the Odroid-C1+ schematics the Ethernet TXD1 signal is routed to GPIOH_5 and the TXD0 signal is routed to GPIOH_6. The public S805 datasheet shows that TXD0 can be routed to DIF_2_P and TXD1 can

[PATCH AUTOSEL 4.19 105/192] kprobes: Prohibit probing on RCU debug routine

2019-03-27 Thread Sasha Levin
From: Masami Hiramatsu [ Upstream commit a39f15b9644fac3f950f522c39e667c3af25c588 ] Since kprobe itself depends on RCU, probing on RCU debug routine can cause recursive breakpoint bugs. Prohibit probing on RCU debug routines. int3 ->do_int3() ->ist_enter() ->RCU_LOCKDEP_WARN()

[PATCH AUTOSEL 4.19 134/192] sched/debug: Initialize sd_sysctl_cpus if !CONFIG_CPUMASK_OFFSTACK

2019-03-27 Thread Sasha Levin
From: Hidetoshi Seto [ Upstream commit 1ca4fa3ab604734e38e2a3000c9abf788512ffa7 ] register_sched_domain_sysctl() copies the cpu_possible_mask into sd_sysctl_cpus, but only if sd_sysctl_cpus hasn't already been allocated (ie, CONFIG_CPUMASK_OFFSTACK is set). However, when

Re: [RFC 0/7] cpuidle: Add poking mechanism to support non-IPI wakeup

2019-03-27 Thread Marc Zyngier
On 27/03/2019 17:00, Leonard Crestez wrote: > On Wed, 2019-03-27 at 17:06 +0100, Lucas Stach wrote: >> Am Mittwoch, den 27.03.2019, 15:57 + schrieb Marc Zyngier: >>> On 27/03/2019 15:44, Lucas Stach wrote: Am Mittwoch, den 27.03.2019, 13:21 + schrieb Abel Vesa: > This work is a

[PATCH AUTOSEL 4.19 109/192] ALSA: PCM: check if ops are defined before suspending PCM

2019-03-27 Thread Sasha Levin
From: Ranjani Sridharan [ Upstream commit d9c0b2afe820fa3b3f8258a659daee2cc71ca3ef ] BE dai links only have internal PCM's and their substream ops may not be set. Suspending these PCM's will result in their ops->trigger() being invoked and cause a kernel oops. So skip suspending PCM's if their

[PATCH AUTOSEL 4.19 115/192] bcache: fix potential div-zero error of writeback_rate_i_term_inverse

2019-03-27 Thread Sasha Levin
From: Coly Li [ Upstream commit c3b75a2199cdbfc1c335155fe143d842604b1baa ] dc->writeback_rate_i_term_inverse can be set via sysfs interface. It is in type unsigned int, and convert from input string by d_strtoul(). The problem is d_strtoul() does not check valid range of the input, if

[PATCH AUTOSEL 4.19 113/192] bcache: fix input overflow to cache set sysfs file io_error_halflife

2019-03-27 Thread Sasha Levin
From: Coly Li [ Upstream commit a91fbda49f746119828f7e8ad0f0aa2ab0578f65 ] Cache set sysfs entry io_error_halflife is used to set c->error_decay. c->error_decay is in type unsigned int, and it is converted by strtoul_or_return(), therefore overflow to c->error_decay is possible for a large

[PATCH AUTOSEL 4.19 112/192] sched/topology: Fix percpu data types in struct sd_data & struct s_data

2019-03-27 Thread Sasha Levin
From: Luc Van Oostenryck [ Upstream commit 99687cdbb3f6c8e32bcc7f37496e811f30460e48 ] The percpu members of struct sd_data and s_data are declared as: struct ... ** __percpu member; So their type is: __percpu pointer to pointer to struct ... But looking at how they're used,

[PATCH AUTOSEL 4.19 121/192] fbdev: fbmem: fix memory access if logo is bigger than the screen

2019-03-27 Thread Sasha Levin
From: Manfred Schlaegl [ Upstream commit a5399db139cb3ad9b8502d8b1bd02da9ce0b9df0 ] There is no clipping on the x or y axis for logos larger that the framebuffer size. Therefore: a logo bigger than screen size leads to invalid memory access: [1.254664] Backtrace: [1.254728] []

Re: [PATCH v7 2/2] drivers/misc: Add Aspeed P2A control driver

2019-03-27 Thread Patrick Venture
On Wed, Mar 27, 2019 at 11:54 AM Greg KH wrote: > > On Wed, Mar 27, 2019 at 11:44:36AM -0700, Patrick Venture wrote: > > On Wed, Mar 27, 2019 at 11:28 AM Greg KH wrote: > > > > > > On Tue, Mar 12, 2019 at 09:31:01AM -0700, Patrick Venture wrote: > > > > + phys_addr_t mem_base; > > > > > > Is

[PATCH AUTOSEL 4.19 123/192] drm: rcar-du: add missing of_node_put

2019-03-27 Thread Sasha Levin
From: Julia Lawall [ Upstream commit 4c6d8fc20b09f9684743afd72e4dbc3f15524479 ] Add an of_node_put when the result of of_graph_get_remote_port_parent is not available. Add a second of_node_put if no encoder is selected (encoder remains NULL). The semantic match that finds the first problem is

[PATCH AUTOSEL 4.19 122/192] cdrom: Fix race condition in cdrom_sysctl_register

2019-03-27 Thread Sasha Levin
From: Guenter Roeck [ Upstream commit f25191bb322dec8fa2979ecb8235643aa42470e1 ] The following traceback is sometimes seen when booting an image in qemu: [ 54.608293] cdrom: Uniform CD-ROM driver Revision: 3.20 [ 54.611085] Fusion MPT base driver 3.04.20 [ 54.611877] Copyright (c)

[PATCH AUTOSEL 4.19 126/192] perf/aux: Make perf_event accessible to setup_aux()

2019-03-27 Thread Sasha Levin
From: Mathieu Poirier [ Upstream commit 840018668ce2d96783356204ff282d6c9b0e5f66 ] When pmu::setup_aux() is called the coresight PMU needs to know which sink to use for the session by looking up the information in the event's attr::config2 field. As such simply replace the cpu information by

[PATCH AUTOSEL 4.19 131/192] staging: spi: mt7621: Add return code check on device_reset()

2019-03-27 Thread Sasha Levin
From: Stefan Roese [ Upstream commit 46c337872f34bc6387b0c29a4964f562c70139e3 ] This patch adds a return code check on device_reset() and removes the compile warning. Signed-off-by: Stefan Roese Cc: Mark Brown Cc: Sankalp Negi Cc: Chuanhong Guo Cc: John Crispin Reviewed-by: NeilBrown

[PATCH AUTOSEL 4.19 130/192] i2c: of: Try to find an I2C adapter matching the parent

2019-03-27 Thread Sasha Levin
From: Thierry Reding [ Upstream commit e814e688413aabd7b0d75e2a8ed1caa472951dec ] If an I2C adapter doesn't match the provided device tree node, also try matching the parent's device tree node. This allows finding an adapter based on the device node of the parent device that was used to

[PATCH AUTOSEL 4.19 135/192] locking/lockdep: Add debug_locks check in __lock_downgrade()

2019-03-27 Thread Sasha Levin
From: Waiman Long [ Upstream commit 71492580571467fb7177aade19c18ce7486267f5 ] Tetsuo Handa had reported he saw an incorrect "downgrading a read lock" warning right after a previous lockdep warning. It is likely that the previous warning turned off lock debugging causing the lockdep to have

[PATCH AUTOSEL 4.19 144/192] ARM: avoid Cortex-A9 livelock on tight dmb loops

2019-03-27 Thread Sasha Levin
From: Russell King [ Upstream commit 5388a5b82199facacd3d7ac0d05aca6e8f902fed ] machine_crash_nonpanic_core() does this: while (1) cpu_relax(); because the kernel has crashed, and we have no known safe way to deal with the CPU. So, we place the CPU into an infinite

[PATCH AUTOSEL 4.19 137/192] sched/core: Use READ_ONCE()/WRITE_ONCE() in move_queued_task()/task_rq_lock()

2019-03-27 Thread Sasha Levin
From: Andrea Parri [ Upstream commit c546951d9c9300065bad253ecdf1ac59ce9d06c8 ] move_queued_task() synchronizes with task_rq_lock() as follows: move_queued_task() task_rq_lock() [S] ->on_rq = MIGRATING [L] rq = task_rq() WMB (__set_task_cpu())

[PATCH AUTOSEL 4.19 142/192] mt7601u: bump supported EEPROM version

2019-03-27 Thread Sasha Levin
From: Stanislaw Gruszka [ Upstream commit 3bd1505fed71d834f45e87b32ff07157fdda47e0 ] As reported by Michael eeprom 0d is supported and work with the driver. Dump of /sys/kernel/debug/ieee80211/phy1/mt7601u/eeprom_param with 0d EEPORM looks like this: RSSI offset: 0 0 Reference temp: f9 LNA

Re: KASAN: use-after-free Read in path_lookupat

2019-03-27 Thread Al Viro
On Wed, Mar 27, 2019 at 05:58:31PM +0100, Jan Kara wrote: > On Tue 26-03-19 04:15:10, Al Viro wrote: > > On Mon, Mar 25, 2019 at 08:18:25PM -0700, Mark Fasheh wrote: > > > > > Hey Al, > > > > > > It's been a while since I've looked at that bit of code but it looks like > > > Ocfs2 is syncing the

[PATCH AUTOSEL 4.19 143/192] ARM: 8830/1: NOMMU: Toggle only bits in EXC_RETURN we are really care of

2019-03-27 Thread Sasha Levin
From: Vladimir Murzin [ Upstream commit 72cd4064fccaae15ab84d40d4be23667402df4ed ] ARMv8M introduces support for Security extension to M class, among other things it affects exception handling, especially, encoding of EXC_RETURN. The new bits have been added: Bit [6] Secure or Non-secure

Re: [RFC PATCH 0/10] Another Approach to Use PMEM as NUMA Node

2019-03-27 Thread Yang Shi
On 3/27/19 10:34 AM, Dan Williams wrote: On Wed, Mar 27, 2019 at 2:01 AM Michal Hocko wrote: On Tue 26-03-19 19:58:56, Yang Shi wrote: On 3/26/19 11:37 AM, Michal Hocko wrote: On Tue 26-03-19 11:33:17, Yang Shi wrote: On 3/26/19 6:58 AM, Michal Hocko wrote: On Sat 23-03-19 12:44:25,

[PATCH AUTOSEL 4.19 149/192] cgroup/pids: turn cgroup_subsys->free() into cgroup_subsys->release() to fix the accounting

2019-03-27 Thread Sasha Levin
From: Oleg Nesterov [ Upstream commit 51bee5abeab2058ea5813c5615d6197a23dbf041 ] The only user of cgroup_subsys->free() callback is pids_cgrp_subsys which needs pids_free() to uncharge the pid. However, ->free() is called from __put_task_struct()->cgroup_free() and this is too late. Even the

[PATCH AUTOSEL 4.19 155/192] usb: dwc3: gadget: Fix OTG events when gadget driver isn't loaded

2019-03-27 Thread Sasha Levin
From: Roger Quadros [ Upstream commit 169e3b68cadb5775daca009ced4faf01ffd97dcf ] On v3.10a in dual-role mode, if port is in device mode and gadget driver isn't loaded, the OTG event interrupts don't come through. It seems that if the core is configured to be OTG2.0 only, then we can't leave

[PATCH AUTOSEL 4.19 151/192] tty: increase the default flip buffer limit to 2*640K

2019-03-27 Thread Sasha Levin
From: Manfred Schlaegl [ Upstream commit 7ab57b76ebf632bf2231ccabe26bea33868118c6 ] We increase the default limit for buffer memory allocation by a factor of 10 to 640K to prevent data loss when using fast serial interfaces. For example when using RS485 without flow-control at speeds of

[PATCH AUTOSEL 4.19 150/192] backlight: pwm_bl: Use gpiod_get_value_cansleep() to get initial state

2019-03-27 Thread Sasha Levin
From: Chen-Yu Tsai [ Upstream commit cec2b18832e26bc866bef2be22eff4e25bbc4034 ] gpiod_get_value() gives out a warning if access to the underlying gpiochip requires sleeping, which is common for I2C based chips: WARNING: CPU: 0 PID: 77 at drivers/gpio/gpiolib.c:2500

[PATCH AUTOSEL 4.19 153/192] drm/amd/display: Enable vblank interrupt during CRC capture

2019-03-27 Thread Sasha Levin
From: Nicholas Kazlauskas [ Upstream commit 428da2bdb05d76c48d0bd8fbfa2e4c102685be08 ] [Why] In order to read CRC events when CRC capture is enabled the vblank interrput handler needs to be running for the CRTC. The handler is enabled while there is an active vblank reference. When running IGT

[PATCH AUTOSEL 4.19 166/192] Bluetooth: hci_uart: Check if socket buffer is ERR_PTR in h4_recv_buf()

2019-03-27 Thread Sasha Levin
From: Myungho Jung [ Upstream commit 1dc2d785156cbdc80806c32e8d2c7c735d0b4721 ] h4_recv_buf() callers store the return value to socket buffer and recursively pass the buffer to h4_recv_buf() without protection. So, ERR_PTR returned from h4_recv_buf() can be dereferenced, if called again before

[PATCH AUTOSEL 4.19 156/192] platform/x86: intel-hid: Missing power button release on some Dell models

2019-03-27 Thread Sasha Levin
From: Jérôme de Bretagne [ Upstream commit e97a34563d18606ee5db93e495382a967f999cd4 ] Power button suspend for some Dell models was added in: commit 821b85366284 ("platform/x86: intel-hid: Power button suspend on Dell Latitude 7275") by checking against the power button press notification

Re: [PATCH 1/2] efi: add a function for transferring status to string

2019-03-27 Thread Ard Biesheuvel
On Sun, 24 Mar 2019 at 01:26, Lee, Chun-Yi wrote: > > This function can be used to transfer EFI status code to string > for printing out debug message. Using this function can improve > the readability of log. > > Cc: Ard Biesheuvel > Cc: Kees Cook > Cc: Anton Vorontsov > Cc: Colin Cross >

[PATCH AUTOSEL 4.19 162/192] HID: intel-ish: ipc: handle PIMR before ish_wakeup also clear PISR busy_clear bit

2019-03-27 Thread Sasha Levin
From: Song Hongyan [ Upstream commit 2edefc056e4f0e6ec9508dd1aca2c18fa320efef ] Host driver should handle interrupt mask register earlier than wake up ish FW else there will be conditions when FW interrupt comes, host PIMR register still not set ready, so move the interrupt mask setting before

[PATCH AUTOSEL 4.19 159/192] media: mt9m111: set initial frame size other than 0x0

2019-03-27 Thread Sasha Levin
From: Akinobu Mita [ Upstream commit 29856308137de1c21eda89411695f4fc6e9780ff ] This driver sets initial frame width and height to 0x0, which is invalid. So set it to selection rectangle bounds instead. This is detected by v4l2-compliance detected. Cc: Enrico Scholz Cc: Michael Grzeschik

[PATCH AUTOSEL 4.19 161/192] soc/tegra: fuse: Fix illegal free of IO base address

2019-03-27 Thread Sasha Levin
From: Timo Alho [ Upstream commit 51294bf6b9e897d595466dcda5a3f2751906a200 ] On cases where device tree entries for fuse and clock provider are in different order, fuse driver needs to defer probing. This leads to freeing incorrect IO base address as the fuse->base variable gets overwritten

[PATCH AUTOSEL 4.19 165/192] hpet: Fix missing '=' character in the __setup() code of hpet_mmap_enable

2019-03-27 Thread Sasha Levin
From: Buland Singh [ Upstream commit 24d48a61f230da130cc2ec2e526eacf229e3 ] Commit '3d035f580699 ("drivers/char/hpet.c: allow user controlled mmap for user processes")' introduced a new kernel command line parameter hpet_mmap, that is required to expose the memory map of the HPET registers

[PATCH AUTOSEL 4.19 163/192] Bluetooth: Verify that l2cap_get_conf_opt provides large enough buffer

2019-03-27 Thread Sasha Levin
From: Marcel Holtmann [ Upstream commit 7c9cbd0b5e38a1672fcd137894ace3b042dfbf69 ] The function l2cap_get_conf_opt will return L2CAP_CONF_OPT_SIZE + opt->len as length value. The opt->len however is in control over the remote user and can be used by an attacker to gain access beyond the bounds

[PATCH AUTOSEL 4.19 167/192] cpu/hotplug: Mute hotplug lockdep during init

2019-03-27 Thread Sasha Levin
From: Valentin Schneider [ Upstream commit ce48c457b95316b9a01b5aa9d4456ce820df94b4 ] Since we've had: commit cb538267ea1e ("jump_label/lockdep: Assert we hold the hotplug lock for _cpuslocked() operations") we've been getting some lockdep warnings during init, such as on HiKey960: [

[PATCH AUTOSEL 4.19 169/192] dmaengine: qcom_hidma: assign channel cookie correctly

2019-03-27 Thread Sasha Levin
From: Shunyong Yang [ Upstream commit 546c0547555efca8ba8c120716c325435e29df1b ] When dma_cookie_complete() is called in hidma_process_completed(), dma_cookie_status() will return DMA_COMPLETE in hidma_tx_status(). Then, hidma_txn_is_success() will be called to use channel cookie

[PATCH AUTOSEL 4.19 168/192] dmaengine: imx-dma: fix warning comparison of distinct pointer types

2019-03-27 Thread Sasha Levin
From: Anders Roxell [ Upstream commit 9227ab5643cb8350449502dd9e3168a873ab0e3b ] The warning got introduced by commit 930507c18304 ("arm64: add basic Kconfig symbols for i.MX8"). Since it got enabled for arm64. The warning haven't been seen before since size_t was 'unsigned int' when built on

[PATCH AUTOSEL 4.19 181/192] wlcore: Fix memory leak in case wl12xx_fetch_firmware failure

2019-03-27 Thread Sasha Levin
From: Zumeng Chen [ Upstream commit ba2ffc96321c8433606ceeb85c9e722b8113e5a7 ] Release fw_status, raw_fw_status, and tx_res_if when wl12xx_fetch_firmware failed instead of meaningless goto out to avoid the following memory leak reports(Only the last one listed): unreferenced object 0xc28a9a00

[PATCH AUTOSEL 4.19 183/192] drm/fb-helper: fix leaks in error path of drm_fb_helper_fbdev_setup

2019-03-27 Thread Sasha Levin
From: Peter Wu [ Upstream commit 00eb5b0da8d27b3c944bfc959c3344d665caae26 ] After drm_fb_helper_fbdev_setup calls drm_fb_helper_init, "dev->fb_helper" will be initialized (and thus drm_fb_helper_fini will have some effect). After that, drm_fb_helper_initial_config is called which may call the

[PATCH AUTOSEL 4.19 182/192] x86/build: Mark per-CPU symbols as absolute explicitly for LLD

2019-03-27 Thread Sasha Levin
From: Rafael Ávila de Espíndola [ Upstream commit d071ae09a4a1414c1433d5ae9908959a7325b0ad ] Accessing per-CPU variables is done by finding the offset of the variable in the per-CPU block and adding it to the address of the respective CPU's block. Section 3.10.8 of ld.bfd's documentation

[PATCH AUTOSEL 4.19 185/192] clk: rockchip: fix frac settings of GPLL clock for rk3328

2019-03-27 Thread Sasha Levin
From: Katsuhiro Suzuki [ Upstream commit a0e447b0c50240a90ab84b7126b3c06b0bab4adc ] This patch fixes settings of GPLL frequency in fractional mode for rk3328. In this mode, FOUTVCO is calcurated by following formula: FOUTVCO = FREF * FBDIV / REFDIV + ((FREF * FRAC / REFDIV) >> 24) The

[PATCH AUTOSEL 4.19 178/192] x86/build: Specify elf_i386 linker emulation explicitly for i386 objects

2019-03-27 Thread Sasha Levin
From: George Rimar [ Upstream commit 927185c124d62a9a4d35878d7f6d432a166b74e3 ] The kernel uses the OUTPUT_FORMAT linker script command in it's linker scripts. Most of the time, the -m option is passed to the linker with correct architecture, but sometimes (at least for x86_64) the -m option

[PATCH AUTOSEL 4.19 184/192] clk: meson: clean-up clock registration

2019-03-27 Thread Sasha Levin
From: Jerome Brunet [ Upstream commit 8d9981efbcab066d17af4d3c85c169200f6f78df ] Order, ids and size between the table of regmap clocks and the onecell data table could be different. Set regmap pointer in all the regmap clocks before starting the registration using the onecell data, to make

[PATCH AUTOSEL 4.19 187/192] Input: soc_button_array - fix mapping of the 5th GPIO in a PNP0C40 device

2019-03-27 Thread Sasha Levin
From: Hans de Goede [ Upstream commit e9eb788f9442d1b5d93efdb30c3be071ce8a22b1 ] The Microsoft documenation for the PNP0C40 device aka the "Windows-compatible button array" describes the 5th GpioInt listed in the resources as: '5. Interrupt corresponding to the "Rotation Lock" button, if

[PATCH AUTOSEL 4.19 192/192] bcache: fix potential div-zero error of writeback_rate_p_term_inverse

2019-03-27 Thread Sasha Levin
From: Coly Li [ Upstream commit 5b5fd3c94eef69dcfaa8648198e54c92e5687d6d ] Current code already uses d_strtoul_nonzero() to convert input string to an unsigned integer, to make sure writeback_rate_p_term_inverse won't be zero value. But overflow may happen when converting input string to an

[PATCH AUTOSEL 4.19 186/192] dmaengine: tegra: avoid overflow of byte tracking

2019-03-27 Thread Sasha Levin
From: Ben Dooks [ Upstream commit e486df39305864604b7e25f2a95d51039517ac57 ] The dma_desc->bytes_transferred counter tracks the number of bytes moved by the DMA channel. This is then used to calculate the information passed back in the in the tegra_dma_tx_status callback, which is usually fine.

[PATCH AUTOSEL 4.19 191/192] ACPI / video: Extend chassis-type detection with a "Lunch Box" check

2019-03-27 Thread Sasha Levin
From: Hans de Goede [ Upstream commit d693c008e3ca04db5916ff72e68ce661888a913b ] Commit 53fa1f6e8a59 ("ACPI / video: Only default only_lcd to true on Win8-ready _desktops_") introduced chassis type detection, limiting the lcd_only check for the backlight to devices where the chassis-type

[PATCH AUTOSEL 4.19 190/192] net: stmmac: Avoid one more sometimes uninitialized Clang warning

2019-03-27 Thread Sasha Levin
From: Nathan Chancellor [ Upstream commit 1f5d861f7fefa971b2c6e766f77932c86419a319 ] When building with -Wsometimes-uninitialized, Clang warns: drivers/net/ethernet/stmicro/stmmac/stmmac_ptp.c:111:2: error: variable 'ns' is used uninitialized whenever 'if' condition is false

[PATCH AUTOSEL 4.14 002/123] h8300: use cc-cross-prefix instead of hardcoding h8300-unknown-linux-

2019-03-27 Thread Sasha Levin
From: Masahiro Yamada [ Upstream commit fc2b47b55f17fd996f7a01975ce1c33c2f2513f6 ] It believe it is a bad idea to hardcode a specific compiler prefix that may or may not be installed on a user's system. It is annoying when testing features that should not require compilers at all. For example,

[PATCH AUTOSEL 4.19 188/192] drm: Reorder set_property_atomic to avoid returning with an active ww_ctx

2019-03-27 Thread Sasha Levin
From: Chris Wilson [ Upstream commit 227ad6d957898a88b1746e30234ece64d305f066 ] Delay the drm_modeset_acquire_init() until after we check for an allocation failure so that we can return immediately upon error without having to unwind. WARNING: lock held when returning to user space! 4.20.0+

[PATCH AUTOSEL 4.14 003/123] f2fs: fix to avoid deadlock in f2fs_read_inline_dir()

2019-03-27 Thread Sasha Levin
From: Chao Yu [ Upstream commit aadcef64b22f668c1a107b86d3521d9cac915c24 ] As Jiqun Li reported in bugzilla: https://bugzilla.kernel.org/show_bug.cgi?id=202883 sometimes, dead lock when make system call SYS_getdents64 with fsync() is called by another process. monkey running on android9.0

[PATCH AUTOSEL 4.14 007/123] net/mlx5: Avoid panic when setting vport mac, getting vport config

2019-03-27 Thread Sasha Levin
From: Tonghao Zhang [ Upstream commit 6e77c413e8e73d0f36b5358b601389d75ec4451c ] If we try to set VFs mac address on a VF (not PF) net device, the kernel will be crash. The commands are show as below: $ echo 2 > /sys/class/net/$MLX_PF0/device/sriov_numvfs $ ip link set $MLX_VF0 vf 0 mac

[PATCH AUTOSEL 4.14 010/123] sysctl: handle overflow for file-max

2019-03-27 Thread Sasha Levin
From: Christian Brauner [ Upstream commit 32a5ad9c22852e6bd9e74bdec5934ef9d1480bc5 ] Currently, when writing echo 18446744073709551616 > /proc/sys/fs/file-max /proc/sys/fs/file-max will overflow and be set to 0. That quickly crashes the system. This commit sets the max and min value for

[PATCH AUTOSEL 4.14 012/123] scsi: hisi_sas: Set PHY linkrate when disconnected

2019-03-27 Thread Sasha Levin
From: John Garry [ Upstream commit efdcad62e7b8a02f5ccca57806dce1482ac8 ] When the PHY comes down, we currently do not set the negotiated linkrate: root@(none)$ pwd /sys/class/sas_phy/phy-0:0 root@(none)$ more enable 1 root@(none)$ more negotiated_linkrate 12.0 Gbit root@(none)$ echo 0 >

[PATCH AUTOSEL 4.14 008/123] gpio: gpio-omap: fix level interrupt idling

2019-03-27 Thread Sasha Levin
From: Russell King [ Upstream commit d01849f7deba81f4959fd9e51bf20dbf46987d1c ] Tony notes that the GPIO module does not idle when level interrupts are in use, as the wakeup appears to get stuck. After extensive investigation, it appears that the wakeup will only be cleared if the interrupt

[PATCH AUTOSEL 4.14 009/123] include/linux/relay.h: fix percpu annotation in struct rchan

2019-03-27 Thread Sasha Levin
From: Luc Van Oostenryck [ Upstream commit 62461ac2e5b6520b6d65fc6d7d7b4b8df4b848d8 ] The percpu member of this structure is declared as: struct ... ** __percpu member; So its type is: __percpu pointer to pointer to struct ... But looking at how it's used, its type should be:

[PATCH AUTOSEL 4.14 001/123] CIFS: fix POSIX lock leak and invalid ptr deref

2019-03-27 Thread Sasha Levin
From: Aurelien Aptel [ Upstream commit bc31d0cdcfbadb6258b45db97e93b1c83822ba33 ] We have a customer reporting crashes in lock_get_status() with many "Leaked POSIX lock" messages preceeding the crash. Leaked POSIX lock on dev=0x0:0x56 ... Leaked POSIX lock on dev=0x0:0x56 ... Leaked POSIX

[PATCH AUTOSEL 4.14 005/123] tracing: kdb: Fix ftdump to not sleep

2019-03-27 Thread Sasha Levin
From: Douglas Anderson [ Upstream commit 31b265b3baaf55f209229888b7ffea523ddab366 ] As reported back in 2016-11 [1], the "ftdump" kdb command triggers a BUG for "sleeping function called from invalid context". kdb's "ftdump" command wants to call ring_buffer_read_prepare() in atomic context.

Re: [PATCH v4] kmemleak: survive in a low-memory situation

2019-03-27 Thread Michal Hocko
On Wed 27-03-19 17:29:57, Catalin Marinas wrote: [...] > Quick attempt below and it needs some more testing (pretty random pick > of the EMERGENCY_POOL_SIZE value). Also, with __GFP_NOFAIL removed, are > the other flags safe or we should trim them further? I would be still careful about

[PATCH AUTOSEL 4.14 017/123] mm, mempolicy: fix uninit memory access

2019-03-27 Thread Sasha Levin
From: Vlastimil Babka [ Upstream commit 2e25644e8da4ed3a27e7b8315aaae74660be72dc ] Syzbot with KMSAN reports (excerpt): == BUG: KMSAN: uninit-value in mpol_rebind_policy mm/mempolicy.c:353 [inline] BUG: KMSAN: uninit-value in

[PATCH AUTOSEL 4.19 175/192] pinctrl: meson: meson8b: add the eth_rxd2 and eth_rxd3 pins

2019-03-27 Thread Sasha Levin
From: Martin Blumenstingl [ Upstream commit 6daae00243e622dd3feec7965bfe421ad6dd317e ] Gigabit Ethernet requires the Ethernet TXD0..3 and RXD0..3 data lines. Add the missing eth_rxd2 and eth_rxd3 definitions so we don't have to rely on the bootloader to set them up correctly. The vendor u-boot

[PATCH AUTOSEL 4.14 013/123] iio: adc: fix warning in Qualcomm PM8xxx HK/XOADC driver

2019-03-27 Thread Sasha Levin
From: Linus Torvalds [ Upstream commit e0f0ae838a25464179d37f355d763f9ec139fc15 ] The pm8xxx_get_channel() implementation is unclear, and causes gcc to suddenly generate odd warnings. The trigger for the warning (at least for me) was the entirely unrelated commit 79a4e91d1bb2 ("device.h: Add

Re: [PATCH v7 2/2] drivers/misc: Add Aspeed P2A control driver

2019-03-27 Thread Greg KH
On Wed, Mar 27, 2019 at 11:44:36AM -0700, Patrick Venture wrote: > On Wed, Mar 27, 2019 at 11:28 AM Greg KH wrote: > > > > On Tue, Mar 12, 2019 at 09:31:01AM -0700, Patrick Venture wrote: > > > + phys_addr_t mem_base; > > > > Is this really a 32bit value? > > It's going to be a 32-bit value

Re: [PATCH v2] efi: Unify dmi setup code over architectures arm/arm64, io64 and x86

2019-03-27 Thread Ard Biesheuvel
On Wed, 20 Mar 2019 at 16:23, Robert Richter wrote: > > On 20.03.19 14:16:07, Robert Richter wrote: > > On 20.03.19 13:05:37, Robert Richter wrote: > > > @@ -167,6 +167,7 @@ static int __init arm_dmi_init(void) > > > * itself, depends on dmi_scan_machine() having been called already. > > >

[PATCH AUTOSEL 4.14 015/123] mm/cma.c: cma_declare_contiguous: correct err handling

2019-03-27 Thread Sasha Levin
From: Peng Fan [ Upstream commit 0d3bd18a5efd66097ef58622b898d3139790aa9d ] In case cma_init_reserved_mem failed, need to free the memblock allocated by memblock_reserve or memblock_alloc_range. Quote Catalin's comments: https://lkml.org/lkml/2019/2/26/482 Kmemleak is supposed to work with

[PATCH AUTOSEL 4.14 016/123] mm/page_ext.c: fix an imbalance with kmemleak

2019-03-27 Thread Sasha Levin
From: Qian Cai [ Upstream commit 0c81585499601acd1d0e1cbf424cabfaee60628c ] After offlining a memory block, kmemleak scan will trigger a crash, as it encounters a page ext address that has already been freed during memory offlining. At the beginning in alloc_page_ext(), it calls

[PATCH AUTOSEL 4.14 026/123] dm thin: add sanity checks to thin-pool and external snapshot creation

2019-03-27 Thread Sasha Levin
From: "Jason Cai (Xiang Feng)" [ Upstream commit 70de2cbda8a5d788284469e755f8b097d339c240 ] Invoking dm_get_device() twice on the same device path with different modes is dangerous. Because in that case, upgrade_mode() will alloc a new 'dm_dev' and free the old one, which may be referenced by

[PATCH AUTOSEL 4.14 024/123] page_poison: play nicely with KASAN

2019-03-27 Thread Sasha Levin
From: Qian Cai [ Upstream commit 4117992df66a26fa33908b4969e04801534baab1 ] KASAN does not play well with the page poisoning (CONFIG_PAGE_POISONING). It triggers false positives in the allocation path: BUG: KASAN: use-after-free in memchr_inv+0x2ea/0x330 Read of size 8 at addr

[PATCH AUTOSEL 4.14 023/123] fs/file.c: initialize init_files.resize_wait

2019-03-27 Thread Sasha Levin
From: Shuriyc Chu [ Upstream commit 5704a06810682683355624923547b41540e2801a ] (Taken from https://bugzilla.kernel.org/show_bug.cgi?id=200647) 'get_unused_fd_flags' in kthread cause kernel crash. It works fine on 4.1, but causes crash after get 64 fds. It also cause crash on

[PATCH AUTOSEL 4.14 018/123] mm/vmalloc.c: fix kernel BUG at mm/vmalloc.c:512!

2019-03-27 Thread Sasha Levin
From: "Uladzislau Rezki (Sony)" [ Upstream commit afd07389d3f4933c7f7817a92fb5e053d59a3182 ] One of the vmalloc stress test case triggers the kernel BUG(): [60.562151] [ cut here ] [60.562154] kernel BUG at mm/vmalloc.c:512! [60.562206] invalid opcode:

[PATCH AUTOSEL 4.14 029/123] jbd2: fix invalid descriptor block checksum

2019-03-27 Thread Sasha Levin
From: luojiajun [ Upstream commit 6e876c3dd205d30b0db6850e97a03d75457df007 ] In jbd2_journal_commit_transaction(), if we are in abort mode, we may flush the buffer without setting descriptor block checksum by goto start_journal_io. Then fs is mounted, jbd2_descriptor_block_csum_verify() failed.

[PATCH AUTOSEL 4.14 040/123] serial: 8250_pxa: honor the port number from devicetree

2019-03-27 Thread Sasha Levin
From: Lubomir Rintel [ Upstream commit fe9ed6d2483fda55465f32924fb15bce0fac3fac ] Like the other OF-enabled drivers, use the port number from the firmware if the devicetree specifies an alias: aliases { ... serial2 = /* Should be ttyS2 */ } This is how the deprecated pxa.c

[PATCH AUTOSEL 4.14 039/123] coresight: etm4x: Add support to enable ETMv4.2

2019-03-27 Thread Sasha Levin
From: Sai Prakash Ranjan [ Upstream commit 5666dfd1d8a45a167f0d8b4ef47ea7f780b1f24a ] SDM845 has ETMv4.2 and can use the existing etm4x driver. But the current etm driver checks only for ETMv4.0 and errors out for other etm4x versions. This patch adds this missing support to enable SoC's with

[PATCH AUTOSEL 4.14 044/123] mmc: omap: fix the maximum timeout setting

2019-03-27 Thread Sasha Levin
From: Aaro Koskinen [ Upstream commit a6327b5e57fdc679c842588c3be046c0b39cc127 ] When running OMAP1 kernel on QEMU, MMC access is annoyingly noisy: MMC: CTO of 0xff and 0xfe cannot be used! MMC: CTO of 0xff and 0xfe cannot be used! MMC: CTO of 0xff and 0xfe cannot be

[PATCH AUTOSEL 4.14 046/123] mlxsw: spectrum: Avoid -Wformat-truncation warnings

2019-03-27 Thread Sasha Levin
From: Florian Fainelli [ Upstream commit ab2c4e2581ad32c28627235ff0ae8c5a5ea6899f ] Give precision identifiers to the two snprintf() formatting the priority and TC strings to avoid producing these two warnings: drivers/net/ethernet/mellanox/mlxsw/spectrum.c: In function

[PATCH AUTOSEL 4.14 045/123] e1000e: Fix -Wformat-truncation warnings

2019-03-27 Thread Sasha Levin
From: Florian Fainelli [ Upstream commit 135e7245479addc6b1f5d031e3d7e2ddb3d2b109 ] Provide precision hints to snprintf() since we know the destination buffer size of the RX/TX ring names are IFNAMSIZ + 5 - 1. This fixes the following warnings: drivers/net/ethernet/intel/e1000e/netdev.c: In

[PATCH AUTOSEL 4.14 050/123] cpufreq: acpi-cpufreq: Report if CPU doesn't support boost technologies

2019-03-27 Thread Sasha Levin
From: Erwan Velu [ Upstream commit 1222d527f314c86a3b59a522115d62facc5a7965 ] There is some rare cases where CPB (and possibly IDA) are missing on processors. This is the case fixed by commit f7f3dc00f612 ("x86/cpu/AMD: Fix erratum 1076 (CPB bit)") and following. In such context, the boost

[PATCH AUTOSEL 4.14 052/123] scsi: megaraid_sas: return error when create DMA pool failed

2019-03-27 Thread Sasha Levin
From: Jason Yan [ Upstream commit bcf3b67d16a4c8ffae0aa79de5853435e683945c ] when create DMA pool for cmd frames failed, we should return -ENOMEM, instead of 0. In some case in: megasas_init_adapter_fusion() -->megasas_alloc_cmds() -->megasas_create_frame_pool create

[PATCH AUTOSEL 4.14 047/123] IB/mlx4: Increase the timeout for CM cache

2019-03-27 Thread Sasha Levin
From: Håkon Bugge [ Upstream commit 2612d723aadcf8281f9bf8305657129bd9f3cd57 ] Using CX-3 virtual functions, either from a bare-metal machine or pass-through from a VM, MAD packets are proxied through the PF driver. Since the VF drivers have separate name spaces for MAD Transaction Ids (TIDs),

[PATCH AUTOSEL 4.14 049/123] ASoC: qcom: Fix of-node refcount unbalance in apq8016_sbc_parse_of()

2019-03-27 Thread Sasha Levin
From: Takashi Iwai [ Upstream commit 8d1667200850f8753c0265fa4bd25c9a6e5f94ce ] The apq8016 driver leaves the of-node refcount at aborting from the loop of for_each_child_of_node() in the error path. Not only the iterator node of for_each_child_of_node(), the children nodes referred from it

[PATCH AUTOSEL 4.14 048/123] clk: fractional-divider: check parent rate only if flag is set

2019-03-27 Thread Sasha Levin
From: Katsuhiro Suzuki [ Upstream commit d13501a2bedfbea0983cc868d3f1dc692627f60d ] Custom approximation of fractional-divider may not need parent clock rate checking. For example Rockchip SoCs work fine using grand parent clock rate even if target rate is greater than parent. This patch

[PATCH AUTOSEL 4.14 062/123] vfs: fix preadv64v2 and pwritev64v2 compat syscalls with offset == -1

2019-03-27 Thread Sasha Levin
From: Aurelien Jarno [ Upstream commit cc4b1242d7e3b42eed73881fc749944146493e4f ] The preadv2 and pwritev2 syscalls are supposed to emulate the readv and writev syscalls when offset == -1. Therefore the compat code should check for offset before calling do_compat_preadv64 and

[PATCH AUTOSEL 4.14 061/123] Bluetooth: hci_ldisc: Initialize hci_dev before open()

2019-03-27 Thread Sasha Levin
From: Jeremy Cline [ Upstream commit 32a7b4cbe93b0a0ef7e63d31ca69ce54736c4412 ] The hci_dev struct hdev is referenced in work queues and timers started by open() in some protocols. This creates a race between the initialization function and the work or timer which can result hdev being

[PATCH AUTOSEL 4.14 067/123] ACPI / video: Refactor and fix dmi_is_desktop()

2019-03-27 Thread Sasha Levin
From: Hans de Goede [ Upstream commit cecf3e3e0803462335e25d083345682518097334 ] This commit refactors the chassis-type detection introduced by commit 53fa1f6e8a59 ("ACPI / video: Only default only_lcd to true on Win8-ready _desktops_") (where desktop means anything without a builtin screen).

[PATCH AUTOSEL 4.14 065/123] leds: lp55xx: fix null deref on firmware load failure

2019-03-27 Thread Sasha Levin
From: Michal Kazior [ Upstream commit 5ddb0869bfc1bca6cfc592c74c64a026f936638c ] I've stumbled upon a kernel crash and the logs pointed me towards the lp5562 driver: > <4>[306013.841294] lp5562 0-0030: Direct firmware load for lp5562 failed with > error -2 > <4>[306013.894990] lp5562 0-0030:

[PATCH AUTOSEL 4.14 071/123] ARM: 8833/1: Ensure that NEON code always compiles with Clang

2019-03-27 Thread Sasha Levin
From: Nathan Chancellor [ Upstream commit de9c0d49d85dc563549972edc5589d195cd5e859 ] While building arm32 allyesconfig, I ran into the following errors: arch/arm/lib/xor-neon.c:17:2: error: You should compile this file with '-mfloat-abi=softfp -mfpu=neon' In file included from

[PATCH v2] eventfd: prepare id to userspace via fdinfo

2019-03-27 Thread Masatake YAMATO
Finding endpoints of an IPC channel is one of essential task to understand how a user program works. Procfs and netlink socket provide enough hints to find endpoints for IPC channels like pipes, unix sockets, and pseudo terminals. However, there is no simple way to find endpoints for an eventfd

[PATCH AUTOSEL 4.14 069/123] kprobes: Prohibit probing on bsearch()

2019-03-27 Thread Sasha Levin
From: Andrea Righi [ Upstream commit 02106f883cd745523f7766d90a739f983f19e650 ] Since kprobe breakpoing handler is using bsearch(), probing on this routine can cause recursive breakpoint problem. int3 ->do_int3() ->ftrace_int3_handler() ->ftrace_location()

[PATCH AUTOSEL 4.14 074/123] sched/topology: Fix percpu data types in struct sd_data & struct s_data

2019-03-27 Thread Sasha Levin
From: Luc Van Oostenryck [ Upstream commit 99687cdbb3f6c8e32bcc7f37496e811f30460e48 ] The percpu members of struct sd_data and s_data are declared as: struct ... ** __percpu member; So their type is: __percpu pointer to pointer to struct ... But looking at how they're used,

[PATCH AUTOSEL 4.14 075/123] bcache: fix input overflow to cache set sysfs file io_error_halflife

2019-03-27 Thread Sasha Levin
From: Coly Li [ Upstream commit a91fbda49f746119828f7e8ad0f0aa2ab0578f65 ] Cache set sysfs entry io_error_halflife is used to set c->error_decay. c->error_decay is in type unsigned int, and it is converted by strtoul_or_return(), therefore overflow to c->error_decay is possible for a large

<    1   2   3   4   5   6   7   8   9   10   >