[PATCH v2 02/15] drm/vc4: hdmi: Move hdmi reset to bind

2021-01-11 Thread Maxime Ripard
From: Dom Cobley The hdmi reset got moved to a later point in the commit 9045e91a476b ("drm/vc4: hdmi: Add reset callback"). However, the reset now occurs after vc4_hdmi_cec_init and so tramples the setup of registers like HDMI_CEC_CNTRL_1 This only affects pi0-3 as on pi4 the cec registers are

Re: [PATCH v2 0/3] Create 'old' ptes for faultaround mappings on arm64 with hardware access flag

2021-01-11 Thread Kirill A. Shutemov
On Fri, Jan 08, 2021 at 11:34:08AM -0800, Linus Torvalds wrote: > I still dislike how we basically randomly modify the information in > that 'vmf' thing. I wounder if it would be acceptable to pass down to faultaround a copy of vmf, so it mess with it without risking to corrupt the original one?

[PATCH v2 13/15] dt-binding: display: bcm2711-hdmi: Add CEC and hotplug interrupts

2021-01-11 Thread Maxime Ripard
The CEC and hotplug interrupts were missing when that binding was introduced, let's add them in now that we've figured out how it works. Signed-off-by: Maxime Ripard --- .../bindings/display/brcm,bcm2711-hdmi.yaml | 20 ++- 1 file changed, 19 insertions(+), 1 deletion(-) diff

[PATCH v2 04/15] drm/vc4: hdmi: Fix up CEC registers

2021-01-11 Thread Maxime Ripard
From: Dom Cobley The commit 311e305fdb4e ("drm/vc4: hdmi: Implement a register layout abstraction") forgot one CEC register, and made a copy and paste mistake for another one. Fix those mistakes. Fixes: 311e305fdb4e ("drm/vc4: hdmi: Implement a register layout abstraction") Reviewed-by: Dave Ste

[PATCH v2 12/15] drm/vc4: hdmi: Don't register the CEC adapter if there's no interrupts

2021-01-11 Thread Maxime Ripard
We introduced the BCM2711 support to the vc4 HDMI controller with 5.10, but this was lacking any of the interrupts of the CEC controller so we have to deal with the backward compatibility. Do so by simply ignoring the CEC setup if the DT doesn't have the interrupts property. Reviewed-by: Dave Ste

[PATCH v2 06/15] drm/vc4: hdmi: Compute the CEC clock divider from the clock rate

2021-01-11 Thread Maxime Ripard
The CEC clock divider needs to output a frequency of 40kHz from the HSM rate on the BCM2835. The driver used to have a fixed frequency for it, but that changed for the BCM2711 and we now need to compute it dynamically to maintain the proper rate. Fixes: cd4cb49dc5bb ("drm/vc4: hdmi: Adjust HSM clo

[PATCH v2 07/15] drm/vc4: hdmi: Update the CEC clock divider on HSM rate change

2021-01-11 Thread Maxime Ripard
As part of the enable sequence we might change the HSM clock rate if the pixel rate is different than the one we were already dealing with. On the BCM2835 however, the CEC clock derives from the HSM clock so any rate change will need to be reflected in the CEC clock divider to output 40kHz. Fixes

[PATCH v2 14/15] ARM: dts: bcm2711: Add the BSC interrupt controller

2021-01-11 Thread Maxime Ripard
The BSC controllers used for the HDMI DDC have an interrupt controller shared between both instances. Let's add it to avoid polling. Reviewed-by: Florian Fainelli Signed-off-by: Maxime Ripard --- arch/arm/boot/dts/bcm2711.dtsi | 12 1 file changed, 12 insertions(+) diff --git a/ar

Re: [PATCH] thunderbolt: Constify static attribute_group structs

2021-01-11 Thread Mika Westerberg
On Sat, Jan 09, 2021 at 12:09:19AM +0100, Rikard Falkeborn wrote: > The only usage of these is to put their addresses in arrays of pointers > to const attribute_groups. Make them const to allow the compiler to put > them in read-only memory. > > Signed-off-by: Rikard Falkeborn Applied to thunder

[PATCH v2 05/15] drm/vc4: hdmi: Restore cec physical address on reconnect

2021-01-11 Thread Maxime Ripard
From: Dom Cobley Currently we call cec_phys_addr_invalidate on a hotplug deassert. That may be due to a TV power cycling, or an AVR being switched on (and switching edid). This makes CEC unusable since our controller wouldn't have a physical address anymore. Set it back up again on the hotplug

[PATCH v2 08/15] drm/vc4: hdmi: Introduce a CEC clock

2021-01-11 Thread Maxime Ripard
While the BCM2835 had the CEC clock derived from the HSM clock, the BCM2711 has a dedicated parent clock for it. Let's introduce a separate clock for it so that we can handle both cases. Reviewed-by: Dave Stevenson Signed-off-by: Maxime Ripard --- drivers/gpu/drm/vc4/vc4_hdmi.c | 9 -

[PATCH v2 15/15] ARM: dts: bcm2711: Add the CEC interrupt controller

2021-01-11 Thread Maxime Ripard
The CEC and hotplug interrupts go through an interrupt controller shared between the two HDMI controllers. Let's add that interrupt controller and the interrupts for both HDMI controllers Reviewed-by: Florian Fainelli Signed-off-by: Maxime Ripard --- arch/arm/boot/dts/bcm2711.dtsi | 18 +++

[PATCH v2 11/15] drm/vc4: hdmi: Remove cec_available flag

2021-01-11 Thread Maxime Ripard
From: Dom Cobley Now that our HDMI controller supports CEC for the BCM2711, let's remove that flag. Reviewed-by: Dave Stevenson Signed-off-by: Dom Cobley Signed-off-by: Maxime Ripard --- drivers/gpu/drm/vc4/vc4_hdmi.c | 4 drivers/gpu/drm/vc4/vc4_hdmi.h | 3 --- 2 files changed, 7 delet

[PATCH v2 09/15] drm/vc4: hdmi: Split the interrupt handlers

2021-01-11 Thread Maxime Ripard
The BCM2711 has two different interrupt sources to transmit and receive CEC messages, provided through an external interrupt chip shared between the two HDMI interrupt controllers. The rest of the CEC controller is identical though so we need to change a bit the code organisation to share the code

[PATCH v2 10/15] drm/vc4: hdmi: Support BCM2711 CEC interrupt setup

2021-01-11 Thread Maxime Ripard
The HDMI controller found in the BCM2711 has an external interrupt controller for the CEC and hotplug interrupt shared between the two instances. Let's add a variant flag to register a single interrupt handler and deals with the interrupt handler setup, or two interrupt handlers relying on an exte

[PATCH] csky: kprobe: fix unreachable code in simulate_blz32

2021-01-11 Thread menglong8 . dong
From: Menglong Dong The type of 'val' is 'unsigned long' in simulate_blz32, so 'val < 0' can't be true. When 'csky_insn_reg_get_val' fails, 'false' will be returned. We can directly use its return value here. Fixes: 33e53ae1ce41 ("csky: Add kprobes supported") Signed-off-by: Menglong Dong ---

[PATCH -tip V4 0/8] workqueue: break affinity initiatively

2021-01-11 Thread Lai Jiangshan
From: Lai Jiangshan 06249738a41a ("workqueue: Manually break affinity on hotplug") said that scheduler will not force break affinity for us. But workqueue highly depends on the old behavior. Many parts of the codes relies on it, 06249738a41a ("workqueue: Manually break affinity on hotplug") is n

Re: [PATCH v2 2/3] mm: Allow architectures to request 'old' entries when prefaulting

2021-01-11 Thread Kirill A. Shutemov
On Fri, Jan 08, 2021 at 05:15:16PM +, Will Deacon wrote: > diff --git a/mm/filemap.c b/mm/filemap.c > index c1f2dc89b8a7..0fb9d1714797 100644 > --- a/mm/filemap.c > +++ b/mm/filemap.c > @@ -3051,14 +3051,18 @@ vm_fault_t filemap_map_pages(struct vm_fault *vmf, > if (!pte_none(*vmf

[PATCH -tip V4 1/8] workqueue: split cpuhotplug callbacks for unbound workqueue

2021-01-11 Thread Lai Jiangshan
From: Lai Jiangshan Unbound workers are normally non-per-cpu-kthread, but when cpu hotplug, we also need to update the pools of unbound workqueues based on the info that whether the relevant node has CPUs online or not for every workqueue. The code reuses current cpu hotplug callbacks which are

Re: [PATCH v2 1/3] mm: Cleanup faultaround and finish_fault() codepaths

2021-01-11 Thread Kirill A. Shutemov
On Fri, Jan 08, 2021 at 05:15:15PM +, Will Deacon wrote: > From: "Kirill A. Shutemov" > > alloc_set_pte() has two users with different requirements: in the > faultaround code, it called from an atomic context and PTE page table > has to be preallocated. finish_fault() can sleep and allocate p

[PATCH -tip V4 3/8] workqueue: use cpu_possible_mask instead of cpu_active_mask to break affinity

2021-01-11 Thread Lai Jiangshan
From: Lai Jiangshan The scheduler won't break affinity for us any more, and we should "emulate" the same behavior when the scheduler breaks affinity for us. The behavior is "changing the cpumask to cpu_possible_mask". And there might be some other CPUs online later while the worker is still run

[PATCH -tip V4 2/8] workqueue: set pool->attr->cpumask to workers when cpu online

2021-01-11 Thread Lai Jiangshan
From: Lai Jiangshan The commit d945b5e9f0e("workqueue: Fix setting affinity of unbound worker threads") fixed a problem of set_cpus_allowed_ptr() with online&!active cpumasks (more than one CPUs) when restore_unbound_workers_cpumask() in online callback. But now the new online callback for unbou

[PATCH -tip V4 4/8] workqueue: Manually break affinity on pool detachment

2021-01-11 Thread Lai Jiangshan
From: Lai Jiangshan The pool->attrs->cpumask might be a single CPU and it may go down after detachment, and the scheduler won't force to break affinity for us since it is a per-cpu-ktrhead. So we have to do it on our own and unbind this worker which can't be unbound by workqueue_offline_cpu() si

[PATCH -tip V4 6/8] workqueue: use wq_unbound_online_cpumask in restore_unbound_workers_cpumask()

2021-01-11 Thread Lai Jiangshan
From: Lai Jiangshan restore_unbound_workers_cpumask() is called when CPU_ONLINE, where wq_online_cpumask equals to cpu_online_mask. So no fucntionality changed. Acked-by: Tejun Heo Tested-by: Paul E. McKenney Signed-off-by: Lai Jiangshan --- kernel/workqueue.c | 3 ++- 1 file changed, 2 ins

[PATCH -tip V4 7/8] workqueue: Manually break affinity on hotplug for unbound pool

2021-01-11 Thread Lai Jiangshan
From: Lai Jiangshan There is possible that a per-node pool/woker's affinity is a single CPU. It can happen when the workqueue user changes the cpumask of the workqueue or when wq_unbound_cpumask is changed by system adim via /sys/devices/virtual/workqueue/cpumask. And pool->attrs->cpumask is wo

[PATCH -tip V4 8/8] workqueue: Fix affinity of kworkers when attaching into pool

2021-01-11 Thread Lai Jiangshan
From: Lai Jiangshan When worker_attach_to_pool() is called, we should not put the workers to pool->attrs->cpumask when there is or will be no CPU online in it. Otherwise, it may cause BUG_ON(): (quote from Valentin:) Per-CPU kworkers forcefully migrated away by hotplug via workqueue_offline_

Re: [PATCH v2 1/3] mm: Cleanup faultaround and finish_fault() codepaths

2021-01-11 Thread Will Deacon
On Mon, Jan 11, 2021 at 05:26:20PM +0300, Kirill A. Shutemov wrote: > On Fri, Jan 08, 2021 at 05:15:15PM +, Will Deacon wrote: > > diff --git a/include/linux/mm.h b/include/linux/mm.h > > index ecdf8a8cd6ae..801dd99f733c 100644 > > --- a/include/linux/mm.h > > +++ b/include/linux/mm.h > > @@ -5

Re: [PATCH v1 1/2] net: phy: Add 100 base-x mode

2021-01-11 Thread Andrew Lunn
On Mon, Jan 11, 2021 at 02:06:56PM +0100, Bjarni Jonasson wrote: > Sparx-5 supports this mode and it is missing in the PHY core. > > Signed-off-by: Bjarni Jonasson Reviewed-by: Andrew Lunn Andrew

[PATCH] i2c: tegra-bpmp: ignore DMA safe buffer flag

2021-01-11 Thread Mikko Perttunen
From: Muhammed Fazal Ignore I2C_M_DMA_SAFE flag as it does not make a difference for bpmp-i2c, but causes -EINVAL to be returned for valid transactions. Signed-off-by: Muhammed Fazal Cc: sta...@vger.kernel.org # v4.19+ Signed-off-by: Mikko Perttunen --- This fixes failures seen with PMIC probi

Re: [PATCH 00/11] scsi: libsas: Remove in_interrupt() check

2021-01-11 Thread Ahmed S. Darwish
On Mon, Jan 11, 2021 at 01:59:25PM +, John Garry wrote: ... > To me, what you're doing seems fine. > ... > > Just one other thing to mention: > I have a patch to remove the indirection in libsas notifiers: > https://github.com/hisilicon/kernel-dev/commit/87fcd7e113dc05b7933260e7fa4588dc3730cc2a

[PATCH -tip V4 5/8] workqueue: introduce wq_unbound_online_cpumask

2021-01-11 Thread Lai Jiangshan
From: Lai Jiangshan wq_unbound_online_cpumask is the cached result of cpu_online_mask with the going-down cpu cleared before the cpu is cleared from cpu_active_mask. It is used to track the cpu hotplug process so the creation/attachment of unbound workers can know where it is in the process when

Re: [PATCH 0/2] page_count can't be used to decide when wp_page_copy

2021-01-11 Thread Jason Gunthorpe
On Fri, Jan 08, 2021 at 09:50:08PM -0500, Andrea Arcangeli wrote: > For all those that aren't using mmu notifier and that rely solely on > page pins, they still require privilege, except they do through /dev/ > permissions. It is normal that the dev nodes are a+rw so it doesn't really require pri

Re: [PATCH v2] can: mcba_usb: Fix memory leak when cancelling urb

2021-01-11 Thread Bui Quang Minh
On Mon, Jan 11, 2021 at 01:00:31PM +0100, Oliver Neukum wrote: > Am Montag, den 11.01.2021, 10:49 + schrieb Bui Quang Minh: > > In mcba_usb_read_bulk_callback(), when we don't resubmit or fails to > > resubmit the urb, we need to deallocate the transfer buffer that is > > allocated in mcba_usb_

RE: [PATCH] i2c: tegra: Wait for config load atomically while in ISR

2021-01-11 Thread David Laight
From: Mikko Perttunen > Sent: 11 January 2021 13:56 > > Upon a communication error, the interrupt handler can call > tegra_i2c_disable_packet_mode. This causes a sleeping poll to happen > unless the current transaction was marked atomic. Since > tegra_i2c_disable_packet_mode is only called from th

Re: [GIT PULL]: Generic phy fixes for v5.11

2021-01-11 Thread Greg KH
On Sat, Jan 09, 2021 at 02:24:23PM +0530, Vinod Koul wrote: > Hi Greg, > > Please pull to receive couple of driver fixes for generic phy subsystem. > All these are in linux-next > > The following changes since commit 5c8fe583cce542aa0b84adc939ce85293de36e5e: > > Linux 5.11-rc1 (2020-12-27 15:3

Re: [RFC][PATCH 1/5] sched/fair: Fix select_idle_cpu()s cost accounting

2021-01-11 Thread Vincent Guittot
On Fri, 8 Jan 2021 at 17:14, Mel Gorman wrote: > > On Fri, Jan 08, 2021 at 04:10:51PM +0100, Vincent Guittot wrote: > > > > Trying to bias the avg_scan_cost with: loops <<= 2; > > > > will just make avg_scan_cost lost any kind of meaning because it > > > > doesn't reflect the avg cost of scanning

Re: platform/surface: Add Surface Aggregator user-space interface (static analysis issues)

2021-01-11 Thread Maximilian Luz
On 1/11/21 3:11 PM, Colin Ian King wrote: On 11/01/2021 13:55, Maximilian Luz wrote: On 1/11/21 1:12 PM, Colin Ian King wrote: Hi Maximilian, Static analysis of linux-next with Coverity has found several issues with the following commit: commit 178f6ab77e617c984d6520b92e747075a12676ff Author:

Re: [PATCH v2 2/3] mm: Allow architectures to request 'old' entries when prefaulting

2021-01-11 Thread Will Deacon
On Mon, Jan 11, 2021 at 05:25:33PM +0300, Kirill A. Shutemov wrote: > On Fri, Jan 08, 2021 at 05:15:16PM +, Will Deacon wrote: > > diff --git a/mm/filemap.c b/mm/filemap.c > > index c1f2dc89b8a7..0fb9d1714797 100644 > > --- a/mm/filemap.c > > +++ b/mm/filemap.c > > @@ -3051,14 +3051,18 @@ vm_fa

Re: [PATCH] i2c: tegra: Wait for config load atomically while in ISR

2021-01-11 Thread Mikko Perttunen
Agreed that this is possibly not optimal, but this patch simply returns the behavior to what it was before "i2c: tegra: Support atomic transfers", fixing the overt issue. Design fixes can be considered later, in a non-stable patch. Mikko On 1/11/21 4:31 PM, David Laight wrote: From: Mikko Pe

Re: [PATCH 0/2] page_count can't be used to decide when wp_page_copy

2021-01-11 Thread Jason Gunthorpe
On Sat, Jan 09, 2021 at 11:49:58AM +0800, Hillf Danton wrote: > On Fri, 8 Jan 2021 14:19:45 -0400 Jason Gunthorpe wrote: > > > > What I was trying to explain below, is I think we agreed that a page > > under active FOLL_LONGTERM pin *can not* be write protected. > > > > Establishing the FOLL_LONG

Re: [PATCH] mfd: mt6360: Fix MFD cell names and compatibles

2021-01-11 Thread Matthias Brugger
On 11/01/2021 14:05, Gene Chen wrote: > Hi Lee, > > This change exists in [PATCH v7 03/11] mfd: mt6360: Indicate sub-dev > compatible name by using "-". > Does patch v7 also merge together to mfd-next? > once again, please don't top-post. Sorry I didn't saw this patch. Looks good to me, so p

Re: [RFC][PATCH 1/5] sched/fair: Fix select_idle_cpu()s cost accounting

2021-01-11 Thread Vincent Guittot
On Fri, 8 Jan 2021 at 20:45, Peter Zijlstra wrote: > > On Fri, Jan 08, 2021 at 04:10:51PM +0100, Vincent Guittot wrote: > > Also, there is another problem (that I'm investigating) which is that > > this_rq()->avg_idle is stalled when your cpu is busy. Which means that > > this avg_idle can just b

[PATCH/v2] ARM: ixp4xx: Fix typos in Kconfig

2021-01-11 Thread Masanari Iida
This patch fixes some spelling typos in Kconfig. Signed-off-by: Masanari Iida --- arch/arm/mach-ixp4xx/Kconfig | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/arch/arm/mach-ixp4xx/Kconfig b/arch/arm/mach-ixp4xx/Kconfig index f7211b57b1e7..affee2e0ff55 100644 --- a/arch/ar

Re: [PATCH 0/8] FPGA DFL Changes for 5.12

2021-01-11 Thread Tom Rix
On 1/10/21 10:57 PM, Greg KH wrote: > On Sun, Jan 10, 2021 at 11:43:54AM -0800, Tom Rix wrote: >> On 1/10/21 9:05 AM, Moritz Fischer wrote: >>> Tom, >>> >>> On Sun, Jan 10, 2021 at 07:46:29AM -0800, Tom Rix wrote: On 1/7/21 8:09 AM, Tom Rix wrote: > On 1/6/21 8:37 PM, Moritz Fischer wrot

Re: [PATCH 01/13] KVM: SVM: Free sev_asid_bitmap during init if SEV setup fails

2021-01-11 Thread Tom Lendacky
On 1/8/21 6:47 PM, Sean Christopherson wrote: Free sev_asid_bitmap if the reclaim bitmap allocation fails, othwerise it will be leaked as sev_hardware_teardown() frees the bitmaps if and only if SEV is fully enabled (which obviously isn't the case if SEV setup fails). The svm_sev_enabled() func

Re: [PATCH v5 1/4] sgl_alloc_order: remove 4 GiB limit, sgl_free() warning

2021-01-11 Thread Jason Gunthorpe
On Sat, Jan 09, 2021 at 05:58:50PM -0500, Douglas Gilbert wrote: > On 2021-01-07 12:44 p.m., Jason Gunthorpe wrote: > > On Mon, Dec 28, 2020 at 06:49:52PM -0500, Douglas Gilbert wrote: > > > diff --git a/lib/scatterlist.c b/lib/scatterlist.c > > > index a59778946404..4986545beef9 100644 > > > +++ b

Re: lockdep splat in v5.11-rc1 involving console_sem and rq locks

2021-01-11 Thread Peter Zijlstra
On Tue, Jan 05, 2021 at 02:01:15PM -0800, Paul E. McKenney wrote: > Hello! > > The RUDE01 rcutorture scenario (and less often, the TASKS01 scenario) Is: tools/testing/selftests/rcutorture/bin/kvm.sh --duration 10 --configs RUDE01 --allcpus the right incantation?

Re: [PATCH v2 1/3] regulator: mt6360: Add OF match table

2021-01-11 Thread Matthias Brugger
On 11/01/2021 03:18, gene_chen(陳俊宇) wrote: > [ Internal Use - External ] > > Hi Matthias, > > I discussed OF match table with Mark in previous mail in our PATCH v3, > MFD should just instantiate the platform device. > >> Mark Brown 於 2020年8月20日 週四 下午7:45寫道: > >>> This device only exists in

Re: 5.11-rc device reordering breaks ThinkPad rmi4 suspend

2021-01-11 Thread Rafael J. Wysocki
On Mon, Jan 11, 2021 at 2:43 PM Thierry Reding wrote: > > On Sun, Jan 10, 2021 at 08:44:13PM -0800, Hugh Dickins wrote: > > Hi Rafael, > > > > Synaptics RMI4 SMBus touchpad on ThinkPad X1 Carbon (5th generation) > > fails to suspend when running 5.11-rc kernels: bisected to > > 5b6164d3465f ("driv

Re: [RFC v2] nvfs: a filesystem for persistent memory

2021-01-11 Thread Al Viro
On Mon, Jan 11, 2021 at 11:57:08AM +, David Laight wrote: > > > > size = copy_to_iter(to, ptr, size); > > > > if (unlikely(!size)) { > > > > r = -EFAULT; > > > > goto ret_r; > > > > } > > > > > > > >

[PATCH] usb: cdnsp: fixes undefined reference to cdns_remove

2021-01-11 Thread Pawel Laszczak
Patch fixes the following errors: ld: drivers/usb/cdns3/cdnsp-pci.o: in function `cdnsp_pci_remove': cdnsp-pci.c:(.text+0x80): undefined reference to `cdns_remove' ld: drivers/usb/cdns3/cdnsp-pci.o: in function `cdnsp_pci_probe': cdnsp-pci.c:(.text+0x34c): undefined reference to `cdns_init' Issue

Re: platform/surface: Add Surface Aggregator user-space interface (static analysis issues)

2021-01-11 Thread Colin Ian King
On 11/01/2021 14:37, Maximilian Luz wrote: > On 1/11/21 3:11 PM, Colin Ian King wrote: >> On 11/01/2021 13:55, Maximilian Luz wrote: >>> On 1/11/21 1:12 PM, Colin Ian King wrote: Hi Maximilian, Static analysis of linux-next with Coverity has found several issues with the followi

Re: [PATCH 1/3 v2] sched/fair: skip idle cfs_rq

2021-01-11 Thread Mel Gorman
On Thu, Jan 07, 2021 at 11:33:23AM +0100, Vincent Guittot wrote: > Don't waste time checking whether an idle cfs_rq could be the busiest > queue. Furthermore, this can end up selecting a cfs_rq with a high load > but being idle in case of migrate_load. > > Signed-off-by: Vincent Guittot > Reviewe

Re: Old platforms: bring out your dead

2021-01-11 Thread Alexander Shiyan
On Fri, 8 Jan 2021 23:55:06 +0100 Arnd Bergmann wrote: Hello. ... > Then there are ARM platforms that are old but have still seen some work > in the past years. If I hear nothing, these will all stay, but if maintainers > may want to drop them anyway, I can help with that: > > * clps711x -- pre

[PATCH][next] platform/surface: fix potential integer overflow on shift of a int

2021-01-11 Thread Colin King
From: Colin Ian King The left shift of int 32 bit integer constant 1 is evaluated using 32 bit arithmetic and then passed as a 64 bit function argument. In the case where func is 32 or more this can lead to an oveflow. Avoid this by shifting using the BIT_ULL macro instead. Addresses-Coverity:

Re: [PATCH v2 2/3] mm: Allow architectures to request 'old' entries when prefaulting

2021-01-11 Thread Kirill A. Shutemov
On Mon, Jan 11, 2021 at 02:37:42PM +, Will Deacon wrote: > On Mon, Jan 11, 2021 at 05:25:33PM +0300, Kirill A. Shutemov wrote: > > On Fri, Jan 08, 2021 at 05:15:16PM +, Will Deacon wrote: > > > diff --git a/mm/filemap.c b/mm/filemap.c > > > index c1f2dc89b8a7..0fb9d1714797 100644 > > > ---

Re: [RFC PATCH v2 15/26] of/fdt: Introduce early_init_dt_add_memory_hyp()

2021-01-11 Thread Rob Herring
On Fri, Jan 8, 2021 at 6:16 AM Quentin Perret wrote: > > Introduce early_init_dt_add_memory_hyp() to allow KVM to conserve a copy > of the memory regions parsed from DT. This will be needed in the context > of the protected nVHE feature of KVM/arm64 where the code running at EL2 > will be cleanly

Re: [PATCH] block/rnbd-clt: improve find_or_create_sess() return check

2021-01-11 Thread Tom Rix
On 1/10/21 9:14 PM, Nathan Chancellor wrote: > On Sun, Jan 10, 2021 at 01:57:26PM -0800, t...@redhat.com wrote: >> From: Tom Rix >> >> clang static analysis reports this problem >> >> rnbd-clt.c:1212:11: warning: Branch condition evaluates to a >> garbage value >> else if (!first) >>

Re: [RFC][PATCH 1/5] sched/fair: Fix select_idle_cpu()s cost accounting

2021-01-11 Thread Vincent Guittot
On Fri, 8 Jan 2021 at 20:49, Peter Zijlstra wrote: > > On Fri, Jan 08, 2021 at 04:10:51PM +0100, Vincent Guittot wrote: > > Another thing that worries me, is that we use the avg_idle of the > > local cpu, which is obviously not idle otherwise it would have been > > selected, to decide how much tim

[PATCH v2 4/5] iommu: Introduce map_sg() as an IOMMU op for IOMMU drivers

2021-01-11 Thread Isaac J. Manjarres
Add support for IOMMU drivers to have their own map_sg() callbacks. This completes the path for having iommu_map_sg() invoke an IOMMU driver's map_sg() callback, which can then invoke the io-pgtable map_sg() callback with the entire scatter-gather list, so that it can be processed entirely in the i

[PATCH v2 2/5] iommu/io-pgtable-arm: Hook up map_sg()

2021-01-11 Thread Isaac J. Manjarres
Implement the map_sg io-pgtable op for the ARM LPAE io-pgtable code, so that IOMMU drivers can call it when they need to map a scatter-gather list. Signed-off-by: Isaac J. Manjarres Tested-by: Sai Prakash Ranjan --- drivers/iommu/io-pgtable-arm.c | 86 ++

[PATCH v2 3/5] iommu/io-pgtable-arm-v7s: Hook up map_sg()

2021-01-11 Thread Isaac J. Manjarres
Implement the map_sg io-pgtable op for the ARMv7s io-pgtable code, so that IOMMU drivers can call it when they need to map a scatter-gather list. Signed-off-by: Isaac J. Manjarres Tested-by: Sai Prakash Ranjan --- drivers/iommu/io-pgtable-arm-v7s.c | 90 ++ 1

[PATCH] media: staging/intel-ipu3 : Do not zero reserved fields

2021-01-11 Thread Ricardo Ribalda
Core code already clears reserved fields of struct v4l2_pix_format_mplane, check: 4e1e0eb0e074 ("media: v4l2-ioctl: Zero v4l2_plane_pix_format reserved fields"). Cc: Sakari Ailus Signed-off-by: Ricardo Ribalda --- drivers/staging/media/ipu3/ipu3-v4l2.c | 3 --- 1 file changed, 3 deletions(-) d

[PATCH v2 1/5] iommu/io-pgtable: Introduce map_sg() as a page table op

2021-01-11 Thread Isaac J. Manjarres
While mapping a scatter-gather list, iommu_map_sg() calls into the IOMMU driver through an indirect call, which can call into the io-pgtable code through another indirect call. This sequence of going through the IOMMU core code, the IOMMU driver, and finally the io-pgtable code, occurs for every e

[PATCH 2/9] media: mtk-mdp: Do not zero reserved fields

2021-01-11 Thread Ricardo Ribalda
Core code already clears reserved fields of struct v4l2_pix_format_mplane, check: 4e1e0eb0e074 ("media: v4l2-ioctl: Zero v4l2_plane_pix_format reserved fields"). Cc: Matthias Brugger Signed-off-by: Ricardo Ribalda --- drivers/media/platform/mtk-mdp/mtk_mdp_m2m.c | 3 --- 1 file changed, 3 delet

[PATCH 1/9] media: ipu3-cio2: Do not zero reserved fields

2021-01-11 Thread Ricardo Ribalda
Core code already clears reserved fields of struct v4l2_pix_format_mplane, check: 4e1e0eb0e074 ("media: v4l2-ioctl: Zero v4l2_plane_pix_format reserved fields"). Cc: Sakari Ailus Signed-off-by: Ricardo Ribalda --- drivers/media/pci/intel/ipu3/ipu3-cio2.c | 3 --- 1 file changed, 3 deletions(-)

Re: [PATCH 0/8] FPGA DFL Changes for 5.12

2021-01-11 Thread Greg KH
On Mon, Jan 11, 2021 at 06:40:24AM -0800, Tom Rix wrote: > > On 1/10/21 10:57 PM, Greg KH wrote: > > On Sun, Jan 10, 2021 at 11:43:54AM -0800, Tom Rix wrote: > >> On 1/10/21 9:05 AM, Moritz Fischer wrote: > >>> Tom, > >>> > >>> On Sun, Jan 10, 2021 at 07:46:29AM -0800, Tom Rix wrote: > On 1/7

[PATCH v2 5/5] iommu/arm-smmu: Hook up map_sg()

2021-01-11 Thread Isaac J. Manjarres
Now that everything is in place for iommu_map_sg() to defer mapping a scatter-gather list to the io-pgtable layer, implement the map_sg() callback in the SMMU driver, so that iommu_map_sg() can invoke it with the entire scatter-gather list that will be mapped. Signed-off-by: Isaac J. Manjarres Te

RE: [RFC v2] nvfs: a filesystem for persistent memory

2021-01-11 Thread David Laight
From: Al Viro On Behalf Of Al Viro > Sent: 11 January 2021 14:44 > On Mon, Jan 11, 2021 at 11:57:08AM +, David Laight wrote: > > > > > size = copy_to_iter(to, ptr, size); > > > > > if (unlikely(!size)) { > > > > > r = -EFAULT; > > > > >

[PATCH 3/9] media: mtk-vcodec: Do not zero reserved fields

2021-01-11 Thread Ricardo Ribalda
Core code already clears reserved fields of struct v4l2_pix_format_mplane, check: 4e1e0eb0e074 ("media: v4l2-ioctl: Zero v4l2_plane_pix_format reserved fields"). Cc: Matthias Brugger Signed-off-by: Ricardo Ribalda --- drivers/media/platform/mtk-vcodec/mtk_vcodec_dec.c | 5 - drivers/media/p

[PATCH 6/9] media: sum4i-csi: Do not zero reserved fields

2021-01-11 Thread Ricardo Ribalda
Core code already clears reserved fields of struct v4l2_pix_format_mplane, check: 4e1e0eb0e074 ("media: v4l2-ioctl: Zero v4l2_plane_pix_format reserved fields"). Cc: Maxime Ripard Cc: Chen-Yu Tsai Signed-off-by: Ricardo Ribalda --- drivers/media/platform/sunxi/sun4i-csi/sun4i_v4l2.c | 4

[PATCH 5/9] media: jpu: Do not zero reserved fields

2021-01-11 Thread Ricardo Ribalda
Core code already clears reserved fields of struct v4l2_pix_format_mplane, check: 4e1e0eb0e074 ("media: v4l2-ioctl: Zero v4l2_plane_pix_format reserved fields"). Cc: Mikhail Ulyanov Signed-off-by: Ricardo Ribalda --- drivers/media/platform/rcar_jpu.c | 5 - 1 file changed, 5 deletions(-) d

[PATCH v2 0/5] Optimize iommu_map_sg() performance

2021-01-11 Thread Isaac J. Manjarres
The iommu_map_sg() code currently iterates through the given scatter-gather list, and in the worst case, invokes iommu_map() for each element in the scatter-gather list, which calls into the IOMMU driver through an indirect call. For an IOMMU driver that uses a format supported by the io-pgtable co

[PATCH 7/9] media: ti-vpe: Do not zero reserved fields

2021-01-11 Thread Ricardo Ribalda
Core code already clears reserved fields of struct v4l2_pix_format_mplane, check: 4e1e0eb0e074 ("media: v4l2-ioctl: Zero v4l2_plane_pix_format reserved fields"). Cc: Benoit Parrot Signed-off-by: Ricardo Ribalda --- drivers/media/platform/ti-vpe/vpe.c | 2 -- 1 file changed, 2 deletions(-) diff

[PATCH 8/9] media: vicodec: Do not zero reserved fields

2021-01-11 Thread Ricardo Ribalda
Core code already clears reserved fields of struct v4l2_pix_format_mplane, check: 4e1e0eb0e074 ("media: v4l2-ioctl: Zero v4l2_plane_pix_format reserved fields"). Cc: Hans Verkuil Signed-off-by: Ricardo Ribalda --- drivers/media/test-drivers/vicodec/vicodec-core.c | 5 - 1 file changed, 5 de

Re: [PATCH] thermal/core: Make cooling device state change private

2021-01-11 Thread Guenter Roeck
On 1/11/21 6:13 AM, Daniel Lezcano wrote: > The change of the cooling device state should be used by the governor > or at least by the core code, not by the drivers themselves. > > Remove the API usage and move the function declaration to the internal > headers. > > Signed-off-by: Daniel Lezcano

[PATCH 4/9] media: fdp1: Do not zero reserved fields

2021-01-11 Thread Ricardo Ribalda
Core code already clears reserved fields of struct v4l2_pix_format_mplane, check: 4e1e0eb0e074 ("media: v4l2-ioctl: Zero v4l2_plane_pix_format reserved fields"). Cc: linux-renesas-...@vger.kernel.org Signed-off-by: Ricardo Ribalda --- drivers/media/platform/rcar_fdp1.c | 4 1 file changed,

Re: Old platforms: bring out your dead

2021-01-11 Thread chase rayfield
On Mon, Jan 11, 2021 at 3:09 AM John Paul Adrian Glaubitz wrote: > > I'm not sure I understand the reasoning for doing this. The SPARC architecture > isn't going to see any new hardware developments in the future after Oracle > let go of most of the SPARC developers. So it's not that we need to m

Re: 5.11-rc device reordering breaks ThinkPad rmi4 suspend

2021-01-11 Thread Rafael J. Wysocki
On Mon, Jan 11, 2021 at 2:43 PM Thierry Reding wrote: > > On Sun, Jan 10, 2021 at 08:44:13PM -0800, Hugh Dickins wrote: > > Hi Rafael, > > > > Synaptics RMI4 SMBus touchpad on ThinkPad X1 Carbon (5th generation) > > fails to suspend when running 5.11-rc kernels: bisected to > > 5b6164d3465f ("driv

[PATCH 9/9] media: staging/intel-ipu3 : Do not zero reserved fields

2021-01-11 Thread Ricardo Ribalda
Core code already clears reserved fields of struct v4l2_pix_format_mplane, check: 4e1e0eb0e074 ("media: v4l2-ioctl: Zero v4l2_plane_pix_format reserved fields"). Cc: Sakari Ailus Signed-off-by: Ricardo Ribalda --- drivers/staging/media/ipu3/ipu3-v4l2.c | 3 --- 1 file changed, 3 deletions(-) d

Re: Old platforms: bring out your dead

2021-01-11 Thread Arnd Bergmann
On Mon, Jan 11, 2021 at 3:48 PM Alexander Shiyan wrote: > On Fri, 8 Jan 2021 23:55:06 +0100 Arnd Bergmann wrote: > > Then there are ARM platforms that are old but have still seen some work > > in the past years. If I hear nothing, these will all stay, but if > > maintainers > > may want to drop

Re: [PATCH] Revert "tcp: simplify window probe aborting on USER_TIMEOUT"

2021-01-11 Thread Neal Cardwell
On Fri, Jan 8, 2021 at 11:38 PM Enke Chen wrote: > > From: Enke Chen > > This reverts commit 9721e709fa68ef9b860c322b474cfbd1f8285b0f. > > With the commit 9721e709fa68 ("tcp: simplify window probe aborting > on USER_TIMEOUT"), the TCP session does not terminate with > TCP_USER_TIMEOUT when data r

Re: [PATCH v5 1/2] fpga: dfl: add the userspace I/O device support for DFL devices

2021-01-11 Thread Tom Rix
On 1/10/21 10:16 PM, Xu Yilun wrote: > On Sun, Jan 10, 2021 at 12:11:17PM -0800, Moritz Fischer wrote: >> On Sat, Jan 02, 2021 at 11:13:01AM +0800, Xu Yilun wrote: >>> This patch supports the DFL drivers be written in userspace. This is >>> realized by exposing the userspace I/O device interfaces

Re: [PATCH -tip V3 0/8] workqueue: break affinity initiatively

2021-01-11 Thread Paul E. McKenney
On Mon, Jan 11, 2021 at 12:01:03PM +0100, Peter Zijlstra wrote: > On Mon, Jan 11, 2021 at 11:07:34AM +0100, Thomas Gleixner wrote: > > On Fri, Jan 08 2021 at 12:46, Peter Zijlstra wrote: > > > On Sat, Dec 26, 2020 at 10:51:08AM +0800, Lai Jiangshan wrote: > > >> From: Lai Jiangshan > > >> > > >>

Re: Old platforms: bring out your dead

2021-01-11 Thread Arnd Bergmann
On Mon, Jan 11, 2021 at 3:22 PM Mark Salter wrote: > > On Fri, 2021-01-08 at 23:55 +0100, Arnd Bergmann wrote: > > * c6x: Added in 2011, this has seen very few updates since, but > > Mark still Acks patches when they come. Like most other DSP platforms, > > the model of running Linux on a

Re: [PATCH][next] platform/surface: fix potential integer overflow on shift of a int

2021-01-11 Thread Maximilian Luz
On 1/11/21 3:46 PM, Colin King wrote: From: Colin Ian King The left shift of int 32 bit integer constant 1 is evaluated using 32 bit arithmetic and then passed as a 64 bit function argument. In the case where func is 32 or more this can lead to an oveflow. Avoid this by shifting using the BIT_

Re: Old platforms: bring out your dead

2021-01-11 Thread Gerhard Pircher
Am 10.01.21 um 18:35 schrieb John Paul Adrian Glaubitz: > Hi Arnd! > > (Please let's have this cross-posted for more visibility. I only learned > about this > while reading Phoronix news) Same for me! >> I also looked at non-ARM platforms while preparing for my article. Some of >> these look lik

Я связываюсь с вами из-за покойного доктора Чанга Уоллеса, который скончался из-за (COVID-19)

2021-01-11 Thread Hon. Advocate John Peter Chambers
Я связываюсь с вами из-за покойного доктора Чанга Уоллеса, который скончался из-за (COVID-19) Привет, меня зовут достопочтенный Джон Питер, и я защитник покойного доктора Чанга Уоллеса, который я отправил вам это письмо месяц назад, но я не уверен, что вы его получили, потому что я не слышал от ва

Re: [PATCH] i2c: tegra-bpmp: ignore DMA safe buffer flag

2021-01-11 Thread Ben Dooks
On 11/01/2021 14:27, Mikko Perttunen wrote: From: Muhammed Fazal Ignore I2C_M_DMA_SAFE flag as it does not make a difference for bpmp-i2c, but causes -EINVAL to be returned for valid transactions. Signed-off-by: Muhammed Fazal Cc: sta...@vger.kernel.org # v4.19+ Signed-off-by: Mikko Perttunen

Re: [PATCH v2 2/2] mm: fix initialization of struct page for holes in memory layout

2021-01-11 Thread Qian Cai
On Sun, 2021-01-10 at 17:39 +0200, Mike Rapoport wrote: > On Wed, Jan 06, 2021 at 04:04:21PM -0500, Qian Cai wrote: > > On Wed, 2021-01-06 at 10:05 +0200, Mike Rapoport wrote: > > > I think we trigger PF_POISONED_CHECK() in PageSlab(), then > > > fffe > > > is "accessed" from VM_BUG_ON_

Re: [PATCH v1 3/7] perf cs-etm: Calculate per CPU metadata array size

2021-01-11 Thread Leo Yan
Hi Mike, On Mon, Jan 11, 2021 at 12:09:12PM +, Mike Leach wrote: > Hi Leo, > > I think there is an issue here in that your modification assumes that > all cpus in the system are of the same ETM type. The original routine > allowed for differing ETM types, thus differing cpu ETM field lengths

Re: lockdep splat in v5.11-rc1 involving console_sem and rq locks

2021-01-11 Thread Paul E. McKenney
On Mon, Jan 11, 2021 at 03:42:28PM +0100, Peter Zijlstra wrote: > On Tue, Jan 05, 2021 at 02:01:15PM -0800, Paul E. McKenney wrote: > > Hello! > > > > The RUDE01 rcutorture scenario (and less often, the TASKS01 scenario) > > Is: > > tools/testing/selftests/rcutorture/bin/kvm.sh --duration 10 -

Re: [PATCH 0/5] Optimize iommu_map_sg() performance

2021-01-11 Thread isaacm
On 2021-01-10 23:52, Sai Prakash Ranjan wrote: On 2021-01-11 11:52, Sai Prakash Ranjan wrote: Hi Isaac, I gave this series a go on chromebook and saw these warnings and several device probe failures, logs attached below: WARN corresponds to this code in arm_lpae_map_by_pgsize() if (WA

Re: [PATCH -next] fpga: dfl-pci: rectify ReST formatting

2021-01-11 Thread Tom Rix
ocumentation/fpga/dfl.rst. Can you explain how to reproduce this problem ? Tom > > Signed-off-by: Lukas Bulwahn > --- > applies cleanly on next-20210111 > > Moritz, Matthew, please ack. > > Greg, please pick this doc fixup to your fpga -next tree on top of > the comm

Re: [PATCH] i2c: tegra: Wait for config load atomically while in ISR

2021-01-11 Thread Dmitry Osipenko
11.01.2021 16:55, Mikko Perttunen пишет: > Upon a communication error, the interrupt handler can call > tegra_i2c_disable_packet_mode. This causes a sleeping poll to happen > unless the current transaction was marked atomic. Since > tegra_i2c_disable_packet_mode is only called from the interrupt pa

Re: [PATCH 5.10 000/145] 5.10.7-rc1 review

2021-01-11 Thread Guenter Roeck
On 1/11/21 5:00 AM, Greg Kroah-Hartman wrote: > This is the start of the stable review cycle for the 5.10.7 release. > There are 145 patches in this series, all will be posted as a response > to this one. If anyone has any issues with these being applied, please > let me know. > > Responses shoul

[PATCH] ARM: dts: imx7d-flex-concentrator: fix pcf2127 reset

2021-01-11 Thread Bruno Thomsen
RTC pcf2127 device driver has changed default behaviour of the watchdog feature in v5.11-rc1. Now you need to explicitly enable it with a device tree property, "reset-source", when used in the board design. Fixes: 71ac13457d9d ("rtc: pcf2127: only use watchdog when explicitly available") Signed-

[PATCH 0/7] Add and enable GPI DMA users

2021-01-11 Thread Vinod Koul
Hello, This series add the GPI DMA in qcom geni spi and i2c drivers. For this we first need to move GENI_IF_DISABLE_RO and struct geni_wrapper to common headers and then add support for gpi dma in geni driver. Then we add spi and i2c geni driver changes to support this DMA. Lastly, add the GPI d

[PATCH 0/1] ARM: imx: build suspend-imx6.S with arm instruction set

2021-01-11 Thread Max Krummenacher
When the kernel is configured to use the Thumb-2 instruction set "suspend-to-memory" fails to resume while in ARM mode it works as expected. (I used imx_v6_v7_defconfig and deselected ARCH_MULTI_V6 and selected THUMB2_KERNEL) The system prints what is expected when suspending but an event of a wak

[PATCH 3/7] soc: qcom: geni: Add support for gpi dma

2021-01-11 Thread Vinod Koul
GPI DMA is one of the DMA modes supported on geni, this adds support to enable that mode Signed-off-by: Vinod Koul --- drivers/soc/qcom/qcom-geni-se.c | 39 - include/linux/qcom-geni-se.h| 4 2 files changed, 42 insertions(+), 1 deletion(-) diff --git a

<    5   6   7   8   9   10   11   12   13   14   >