[PATCH 22/22] perf scripts python: exported-sql-viewer.py: Select find text when find bar is activated

2019-05-20 Thread Adrian Hunter
The user probably wants to replace the find text, so select the find text when the find bar is activated. That is fairly standard behaviour for search text entry. Entering text will replace the current text, but using edit keys (arrows, home, end etc) cancels the selection and enables editing. Sig

[PATCH 21/22] perf scripts python: exported-sql-viewer.py: Add IPC information to Call Tree

2019-05-20 Thread Adrian Hunter
Enhance the call tree to display IPC information if it is available. Signed-off-by: Adrian Hunter --- .../scripts/python/exported-sql-viewer.py | 69 +++ 1 file changed, 56 insertions(+), 13 deletions(-) diff --git a/tools/perf/scripts/python/exported-sql-viewer.py b/tools/

[PATCH 19/22] perf scripts python: exported-sql-viewer.py: Add CallGraphModelParams

2019-05-20 Thread Adrian Hunter
Add a parameter to call graph and call tree, to determine whether IPC information is available. Signed-off-by: Adrian Hunter --- .../scripts/python/exported-sql-viewer.py | 73 +++ 1 file changed, 41 insertions(+), 32 deletions(-) diff --git a/tools/perf/scripts/python/expor

[PATCH 01/22] perf intel-pt: Fix itrace defaults for perf script

2019-05-20 Thread Adrian Hunter
Commit 4eb068157121 ("perf script: Make itrace script default to all calls") does not work because 'use_browser' is being used to determine whether to default to periodic sampling (i.e. better for perf report). The result is that nothing but CBR events display for perf script when no --itrace optio

[PATCH 03/22] perf intel-pt: Fix itrace defaults for perf script intel-pt documentation

2019-05-20 Thread Adrian Hunter
Fix intel-pt documentation to reflect the change of itrace defaults for perf script. Signed-off-by: Adrian Hunter Fixes: 4eb068157121 ("perf script: Make itrace script default to all calls") Cc: sta...@vger.kernel.org --- tools/perf/Documentation/intel-pt.txt | 10 +- 1 file changed, 5 i

[PATCH 16/22] perf scripts python: export-to-sqlite.py: Export IPC information

2019-05-20 Thread Adrian Hunter
Export cycle and instruction counts on samples and calls tables. Signed-off-by: Adrian Hunter --- tools/perf/scripts/python/export-to-sqlite.py | 36 --- 1 file changed, 24 insertions(+), 12 deletions(-) diff --git a/tools/perf/scripts/python/export-to-sqlite.py b/tools/perf/sc

[PATCH 08/22] perf script: Add output of IPC ratio

2019-05-20 Thread Adrian Hunter
Add field 'ipc' to display instructions-per-cycle. Example: perf record -e intel_pt/cyc/u ls perf script --insn-trace --xed -F+ipc,-dso,-cpu,-tid ls 2670177.697113434: 7f0dfdbcd090 _start+0x0 mov %rsp, %rdi IPC: 0.00 (1/877) ls 2670177.697113434: 7f0dfdbcd093 _start+0x3 call

[PATCH 15/22] perf db-export: Export IPC information

2019-05-20 Thread Adrian Hunter
Export cycle and instruction counts on samples and call-returns. Signed-off-by: Adrian Hunter --- tools/perf/util/scripting-engines/trace-event-python.c | 8 ++-- 1 file changed, 6 insertions(+), 2 deletions(-) diff --git a/tools/perf/util/scripting-engines/trace-event-python.c b/tools/per

[PATCH 09/22] perf intel-pt: Record when decoding PSB+ packets

2019-05-20 Thread Adrian Hunter
In preparation for using MTC packets to count cycles, record whether decoding is between a PSB and PSBEND packets. Signed-off-by: Adrian Hunter --- .../util/intel-pt-decoder/intel-pt-decoder.c | 41 ++- 1 file changed, 31 insertions(+), 10 deletions(-) diff --git a/tools/perf/u

[PATCH 13/22] perf thread-stack: Accumulate IPC information

2019-05-20 Thread Adrian Hunter
Cycle and instruction counts are added to the stack. The IPC of a function and all functions it calls, is also recorded. Signed-off-by: Adrian Hunter --- tools/perf/util/thread-stack.c | 14 ++ tools/perf/util/thread-stack.h | 4 2 files changed, 18 insertions(+) diff --git a/

Re: [PATCH 4/6] ARM: dts: sun8i: a83t: Add device node for CSI (Camera Sensor Interface)

2019-05-20 Thread Ondřej Jirman
Hi Maxime, On Mon, May 20, 2019 at 01:10:49PM +0200, Maxime Ripard wrote: > Hi Ondřej, > > On Sun, May 19, 2019 at 03:54:22PM +0200, Ondřej Jirman wrote: > > On Tue, Apr 09, 2019 at 04:52:25PM +0200, Maxime Ripard wrote: > > > On Tue, Apr 09, 2019 at 04:40:40PM +0800, Chen-Yu Tsai wrote: > > > >

[PATCH 12/22] perf intel-pt: Document IPC usage

2019-05-20 Thread Adrian Hunter
Add brief documentation about instructions-per-cycle (IPC) information derived from Intel PT. Signed-off-by: Adrian Hunter --- tools/perf/Documentation/intel-pt.txt | 30 +++ 1 file changed, 30 insertions(+) diff --git a/tools/perf/Documentation/intel-pt.txt b/tools/per

[PATCH 14/22] perf db-export: Add brief documentation

2019-05-20 Thread Adrian Hunter
Add brief documentation to explain how the database export maintains backward and forward compatibility. Signed-off-by: Adrian Hunter --- tools/perf/Documentation/db-export.txt | 41 ++ 1 file changed, 41 insertions(+) create mode 100644 tools/perf/Documentation/db-expor

[PATCH 05/22] perf intel-pt: Accumulate cycle count from CYC packets

2019-05-20 Thread Adrian Hunter
In preparation for providing instructions-per-cycle (IPC) information, accumulate cycle count from CYC packets. Although CYC packets are optional (requires config term 'cyc' to enable cycle-accurate mode when recording), the simplest way to count cycles is with CYC packets. The first complication

[PATCH 02/22] perf auxtrace: Fix itrace defaults for perf script

2019-05-20 Thread Adrian Hunter
Commit 4eb068157121 ("perf script: Make itrace script default to all calls") does not work for the case when '--itrace' only is used, because default_no_sample is not being passed. Example: Before: $ perf record -e intel_pt/cyc/u ls $ perf script --itrace > cmp1.txt $ perf script --itrace

[PATCH 04/22] perf intel-pt: Factor out intel_pt_update_sample_time

2019-05-20 Thread Adrian Hunter
To eliminate some duplication and make the code more understandable, factor out intel_pt_update_sample_time. Signed-off-by: Adrian Hunter --- .../util/intel-pt-decoder/intel-pt-decoder.c | 18 ++ 1 file changed, 10 insertions(+), 8 deletions(-) diff --git a/tools/perf/util/int

Re: [PATCH RESEND 2/4] KVM: X86: Emulate MSR_IA32_MISC_ENABLE MWAIT bit

2019-05-20 Thread Wanpeng Li
On Mon, 20 May 2019 at 18:34, Paolo Bonzini wrote: > > On 17/05/19 10:49, Wanpeng Li wrote: > > MSR IA32_MSIC_ENABLE bit 18, according to SDM: > > > > | When this bit is set to 0, the MONITOR feature flag is not set > > (CPUID.01H:ECX[bit 3] = 0). > > | This indicates that MONITOR/MWAIT are not s

Re: [PATCH v4 4/5] KVM: LAPIC: Delay trace advance expire delta

2019-05-20 Thread Paolo Bonzini
On 20/05/19 13:36, Wanpeng Li wrote: >> Hmm, yeah, that makes sense. The location of the tracepoint is a bit >> weird, but I guess we can add a comment in the code. > Do you need me to post a new patchset? :) No problem. The final patch that I committed is this: diff --git a/arch/x86/kvm/lapic.

Re: SGX vs LSM (Re: [PATCH v20 00/28] Intel SGX1 support)

2019-05-20 Thread Jarkko Sakkinen
On Thu, May 16, 2019 at 05:26:15PM -0700, Andy Lutomirski wrote: > Is userspace actually requred to mmap() the enclave prior to EADDing things? Nope, not since v20. Here is what I wrote about API to the kernel documentation: "The enclave life-cycle starts by opening `/dev/sgx/enclave`. After this

Re: SGX vs LSM (Re: [PATCH v20 00/28] Intel SGX1 support)

2019-05-20 Thread Jarkko Sakkinen
On Fri, May 17, 2019 at 08:41:28AM -0700, Sean Christopherson wrote: > It was a requirement prior to the API rework in v20, i.e. unless someone > was really quick on the draw after the v20 update all existing userspace > implementations mmap() the enclave before ECREATE. Requiring a valid > encla

Re: [RFC v2 1/5] clk: bcm2835: set CLK_GET_RATE_NOCACHE on CPU clocks

2019-05-20 Thread Stefan Wahren
On 20.05.19 12:47, Nicolas Saenz Julienne wrote: > Raspberry Pi's firmware is responsible for updating the cpu clocks and > pll. This makes sure we get the right rates anytime. > > Signed-off-by: Nicolas Saenz Julienne Acked-by: Stefan Wahren

Re: [RFC PATCH 0/4] KVM selftests for s390x

2019-05-20 Thread Paolo Bonzini
On 20/05/19 13:30, Thomas Huth wrote: >> No objections at all, though it would be like to have ucall plumbed in >> from the beginning. > I'm still looking at the ucall interface ... what I don't quite get yet > is the question why the ucall_type there is selectable during runtime? > > Are there pl

Re: [PATCH v4 2/2] RISC-V: Setup initial page tables in two stages

2019-05-20 Thread Christoph Hellwig
> void __init parse_dtb(unsigned int hartid, void *dtb) > { > - if (early_init_dt_scan(__va(dtb))) > + dtb = (void *)fix_to_virt(FIX_FDT) + ((uintptr_t)dtb & ~PAGE_MASK); > + if (early_init_dt_scan(dtb)) FYI, parse_dtb in mainline now lost the hartid argument and takes a phys_addr_t

Re: [RFC v2 2/5] clk: bcm2835: set pllb_arm divisor as readonly

2019-05-20 Thread Stefan Wahren
On 20.05.19 12:47, Nicolas Saenz Julienne wrote: > This divisor is controlled by the firmware, we don't want the clock > subsystem to update it inadvertently. > > Signed-off-by: Nicolas Saenz Julienne Acked-by: Stefan Wahren

Re: [PATCH v4 4/5] KVM: LAPIC: Delay trace advance expire delta

2019-05-20 Thread Wanpeng Li
On Mon, 20 May 2019 at 19:41, Paolo Bonzini wrote: > > On 20/05/19 13:36, Wanpeng Li wrote: > >> Hmm, yeah, that makes sense. The location of the tracepoint is a bit > >> weird, but I guess we can add a comment in the code. > > Do you need me to post a new patchset? :) > > No problem. The final

Re: [PATCH v3 2/2] dt-bindings: arm: renesas: Add HopeRun RZ/G2[M] boards

2019-05-20 Thread Simon Horman
On Fri, May 17, 2019 at 10:26:29AM +0100, Fabrizio Castro wrote: > This patch adds board HiHope RZ/G2M (the main board, powered by > the R8A774A1) and board HiHope RZ/G2 EX (the expansion board > that sits on top of the HiHope RZ/G2M). Both boards are made > by Jiangsu HopeRun Software Co., Ltd. (a

Re: [PATCH v3 1/2] dt-bindings: Add vendor prefix for HopeRun

2019-05-20 Thread Simon Horman
On Fri, May 17, 2019 at 08:38:14AM -0500, Rob Herring wrote: > On Fri, May 17, 2019 at 4:27 AM Fabrizio Castro > wrote: > > > > Add "Jiangsu HopeRun Software Co., Ltd." to the list of devicetree > > vendor prefixes as "hoperun". > > > > Website: http://www.hoperun.com/en > > > > Signed-off-by: Fab

Re: 5.1 and 5.1.1: BUG: unable to handle kernel paging request at ffffea0002030000

2019-05-20 Thread Mel Gorman
On Sun, May 12, 2019 at 04:27:45AM -0400, Justin Piszcz wrote: > Hello, > > I've turned off zram/zswap and I am still seeing the following during > periods of heavy I/O, I am returning to 5.0.xx in the meantime. > > Kernel: 5.1.1 > Arch: x86_64 > Dist: Debian x86_64 > > [29967.019411] BUG: unabl

Re: [PATCH] scsi: libsas: no need to join wide port again in sas_ex_discover_dev()

2019-05-20 Thread Jason Yan
On 2019/5/20 18:54, John Garry wrote: On 18/05/2019 10:40, Jason Yan wrote: Since we are processing events synchronously now, the second call of sas_ex_join_wide_port() in sas_ex_discover_dev() is not needed. There will be no races with other works in disco workqueue. So remove the second sas

Re: [RFC v2 3/5] clk: bcm2835: use firmware interface to update pllb

2019-05-20 Thread Stefan Wahren
Hi Nicolas, the following comments applies only in case Eric is fine with the whole approach. On 20.05.19 12:47, Nicolas Saenz Julienne wrote: > Raspberry Pi's firmware, which runs in a dedicated processor, keeps maybe we should clarify that the firmware is running in the VPU > track of the board

Re: [PATCH] wireless: fix typos in code comments

2019-05-20 Thread Rafał Miłecki
On 2019-05-19 05:22, Weitao Hou wrote: fix lengh to length Signed-off-by: Weitao Hou --- drivers/net/wireless/broadcom/brcm80211/brcmfmac/fwil.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) Please use: git log --oneline drivers/net/wireless/broadcom/brcm80211/brcmfmac/ to see how pa

Re: [RFC v2 3/5] clk: bcm2835: use firmware interface to update pllb

2019-05-20 Thread Stefan Wahren
On 20.05.19 14:11, Stefan Wahren wrote: > > Please verify that the kernel still works (and this clock driver probe) > under the following conditions: > > - CONFIG_RASPBERRYPI_FIRMWARE=n > - CONFIG_RASPBERRYPI_FIRMWARE=m > - older DTBs without patch #1 Sorry, i meant patch #4

Re: [PATCH v2 1/3] mtd: spinand: Add #define-s for page-read ops with three-byte addresses

2019-05-20 Thread Miquel Raynal
Hi Jeff, Jeff Kletsky wrote on Sun, 19 May 2019 13:27:58 -0700: > On 5/14/19 11:49 PM, Schrempf Frieder wrote: > > > On 15.05.19 08:17, Marek Vasut wrote: > >> On 5/14/19 11:53 PM, Jeff Kletsky wrote: > >>> From: Jeff Kletsky > >> That #define in $subject is called a macro. > >> > >> See

[PATCH 4.9 16/44] ALSA: usb-audio: Fix a memory leak bug

2019-05-20 Thread Greg Kroah-Hartman
From: Wenwen Wang commit cb5173594d50c72b7bfa14113dfc5084b4d2f726 upstream. In parse_audio_selector_unit(), the string array 'namelist' is allocated through kmalloc_array(), and each string pointer in this array, i.e., 'namelist[]', is allocated through kmalloc() in the following for loop. Then,

[PATCH 4.9 17/44] ALSA: hda/hdmi - Read the pin sense from register when repolling

2019-05-20 Thread Greg Kroah-Hartman
From: Hui Wang commit 8c2e6728c2bf95765b724e07d0278ae97cd1ee0d upstream. The driver will check the monitor presence when resuming from suspend, starting poll or interrupt triggers. In these 3 situations, the jack_dirty will be set to 1 first, then the hda_jack.c reads the pin_sense from register

[PATCH 4.9 14/44] crypto: crct10dif-generic - fix use via crypto_shash_digest()

2019-05-20 Thread Greg Kroah-Hartman
From: Eric Biggers commit 307508d1072979f4435416f87936f87eaeb82054 upstream. The ->digest() method of crct10dif-generic reads the current CRC value from the shash_desc context. But this value is uninitialized, causing crypto_shash_digest() to compute the wrong result. Fix it. Probably this wa

[PATCH 4.9 12/44] crypto: chacha20poly1305 - set cra_name correctly

2019-05-20 Thread Greg Kroah-Hartman
From: Eric Biggers commit 5e27f38f1f3f45a0c938299c3a34a2d2db77165a upstream. If the rfc7539 template is instantiated with specific implementations, e.g. "rfc7539(chacha20-generic,poly1305-generic)" rather than "rfc7539(chacha20,poly1305)", then the implementation names end up included in the ins

[PATCH 4.9 04/44] x86/speculation/mds: Revert CPU buffer clear on double fault exit

2019-05-20 Thread Greg Kroah-Hartman
From: Andy Lutomirski commit 88640e1dcd089879530a49a8d212d1814678dfe7 upstream. The double fault ESPFIX path doesn't return to user mode at all -- it returns back to the kernel by simulating a #GP fault. prepare_exit_to_usermode() will run on the way out of general_protection before running user

[PATCH 4.9 15/44] crypto: x86/crct10dif-pcl - fix use via crypto_shash_digest()

2019-05-20 Thread Greg Kroah-Hartman
From: Eric Biggers commit dec3d0b1071a0f3194e66a83d26ecf4aa8c5910e upstream. The ->digest() method of crct10dif-pclmul reads the current CRC value from the shash_desc context. But this value is uninitialized, causing crypto_shash_digest() to compute the wrong result. Fix it. Probably this was

[PATCH 4.9 13/44] crypto: vmx - fix copy-paste error in CTR mode

2019-05-20 Thread Greg Kroah-Hartman
From: Daniel Axtens commit dcf7b48212c0fab7df69e84fab22d6cb7c8c0fb9 upstream. The original assembly imported from OpenSSL has two copy-paste errors in handling CTR mode. When dealing with a 2 or 3 block tail, the code branches to the CBC decryption exit path, rather than to the CTR exit path. T

[PATCH 4.9 03/44] PCI: hv: Fix a memory leak in hv_eject_device_work()

2019-05-20 Thread Greg Kroah-Hartman
[ Upstream commit 05f151a73ec2b23ffbff706e5203e729a995cdc2 ] When a device is created in new_pcichild_device(), hpdev->refs is set to 2 (i.e. the initial value of 1 plus the get_pcichild()). When we hot remove the device from the host, in a Linux VM we first call hv_pci_eject_device(), which incr

[PATCH 4.9 01/44] net: core: another layer of lists, around PF_MEMALLOC skb handling

2019-05-20 Thread Greg Kroah-Hartman
[ Upstream commit 78ed8cc25986ac5c21762eeddc1e86e94d422e36 ] First example of a layer splitting the list (rather than merely taking individual packets off it). Involves new list.h function, list_cut_before(), like list_cut_position() but cuts on the other side of the given entry. Signed-off-by:

[PATCH 4.9 10/44] arm64: Clear OSDLR_EL1 on CPU boot

2019-05-20 Thread Greg Kroah-Hartman
From: Jean-Philippe Brucker commit 6fda41bf12615ee7c3ddac88155099b1a8cf8d00 upstream. Some firmwares may reboot CPUs with OS Double Lock set. Make sure that it is unlocked, in order to use debug exceptions. Cc: Signed-off-by: Jean-Philippe Brucker Signed-off-by: Will Deacon Signed-off-by: Gr

[PATCH 4.9 11/44] sched/x86: Save [ER]FLAGS on context switch

2019-05-20 Thread Greg Kroah-Hartman
From: Peter Zijlstra commit 6690e86be83ac75832e461c141055b5d601c0a6d upstream. Effectively reverts commit: 2c7577a75837 ("sched/x86_64: Don't save flags on context switch") Specifically because SMAP uses FLAGS.AC which invalidates the claim that the kernel has clean flags. In particular; wh

[PATCH 4.9 05/44] x86/speculation/mds: Improve CPU buffer clear documentation

2019-05-20 Thread Greg Kroah-Hartman
From: Andy Lutomirski commit 9d8d0294e78a164d407133dea05caf4b84247d6a upstream. On x86_64, all returns to usermode go through prepare_exit_to_usermode(), with the sole exception of do_nmi(). This even includes machine checks -- this was added several years ago to support MCE recovery. Update th

[PATCH 4.9 19/44] ALSA: hda/realtek - EAPD turn on later

2019-05-20 Thread Greg Kroah-Hartman
From: Kailang Yang commit 607ca3bd220f4022e6f5356026b19dafc363863a upstream. Let EAPD turn on after set pin output. [ NOTE: This change is supposed to reduce the possible click noises at (runtime) PM resume. The functionality should be same (i.e. the verbs are executed correctly) no matter

[PATCH 4.9 06/44] objtool: Fix function fallthrough detection

2019-05-20 Thread Greg Kroah-Hartman
From: Josh Poimboeuf commit e6f393bc939d566ce3def71232d8013de9aaadde upstream. When a function falls through to the next function due to a compiler bug, objtool prints some obscure warnings. For example: drivers/regulator/core.o: warning: objtool: regulator_count_voltages()+0x95: return wit

[PATCH 4.9 30/44] Btrfs: do not start a transaction at iterate_extent_inodes()

2019-05-20 Thread Greg Kroah-Hartman
From: Filipe Manana commit bfc61c36260ca990937539cd648ede3cd749bc10 upstream. When finding out which inodes have references on a particular extent, done by backref.c:iterate_extent_inodes(), from the BTRFS_IOC_LOGICAL_INO (both v1 and v2) ioctl and from scrub we use the transaction join API to g

[PATCH 4.9 08/44] power: supply: axp288_charger: Fix unchecked return value

2019-05-20 Thread Greg Kroah-Hartman
From: Gustavo A. R. Silva commit c3422ad5f84a66739ec6a37251ca27638c85b6be upstream. Currently there is no check on platform_get_irq() return value in case it fails, hence never actually reporting any errors and causing unexpected behavior when using such value as argument for function regmap_irq

[PATCH 4.9 34/44] crypto: gcm - Fix error return code in crypto_gcm_create_common()

2019-05-20 Thread Greg Kroah-Hartman
From: Wei Yongjun commit 9b40f79c08e81234d759f188b233980d7e81df6c upstream. Fix to return error code -EINVAL from the invalid alg ivsize error handling case instead of 0, as done elsewhere in this function. Signed-off-by: Wei Yongjun Signed-off-by: Herbert Xu Signed-off-by: Greg Kroah-Hartman

[PATCH 4.9 21/44] ASoC: RT5677-SPI: Disable 16Bit SPI Transfers

2019-05-20 Thread Greg Kroah-Hartman
From: Curtis Malainey commit a46eb523220e242affb9a6bc9bb8efc05f4f7459 upstream. The current algorithm allows 3 types of transfers, 16bit, 32bit and burst. According to Realtek, 16bit transfers have a special restriction in that it is restricted to the memory region of 0x1802 ~ 0x18021000. Th

[PATCH 4.9 33/44] ipmi:ssif: compare block number correctly for multi-part return messages

2019-05-20 Thread Greg Kroah-Hartman
From: Kamlakant Patel commit 55be8658c7e2feb11a5b5b33ee031791dbd23a69 upstream. According to ipmi spec, block number is a number that is incremented, starting with 0, for each new block of message data returned using the middle transaction. Here, the 'blocknum' is data[0] which always starts fr

[PATCH 4.9 32/44] bcache: never set KEY_PTRS of journal key to 0 in journal_reclaim()

2019-05-20 Thread Greg Kroah-Hartman
From: Coly Li commit 1bee2addc0c8470c8aaa65ef0599eeae96dd88bc upstream. In journal_reclaim() ja->cur_idx of each cache will be update to reclaim available journal buckets. Variable 'int n' is used to count how many cache is successfully reclaimed, then n is set to c->journal.key by SET_KEY_PTRS(

[PATCH 4.9 09/44] arm64: compat: Reduce address limit

2019-05-20 Thread Greg Kroah-Hartman
From: Vincenzo Frascino commit d263119387de9975d2acba1dfd3392f7c5979c18 upstream. Currently, compat tasks running on arm64 can allocate memory up to TASK_SIZE_32 (UL(0x1)). This means that mmap() allocations, if we treat them as returning an array, are not compliant with the sections 6.

[PATCH 4.9 28/44] ext4: actually request zeroing of inode table after grow

2019-05-20 Thread Greg Kroah-Hartman
From: Kirill Tkhai commit 310a997fd74de778b9a4848a64be9cda9f18764a upstream. It is never possible, that number of block groups decreases, since only online grow is supported. But after a growing occured, we have to zero inode tables for just created new block groups. Fixes: 19c5246d2516 ("ext4

[PATCH 4.14 10/63] ARM: dts: exynos: Fix audio (microphone) routing on Odroid XU3

2019-05-20 Thread Greg Kroah-Hartman
From: Sylwester Nawrocki commit 9b23e1a3e8fde76e8cc0e366ab1ed4ffb4440feb upstream. The name of CODEC input widget to which microphone is connected through the "Headphone" jack is "IN12" not "IN1". This fixes microphone support on Odroid XU3. Cc: # v4.14+ Signed-off-by: Sylwester Nawrocki Sign

[PATCH 4.9 23/44] ocfs2: fix ocfs2 read inode data panic in ocfs2_iget

2019-05-20 Thread Greg Kroah-Hartman
From: Shuning Zhang commit e091eab028f9253eac5c04f9141bbc9d170acab3 upstream. In some cases, ocfs2_iget() reads the data of inode, which has been deleted for some reason. That will make the system panic. So We should judge whether this inode has been deleted, and tell the caller that the inode

[PATCH 4.9 27/44] jbd2: check superblock mapped prior to committing

2019-05-20 Thread Greg Kroah-Hartman
From: Jiufei Xue commit 742b06b5628f2cd23cb51a034cb54dc33c6162c5 upstream. We hit a BUG at fs/buffer.c:3057 if we detached the nbd device before unmounting ext4 filesystem. The typical chain of events leading to the BUG: jbd2_write_superblock submit_bh submit_bh_wbc BUG_ON(!buffer_m

[PATCH 4.9 44/44] KVM: x86: Skip EFER vs. guest CPUID checks for host-initiated writes

2019-05-20 Thread Greg Kroah-Hartman
From: Sean Christopherson commit 11988499e62b310f3bf6f6d0a807a06d3f9ccc96 upstream. KVM allows userspace to violate consistency checks related to the guest's CPUID model to some degree. Generally speaking, userspace has carte blanche when it comes to guest state so long as jamming invalid state

[PATCH 4.9 29/44] ext4: fix ext4_show_options for file systems w/o journal

2019-05-20 Thread Greg Kroah-Hartman
From: Debabrata Banerjee commit 50b29d8f033a7c88c5bc011abc2068b1691ab755 upstream. Instead of removing EXT4_MOUNT_JOURNAL_CHECKSUM from s_def_mount_opt as I assume was intended, all other options were blown away leading to _ext4_show_options() output being incorrect. Fixes: 1e381f60dad9 ("ext4:

[PATCH 4.9 42/44] ext4: fix data corruption caused by overlapping unaligned and aligned IO

2019-05-20 Thread Greg Kroah-Hartman
From: Lukas Czerner commit 57a0da28ced8707cb9f79f071a016b9d005caf5a upstream. Unaligned AIO must be serialized because the zeroing of partial blocks of unaligned AIO can result in data corruption in case it's overlapping another in flight IO. Currently we wait for all unwritten extents before w

[PATCH 4.14 11/63] ARM: exynos: Fix a leaked reference by adding missing of_node_put

2019-05-20 Thread Greg Kroah-Hartman
From: Wen Yang commit 629266bf7229cd6a550075f5961f95607b823b59 upstream. The call to of_get_next_child returns a node pointer with refcount incremented thus it must be explicitly decremented after the last usage. Detected by coccinelle with warnings like: arch/arm/mach-exynos/firmware.c:201

[PATCH 4.9 37/44] crypto: arm/aes-neonbs - dont access already-freed walk.iv

2019-05-20 Thread Greg Kroah-Hartman
From: Eric Biggers commit 767f015ea0b7ab9d60432ff6cd06b664fd71f50f upstream. If the user-provided IV needs to be aligned to the algorithm's alignmask, then skcipher_walk_virt() copies the IV into a new aligned buffer walk.iv. But skcipher_walk_virt() can fail afterwards, and then if the caller

[PATCH 4.9 40/44] fs/writeback.c: use rcu_barrier() to wait for inflight wb switches going into workqueue when umount

2019-05-20 Thread Greg Kroah-Hartman
From: Jiufei Xue commit ec084de929e419e51bcdafaafe567d9e7d0273b7 upstream. synchronize_rcu() didn't wait for call_rcu() callbacks, so inode wb switch may not go to the workqueue after synchronize_rcu(). Thus previous scheduled switches was not finished even flushing the workqueue, which will ca

[PATCH 4.9 35/44] crypto: gcm - fix incompatibility between "gcm" and "gcm_base"

2019-05-20 Thread Greg Kroah-Hartman
From: Eric Biggers commit f699594d436960160f6d5ba84ed4a222f20d11cd upstream. GCM instances can be created by either the "gcm" template, which only allows choosing the block cipher, e.g. "gcm(aes)"; or by "gcm_base", which allows choosing the ctr and ghash implementations, e.g. "gcm_base(ctr(aes-

[PATCH 4.14 01/63] net: core: another layer of lists, around PF_MEMALLOC skb handling

2019-05-20 Thread Greg Kroah-Hartman
[ Upstream commit 78ed8cc25986ac5c21762eeddc1e86e94d422e36 ] First example of a layer splitting the list (rather than merely taking individual packets off it). Involves new list.h function, list_cut_before(), like list_cut_position() but cuts on the other side of the given entry. Signed-off-by:

[PATCH 4.9 22/44] mm/mincore.c: make mincore() more conservative

2019-05-20 Thread Greg Kroah-Hartman
From: Jiri Kosina commit 134fca9063ad4851de767d1768180e5dede9a881 upstream. The semantics of what mincore() considers to be resident is not completely clear, but Linux has always (since 2.3.52, which is when mincore() was initially done) treated it as "page is available in page cache". That's p

[PATCH 4.9 24/44] mfd: da9063: Fix OTP control register names to match datasheets for DA9063/63L

2019-05-20 Thread Greg Kroah-Hartman
From: Steve Twiss commit 6b4814a9451add06d457e198be418bf6a3e6a990 upstream. Mismatch between what is found in the Datasheets for DA9063 and DA9063L provided by Dialog Semiconductor, and the register names provided in the MFD registers file. The changes are for the OTP (one-time-programming) cont

[PATCH 4.9 39/44] writeback: synchronize sync(2) against cgroup writeback membership switches

2019-05-20 Thread Greg Kroah-Hartman
From: Tejun Heo commit 7fc5854f8c6efae9e7624970ab49a1eac2faefb1 upstream. sync_inodes_sb() can race against cgwb (cgroup writeback) membership switches and fail to writeback some inodes. For example, if an inode switches to another wb while sync_inodes_sb() is in progress, the new wb might not

[PATCH 4.9 25/44] mfd: max77620: Fix swapped FPS_PERIOD_MAX_US values

2019-05-20 Thread Greg Kroah-Hartman
From: Dmitry Osipenko commit ea611d1cc180fbb56982c83cd5142a2b34881f5c upstream. The FPS_PERIOD_MAX_US definitions are swapped for MAX20024 and MAX77620, fix it. Cc: stable Signed-off-by: Dmitry Osipenko Signed-off-by: Lee Jones Signed-off-by: Greg Kroah-Hartman --- include/linux/mfd/max77

[PATCH 4.9 43/44] ALSA: hda/realtek - Fix for Lenovo B50-70 inverted internal microphone bug

2019-05-20 Thread Greg Kroah-Hartman
From: Michał Wadowski commit 56df90b631fc027fe28b70d41352d820797239bb upstream. Add patch for realtek codec in Lenovo B50-70 that fixes inverted internal microphone channel. Device IdeaPad Y410P has the same PCI SSID as Lenovo B50-70, but first one is about fix the noise and it didn't seem help

[PATCH 4.9 26/44] tty/vt: fix write/write race in ioctl(KDSKBSENT) handler

2019-05-20 Thread Greg Kroah-Hartman
From: Sergei Trofimovich commit 46ca3f735f345c9d87383dd3a09fa5d43870770e upstream. The bug manifests as an attempt to access deallocated memory: BUG: unable to handle kernel paging request at 9c8735448000 #PF error: [PROT] [WRITE] PGD 288a05067 P4D 288a05067 PUD 288a07067 PMD 7f

[PATCH 4.9 36/44] crypto: salsa20 - dont access already-freed walk.iv

2019-05-20 Thread Greg Kroah-Hartman
From: Eric Biggers commit edaf28e996af69222b2cb40455dbb5459c2b875a upstream. If the user-provided IV needs to be aligned to the algorithm's alignmask, then skcipher_walk_virt() copies the IV into a new aligned buffer walk.iv. But skcipher_walk_virt() can fail afterwards, and then if the caller

[PATCH 4.14 02/63] locking/rwsem: Prevent decrement of reader count before increment

2019-05-20 Thread Greg Kroah-Hartman
[ Upstream commit a9e9bcb45b1525ba7aea26ed9441e8632aeeda58 ] During my rwsem testing, it was found that after a down_read(), the reader count may occasionally become 0 or even negative. Consequently, a writer may steal the lock at that time and execute with the reader in parallel thus breaking the

[PATCH 4.14 08/63] objtool: Fix function fallthrough detection

2019-05-20 Thread Greg Kroah-Hartman
From: Josh Poimboeuf commit e6f393bc939d566ce3def71232d8013de9aaadde upstream. When a function falls through to the next function due to a compiler bug, objtool prints some obscure warnings. For example: drivers/regulator/core.o: warning: objtool: regulator_count_voltages()+0x95: return wit

[PATCH 4.14 07/63] x86/speculation/mds: Improve CPU buffer clear documentation

2019-05-20 Thread Greg Kroah-Hartman
From: Andy Lutomirski commit 9d8d0294e78a164d407133dea05caf4b84247d6a upstream. On x86_64, all returns to usermode go through prepare_exit_to_usermode(), with the sole exception of do_nmi(). This even includes machine checks -- this was added several years ago to support MCE recovery. Update th

[PATCH 4.14 29/63] ASoC: max98090: Fix restore of DAPM Muxes

2019-05-20 Thread Greg Kroah-Hartman
From: Jon Hunter commit ecb2795c08bc825ebd604997e5be440b060c5b18 upstream. The max98090 driver defines 3 DAPM muxes; one for the right line output (LINMOD Mux), one for the left headphone mixer source (MIXHPLSEL Mux) and one for the right headphone mixer source (MIXHPRSEL Mux). The same bit is u

[PATCH 4.14 27/63] ALSA: hda/hdmi - Consider eld_valid when reporting jack event

2019-05-20 Thread Greg Kroah-Hartman
From: Hui Wang commit 7f641e26a6df9269cb25dd7a4b0a91d6586ed441 upstream. On the machines with AMD GPU or Nvidia GPU, we often meet this issue: after s3, there are 4 HDMI/DP audio devices in the gnome-sound-setting even there is no any monitors plugged. When this problem happens, we check the /p

[PATCH 4.14 25/63] ALSA: usb-audio: Fix a memory leak bug

2019-05-20 Thread Greg Kroah-Hartman
From: Wenwen Wang commit cb5173594d50c72b7bfa14113dfc5084b4d2f726 upstream. In parse_audio_selector_unit(), the string array 'namelist' is allocated through kmalloc_array(), and each string pointer in this array, i.e., 'namelist[]', is allocated through kmalloc() in the following for loop. Then,

[PATCH 4.14 28/63] ALSA: hda/realtek - EAPD turn on later

2019-05-20 Thread Greg Kroah-Hartman
From: Kailang Yang commit 607ca3bd220f4022e6f5356026b19dafc363863a upstream. Let EAPD turn on after set pin output. [ NOTE: This change is supposed to reduce the possible click noises at (runtime) PM resume. The functionality should be same (i.e. the verbs are executed correctly) no matter

[PATCH 4.14 15/63] arm64: Save and restore OSDLR_EL1 across suspend/resume

2019-05-20 Thread Greg Kroah-Hartman
From: Jean-Philippe Brucker commit 827a108e354db633698f0b4a10c1ffd2b1f8d1d0 upstream. When the CPU comes out of suspend, the firmware may have modified the OS Double Lock Register. Save it in an unused slot of cpu_suspend_ctx, and restore it on resume. Cc: Signed-off-by: Jean-Philippe Brucker

[PATCH 4.14 31/63] bpf, arm64: remove prefetch insn in xadd mapping

2019-05-20 Thread Greg Kroah-Hartman
From: Daniel Borkmann commit 8968c67a82ab7501bc3b9439c3624a49b42fe54c upstream. Prefetch-with-intent-to-write is currently part of the XADD mapping in the AArch64 JIT and follows the kernel's implementation of atomic_add. This may interfere with other threads executing the LDXR/STXR loop, leadin

[PATCH 4.14 43/63] ext4: avoid drop reference to iloc.bh twice

2019-05-20 Thread Greg Kroah-Hartman
From: Pan Bian commit 8c380ab4b7b59c0c602743810be1b712514eaebc upstream. The reference to iloc.bh has been dropped in ext4_mark_iloc_dirty. However, the reference is dropped again if error occurs during ext4_handle_dirty_metadata, which may result in use-after-free bugs. Fixes: fb265c9cb49e("ex

[PATCH 4.14 41/63] ext4: make sanity check in mballoc more strict

2019-05-20 Thread Greg Kroah-Hartman
From: Jan Kara commit 31562b954b60f02acb91b7349dc6432d3f8c3c5f upstream. The sanity check in mb_find_extent() only checked that returned extent does not extend past blocksize * 8, however it should not extend past EXT4_CLUSTERS_PER_GROUP(sb). This can happen when clusters_per_group < blocksize *

[PATCH 4.14 44/63] Btrfs: do not start a transaction during fiemap

2019-05-20 Thread Greg Kroah-Hartman
From: Filipe Manana commit 03628cdbc64db6262e50d0357960a4e9562676a1 upstream. During fiemap, for regular extents (non inline) we need to check if they are shared and if they are, set the shared bit. Checking if an extent is shared requires checking the delayed references of the currently running

[PATCH 4.14 45/63] Btrfs: do not start a transaction at iterate_extent_inodes()

2019-05-20 Thread Greg Kroah-Hartman
From: Filipe Manana commit bfc61c36260ca990937539cd648ede3cd749bc10 upstream. When finding out which inodes have references on a particular extent, done by backref.c:iterate_extent_inodes(), from the BTRFS_IOC_LOGICAL_INO (both v1 and v2) ioctl and from scrub we use the transaction join API to g

[PATCH 4.14 40/63] jbd2: check superblock mapped prior to committing

2019-05-20 Thread Greg Kroah-Hartman
From: Jiufei Xue commit 742b06b5628f2cd23cb51a034cb54dc33c6162c5 upstream. We hit a BUG at fs/buffer.c:3057 if we detached the nbd device before unmounting ext4 filesystem. The typical chain of events leading to the BUG: jbd2_write_superblock submit_bh submit_bh_wbc BUG_ON(!buffer_m

[PATCH 4.14 51/63] ipmi:ssif: compare block number correctly for multi-part return messages

2019-05-20 Thread Greg Kroah-Hartman
From: Kamlakant Patel commit 55be8658c7e2feb11a5b5b33ee031791dbd23a69 upstream. According to ipmi spec, block number is a number that is incremented, starting with 0, for each new block of message data returned using the middle transaction. Here, the 'blocknum' is data[0] which always starts fr

[PATCH 4.14 17/63] crypto: chacha20poly1305 - set cra_name correctly

2019-05-20 Thread Greg Kroah-Hartman
From: Eric Biggers commit 5e27f38f1f3f45a0c938299c3a34a2d2db77165a upstream. If the rfc7539 template is instantiated with specific implementations, e.g. "rfc7539(chacha20-generic,poly1305-generic)" rather than "rfc7539(chacha20,poly1305)", then the implementation names end up included in the ins

Re: 5.1 and 5.1.1: BUG: unable to handle kernel paging request at ffffea0002030000

2019-05-20 Thread Justin Piszcz
On Mon, May 20, 2019 at 7:56 AM Mel Gorman wrote: > > On Sun, May 12, 2019 at 04:27:45AM -0400, Justin Piszcz wrote: > > Hello, > > > > I've turned off zram/zswap and I am still seeing the following during > > periods of heavy I/O, I am returning to 5.0.xx in the meantime. > > > > Kernel: 5.1.1 >

[PATCH 4.14 53/63] crypto: salsa20 - dont access already-freed walk.iv

2019-05-20 Thread Greg Kroah-Hartman
From: Eric Biggers commit edaf28e996af69222b2cb40455dbb5459c2b875a upstream. If the user-provided IV needs to be aligned to the algorithm's alignmask, then skcipher_walk_virt() copies the IV into a new aligned buffer walk.iv. But skcipher_walk_virt() can fail afterwards, and then if the caller

[PATCH 4.14 22/63] crypto: gcm - fix incompatibility between "gcm" and "gcm_base"

2019-05-20 Thread Greg Kroah-Hartman
From: Eric Biggers commit f699594d436960160f6d5ba84ed4a222f20d11cd upstream. GCM instances can be created by either the "gcm" template, which only allows choosing the block cipher, e.g. "gcm(aes)"; or by "gcm_base", which allows choosing the ctr and ghash implementations, e.g. "gcm_base(ctr(aes-

[PATCH 4.14 50/63] ext4: fix ext4_show_options for file systems w/o journal

2019-05-20 Thread Greg Kroah-Hartman
From: Debabrata Banerjee commit 50b29d8f033a7c88c5bc011abc2068b1691ab755 upstream. Instead of removing EXT4_MOUNT_JOURNAL_CHECKSUM from s_def_mount_opt as I assume was intended, all other options were blown away leading to _ext4_show_options() output being incorrect. Fixes: 1e381f60dad9 ("ext4:

[PATCH 4.14 57/63] ext4: zero out the unused memory region in the extent tree block

2019-05-20 Thread Greg Kroah-Hartman
From: Sriram Rajagopalan commit 592acbf16821288ecdc4192c47e3774a4c48bb64 upstream. This commit zeroes out the unused memory region in the buffer_head corresponding to the extent metablock after writing the extent header and the corresponding extent node entries. This is done to prevent random u

[PATCH 4.14 49/63] ext4: actually request zeroing of inode table after grow

2019-05-20 Thread Greg Kroah-Hartman
From: Kirill Tkhai commit 310a997fd74de778b9a4848a64be9cda9f18764a upstream. It is never possible, that number of block groups decreases, since only online grow is supported. But after a growing occured, we have to zero inode tables for just created new block groups. Fixes: 19c5246d2516 ("ext4

[PATCH 4.14 55/63] fib_rules: fix error in backport of e9919a24d302 ("fib_rules: return 0...")

2019-05-20 Thread Greg Kroah-Hartman
From: Greg Kroah-Hartman When commit e9919a24d302 ("fib_rules: return 0 directly if an exactly same rule exists when NLM_F_EXCL not supplied") was backported to 4.9.y, it changed the logic a bit as err should have been reset before exiting the test, like it happens in the original logic. If this

[PATCH 4.14 47/63] bcache: never set KEY_PTRS of journal key to 0 in journal_reclaim()

2019-05-20 Thread Greg Kroah-Hartman
From: Coly Li commit 1bee2addc0c8470c8aaa65ef0599eeae96dd88bc upstream. In journal_reclaim() ja->cur_idx of each cache will be update to reclaim available journal buckets. Variable 'int n' is used to count how many cache is successfully reclaimed, then n is set to c->journal.key by SET_KEY_PTRS(

[PATCH 4.14 13/63] arm64: compat: Reduce address limit

2019-05-20 Thread Greg Kroah-Hartman
From: Vincenzo Frascino commit d263119387de9975d2acba1dfd3392f7c5979c18 upstream. Currently, compat tasks running on arm64 can allocate memory up to TASK_SIZE_32 (UL(0x1)). This means that mmap() allocations, if we treat them as returning an array, are not compliant with the sections 6.

[PATCH 4.14 54/63] crypto: ccm - fix incompatibility between "ccm" and "ccm_base"

2019-05-20 Thread Greg Kroah-Hartman
From: Eric Biggers commit 6a1faa4a43f5fabf9cbeaa742d916e7b5e73120f upstream. CCM instances can be created by either the "ccm" template, which only allows choosing the block cipher, e.g. "ccm(aes)"; or by "ccm_base", which allows choosing the ctr and cbcmac implementations, e.g. "ccm_base(ctr(aes

[PATCH 4.14 18/63] crypto: vmx - fix copy-paste error in CTR mode

2019-05-20 Thread Greg Kroah-Hartman
From: Daniel Axtens commit dcf7b48212c0fab7df69e84fab22d6cb7c8c0fb9 upstream. The original assembly imported from OpenSSL has two copy-paste errors in handling CTR mode. When dealing with a 2 or 3 block tail, the code branches to the CBC decryption exit path, rather than to the CTR exit path. T

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