Re: [PATCH v1] x86: Pin cr4 FSGSBASE

2020-05-25 Thread Greg KH
On Mon, May 25, 2020 at 10:28:48PM -0700, Andi Kleen wrote: > From: Andi Kleen > > Since there seem to be kernel modules floating around that set > FSGSBASE incorrectly, prevent this in the CR4 pinning. Currently > CR4 pinning just checks that bits are set, this also checks > that the FSGSBASE bi

RE: [PATCH] Input: elantech - Remove read/write registers in attr.

2020-05-25 Thread jingle
HI Dmitry: These changes would not affect all the behavior of the old IC, including all the TP functions THANKS JINGLE -Original Message- From: Dmitry Torokhov [mailto:dmitry.torok...@gmail.com] Sent: Tuesday, May 26, 2020 12:17 PM To: Jingle.Wu Cc: linux-kernel@vger.kernel.org; linux-i

Re: [PATCH v3 16/18] nitro_enclaves: Add sample for ioctl interface usage

2020-05-25 Thread Greg KH
On Tue, May 26, 2020 at 01:13:32AM +0300, Andra Paraschiv wrote: > Signed-off-by: Alexandru Vasile > Signed-off-by: Andra Paraschiv Again, I can't take patches without any changelog text, and you shouldn't be writing them, as they are just lazy :) thanks, greg k-h

Re: [PATCH v3 07/18] nitro_enclaves: Init misc device providing the ioctl interface

2020-05-25 Thread Greg KH
On Tue, May 26, 2020 at 01:13:23AM +0300, Andra Paraschiv wrote: > +#define NE "nitro_enclaves: " Again, no need for this. > +#define NE_DEV_NAME "nitro_enclaves" KBUILD_MODNAME? > +#define NE_IMAGE_LOAD_OFFSET (8 * 1024UL * 1024UL) > + > +static char *ne_cpus; > +module_param(ne_cpus, charp, 0

Re: [PATCH v4 2/3] dmaengine: ptdma: register PTDMA controller as a DMA resource

2020-05-25 Thread Sanjay R Mehta
On 5/4/2020 11:44 AM, Vinod Koul wrote: > [CAUTION: External Email] > > On 28-04-20, 16:13, Sanjay R Mehta wrote: > >> +static void pt_do_cmd_complete(unsigned long data) >> +{ >> + struct pt_tasklet_data *tdata = (struct pt_tasklet_data *)data; >> + struct pt_cmd *cmd = tdata->cmd; >>

Re: [PATCH v3 04/18] nitro_enclaves: Init PCI device driver

2020-05-25 Thread Greg KH
On Tue, May 26, 2020 at 01:13:20AM +0300, Andra Paraschiv wrote: > The Nitro Enclaves PCI device is used by the kernel driver as a means of > communication with the hypervisor on the host where the primary VM and > the enclaves run. It handles requests with regard to enclave lifetime. > > Setup th

Re: [PATCH v3 03/18] nitro_enclaves: Define enclave info for internal bookkeeping

2020-05-25 Thread Greg KH
On Tue, May 26, 2020 at 01:13:19AM +0300, Andra Paraschiv wrote: > +/* Nitro Enclaves (NE) misc device */ > +extern struct miscdevice ne_miscdevice; Why does your misc device need to be in a .h file? Having the patch series like this (add random .h files, and then start to use them), is hard to r

Re: [PATCH v3 02/18] nitro_enclaves: Define the PCI device interface

2020-05-25 Thread Greg KH
On Tue, May 26, 2020 at 01:13:18AM +0300, Andra Paraschiv wrote: > +struct enclave_get_slot_req { > + /* Context ID (CID) for the enclave vsock device. */ > + u64 enclave_cid; > +} __attribute__ ((__packed__)); Can you really "pack" a single member structure? Anyway, we have better ways t

[PATCH] doc: filesystems: format tables in locking properly

2020-05-25 Thread Lukas Bulwahn
Commit 28df3d1539de ("nfsd: clients don't need to break their own delegations") introduced lm_breaker_owns_lease and documented that in the according table. Commit 43dbd0e7e62b ("mmap locking API: convert mmap_sem comments") renamed mmap_sem to mmap_lock in another table. Both changes created a tab

Re: [PATCH v2 07/18] nitro_enclaves: Init misc device providing the ioctl interface

2020-05-25 Thread Greg KH
On Mon, May 25, 2020 at 11:49:50PM +0300, Paraschiv, Andra-Irina wrote: > > > On 22/05/2020 10:07, Greg KH wrote: > > On Fri, May 22, 2020 at 09:29:35AM +0300, Andra Paraschiv wrote: > > > +static char *ne_cpus; > > > +module_param(ne_cpus, charp, 0644); > > > +MODULE_PARM_DESC(ne_cpus, " - CPU p

Re: [PATCH v2 16/18] nitro_enclaves: Add sample for ioctl interface usage

2020-05-25 Thread Greg KH
On Mon, May 25, 2020 at 11:57:26PM +0300, Paraschiv, Andra-Irina wrote: > > > On 22/05/2020 10:08, Greg KH wrote: > > On Fri, May 22, 2020 at 09:29:44AM +0300, Andra Paraschiv wrote: > > > Signed-off-by: Alexandru Vasile > > > Signed-off-by: Andra Paraschiv > > I know I don't take commits with

Re: [PATCH v3 1/6] arm64: Detect the ARMv8.4 TTL feature

2020-05-25 Thread Zhenyu Ye
Hi Anshuman, On 2020/5/26 10:39, Anshuman Khandual wrote: > This patch (https://patchwork.kernel.org/patch/11557359/) is adding some > more ID_AA64MMFR2 features including the TTL. I am going to respin parts > of the V4 series patches along with the above mentioned patch. So please > rebase this s

Re: [RFC 07/16] KVM: mm: Introduce VM_KVM_PROTECTED

2020-05-25 Thread John Hubbard
On 2020-05-22 05:52, Kirill A. Shutemov wrote: ... @@ -2773,6 +2780,7 @@ struct page *follow_page(struct vm_area_struct *vma, unsigned long address, #define FOLL_LONGTERM 0x1 /* mapping lifetime is indefinite: see below */ #define FOLL_SPLIT_PMD0x2 /* split huge pmd before re

Re: [PATCH v4 1/3] dmaengine: ptdma: Initial driver for the AMD PTDMA controller

2020-05-25 Thread Sanjay R Mehta
On 5/26/2020 11:59 AM, Greg KH wrote: > [CAUTION: External Email] > > On Tue, May 26, 2020 at 11:35:02AM +0530, Sanjay R Mehta wrote: >> Apologies for my delayed response. >> +#include +#include +#include +#include +#include + +#include "ptdma.h" + >

Re: [RFC PATCH 0/3] METADATA design using V4l2 Request API

2020-05-25 Thread dikshita
Hi, A gentle reminder for the review. On 2020-05-08 11:51, Dikshita Agarwal wrote: There are many commercialized video use cases which needs metadata info to be circulated between v4l2 client and v4l2 driver. METADATA has following requirements associated: •Metadata is an optional info availab

Re: [PATCH v4 1/3] dmaengine: ptdma: Initial driver for the AMD PTDMA controller

2020-05-25 Thread Greg KH
On Tue, May 26, 2020 at 11:35:02AM +0530, Sanjay R Mehta wrote: > Apologies for my delayed response. > > >> +#include > >> +#include > >> +#include > >> +#include > >> +#include > >> + > >> +#include "ptdma.h" > >> + > >> +static int cmd_queue_length = 32; > >> +module_param(cmd_queue_length,

[PATCH] ALSA: usb: mixer: volume quirk for ESS Technology Asus USB DAC

2020-05-25 Thread Chris Chiu
The Asus USB DAC is a USB type-C audio dongle for connecting to the headset and headphone. The volume minimum value -23040 which is 0xa600 in hexadecimal with the resolution value 1 indicates this should be endianness issue caused by the firmware bug. Add a volume quirk to fix the volume control pr

RE: [PATCH] scsi: ufs-qcom: Fix scheduling while atomic issue

2020-05-25 Thread Avri Altman
> ufs_qcom_dump_dbg_regs() uses usleep_range, a sleeping function, but can > be called from atomic context in the following flow: > > ufshcd_intr -> ufshcd_sl_intr -> ufshcd_check_errors -> > ufshcd_print_host_regs -> ufshcd_vops_dbg_register_dump -> > ufs_qcom_dump_dbg_regs > > This causes a b

[PATCH 2/2] KVM: SVM: convert get_user_pages() --> pin_user_pages()

2020-05-25 Thread John Hubbard
This code was using get_user_pages*(), in a "Case 2" scenario (DMA/RDMA), using the categorization from [1]. That means that it's time to convert the get_user_pages*() + put_page() calls to pin_user_pages*() + unpin_user_pages() calls. There is some helpful background in [2]: basically, this is a

[PATCH 0/2] KVM: SVM: convert get_user_pages() --> pin_user_pages(), bug fixes

2020-05-25 Thread John Hubbard
Hi, This is just for the SEV (Secure Encrypted Virtualization) part of KVM. It converts the get_user_pages_fast() call, after fixing a couple of small bugs in the vicinity. Note that I have only compile-tested these two patches, so any run-time testing coverage would be greatly appreciated. Cc:

[PATCH 1/2] KVM: SVM: fix svn_pin_memory()'s use of get_user_pages_fast()

2020-05-25 Thread John Hubbard
There are two problems in svn_pin_memory(): 1) The return value of get_user_pages_fast() is stored in an unsigned long, although the declared return value is of type int. This will not cause any symptoms, but it is misleading. Fix this by changing the type of npinned to "int". 2) The number of pa

Re: [PATCH v9 0/8] KVM: Add virtualization support of split lock detection

2020-05-25 Thread Xiaoyao Li
Hi Thomas, On 5/18/2020 9:27 AM, Xiaoyao Li wrote: On 5/9/2020 7:05 PM, Xiaoyao Li wrote: This series aims to add the virtualization of split lock detection in KVM. Due to the fact that split lock detection is tightly coupled with CPU model and CPU model is configurable by host VMM, we elect t

[PATCH v4] thermal: qoriq: Update the settings for TMUv2

2020-05-25 Thread Yuantian Tang
For TMU v2, TMSAR registers need to be set properly to get the accurate temperature values. Also the temperature read needs to be converted to degree Celsius since it is in degrees Kelvin. Signed-off-by: Yuantian Tang --- v4: - replace the hard-coded number with constant variables

Re: [RFC 00/16] KVM protected memory extension

2020-05-25 Thread Mike Rapoport
On Mon, May 25, 2020 at 04:47:18PM +0300, Liran Alon wrote: > > On 22/05/2020 15:51, Kirill A. Shutemov wrote: > > Furthermore, I would like to point out that just unmapping guest data from > kernel direct-map is not sufficient to prevent all > guest-to-guest info-leaks via a kernel memory info-l

Re: [RFC 16/16] KVM: Unmap protected pages from direct mapping

2020-05-25 Thread Mike Rapoport
On Fri, May 22, 2020 at 03:52:14PM +0300, Kirill A. Shutemov wrote: > If the protected memory feature enabled, unmap guest memory from > kernel's direct mappings. > > Migration and KSM is disabled for protected memory as it would require a > special treatment. > > Signed-off-by: Kirill A. Shutemo

Re: [RFC 07/16] KVM: mm: Introduce VM_KVM_PROTECTED

2020-05-25 Thread Mike Rapoport
On Fri, May 22, 2020 at 03:52:05PM +0300, Kirill A. Shutemov wrote: > The new VMA flag that indicate a VMA that is not accessible to userspace > but usable by kernel with GUP if FOLL_KVM is specified. > > The FOLL_KVM is only used in the KVM code. The code has to know how to > deal with such pages

Re: [RFC 10/16] KVM: x86: Enabled protected memory extension

2020-05-25 Thread Mike Rapoport
On Fri, May 22, 2020 at 03:52:08PM +0300, Kirill A. Shutemov wrote: > Wire up hypercalls for the feature and define VM_KVM_PROTECTED. > > Signed-off-by: Kirill A. Shutemov > --- > arch/x86/Kconfig | 1 + > arch/x86/kvm/cpuid.c | 3 +++ > arch/x86/kvm/x86.c | 9 + > include/linux/mm

RE: Another approach of UFSHPB

2020-05-25 Thread Avri Altman
> On 2020-05-24 22:40, Daejun Park wrote: > > The HPB driver is close to the UFS core function, but it is not essential > > for operating UFS device. With reference to this article > > (https://lwn.net/Articles/645810/), we implemented extended UFS-feature > > as bus model. Because the HPB driver c

Re: [RFC 06/16] KVM: Use GUP instead of copy_from/to_user() to access guest memory

2020-05-25 Thread Mike Rapoport
On Fri, May 22, 2020 at 03:52:04PM +0300, Kirill A. Shutemov wrote: > New helpers copy_from_guest()/copy_to_guest() to be used if KVM memory > protection feature is enabled. > > Signed-off-by: Kirill A. Shutemov > --- > include/linux/kvm_host.h | 4 +++ > virt/kvm/kvm_main.c | 78 +

Re: clean up and streamline probe_kernel_* and friends v4

2020-05-25 Thread Christoph Hellwig
On Mon, May 25, 2020 at 03:19:12PM -0700, Andrew Morton wrote: > hm. Applying linux-next to this series generates a lot of rejects against > powerpc: > > -rw-rw-r-- 1 akpm akpm 493 May 25 15:06 arch/powerpc/kernel/kgdb.c.rej > -rw-rw-r-- 1 akpm akpm 6461 May 25 15:06 > arch/powerpc/kernel/trace

Re: [PATCH v2 4/4] x86/boot: Check that there are no runtime relocations

2020-05-25 Thread Ard Biesheuvel
On Tue, 26 May 2020 at 00:59, Arvind Sankar wrote: > > Add a linker script check that there are no runtime relocations, and > remove the old one that tries to check via looking for specially-named > sections in the object files. > > Drop the tests for -fPIE compiler option and -pie linker option,

[PATCH v4 7/7] perf diff: Support hot streams comparison

2020-05-25 Thread Jin Yao
This patch enables perf-diff with "--stream" option. "--stream": Enable hot streams comparison Now let's see examples. perf record -b ... Generate perf.data.old with branch data perf record -b ... Generate perf.data with branch data perf diff --stream [ Matched hot streams ] hot chai

[PATCH v4 2/7] perf util: Get the evsel_streams by evsel_idx

2020-05-25 Thread Jin Yao
In previous patch, we have created evsel_streams array This patch returns the specified evsel_streams according to the evsel_idx. Signed-off-by: Jin Yao --- tools/perf/util/stream.c | 11 +++ tools/perf/util/stream.h | 3 +++ 2 files changed, 14 insertions(+) diff --git a/tools/perf/u

[PATCH v4 6/7] perf util: Report hot streams

2020-05-25 Thread Jin Yao
We show the streams separately. They are divided into different sections. 1. "Matched hot streams" 2. "Hot streams in old perf data only" 3. "Hot streams in new perf data only". For each stream, we report the cycles and hot percent (hits%). For example, cycles: 2, hits: 4.08% --

[PATCH v4 0/7] perf: Stream comparison

2020-05-25 Thread Jin Yao
Sometimes, a small change in a hot function reducing the cycles of this function, but the overall workload doesn't get faster. It is interesting where the cycles are moved to. What it would like is to diff before/after streams. The stream is the branch history which is aggregated by the branch rec

[PATCH v4 3/7] perf util: Compare two streams

2020-05-25 Thread Jin Yao
Stream is the branch history which is aggregated by the branch records from perf samples. Now we only support the callchain as stream. If the callchain entries of one stream are fully matched with the callchain entries of another stream, we think two streams are matched. For example, cycles:

[PATCH v4 5/7] perf util: Calculate the sum of total streams hits

2020-05-25 Thread Jin Yao
We have used callchain_node->hit to measure the hot level of one stream. This patch calculates the sum of hits of total streams. Then in next patch, we can use following formula to report hot percent for one stream. hot percent = callchain_node->hit / sum of total hits Signed-off-by: Jin Yao --

[PATCH v4 4/7] perf util: Link stream pair

2020-05-25 Thread Jin Yao
In previous patch, we have created an evsel_streams for one event, and top N hottest streams will be saved in a stream array in evsel_streams. This patch compares total streams among two evsel_streams. Once two streams are fully matched, they will be linked as a pair. From the pair, we can know w

[PATCH v4 1/7] perf util: Create streams

2020-05-25 Thread Jin Yao
We define the stream is the branch history which is aggregated by the branch records from perf samples. For example, the callchains aggregated from the branch records. By browsing the hot stream, we can understand the hot code path. Now we only support the callchain. So for measuring the hot level

Re: [PATCH v4 3/3] dmaengine: ptdma: Add debugfs entries for PTDMA information

2020-05-25 Thread Sanjay R Mehta
>> +static const struct file_operations pt_debugfs_info_ops = { >> + .owner = THIS_MODULE, >> + .open = simple_open, >> + .read = ptdma_debugfs_info_read, >> + .write = NULL, >> +}; >> + >> +static const struct file_operations pt_debugfs_queue_ops = { >> + .owner = THIS_MODULE,

Re: [PATCH 4/5] seccomp: Add SECCOMP_ADDFD_FLAG_MOVE flag to add fd ioctl

2020-05-25 Thread Sargun Dhillon
> > + * they are created in. Specifcally, sockets, and their interactions with > > the > > + * net_cls and net_prio cgroup v1 controllers. This "moves" the file > > descriptor > > + * so that it takes on the cgroup controller's configuration in the process > > + * that the file descriptor is bein

[PATCH] Replace HTTP links with HTTPS ones: documentation

2020-05-25 Thread Alexander A. Klimov
Rationale: Reduces attack surface on kernel devs opening the links for MITM as HTTPS traffic is much harder to manipulate. Deterministic algorithm: For each file: For each line: If doesn't contain `\bxmlns\b`: For each link, `\bhttp://[^# \t\r\n]*(?:\w|/)`: If both the HTTP and

Re: [PATCH v4 1/3] dmaengine: ptdma: Initial driver for the AMD PTDMA controller

2020-05-25 Thread Sanjay R Mehta
Apologies for my delayed response. >> +#include >> +#include >> +#include >> +#include >> +#include >> + >> +#include "ptdma.h" >> + >> +static int cmd_queue_length = 32; >> +module_param(cmd_queue_length, uint, 0644); >> +MODULE_PARM_DESC(cmd_queue_length, >> + " length of the c

Re: [PATCH v4 4/7] KVM: PPC: clean up redundant 'kvm_run' parameters

2020-05-25 Thread Paul Mackerras
On Mon, Apr 27, 2020 at 12:35:11PM +0800, Tianjia Zhang wrote: > In the current kvm version, 'kvm_run' has been included in the 'kvm_vcpu' > structure. For historical reasons, many kvm-related function parameters > retain the 'kvm_run' and 'kvm_vcpu' parameters at the same time. This > patch does a

Re: [PATCH v4 5/7] KVM: PPC: clean up redundant kvm_run parameters in assembly

2020-05-25 Thread Paul Mackerras
On Mon, Apr 27, 2020 at 12:35:12PM +0800, Tianjia Zhang wrote: > In the current kvm version, 'kvm_run' has been included in the 'kvm_vcpu' > structure. For historical reasons, many kvm-related function parameters > retain the 'kvm_run' and 'kvm_vcpu' parameters at the same time. This > patch does a

Re: [PATCH 2/2] kobject: send KOBJ_REMOVE uevent when the object is removed from sysfs

2020-05-25 Thread Greg Kroah-Hartman
On Mon, May 25, 2020 at 03:49:01PM -0700, Dmitry Torokhov wrote: > On Sun, May 24, 2020 at 8:34 AM Greg Kroah-Hartman > wrote: > > > > It is possible for a KOBJ_REMOVE uevent to be sent to userspace way > > after the files are actually gone from sysfs, due to how reference > > counting for kobject

[PATCH] coresight: Use devm_kcalloc() in coresight_alloc_conns()

2020-05-25 Thread Xu Wang
A multiplication for the size determination of a memory allocation indicated that an array data structure should be processed. Thus use the corresponding function "devm_kcalloc". Signed-off-by: Xu Wang --- drivers/hwtracing/coresight/coresight-platform.c | 5 ++--- 1 file changed, 2 insertions(+

Re: [RFC PATCH V2 4/7] x86/hw_breakpoint: Prevent data breakpoints on user_pcid_flush_mask

2020-05-25 Thread Lai Jiangshan
On Tue, May 26, 2020 at 12:39 PM Andy Lutomirski wrote: > > On Mon, May 25, 2020 at 9:31 PM Lai Jiangshan > wrote: > > > > On Tue, May 26, 2020 at 12:21 PM Andy Lutomirski wrote: > > > > > > On Mon, May 25, 2020 at 6:42 PM Lai Jiangshan > > > wrote: > > > > > > > > The percpu user_pcid_flush_m

Re: linux-next: manual merge of the net-next tree with the bpf tree

2020-05-25 Thread Björn Töpel
On 2020-05-26 05:12, Stephen Rothwell wrote: I fixed it up (see below) and can carry the fix as necessary. This is now fixed as far as linux-next is concerned, but any non trivial conflicts should be mentioned to your upstream maintainer when your tree is submitted for merging. You may also want

Re: [PATCH v4 3/7] KVM: PPC: Remove redundant kvm_run from vcpu_arch

2020-05-25 Thread Paul Mackerras
On Mon, Apr 27, 2020 at 12:35:10PM +0800, Tianjia Zhang wrote: > The 'kvm_run' field already exists in the 'vcpu' structure, which > is the same structure as the 'kvm_run' in the 'vcpu_arch' and > should be deleted. > > Signed-off-by: Tianjia Zhang This looks fine. I assume each architecture su

Re: [PATCH] power: reset: vexpress: fix build issue

2020-05-25 Thread Nathan Chancellor
On Mon, May 25, 2020 at 07:37:45PM -0400, Valdis Klētnieks wrote: > On Sun, 24 May 2020 15:20:25 -0700, Nathan Chancellor said: > > > arm-linux-gnueabi-ld: drivers/power/reset/vexpress-poweroff.o: in function > > `vexpress_reset_probe': > > vexpress-poweroff.c:(.text+0x36c): undefined reference t

[PATCH] vdpa: bypass waking up vhost_woker for vdpa vq kick

2020-05-25 Thread Zhu Lingshan
Standard vhost devices rely on waking up a vhost_worker to kick a virtquque. However vdpa devices have hardware backends, so it does not need this waking up routin. In this commit, vdpa device will kick a virtqueue directly, reduce the performance overhead caused by waking up a vhost_woker. Signed

[PATCH v1] x86: Pin cr4 FSGSBASE

2020-05-25 Thread Andi Kleen
From: Andi Kleen Since there seem to be kernel modules floating around that set FSGSBASE incorrectly, prevent this in the CR4 pinning. Currently CR4 pinning just checks that bits are set, this also checks that the FSGSBASE bit is not set, and if it is clears it again. Note this patch will need t

linux-next: manual merge of the devicetree tree with the watchdog tree

2020-05-25 Thread Stephen Rothwell
Hi all, Today's linux-next merge of the devicetree tree got a conflict in: Documentation/devicetree/bindings/watchdog/renesas,wdt.txt between commit: ff1ee6fb276c ("dt-bindings: watchdog: renesas,wdt: Document r8a7742 support") from the watchdog tree and commit: d0941cfb9fa8 ("dt-bindin

Re: [PATCH v2] iommu/iova: Retry from last rb tree node if iova search fails

2020-05-25 Thread Vijayanand Jitta
On 5/11/2020 4:34 PM, vji...@codeaurora.org wrote: > From: Vijayanand Jitta > > When ever a new iova alloc request comes iova is always searched > from the cached node and the nodes which are previous to cached > node. So, even if there is free iova space available in the nodes > which are nex

Re: [PATCH 3/3] hwrng: ba431-rng: add support for BA431 hwrng

2020-05-25 Thread Olivier Sobrie
On Mon, May 25, 2020 at 10:28:46PM +0200, Arnd Bergmann wrote: > On Mon, May 25, 2020 at 10:07 PM Olivier Sobrie > wrote: > > > > Silex insight BA431 is an IP designed to generate random numbers that > > can be integrated in various FPGA. > > This driver adds support for it through the hwrng inter

Re: [PATCH v3 0/3] Add Qualcomm IPCC driver support

2020-05-25 Thread Manivannan Sadhasivam
Hi Jassi, On Wed, May 20, 2020 at 02:18:51PM +0530, Manivannan Sadhasivam wrote: > Hello, > > This series adds mailbox driver support for Qualcomm Inter Processor > Communications Controller (IPCC) block found in MSM chipsets. This block > is used to route interrupts between modems, DSPs and APSS

Re: [PATCH] drivers/virt/fsl_hypervisor: Correcting error handling path

2020-05-25 Thread Souptick Joarder
On Fri, May 22, 2020 at 6:24 PM Dan Carpenter wrote: > > On Thu, May 14, 2020 at 01:53:16AM +0530, Souptick Joarder wrote: > > First, when memory allocation for sg_list_unaligned failed, there > > is no point of calling put_pages() as we haven't pinned any pages. > > > > Second, if get_user_pages_

Re: Re: [PATCH] iio: magnetometer: ak8974: Fix runtime PM imbalance on error

2020-05-25 Thread dinghao . liu
Hi, Linus > On Sun, May 24, 2020 at 4:51 AM Dinghao Liu wrote: > > > When devm_regmap_init_i2c() returns an error code, a pairing > > runtime PM usage counter decrement is needed to keep the > > counter balanced. For error paths after ak8974_set_power(), > > ak8974_detect() and ak8974_reset(), t

[PATCH v2 2/2] phy: intel: Add Keem Bay eMMC PHY support

2020-05-25 Thread Wan Ahmad Zainie
Add support for eMMC PHY on Intel Keem Bay SoC. Signed-off-by: Wan Ahmad Zainie --- drivers/phy/intel/Kconfig| 8 + drivers/phy/intel/Makefile | 1 + drivers/phy/intel/phy-keembay-emmc.c | 321 +++ 3 files changed, 330 insertions(+) create mode

[PATCH 2/2] arm64: tegra: Add pwm-fan profile settings

2020-05-25 Thread Sandipan Patra
Add support for profiles in device tree to allow different fan settings for trip point temp/hyst/pwm. Signed-off-by: Sandipan Patra --- arch/arm64/boot/dts/nvidia/tegra194-p2972-.dts | 15 --- 1 file changed, 12 insertions(+), 3 deletions(-) diff --git a/arch/arm64/boot/dts/nvid

[PATCH v2 1/2] dt-bindings: phy: intel: Add Keem Bay eMMC PHY bindings

2020-05-25 Thread Wan Ahmad Zainie
Binding description for Intel Keem Bay eMMC PHY. Signed-off-by: Wan Ahmad Zainie --- .../bindings/phy/intel,keembay-emmc-phy.yaml | 45 +++ 1 file changed, 45 insertions(+) create mode 100644 Documentation/devicetree/bindings/phy/intel,keembay-emmc-phy.yaml diff --git a/Docum

[PATCH v2 0/2] phy: intel: Add Keem Bay eMMC PHY support

2020-05-25 Thread Wan Ahmad Zainie
Hi. The first part is to document DT bindings for Keem Bay eMMC PHY. The second is the driver file, loosely based on phy-rockchip-emmc.c and phy-intel-emmc.c. The latter is not being reused as there are quite a number of differences i.e. registers offset, supported clock rates, bitfield to set.

[PATCH 1/2] hwmon: pwm-fan: Add profile support and add remove module support

2020-05-25 Thread Sandipan Patra
This change has 2 parts: 1. Add support for profiles mode settings. This allows different fan settings for trip point temp/hyst/pwm. T194 has multiple fan-profiles support. 2. Add pwm-fan remove support. This is essential since the config is tristate capable. Signed-off-by: Sandipan P

Re: [PATCH] kexec: Do not verify the signature without the lockdown or mandatory signature

2020-05-25 Thread Dave Young
On 05/25/20 at 01:23pm, Lianbo Jiang wrote: > Signature verification is an important security feature, to protect > system from being attacked with a kernel of unknown origin. Kexec > rebooting is a way to replace the running kernel, hence need be > secured carefully. > > In the current code of ha

drivers/mfd/sprd-sc27xx-spi.c:59:23: warning: no previous prototype for 'sprd_pmic_detect_charger_type'

2020-05-25 Thread kbuild test robot
tree: https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git master head: 9cb1fd0efd195590b828b9b865421ad345a4a145 commit: 2a7e7274f3d43d2a072cab25c0035dc994903bb9 mfd: sc27xx: Add USB charger type detection support date: 8 weeks ago config: h8300-randconfig-r006-20200526 (attac

Re: [PATCH v2 1/4] gpio: gpiolib: Allow GPIO IRQs to lazy disable

2020-05-25 Thread Maulik Shah
Hi, On 5/25/2020 5:52 PM, Hans Verkuil wrote: On 25/05/2020 13:55, Linus Walleij wrote: On Sat, May 23, 2020 at 7:11 PM Maulik Shah wrote: With 'commit 461c1a7d4733 ("gpiolib: override irq_enable/disable")' gpiolib overrides irqchip's irq_enable and irq_disable callbacks. If irq_disable call

Re: linux-next: manual merge of the akpm-current tree with the tip tree

2020-05-25 Thread Singh, Balbir
On Mon, 2020-05-25 at 21:04 +1000, Stephen Rothwell wrote: > Hi all, > > Today's linux-next merge of the akpm-current tree got a conflict in: > > arch/x86/mm/tlb.c > > between commit: > > 83ce56f712af ("x86/mm: Refactor cond_ibpb() to support other use cases") > > from the tip tree and com

Re: [RFC PATCH V2 4/7] x86/hw_breakpoint: Prevent data breakpoints on user_pcid_flush_mask

2020-05-25 Thread Andy Lutomirski
On Mon, May 25, 2020 at 9:31 PM Lai Jiangshan wrote: > > On Tue, May 26, 2020 at 12:21 PM Andy Lutomirski wrote: > > > > On Mon, May 25, 2020 at 6:42 PM Lai Jiangshan > > wrote: > > > > > > The percpu user_pcid_flush_mask is used for CPU entry > > > If a data breakpoint on it, it will cause an

Re: linux-next: build failure after merge of the block tree

2020-05-25 Thread Stephen Rothwell
Hi all, On Mon, 25 May 2020 13:03:44 -0600 Jens Axboe wrote: > > On 5/24/20 11:08 PM, Stephen Rothwell wrote: > > > > After merging the block tree, today's linux-next build (arm > > multi_v7_defconfig) failed like this: > > > > mm/filemap.c: In function 'generic_file_buffered_read': > > mm/file

[PATCH 0/2] x86/entry: simplify RESTORE_CR3

2020-05-25 Thread Lai Jiangshan
When I searched percpu data touched by entry code for #DB protection[1], it seems to me RESTORE_CR3() does too much work, this patchset simplifies it. Patch 1 enhances 21e944591102("x86/mm: Optimize RESTORE_CR3") for kernel CR3. Patch 2 *reverts* 21e944591102("x86/mm: Optimize RESTORE_CR3") for U

[PATCH 2/2] x86/entry: always flush user CR3 in RESTORE_CR3

2020-05-25 Thread Lai Jiangshan
RESTORE_CR3 is called when CPL==0 or #DF, it is unlikely CPL==0&cr3==userCR3 and #DF itself is unlikely case. There is no much overhead to always flush userCR3. Signed-off-by: Lai Jiangshan --- arch/x86/entry/calling.h | 27 ++- arch/x86/entry/entry_64.S | 6 +++--- 2 f

[PATCH 1/2] x86/entry: Don't write to CR3 when restoring to kernel CR3

2020-05-25 Thread Lai Jiangshan
Skip resuming KERNEL pages since it is already KERNEL CR3 Signed-off-by: Lai Jiangshan --- arch/x86/entry/calling.h | 13 - 1 file changed, 4 insertions(+), 9 deletions(-) diff --git a/arch/x86/entry/calling.h b/arch/x86/entry/calling.h index 1c7f13bb6728..505246185624 100644 --- a/

drivers/usb/cdns3/drd.c:43:31: sparse: expected void const volatile [noderef] *

2020-05-25 Thread kbuild test robot
tree: https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git master head: 9cb1fd0efd195590b828b9b865421ad345a4a145 commit: 70d8b9e5e63d212019ba3f6823c8ec3d2df87645 usb: cdns3: make signed 1 bit bitfields unsigned date: 9 weeks ago config: sh-randconfig-s032-20200526 (attached as

Re: [patch V9 00/39] x86/entry: Rework leftovers (was part V)

2020-05-25 Thread Andy Lutomirski
On Thu, May 21, 2020 at 1:31 PM Thomas Gleixner wrote: > > Folks! > > This is V9 of the rework series. V7 and V8 were never posted but I used the > version numbers for tags while fixing up 0day complaints. The last posted > version was V6 which can be found here: The whole pile is Acked-by: Andy

drivers/spi/spi-meson-spicc.c:363:6: warning: variable 'data' set but not used

2020-05-25 Thread kbuild test robot
tree: https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git master head: 9cb1fd0efd195590b828b9b865421ad345a4a145 commit: 0eb707ac7dd7a4329d93d47feada6c9bb5ea8ee9 spi: meson-spicc: adapt burst handling for G12A support date: 2 months ago config: h8300-randconfig-r006-20200526 (

Re: [RFC PATCH V2 4/7] x86/hw_breakpoint: Prevent data breakpoints on user_pcid_flush_mask

2020-05-25 Thread Lai Jiangshan
On Tue, May 26, 2020 at 12:21 PM Andy Lutomirski wrote: > > On Mon, May 25, 2020 at 6:42 PM Lai Jiangshan wrote: > > > > The percpu user_pcid_flush_mask is used for CPU entry > > If a data breakpoint on it, it will cause an unwanted #DB. > > Protect the full cpu_tlbstate structure to be sure. > >

Re: mmotm 2020-05-25-16-56 uploaded (drm/nouveau)

2020-05-25 Thread Randy Dunlap
On 5/25/20 9:23 PM, Dave Airlie wrote: > On Tue, 26 May 2020 at 13:50, Randy Dunlap wrote: >> >> On 5/25/20 4:57 PM, Andrew Morton wrote: >>> The mm-of-the-moment snapshot 2020-05-25-16-56 has been uploaded to >>> >>>http://www.ozlabs.org/~akpm/mmotm/ >>> >>> mmotm-readme.txt says >>> >>> READ

[PATCH 1/1] nvme-fcloop: verify wwnn and wwpn format

2020-05-25 Thread Dongli Zhang
The nvme host and target verify the wwnn and wwpn format via nvme_fc_parse_traddr(). For instance, it is required that the length of wwnn to be either 21 ("nn-0x") or 19 (nn-). Add this verification to nvme-fcloop so that the input should always be in hex and the length of input should always be 1

Re: mmotm 2020-05-25-16-56 uploaded (drm/nouveau)

2020-05-25 Thread Dave Airlie
On Tue, 26 May 2020 at 13:50, Randy Dunlap wrote: > > On 5/25/20 4:57 PM, Andrew Morton wrote: > > The mm-of-the-moment snapshot 2020-05-25-16-56 has been uploaded to > > > >http://www.ozlabs.org/~akpm/mmotm/ > > > > mmotm-readme.txt says > > > > README for mm-of-the-moment: > > > > http://www

Re: [RFC PATCH V2 4/7] x86/hw_breakpoint: Prevent data breakpoints on user_pcid_flush_mask

2020-05-25 Thread Andy Lutomirski
On Mon, May 25, 2020 at 6:42 PM Lai Jiangshan wrote: > > The percpu user_pcid_flush_mask is used for CPU entry > If a data breakpoint on it, it will cause an unwanted #DB. > Protect the full cpu_tlbstate structure to be sure. > > There are some other percpu data used in CPU entry, but they are > e

Re: [PATCH] Input: elantech - Remove read/write registers in attr.

2020-05-25 Thread Dmitry Torokhov
Hi Jingle, On Tue, May 26, 2020 at 10:22:46AM +0800, Jingle.Wu wrote: > New Elan IC would not be accessed with the specific regiters. What about older Elaan parts? We can't simply drop compatibility with older chips in newer kernels. Thanks. -- Dmitry

Re: inux-next: build failure after merge of the drm-msm tree

2020-05-25 Thread Stephen Rothwell
Hi all, On Tue, 19 May 2020 15:09:55 +1000 Stephen Rothwell wrote: > > Hi all, > > After merging the drm-msm tree, today's linux-next build (arm > multi_v7_defconfig) failed like this: > > ERROR: modpost: "__aeabi_ldivmod" [drivers/gpu/drm/msm/msm.ko] undefined! > ERROR: modpost: "__aeabi_uldi

WARNING: suspicious RCU usage in idtentry_exit

2020-05-25 Thread syzbot
Hello, syzbot found the following crash on: HEAD commit:7b4cb0a4 Add linux-next specific files for 20200525 git tree: linux-next console output: https://syzkaller.appspot.com/x/log.txt?x=1335601610 kernel config: https://syzkaller.appspot.com/x/.config?x=47b0740d89299c10 dashboard

drivers/soc/fsl/dpio/qbman-portal.c:661:11: warning: variable 'addr_cena' set but not used

2020-05-25 Thread kbuild test robot
tree: https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git master head: 9cb1fd0efd195590b828b9b865421ad345a4a145 commit: 3b2abda7d28c69f564c1157b9b9c21ef40092ee9 soc: fsl: dpio: Replace QMAN array mode with ring mode enqueue date: 3 months ago config: i386-randconfig-r004-2020

general protection fault in tomoyo_check_acl

2020-05-25 Thread syzbot
Hello, syzbot found the following crash on: HEAD commit:d2f8825a Merge tag 'for_linus' of git://git.kernel.org/pub.. git tree: upstream console output: https://syzkaller.appspot.com/x/log.txt?x=13c5592210 kernel config: https://syzkaller.appspot.com/x/.config?x=b3368ce0cc5f5ace das

[PATCH v1] Bluetooth: hci_qca: Improve controller ID info log level

2020-05-25 Thread Zijun Hu
Controller ID info got by VSC EDL_PATCH_GETVER is very important, so improve its log level from DEBUG to INFO. Signed-off-by: Zijun Hu --- drivers/bluetooth/btqca.c | 8 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/drivers/bluetooth/btqca.c b/drivers/bluetooth/btqca.c i

Re: [PATCH v2] relay: handle alloc_percpu returning NULL in relay_open

2020-05-25 Thread Michael Ellerman
[ + akpm ] Daniel Axtens writes: >>> > Check if alloc_percpu returns NULL. >>> > >>> > This was found by syzkaller both on x86 and powerpc, and the reproducer >>> > it found on powerpc is capable of hitting the issue as an unprivileged >>> > user. >>> > >>> > Fixes: 017c59c042d0 ("relay: Use pe

[PATCH] drm/msm/a6xx: set ubwc config for A640 and A650

2020-05-25 Thread Jonathan Marek
This is required for A640 and A650 to be able to share UBWC-compressed images with other HW such as display, which expect this configuration. Signed-off-by: Jonathan Marek --- drivers/gpu/drm/msm/adreno/a6xx_gpu.c | 38 ++- 1 file changed, 32 insertions(+), 6 deletions(-)

[PATCH 6/8] drm/msm/dpu: intf timing path for displayport

2020-05-25 Thread Jonathan Marek
Calculate the correct timings for displayport, from downstream driver. Signed-off-by: Jonathan Marek --- drivers/gpu/drm/msm/disp/dpu1/dpu_hw_intf.c | 20 +++- 1 file changed, 15 insertions(+), 5 deletions(-) diff --git a/drivers/gpu/drm/msm/disp/dpu1/dpu_hw_intf.c b/drivers/gp

[PATCH 4/8] drm/msm/dpu: don't use INTF_INPUT_CTRL feature on sdm845

2020-05-25 Thread Jonathan Marek
The INTF_INPUT_CTRL feature is not available on sdm845, so don't set it. This also adds separate feature bits for INTF (based on downstream) instead of using CTL feature bit for it, and removes the unnecessary NULL check in the added bind_pingpong_blk function. Fixes: 73bfb790ac786ca55fa2786a06f5

[PATCH 7/8] drm/msm/dpu: add SM8150 to hw catalog

2020-05-25 Thread Jonathan Marek
This brings up basic video mode functionality for SM8150 DPU. Command mode and dual mixer/intf configurations are not working, future patches will address this. Scaler functionality and multiple planes is also untested. Signed-off-by: Jonathan Marek --- .../gpu/drm/msm/disp/dpu1/dpu_hw_catalog.c

[PATCH 5/8] drm/msm/dpu: set missing flush bits for INTF_2 and INTF_3

2020-05-25 Thread Jonathan Marek
This fixes flushing of INTF_2 and INTF_3 on SM8150 and SM8250 hardware. Signed-off-by: Jonathan Marek --- drivers/gpu/drm/msm/disp/dpu1/dpu_hw_ctl.c | 20 ++-- 1 file changed, 2 insertions(+), 18 deletions(-) diff --git a/drivers/gpu/drm/msm/disp/dpu1/dpu_hw_ctl.c b/drivers/gpu

[PATCH 8/8] drm/msm/dpu: add SM8250 to hw catalog

2020-05-25 Thread Jonathan Marek
This brings up basic video mode functionality for SM8250 DPU. Command mode and dual mixer/intf configurations are not working, future patches will address this. Scaler functionality and multiple planes is also untested. Signed-off-by: Jonathan Marek --- .../gpu/drm/msm/disp/dpu1/dpu_hw_catalog.c

[PATCH 2/8] drm/msm/dpu: update UBWC config for sm8150 and sm8250

2020-05-25 Thread Jonathan Marek
Update the UBWC registers to the right values for sm8150 and sm8250. This removes broken dpu_hw_reset_ubwc, which doesn't work because the "force blk offset to zero to access beginning of register region" hack is copied from downstream, where mapped region starts 0x1000 below what is used in the u

[PATCH 3/8] drm/msm/dpu: move some sspp caps to dpu_caps

2020-05-25 Thread Jonathan Marek
This isn't something that ever changes between planes, so move it to dpu_caps struct. Making this change will allow more re-use in the "SSPP sub blocks config" part of the catalog, in particular when adding support for SM8150 and SM8250 which have different max_linewidth. This also sets max_hdeci_

[PATCH 1/8] drm/msm/dpu: use right setup_blend_config for sm8150 and sm8250

2020-05-25 Thread Jonathan Marek
All DPU versions starting from 4.0 use the sdm845 version, so check for that instead of checking each version individually. This chooses the right function for sm8150 and sm8250. Signed-off-by: Jonathan Marek --- drivers/gpu/drm/msm/disp/dpu1/dpu_hw_lm.c | 5 ++--- 1 file changed, 2 insertions(+

[PATCH 0/8] Initial SM8150 and SM8250 DPU bringup

2020-05-25 Thread Jonathan Marek
These patches bring up SM8150 and SM8250 with basic functionality. Tested with displayport output (single mixer, video mode case). I will send patches later to add support for merge3d and dual DSI configurations, and possibly also patches to fix command mode on these SoCs (note it is also current

[PATCH v2 2/2] crypto: virtio: Fix use-after-free in virtio_crypto_skcipher_finalize_req()

2020-05-25 Thread Longpeng(Mike)
The system'll crash when the users insmod crypto/tcrypto.ko with mode=155 ( testing "authenc(hmac(sha1),cbc(aes))" ). It's caused by reuse the memory of request structure. In crypto_authenc_init_tfm(), the reqsize is set to: [PART 1] sizeof(authenc_request_ctx) + [PART 2] ictx->reqoff + [PAR

[PATCH v2 1/2] crypto: virtio: Fix src/dst scatterlist calculation in __virtio_crypto_skcipher_do_req()

2020-05-25 Thread Longpeng(Mike)
The system will crash when the users insmod crypto/tcrypt.ko with mode=38 ( testing "cts(cbc(aes))" ). Usually the next entry of one sg will be @sg@ + 1, but if this sg element is part of a chained scatterlist, it could jump to the start of a new scatterlist array. Fix it by sg_next() on calculati

  1   2   3   4   5   6   7   8   9   10   >