[RFC v2 21/26] mm/asi: Make functions to read cr3/cr4 ASI aware

2019-07-11 Thread Alexandre Chartre
When address space isolation is active, cpu_tlbstate isn't necessarily mapped in the ASI page-table, this would cause ASI to fault. Instead of just mapping cpu_tlbstate, update __get_current_cr3_fast() and cr4_read_shadow() by caching the cr3/cr4 values in the ASI session when ASI is active. Note

[RFC v2 12/26] mm/asi: Function to copy page-table entries for percpu buffer

2019-07-11 Thread Alexandre Chartre
Provide functions to copy page-table entries from the kernel page-table to an ASI page-table for a percpu buffer. A percpu buffer have a different VA range for each cpu and all them have to be copied. Signed-off-by: Alexandre Chartre --- arch/x86/include/asm/asi.h |6 ++

[RFC v2 10/26] mm/asi: Keep track of VA ranges mapped in ASI page-table

2019-07-11 Thread Alexandre Chartre
Add functions to keep track of VA ranges mapped in an ASI page-table. This will be used when unmapping to ensure the same range is unmapped, at the same page-table level. This is also be used to handle mapping and unmapping of overlapping VA ranges. Signed-off-by: Alexandre Chartre ---

[RFC v2 00/27] Kernel Address Space Isolation

2019-07-11 Thread Alexandre Chartre
Hi, This is version 2 of the "KVM Address Space Isolation" RFC. The code has been completely changed compared to v1 and it now provides a generic kernel framework which provides Address Space Isolation; and KVM is now a simple consumer of that framework. That's why the RFC title has been changed

[RFC v2 25/26] KVM: x86/asi: Switch to KVM address space on entry to guest

2019-07-11 Thread Alexandre Chartre
From: Liran Alon Switch to KVM address space on entry to guest. Most of KVM #VMExit handlers will run in KVM isolated address space and switch back to host address space only before accessing sensitive data. Sensitive data is defined as either host data or other VM data. Currently, we switch

[RFC v2 22/26] KVM: x86/asi: Introduce address_space_isolation module parameter

2019-07-11 Thread Alexandre Chartre
From: Liran Alon Add the address_space_isolation parameter to the kvm module. When set to true, KVM #VMExit handlers run in isolated address space which maps only KVM required code and per-VM information instead of entire kernel address space. This mechanism is meant to mitigate memory-leak

[RFC v2 16/26] mm/asi: Option to map current task into ASI

2019-07-11 Thread Alexandre Chartre
Add an option to map the current task into an ASI page-table. The task is mapped when entering isolation and unmapped on abort/exit. Signed-off-by: Alexandre Chartre --- arch/x86/include/asm/asi.h |2 ++ arch/x86/mm/asi.c | 25 +

[RFC v2 24/26] KVM: x86/asi: Populate the KVM ASI page-table

2019-07-11 Thread Alexandre Chartre
Add mappings to the KVM ASI page-table so that KVM can run with its address space isolation without faulting too much. Signed-off-by: Alexandre Chartre --- arch/x86/kvm/vmx/isolation.c | 155 - arch/x86/kvm/vmx/vmx.c |1 -

[RFC v2 08/26] mm/asi: Functions to populate an ASI page-table from a VA range

2019-07-11 Thread Alexandre Chartre
Provide functions to copy page-table entries from the kernel page-table to an ASI page-table for a specified VA range. These functions are based on the copy_pxx_range() functions defined in mm/memory.c. A difference is that a level parameter can be specified to indicate the page-table level (PGD,

[RFC v2 13/26] mm/asi: Add asi_remap() function

2019-07-11 Thread Alexandre Chartre
Add a function to remap an already mapped buffer with a new address in an ASI page-table: the already mapped buffer is unmapped, and a new mapping is added for the specified new address. This is useful to track and remap a buffer which can be freed and then reallocated. Signed-off-by: Alexandre

[RFC v2 20/26] mm/asi: Add option to map cpu_hw_events

2019-07-11 Thread Alexandre Chartre
Add option to map cpu_hw_events in ASI pagetable. Also restructure to select ptions for percpu optional mapping. Signed-off-by: Alexandre Chartre --- arch/x86/include/asm/asi.h |1 + arch/x86/mm/asi.c |3 +++ 2 files changed, 4 insertions(+), 0 deletions(-) diff --git

[RFC v2 23/26] KVM: x86/asi: Introduce KVM address space isolation

2019-07-11 Thread Alexandre Chartre
From: Liran Alon Create a separate address space for KVM that will be active when KVM #VMExit handlers run. Up until the point which we architectully need to access host (or other VM) sensitive data. This patch just create the address space using address space isolation (asi) but never makes it

[RFC v2 15/26] mm/asi: Initialize the ASI page-table with core mappings

2019-07-11 Thread Alexandre Chartre
Core mappings are the minimal mappings we need to be able to enter isolation and handle an isolation abort or exit. This includes the kernel code, the GDT and the percpu ASI sessions. We also need a stack so we map the current stack when entering isolation and unmap it on exit/abort. Optionally,

[RFC v2 18/26] rcu: Make percpu rcu_data non-static

2019-07-11 Thread Alexandre Chartre
Make percpu rcu_data non-static so that it can be mapped into an isolation address space page-table. This will allow address space isolation to use RCU without faulting. Signed-off-by: Alexandre Chartre --- kernel/rcu/tree.c |2 +- kernel/rcu/tree.h |1 + 2 files changed, 2

[RFC v2 06/26] mm/asi: Add ASI page-table entry allocation functions

2019-07-11 Thread Alexandre Chartre
Add functions to allocate p4d/pud/pmd/pte pages for an ASI page-table and keep track of them. Signed-off-by: Alexandre Chartre --- arch/x86/mm/asi_pagetable.c | 111 +++ 1 files changed, 111 insertions(+), 0 deletions(-) diff --git

[RFC v2 14/26] mm/asi: Handle ASI mapped range leaks and overlaps

2019-07-11 Thread Alexandre Chartre
When mapping a buffer in an ASI page-table, data around the buffer can also be mapped if the entire buffer is not aligned with the page directory size used for the mapping. So, data can potentially leak into the ASI page-table. In such a case, print a warning that data are leaking. Also data

Re: [PATCH 4/4] numa: introduce numa cling feature

2019-07-11 Thread Peter Zijlstra
On Wed, Jul 03, 2019 at 11:34:16AM +0800, 王贇 wrote: > Although we paid so many effort to settle down task on a particular > node, there are still chances for a task to leave it's preferred > node, that is by wakeup, numa swap migrations or load balance. > > When we are using cpu cgroup in share

[RFC v2 07/26] mm/asi: Add ASI page-table entry set functions

2019-07-11 Thread Alexandre Chartre
Add wrappers around the page table entry (pgd/p4d/pud/pmd) set functions which check that an existing entry is not being overwritten. Signed-off-by: Alexandre Chartre --- arch/x86/mm/asi_pagetable.c | 124 +++ 1 files changed, 124 insertions(+), 0

[RFC v2 03/26] mm/asi: Handle page fault due to address space isolation

2019-07-11 Thread Alexandre Chartre
When address space isolation is active, kernel page faults can occur because data are not mapped in the ASI page-table. In such a case, log information about the fault and report the page fault as handled. As the page fault handler (like any exception handler) aborts isolation and switch back to

[RFC v2 01/26] mm/x86: Introduce kernel address space isolation

2019-07-11 Thread Alexandre Chartre
Introduce core functions and structures for implementing Address Space Isolation (ASI). Kernel address space isolation provides the ability to run some kernel code with a reduced kernel address space. An address space isolation is defined with a struct asi structure which has its own page-table.

[RFC v2 11/26] mm/asi: Functions to clear ASI page-table entries for a VA range

2019-07-11 Thread Alexandre Chartre
Provide functions to clear page-table entries in the ASI page-table for a specified VA range. Functions also check that the clearing effectively happens in the ASI page-table and there is no crossing of the ASI page-table boundary (through references to the kernel page table), so that the kernel

[RFC v2 09/26] mm/asi: Helper functions to map module into ASI

2019-07-11 Thread Alexandre Chartre
Add helper functions to easily map a module into an ASI. Signed-off-by: Alexandre Chartre --- arch/x86/include/asm/asi.h | 21 + 1 files changed, 21 insertions(+), 0 deletions(-) diff --git a/arch/x86/include/asm/asi.h b/arch/x86/include/asm/asi.h index 19656aa..b5dbc49

[RFC v2 05/26] mm/asi: Add ASI page-table entry offset functions

2019-07-11 Thread Alexandre Chartre
Add wrappers around the p4d/pud/pmd/pte offset kernel functions which ensure that page-table pointers are in the specified ASI page-table. Signed-off-by: Alexandre Chartre --- arch/x86/mm/asi_pagetable.c | 62 +++ 1 files changed, 62 insertions(+), 0

[PATCH -next] pinctrl: aspeed: Make aspeed_pinmux_ips static

2019-07-11 Thread YueHaibing
Fix sparse warning: drivers/pinctrl/aspeed/pinmux-aspeed.c:8:12: warning: symbol 'aspeed_pinmux_ips' was not declared. Should it be static? Reported-by: Hulk Robot Signed-off-by: YueHaibing --- drivers/pinctrl/aspeed/pinmux-aspeed.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff

[PATCH v2] PM: QoS: Get rid of unused flags

2019-07-11 Thread Amit Kucheria
The network_latency and network_throughput flags for PM-QoS have not found much use in drivers or in userspace since they were introduced. Commit 4a733ef1bea7 ("mac80211: remove PM-QoS listener") removed the only user PM_QOS_NETWORK_LATENCY in the kernel a while ago and there don't seem to be any

[PATCH -next] powerpc/powernv/ioda: using kfree_rcu() to simplify the code

2019-07-11 Thread YueHaibing
The callback function of call_rcu() just calls a kfree(), so we can use kfree_rcu() instead of call_rcu() + callback function. Signed-off-by: YueHaibing --- arch/powerpc/platforms/powernv/pci-ioda-tce.c | 10 +- 1 file changed, 1 insertion(+), 9 deletions(-) diff --git

[GIT PULL] vfs: standardize parameter checking for SETFLAGS/FSSETXATTR ioctls

2019-07-11 Thread Darrick J. Wong
Hi Linus, Here's a patch series that sets up common parameter checking functions for the FS_IOC_SETFLAGS and FS_IOC_FSSETXATTR ioctl implementations. The goal here is to reduce the amount of behaviorial variance between the filesystems where those ioctls originated (ext2 and XFS, respectively)

[PATCH -next] scsi: aic94xx: Remove unnecessary null check

2019-07-11 Thread YueHaibing
kmem_cache_destroy() can handle NULL pointer correctly, so there is no need to check NULL pointer before calling kmem_cache_destroy(). Signed-off-by: YueHaibing --- drivers/scsi/aic94xx/aic94xx_init.c | 9 +++-- 1 file changed, 3 insertions(+), 6 deletions(-) diff --git

Re: possible deadlock in process_measurement

2019-07-11 Thread Mimi Zohar
Hi Eric, On Mon, 2019-06-03 at 09:35 -0700, syzbot wrote: > syzbot has found a reproducer for the following crash on: > > HEAD commit:3c09c195 Add linux-next specific files for 20190531 > git tree: linux-next > console output: https://syzkaller.appspot.com/x/log.txt?x=10f61a0ea0 >

[PATCH v2 -next] scsi: qla2xxx: Remove unnecessary null check

2019-07-11 Thread YueHaibing
A null check before dma_pool_destroy is redundant, so remove it. This is detected by coccinelle. Signed-off-by: YueHaibing --- v2: fix commit log --- drivers/scsi/qla2xxx/qla_os.c | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/drivers/scsi/qla2xxx/qla_os.c

Re: [PATCH] dax: Fix missed PMD wakeups

2019-07-11 Thread Matthew Wilcox
On Wed, Jul 10, 2019 at 10:26:47PM +0200, Jan Kara wrote: > On Wed 10-07-19 13:15:39, Matthew Wilcox wrote: > > On Wed, Jul 10, 2019 at 09:02:04PM +0200, Jan Kara wrote: > > > +#define DAX_ENTRY_CONFLICT dax_make_entry(pfn_to_pfn_t(1), DAX_EMPTY) > > > > I was hoping to get rid of DAX_EMPTY ...

RE: [v2,1/2] rtc/fsl: add FTM alarm driver as the wakeup source

2019-07-11 Thread Biwen Li
-Original Message- From: Biwen Li Sent: 2019年7月10日 19:04 To: a.zu...@towertech.it; alexandre.bell...@bootlin.com; Leo Li Cc: linux-...@vger.kernel.org; linux-kernel@vger.kernel.org; Xiaobo Xie ; Jiafei Pan ; Ran Wang ; Biwen Li Subject: [v2,1/2] rtc/fsl: add FTM alarm driver as the

[PATCH -next] scsi: lpfc: Remove unnecessary null check before kfree

2019-07-11 Thread YueHaibing
A null check before a kfree is redundant, so remove it. This is detected by coccinelle. Signed-off-by: YueHaibing --- drivers/scsi/lpfc/lpfc_bsg.c | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) diff --git a/drivers/scsi/lpfc/lpfc_bsg.c b/drivers/scsi/lpfc/lpfc_bsg.c index

Re: [PATCH 3/4] numa: introduce numa group per task group

2019-07-11 Thread Peter Zijlstra
On Wed, Jul 03, 2019 at 11:32:32AM +0800, 王贇 wrote: > By tracing numa page faults, we recognize tasks sharing the same page, > and try pack them together into a single numa group. > > However when two task share lot's of cache pages while not much > anonymous pages, since numa balancing do not

[PATCH -next] scsi: qla2xxx: Remove unnecessary null check

2019-07-11 Thread YueHaibing
A null check before a kfree is dma_pool_destroy, so remove it. This is detected by coccinelle. Signed-off-by: YueHaibing --- drivers/scsi/qla2xxx/qla_os.c | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/drivers/scsi/qla2xxx/qla_os.c b/drivers/scsi/qla2xxx/qla_os.c index

[PATCH] tty: amba-pl011: Make TX optimisation conditional

2019-07-11 Thread Phil Elwell
pl011_tx_chars takes a "from_irq" parameter to reduce the number of register accesses. When from_irq is true the function assumes that the FIFO is half empty and writes up to half a FIFO's worth of bytes without polling the FIFO status register, the reasoning being that the function is being

[PATCH -next] staging: kpc2000: kpc_spi: Remove unnecessary null check before kfree

2019-07-11 Thread YueHaibing
A null check before a kfree is redundant, so remove it. This is detected by coccinelle. Signed-off-by: YueHaibing --- drivers/staging/kpc2000/kpc2000_spi.c | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/drivers/staging/kpc2000/kpc2000_spi.c

Please Let My Situation Touch Your Heart

2019-07-11 Thread Mrs Monica
-- Hello My Dear Calvary Greetings in the name of the ALMIGHTY I am Mrs Monica Gabriele from Switzerland I am married to Late Mr.Gabriele Joseph who is a wealthy business man here in Burkina Faso we were married for many years without a child before he died after a brief illness. Before his

Re: [PATCH v7 0/2] KVM: LAPIC: Implement Exitless Timer

2019-07-11 Thread Paolo Bonzini
On 11/07/19 15:50, Wanpeng Li wrote: > kindly ping, Sorry, I need more time to review this. It's basically the only remaining item for the 5.3 merge window, even though it won't be part of the first pull request to Linus. Paolo >> Dedicated instances are currently disturbed by unnecessary

Re: [PATCH v2] hpet: Fix division by zero in hpet_time_div()

2019-07-11 Thread Arnd Bergmann
On Thu, Jul 11, 2019 at 3:22 PM Kefeng Wang wrote: > > The base value in do_div() called by hpet_time_div() is truncated from > unsigned long to uint32_t, resulting in a divide-by-zero exception. > > UBSAN: Undefined behaviour in ../drivers/char/hpet.c:572:2 > division by zero > CPU: 1 PID: 23682

[PATCH v9 06/11] vfio/pci: Allow to mmap the fault queue

2019-07-11 Thread Eric Auger
The DMA FAULT region contains the fault ring buffer. There is benefit to let the userspace mmap this area. Expose this mmappable area through a sparse mmap entry and implement the mmap operation. Signed-off-by: Eric Auger --- v8 -> v9: - remove unused index local variable in

Re: [PATCH v3 0/3] kernel/notifier.c: avoid duplicate registration

2019-07-11 Thread Vasily Averin
On 7/11/19 4:55 AM, Nixiaoming wrote: > On Wed, July 10, 2019 1:49 PM Vasily Averin wrote: >> On 7/10/19 6:09 AM, Xiaoming Ni wrote: >>> Registering the same notifier to a hook repeatedly can cause the hook >>> list to form a ring or lose other members of the list. >> >> I think is not enough to

Re: Re: [PATCH] media: v4l: Add packed YUV444 24bpp pixel format

2019-07-11 Thread Mirela Rabulea
On Jo, 2019-07-11 at 10:18 +0200, Paul Kocialkowski wrote: > Caution: EXT Email > > Hi, > > On Wed 03 Jul 19, 18:15, Mirela Rabulea wrote: > > > > The added format is V4L2_PIX_FMT_YUV24, this is a packed > > YUV 4:4:4 format, with 8 bits for each component, 24 bits > > per sample. > > > > This

[PATCH -next] RDMA/core: fix -Wunused-const-variable warnings

2019-07-11 Thread Qian Cai
The linux-next commit "linux/dim: Implement RDMA adaptive moderation (DIM)" [1] introduced a few compilation warnings. In file included from ./include/rdma/ib_verbs.h:64, from ./include/linux/mlx5/device.h:37, from ./include/linux/mlx5/driver.h:51,

[PATCH v9 02/11] vfio: VFIO_IOMMU_CACHE_INVALIDATE

2019-07-11 Thread Eric Auger
From: "Liu, Yi L" When the guest "owns" the stage 1 translation structures, the host IOMMU driver has no knowledge of caching structure updates unless the guest invalidation requests are trapped and passed down to the host. This patch adds the VFIO_IOMMU_CACHE_INVALIDATE ioctl with aims at

Re: [PATCH] s390/zcrypt: remove the exporting of ap_query_configuration

2019-07-11 Thread Vasily Gorbik
On Wed, Jul 10, 2019 at 08:44:53AM +0200, Harald Freudenberger wrote: > On 09.07.19 14:25, Denis Efremov wrote: > > The function ap_query_configuration is declared static and marked > > EXPORT_SYMBOL, which is at best an odd combination. Because the > > function is not used outside of the

Re: [PATCH 1/4] numa: introduce per-cgroup numa balancing locality, statistic

2019-07-11 Thread Peter Zijlstra
On Wed, Jul 03, 2019 at 11:28:10AM +0800, 王贇 wrote: > @@ -3562,10 +3563,53 @@ static int memcg_numa_stat_show(struct seq_file *m, > void *v) > seq_putc(m, '\n'); > } > > +#ifdef CONFIG_NUMA_BALANCING > + seq_puts(m, "locality"); > + for (nr = 0; nr < NR_NL_INTERVAL;

Re: [GIT PULL] clone3 for v5.3

2019-07-11 Thread Christian Brauner
On Thu, Jul 11, 2019 at 07:34:28AM +0200, Christian Brauner wrote: > On Wed, Jul 10, 2019 at 10:24:26PM -0700, Linus Torvalds wrote: > > On Mon, Jul 8, 2019 at 8:05 AM Christian Brauner > > wrote: > > > > > > /* Syscall number 435 */ > > > clone3() uses syscall number 435 and is coordinated with

Re: [PATCH 2/4] numa: append per-node execution info in memory.numa_stat

2019-07-11 Thread Peter Zijlstra
On Wed, Jul 03, 2019 at 11:29:15AM +0800, 王贇 wrote: > +++ b/include/linux/memcontrol.h > @@ -190,6 +190,7 @@ enum memcg_numa_locality_interval { > > struct memcg_stat_numa { > u64 locality[NR_NL_INTERVAL]; > + u64 exectime; Maybe call the field jiffies, because that's what it counts.

Re: [PATCH 1/2] dt-bindings: mmc: Document Aspeed SD controller

2019-07-11 Thread Rob Herring
On Wed, Jul 10, 2019 at 6:56 PM Andrew Jeffery wrote: > > > > On Thu, 11 Jul 2019, at 01:20, Rob Herring wrote: > > On Wed, Jul 10, 2019 at 8:16 AM Andrew Jeffery wrote: > > > > > > The ASPEED SD/SDIO/eMMC controller exposes two slots implementing the > > > SDIO Host Specification v2.00, with 1

Re: [PATCH 1/4] numa: introduce per-cgroup numa balancing locality, statistic

2019-07-11 Thread Peter Zijlstra
On Wed, Jul 03, 2019 at 11:28:10AM +0800, 王贇 wrote: > +#ifdef CONFIG_NUMA_BALANCING > + > +enum memcg_numa_locality_interval { > + PERCENT_0_29, > + PERCENT_30_39, > + PERCENT_40_49, > + PERCENT_50_59, > + PERCENT_60_69, > + PERCENT_70_79, > + PERCENT_80_89, > +

Hello dear

2019-07-11 Thread troxellj...@gmail.com
-- Hello dear Friend i am Major. John Wayne Troxell, Write to me back on the below email ( troxellj...@gmail.com )

[PATCH v2 2/2] udf: support 2048-byte spacing of VRS descriptors on 4K media

2019-07-11 Thread Steven J. Magnani
Some UDF creators (specifically Microsoft, but perhaps others) mishandle the ECMA-167 corner case that requires descriptors within a Volume Recognition Sequence to be placed at 4096-byte intervals on media where the block size is 4K. Instead, the descriptors are placed at the 2048- byte interval

[PATCH v2 1/2] udf: refactor VRS descriptor identification

2019-07-11 Thread Steven J. Magnani
Extract code that parses a Volume Recognition Sequence descriptor (component), in preparation for calling it twice against different locations in a block. Change from v1: Fix regression in debug logging of "open disc" condition Signed-off-by: Steven J. Magnani --- a/fs/udf/super.c

Re: [PATCH] rdma/siw: Use proper enumerated type in map_cqe_status

2019-07-11 Thread Jason Gunthorpe
On Thu, Jul 11, 2019 at 01:14:34AM -0700, Nathan Chancellor wrote: > Hi Bernard, > > On Thu, Jul 11, 2019 at 07:44:22AM +, Bernard Metzler wrote: > > Nathan, thanks very much. That's correct. > > Thanks for the confirmation that the fix was correct. > > > I don't know how this could pass

Re: [PATCH 2/3] devfreq: exynos-bus: convert to use dev_pm_opp_set_rate()

2019-07-11 Thread Kamil Konieczny
On 10.07.2019 19:04, Krzysztof Kozlowski wrote: > On Mon, 8 Jul 2019 at 16:12, wrote: >> >> From: Kamil Konieczny >> >> Reuse opp core code for setting bus clock and voltage. As a side >> effect this allow useage of coupled regulators feature (required >> for boards using Exynos5422/5800

Re: [PATCH] dax: Fix missed PMD wakeups

2019-07-11 Thread Matthew Wilcox
On Thu, Jul 11, 2019 at 09:48:59AM +0200, Jan Kara wrote: > On Wed 10-07-19 20:08:55, Matthew Wilcox wrote: > > On Wed, Jul 10, 2019 at 09:02:04PM +0200, Jan Kara wrote: > > > @@ -848,7 +853,7 @@ static int dax_writeback_one(struct xa_state *xas, > > > struct dax_device *dax_dev, > > > if

[PATCH] hpet: Drop unused variable 'm' in hpet_interrupt()

2019-07-11 Thread Kefeng Wang
../drivers/char/hpet.c:159:17: warning: variable ‘m’ set but not used [-Wunused-but-set-variable] unsigned long m, t, mc, base, k; ^ Signed-off-by: Kefeng Wang --- drivers/char/hpet.c | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/drivers/char/hpet.c

Re: [PATCH v6 2/3] KVM: vmx: Emulate MSR IA32_UMWAIT_CONTROL

2019-07-11 Thread Paolo Bonzini
On 21/06/19 07:57, Tao Xu wrote: > + if (guest_cpuid_has(vcpu, X86_FEATURE_WAITPKG)) > + atomic_switch_umwait_control_msr(vmx); > + guest_cpuid_has is slow. Please replace it with a test on secondary_exec_controls_get(vmx). Are you going to look into nested virtualization

[PATCH v2] hpet: Fix division by zero in hpet_time_div()

2019-07-11 Thread Kefeng Wang
The base value in do_div() called by hpet_time_div() is truncated from unsigned long to uint32_t, resulting in a divide-by-zero exception. UBSAN: Undefined behaviour in ../drivers/char/hpet.c:572:2 division by zero CPU: 1 PID: 23682 Comm: syz-executor.3 Not tainted 4.4.184.x86_64+ #4 Hardware

Re: [PATCH] hpet: Fix division by zero in hpet_time_div()

2019-07-11 Thread Kefeng Wang
On 2019/7/11 20:32, Arnd Bergmann wrote: > On Thu, Jul 11, 2019 at 1:20 PM Kefeng Wang > wrote: >> The base value in do_div() called by hpet_time_div() is truncated from >> unsigned long to uint32_t, resulting in a divide-by-zero exception. > > Good catch! > >> --- a/drivers/char/hpet.c >>

Re: [PATCH] rcu: Make jiffies_till_sched_qs writable

2019-07-11 Thread Joel Fernandes
On Thu, Jul 11, 2019 at 05:30:52AM -0700, Paul E. McKenney wrote: > On Wed, Jul 10, 2019 at 10:20:25AM +0900, Byungchul Park wrote: > > On Tue, Jul 09, 2019 at 05:41:02AM -0700, Paul E. McKenney wrote: > > > > Hi Paul, > > > > > > > > IMHO, as much as we want to tune the time for fqs to be

Re: [PATCH] vsyscall: use __iter_div_u64_rem()

2019-07-11 Thread Vincenzo Frascino
Hi Arnd, On 11/07/2019 13:28, Arnd Bergmann wrote: > On Thu, Jul 11, 2019 at 2:14 PM Vincenzo Frascino > wrote: >> >> >> Could you please tell me which version of the compiler did you use? >> >> My building command is: >> >> # make mrproper && make CC=clang HOSTCC=clang i386_defconfig && make

[PATCH 2/2] udf: support 2048-byte spacing of VRS descriptors on 4K media

2019-07-11 Thread Steven J. Magnani
Some UDF creators (specifically Microsoft, but perhaps others) mishandle the ECMA-167 corner case that requires descriptors within a Volume Recognition Sequence to be placed at 4096-byte intervals on media where the block size is 4K. Instead, the descriptors are placed at the 2048- byte interval

[PATCH 1/2] udf: refactor VRS descriptor identification

2019-07-11 Thread Steven J. Magnani
Extract code that parses a Volume Recognition Sequence descriptor (component), in preparation for calling it twice against different locations in a block. Signed-off-by: Steven J. Magnani --- a/fs/udf/super.c2019-07-10 18:57:41.192852154 -0500 +++ b/fs/udf/super.c2019-07-10

[PATCH] clk: renesas: cpg-mssr: Fix reset control race condition

2019-07-11 Thread Geert Uytterhoeven
The module reset code in the Renesas CPG/MSSR driver uses read-modify-write (RMW) operations to write to a Software Reset Register (SRCRn), and simple writes to write to a Software Reset Clearing Register (SRSTCLRn), as was mandated by the R-Car Gen2 and Gen3 Hardware User's Manuals. However,

Fair Pay Project is now: Odén OS

2019-07-11 Thread Ywe Cærlyn
I had the most brilliant idea - Fair Pay Project is now: Odén OS. Us norse always liked a bit faster OS. Still at: https://www.youtube.com/channel/UCR3gmLVjHS5A702wo4bol_Q (Variant spelling is latinization of the runic "Odin, the original meadscald God) Peace.

Re: [RFC PATCH] PM: QoS: Get rid of unused flags

2019-07-11 Thread Amit Kucheria
On Thu, Jul 11, 2019 at 5:45 PM Rafael J. Wysocki wrote: > > On Wed, Jul 10, 2019 at 12:12 PM Amit Kucheria > wrote: > > > > The network_latency and network_throughput flags for PM-QoS have not > > found much use in drivers or in userspace since they were introduced. > > > > Commit 4a733ef1bea7

Re: [PATCH 1/3] opp: core: add regulators enable and disable

2019-07-11 Thread Kamil Konieczny
On 11.07.2019 08:22, Viresh Kumar wrote: > On 08-07-19, 16:11, k.koniec...@partner.samsung.com wrote: >> From: Kamil Konieczny >> >> Add enable regulators to dev_pm_opp_set_regulators() and disable >> regulators to dev_pm_opp_put_regulators(). This prepares for >> converting exynos-bus devfreq

RE: [PATCH] tipc: ensure skb->lock is initialised

2019-07-11 Thread Jon Maloy
> -Original Message- > From: Chris Packham > Sent: 10-Jul-19 16:58 > To: Jon Maloy ; Eric Dumazet > ; ying@windriver.com; > da...@davemloft.net > Cc: net...@vger.kernel.org; tipc-discuss...@lists.sourceforge.net; linux- > ker...@vger.kernel.org > Subject: Re: [PATCH] tipc: ensure

Re: [PATCH V13 12/12] PCI: tegra: Add Tegra194 PCIe support

2019-07-11 Thread Lorenzo Pieralisi
On Wed, Jul 10, 2019 at 11:52:12AM +0530, Vidya Sagar wrote: [...] > diff --git a/drivers/pci/controller/dwc/pcie-tegra194.c > b/drivers/pci/controller/dwc/pcie-tegra194.c > new file mode 100644 > index ..189779edd976 > --- /dev/null > +++

Re: [PATCH v3 3/3] iio: imu: st_lsm6dsx: add i3c basic support for LSM6DSO and LSM6DSR

2019-07-11 Thread Lorenzo Bianconi
> From: Vitor Soares > Date: Thu, Jul 11, 2019 at 11:12:34 > > > Hi Lorenzo, > > > > From: Lorenzo Bianconi > > Date: Wed, Jul 10, 2019 at 20:44:05 > > > > > > For today the st_lsm6dsx driver support LSM6DSO and LSM6DSR sensor only > > > > in > > > > spi and i2c mode. > > > > > > > > The

Re: [PATCH v2 2/6] ARM: tegra: Expose functions required for cpuidle driver

2019-07-11 Thread Jon Hunter
On 11/07/2019 04:13, Dmitry Osipenko wrote: > The upcoming unified CPUIDLE driver will be added to the drivers/cpuidle/ > directory and it will require all these Tegra PM-core functions. > > Signed-off-by: Dmitry Osipenko > --- > arch/arm/mach-tegra/Makefile | 2 +- >

[GIT PULL] ACPI fix for v5.3-rc1

2019-07-11 Thread Rafael J. Wysocki
Hi Linus, Please pull from the tag git://git.kernel.org/pub/scm/linux/kernel/git/rafael/linux-pm.git \ acpi-5.3-rc1-2 with top-most commit 6cf7fb5a95dec9743f4bfd96f9ece580a355cdd1 Revert "ACPICA: Update table load object initialization" on top of commit

Re: [EXT] Re: [PATCH 1/3] spi: spi-nxp-fspi: dynamically alloc AHB memory for FSPI

2019-07-11 Thread Mark Brown
On Wed, Jul 10, 2019 at 03:35:46PM +, Han Xu wrote: > > > dynamically alloc AHB memory for FSPI controller > > Why? This is currently done at probe which is what you'd expect to happen > > here, there's no explanation as to why this change is being made. > Explained in cover letter, It

objtool crashes on clang output (drivers/hwmon/pmbus/adm1275.o)

2019-07-11 Thread Arnd Bergmann
During randconfig testing with clang-9, I came across an object file that makes objtool segfault, see attachment. Let me know if you need more information to debug this. I also get a ton of objtool warnings building random configurations, but Nick mentioned that there is still a bug related to

RE: [PATCH] regulator: da9062: Simplify the code iterating all regulators

2019-07-11 Thread Steve Twiss
On 11 July 2019 12:47, Axel Lin wrote: > To: Steve Twiss; Support Opensource; Liam Girdwood; > linux-kernel@vger.kernel.org > Cc: Axel Lin > Subject: [PATCH] regulator: da9062: Simplify the code iterating all regulators > > It's more straightforward to use for statement here. Thanks Axel,

Re: [PATCH] hpet: Fix division by zero in hpet_time_div()

2019-07-11 Thread Arnd Bergmann
On Thu, Jul 11, 2019 at 1:20 PM Kefeng Wang wrote: > The base value in do_div() called by hpet_time_div() is truncated from > unsigned long to uint32_t, resulting in a divide-by-zero exception. Good catch! > --- a/drivers/char/hpet.c > +++ b/drivers/char/hpet.c > @@ -567,7 +567,7 @@ static

Re: [PATCH] rcu: Make jiffies_till_sched_qs writable

2019-07-11 Thread Paul E. McKenney
On Wed, Jul 10, 2019 at 10:20:25AM +0900, Byungchul Park wrote: > On Tue, Jul 09, 2019 at 05:41:02AM -0700, Paul E. McKenney wrote: > > > Hi Paul, > > > > > > IMHO, as much as we want to tune the time for fqs to be initiated, we > > > can also want to tune the time for the help from scheduler to

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

2019-07-11 Thread Bernard Metzler
-"Jason Gunthorpe" wrote: - >To: "Bernard Metzler" >From: "Jason Gunthorpe" >Date: 07/11/2019 01:53PM >Cc: "Leon Romanovsky" , "Stephen Rothwell" >, "Doug Ledford" , "David >Miller" , "Networking" , >"Linux Next Mailing List" , "Linux Kernel >Mailing List" >Subject: [EXTERNAL] Re: Re:

Re: [PATCH] vsyscall: use __iter_div_u64_rem()

2019-07-11 Thread Arnd Bergmann
On Thu, Jul 11, 2019 at 2:14 PM Vincenzo Frascino wrote: > > > Could you please tell me which version of the compiler did you use? > > My building command is: > > # make mrproper && make CC=clang HOSTCC=clang i386_defconfig && make ARCH=i386 > CC=clang HOSTCC=clang -j56 > See below for the patch

RE: [PATCH v1 9/9] smaples: add vfio-mdev-pci driver

2019-07-11 Thread Liu, Yi L
Hi Alex, > From: kvm-ow...@vger.kernel.org [mailto:kvm-ow...@vger.kernel.org] On Behalf > Of Alex Williamson > Sent: Friday, July 5, 2019 11:55 PM > To: Liu, Yi L > Subject: Re: [PATCH v1 9/9] smaples: add vfio-mdev-pci driver > > On Thu, 4 Jul 2019 09:11:02 + > "Liu, Yi L" wrote: > > >

Re: [v1 0/5] allow to reserve memory for normal kexec kernel

2019-07-11 Thread Pavel Tatashin
On Thu, Jul 11, 2019 at 4:12 AM Vladimir Murzin wrote: > > Hi, > > On 7/10/19 4:56 PM, Pavel Tatashin wrote: > > On Wed, Jul 10, 2019 at 11:19 AM James Morse wrote: > >> > >> Hi Pasha, > >> > >> On 09/07/2019 14:07, Pavel Tatashin wrote: > > Enabling MMU and D-Cache for relocation would

Re: linux-next: build warning after merge of the pm tree

2019-07-11 Thread Rafael J. Wysocki
On Thursday, July 11, 2019 7:46:29 AM CEST wen.yan...@zte.com.cn wrote: > > Hi all, > > > > After merging the pm tree, today's linux-next build (powerpc > > ppc64_defconfig) produced this warning: > > > > drivers/cpufreq/pasemi-cpufreq.c: In function 'pas_cpufreq_cpu_init': > >

Re: [PATCH] phy: Change the configuration interface param to void* to make it more general

2019-07-11 Thread Maxime Ripard
On Fri, Jul 12, 2019 at 02:04:08AM +0800, Zeng Tao wrote: > The phy framework now allows runtime configurations, but only limited > to mipi now, and it's not reasonable to introduce user specified > configurations into the union phy_configure_opts structure. An simple > way is to replace with a

Re: [PATCH v2 5/7] x86/mm, tracing: Fix CR2 corruption

2019-07-11 Thread Peter Zijlstra
On Wed, Jul 10, 2019 at 04:27:09PM -0400, Steven Rostedt wrote: > But isn't it easier for them to just pull the quick fix in, if it is in Steve, I've not yet seen a quick fix that actually fixes all the problems. Your initial one only fixes the IRQ tracing one, but leaves the context tracking

[PATCH] regulator: rk808: Return REGULATOR_MODE_INVALID for invalid mode

2019-07-11 Thread Axel Lin
-EINVAL is not a valid return value for .of_map_mode, return REGULATOR_MODE_INVALID instead. Signed-off-by: Axel Lin --- drivers/regulator/rk808-regulator.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/drivers/regulator/rk808-regulator.c

Re: [bpf-next v3 05/12] selftests/bpf: Allow passing more information to BPF prog test run

2019-07-11 Thread Krzesimir Nowak
On Thu, Jul 11, 2019 at 3:17 AM Andrii Nakryiko wrote: > > On Mon, Jul 8, 2019 at 3:42 PM Krzesimir Nowak wrote: > > > > The test case can now specify a custom length of the data member, > > context data and its length, which will be passed to > > bpf_prog_test_run_xattr. For backward

[PATCH v6 5/5] DO NOT MERGE: ARM: dts: bananapi: Add Camera support

2019-07-11 Thread Maxime Ripard
Signed-off-by: Maxime Ripard --- arch/arm/boot/dts/sun7i-a20-bananapi.dts | 91 +- 1 file changed, 91 insertions(+) diff --git a/arch/arm/boot/dts/sun7i-a20-bananapi.dts b/arch/arm/boot/dts/sun7i-a20-bananapi.dts index 4df921632f7a..cecc4eb26082 100644 ---

[PATCH v6 3/5] media: sunxi: Add A10 CSI driver

2019-07-11 Thread Maxime Ripard
The older CSI drivers have camera capture interface different from the one in the newer ones. This IP is pretty simple. Some variants (one controller out of two instances on some SoCs) have an ISP embedded, but there's no code that make use of it, so we ignored that part for now. Signed-off-by:

Re: [PATCH] IIO: stm32: Remove quadrature related functions from trigger driver

2019-07-11 Thread William Breathitt Gray
On Thu, Jul 11, 2019 at 02:12:27PM +0200, Benjamin Gaignard wrote: > Le jeu. 11 juil. 2019 à 13:51, William Breathitt Gray > a écrit : > > > > On Tue, May 07, 2019 at 11:12:24AM +0200, Benjamin Gaignard wrote: > > > Quadrature feature is now hosted on it own framework. > > > Remove quadrature

[PATCH v6 1/5] dt-bindings: media: Add Allwinner A10 CSI binding

2019-07-11 Thread Maxime Ripard
The Allwinner A10 CMOS Sensor Interface is a camera capture interface also used in later (A10s, A13, A20, R8 and GR8) SoCs. On some SoCs, like the A10, there's multiple instances of that controller, with one instance supporting more channels and having an ISP. Reviewed-by: Rob Herring

Re: [RFC PATCH] PM: QoS: Get rid of unused flags

2019-07-11 Thread Rafael J. Wysocki
On Wed, Jul 10, 2019 at 12:12 PM Amit Kucheria wrote: > > The network_latency and network_throughput flags for PM-QoS have not > found much use in drivers or in userspace since they were introduced. > > Commit 4a733ef1bea7 ("mac80211: remove PM-QoS listener") removed the > only user

[PATCH v6 2/5] media: sunxi: Refactor the Makefile and Kconfig

2019-07-11 Thread Maxime Ripard
The Makefile and Kconfig for the sun6i CSI driver are included in the main Makefile / KConfig file. Since we're going to add a new CSI driver for an older chip, and the Cedrus driver eventually, it makes more sense to put those in our directory. Signed-off-by: Maxime Ripard ---

[PATCH v6 4/5] ARM: dts: sun7i: Add CSI0 controller

2019-07-11 Thread Maxime Ripard
The CSI controller embedded in the A20 can be supported by our new driver. Let's add it to our DT. Signed-off-by: Maxime Ripard --- arch/arm/boot/dts/sun7i-a20.dtsi | 11 +++ 1 file changed, 11 insertions(+) diff --git a/arch/arm/boot/dts/sun7i-a20.dtsi

[PATCH v6 0/5] media: Allwinner A10 CSI support

2019-07-11 Thread Maxime Ripard
Hi, Here is a series introducing the support for the A10 (and SoCs of the same generation) CMOS Sensor Interface (called CSI, not to be confused with MIPI-CSI, which isn't support by that IP). That interface is pretty straightforward, but the driver has a few issues that I wanted to bring up:

Re: [PATCH] vsyscall: use __iter_div_u64_rem()

2019-07-11 Thread Vincenzo Frascino
Hi Arnd, On 10/07/2019 14:01, Arnd Bergmann wrote: > On 32-bit x86 when building with clang-9, the loop gets turned back into > an inefficient division that causes a link error: > > kernel/time/vsyscall.o: In function `update_vsyscall': > vsyscall.c:(.text+0xe3): undefined reference to

Re: [PATCH] IIO: stm32: Remove quadrature related functions from trigger driver

2019-07-11 Thread Benjamin Gaignard
Le jeu. 11 juil. 2019 à 13:51, William Breathitt Gray a écrit : > > On Tue, May 07, 2019 at 11:12:24AM +0200, Benjamin Gaignard wrote: > > Quadrature feature is now hosted on it own framework. > > Remove quadrature related code from stm32-trigger driver to avoid > > code duplication and simplify

Re: [PATCH v2 5/7] x86/mm, tracing: Fix CR2 corruption

2019-07-11 Thread Sasha Levin
On Wed, Jul 10, 2019 at 04:27:09PM -0400, Steven Rostedt wrote: [ added stable folks ] On Sun, 7 Jul 2019 11:17:09 -0700 Linus Torvalds wrote: On Sun, Jul 7, 2019 at 8:11 AM Andy Lutomirski wrote: > > FWIW, I'm leaning toward suggesting that we apply the trivial tracing > fix and backport

Re: [bpf-next v3 04/12] selftests/bpf: Use bpf_prog_test_run_xattr

2019-07-11 Thread Krzesimir Nowak
On Thu, Jul 11, 2019 at 2:03 AM Andrii Nakryiko wrote: > > On Mon, Jul 8, 2019 at 3:43 PM Krzesimir Nowak wrote: > > > > The bpf_prog_test_run_xattr function gives more options to set up a > > test run of a BPF program than the bpf_prog_test_run function. > > > > We will need this extra

<    1   2   3   4   5   6   7   >