[PATCH kernel] powerpc/perf: Fix 32bit compile

2022-04-20 Thread Alexey Kardashevskiy
The "read_bhrb" global symbol is only called under CONFIG_PPC64 of arch/powerpc/perf/core-book3s.c but it is compiled for both 32 and 64 bit anyway (and LLVM fails to link this on 32bit). This fixes it by moving bhrb.o to obj64 targets. Signed-off-by: Alexey Kardashevskiy ---

[PATCH] powerpc/pci: Remove useless null check before call of_node_put()

2022-04-20 Thread Haowen Bai
No need to add null check before call of_node_put(), since the implementation of of_node_put() has done it. Signed-off-by: Haowen Bai --- arch/powerpc/kernel/pci_dn.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/arch/powerpc/kernel/pci_dn.c

[PATCH] ASoC: imx-hdmi: remove useless null check before call of_node_put()

2022-04-20 Thread Haowen Bai
No need to add null check before call of_node_put(), since the implementation of of_node_put() has done it. Signed-off-by: Haowen Bai --- sound/soc/fsl/imx-hdmi.c | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/sound/soc/fsl/imx-hdmi.c b/sound/soc/fsl/imx-hdmi.c index

Re: [PATCH] misc: ocxl: fix possible double free in ocxl_file_register_afu

2022-04-20 Thread Hangyu Hua
On 2022/4/21 06:54, Michael Ellerman wrote: Hangyu Hua writes: info_release() will be called in device_unregister() when info->dev's reference count is 0. So there is no need to call ocxl_afu_put() and kfree() again. Double frees are often exploitable. But it looks to me like this error path

Re: [PATCH] powerpc/time: Always set decrementer in timer_interrupt()

2022-04-20 Thread Nicholas Piggin
Excerpts from Michal Suchánek's message of April 21, 2022 12:28 am: > Hello, > > On Thu, Apr 21, 2022 at 12:16:57AM +1000, Michael Ellerman wrote: >> This is a partial revert of commit 0faf20a1ad16 ("powerpc/64s/interrupt: >> Don't enable MSR[EE] in irq handlers unless perf is in use"). >> >>

Re: [PATCH] powerpc/time: Always set decrementer in timer_interrupt()

2022-04-20 Thread Nicholas Piggin
Excerpts from Michael Ellerman's message of April 21, 2022 12:16 am: > This is a partial revert of commit 0faf20a1ad16 ("powerpc/64s/interrupt: > Don't enable MSR[EE] in irq handlers unless perf is in use"). > > Prior to that commit, we always set the decrementer in > timer_interrupt(), to clear

Re: [PATCH] misc: ocxl: fix possible double free in ocxl_file_register_afu

2022-04-20 Thread Michael Ellerman
Hangyu Hua writes: > info_release() will be called in device_unregister() when info->dev's > reference count is 0. So there is no need to call ocxl_afu_put() and > kfree() again. Double frees are often exploitable. But it looks to me like this error path is not easily reachable by an attacker.

Re: [PATCH v1 1/1] powerpc/83xx/mpc8349emitx: Get rid of of_node assignment

2022-04-20 Thread Michael Ellerman
Linus Walleij writes: > On Wed, Apr 6, 2022 at 3:02 PM Andy Shevchenko > wrote: >> On Mon, Mar 28, 2022 at 03:16:08PM +0200, Linus Walleij wrote: >> > On Wed, Mar 23, 2022 at 6:43 PM Andy Shevchenko >> > wrote: >> > >> > > Let GPIO library to assign of_node from the parent device. >> > > This

Re: [PATCH v2 2/8] mm/debug_vm_pgtable: add tests for __HAVE_ARCH_PTE_SWP_EXCLUSIVE

2022-04-20 Thread Vlastimil Babka
On 3/29/22 18:43, David Hildenbrand wrote: > Let's test that __HAVE_ARCH_PTE_SWP_EXCLUSIVE works as expected. > > Signed-off-by: David Hildenbrand Acked-by: Vlastimil Babka > --- > mm/debug_vm_pgtable.c | 15 +++ > 1 file changed, 15 insertions(+) > > diff --git

Re: [PATCH v2 1/8] mm/swap: remember PG_anon_exclusive via a swp pte bit

2022-04-20 Thread David Hildenbrand
On 20.04.22 19:10, Vlastimil Babka wrote: > On 3/29/22 18:43, David Hildenbrand wrote: >> Currently, we clear PG_anon_exclusive in try_to_unmap() and forget about >> it. We do this, to keep fork() logic on swap entries easy and efficient: >> for example, if we wouldn't clear it when unmapping,

Re: [PATCH v2 1/8] mm/swap: remember PG_anon_exclusive via a swp pte bit

2022-04-20 Thread Vlastimil Babka
On 3/29/22 18:43, David Hildenbrand wrote: > Currently, we clear PG_anon_exclusive in try_to_unmap() and forget about > it. We do this, to keep fork() logic on swap entries easy and efficient: > for example, if we wouldn't clear it when unmapping, we'd have to lookup > the page in the swapcache

Re: [PATCH] powerpc/time: Always set decrementer in timer_interrupt()

2022-04-20 Thread Michal Suchánek
Hello, On Thu, Apr 21, 2022 at 12:16:57AM +1000, Michael Ellerman wrote: > This is a partial revert of commit 0faf20a1ad16 ("powerpc/64s/interrupt: > Don't enable MSR[EE] in irq handlers unless perf is in use"). > > Prior to that commit, we always set the decrementer in > timer_interrupt(), to

[PATCH] powerpc/time: Always set decrementer in timer_interrupt()

2022-04-20 Thread Michael Ellerman
This is a partial revert of commit 0faf20a1ad16 ("powerpc/64s/interrupt: Don't enable MSR[EE] in irq handlers unless perf is in use"). Prior to that commit, we always set the decrementer in timer_interrupt(), to clear the timer interrupt. Otherwise we could end up continuously taking timer

Re: [PATCH 0/3] KVM: x86 SRCU bug fix and SRCU hardening

2022-04-20 Thread Paolo Bonzini
Queued, thanks. Paolo

Re: [PATCH] ASoC: fsl: using pm_runtime_resume_and_get instead of pm_runtime_get_sync

2022-04-20 Thread Pavel Machek
Hi! > From: Minghao Chi > > Using pm_runtime_resume_and_get is more appropriate > for simplifing code > > Reported-by: Zeal Robot > Signed-off-by: Minghao Chi > --- > sound/soc/fsl/fsl_esai.c | 6 ++ > 1 file changed, 2 insertions(+), 4 deletions(-) > > diff --git

Re: [PATCH v2 2/2] fbdev: Warn in hot-unplug workaround for framebuffers without device

2022-04-20 Thread Javier Martinez Canillas
Hello Thomas, Thanks a lot for re-spinning your series. On 4/19/22 12:04, Thomas Zimmermann wrote: > A workaround makes fbdev hot-unplugging work for framebuffers without > device. The only user for this feature was offb. As each OF framebuffer > now has an associated platform device, the

RE: [PATCH RFC 2/8] arm64: stacktrace: Add arch_within_stack_frames

2022-04-20 Thread David Laight
> > Thanks for doing this implementation! One reason usercopy hardening > > didn't persue doing a "full" stacktrace was because it seemed relatively > > expensive. Did you do any usercopy-heavily workload testing to see if > > there was a noticeable performance impact? Look at anything that uses