[PATCH v2 15/16] mm: multigenerational lru: Kconfig

2021-04-13 Thread Yu Zhao
Add configuration options for the multigenerational lru. Signed-off-by: Yu Zhao --- mm/Kconfig | 55 ++ 1 file changed, 55 insertions(+) diff --git a/mm/Kconfig b/mm/Kconfig index 24c045b24b95..0be1c6c90cc0 100644 --- a/mm/Kconfig +++ b/mm/Kco

Re: [PATCH 0/1] Use of /sys/bus/pci/devices/…/index for non-SMBIOS platforms

2021-04-13 Thread Niklas Schnelle
On Tue, 2021-04-13 at 08:39 +0300, Leon Romanovsky wrote: > On Mon, Apr 12, 2021 at 03:59:04PM +0200, Niklas Schnelle wrote: > > Hi Narendra, Hi All, > > > > According to Documentation/ABI/testing/sysfs-bus-pci you are responsible > > for the index device attribute that is used by systemd to creat

[PATCH 1/7] mm: memcontrol: fix page charging in page replacement

2021-04-13 Thread Muchun Song
The pages aren't accounted at the root level, so do not charge the page to the root memcg in page replacement. Although we do not display the value (mem_cgroup_usage) so there shouldn't be any actual problem, but there is a WARN_ON_ONCE in the page_counter_cancel(). Who knows if it will trigger? So

[PATCH 4/7] mm: memcontrol: simplify lruvec_holds_page_lru_lock

2021-04-13 Thread Muchun Song
We already have a helper lruvec_memcg() to get the memcg from lruvec, we do not need to do it ourselves in the lruvec_holds_page_lru_lock(). So use lruvec_memcg() instead. And if mem_cgroup_disabled() returns false, the page_memcg(page) (the LRU pages) cannot be NULL. So remove the odd logic of "me

[PATCH 3/7] mm: memcontrol: remove the pgdata parameter of mem_cgroup_page_lruvec

2021-04-13 Thread Muchun Song
All the callers of mem_cgroup_page_lruvec() just pass page_pgdat(page) as the 2nd parameter to it (except isolate_migratepages_block()). But for isolate_migratepages_block(), the page_pgdat(page) is also equal to the local variable of @pgdat. So mem_cgroup_page_lruvec() do not need the pgdat parame

[PATCH 2/7] mm: memcontrol: bail out early when !mm in get_mem_cgroup_from_mm

2021-04-13 Thread Muchun Song
When mm is NULL, we do not need to hold rcu lock and call css_tryget for the root memcg. And we also do not need to check !mm in every loop of while. So bail out early when !mm. Signed-off-by: Muchun Song Acked-by: Johannes Weiner Reviewed-by: Shakeel Butt --- mm/memcontrol.c | 21 ++--

[PATCH 5/7] mm: memcontrol: simplify the logic of objcg pinning memcg

2021-04-13 Thread Muchun Song
The obj_cgroup_release() and memcg_reparent_objcgs() are serialized by the css_set_lock. We do not need to care about objcg->memcg being released in the process of obj_cgroup_release(). So there is no need to pin memcg before releasing objcg. Remove those pinning logic to simplfy the code. There a

[PATCH 0/7] memcontrol code cleanup and simplification

2021-04-13 Thread Muchun Song
This patch series is part of [1] patch series. Because those patches are code cleanup or simplification. I gather those patches into a separate series to make it easier to review. [1] https://lore.kernel.org/linux-mm/20210409122959.82264-1-songmuc...@bytedance.com/ Muchun Song (7): mm: memcont

[PATCH 6/7] mm: memcontrol: move obj_cgroup_uncharge_pages() out of css_set_lock

2021-04-13 Thread Muchun Song
The css_set_lock is used to guard the list of inherited objcgs. So there is no need to uncharge kernel memory under css_set_lock. Just move it out of the lock. Signed-off-by: Muchun Song --- mm/memcontrol.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/mm/memcontrol.c b/m

[PATCH 7/7] mm: vmscan: remove noinline_for_stack

2021-04-13 Thread Muchun Song
The noinline_for_stack is introduced by commit 666356297ec4 ("vmscan: set up pagevec as late as possible in shrink_inactive_list()"), its purpose is to delay the allocation of pagevec as late as possible to save stack memory. But the commit 2bcf88796381 ("mm: take pagevecs off reclaim stack") repla

Re: Subject: [PATCH v2] staging: media: meson: vdec: declare u32 as static const appropriately

2021-04-13 Thread Greg KH
On Tue, Apr 13, 2021 at 11:57:52AM +0530, Mitali Borkar wrote: > Declared 32 bit unsigned int as static constant inside a function > appropriately. > > Reported-by: kernel test robot > Signed-off-by: Mitali Borkar Why does your Subject: line have "Subject:" twice?

[PATCH v2 13/16] mm: multigenerational lru: page reclaim

2021-04-13 Thread Yu Zhao
With the aging and the eviction in place, we can build the page reclaim in a straightforward manner: 1) In order to reduce the latency, direct reclaim only invokes the aging when both min_seq[2] reaches max_seq-1; otherwise it invokes the eviction. 2) In order to avoid the aging in the dire

[PATCH v2 14/16] mm: multigenerational lru: user interface

2021-04-13 Thread Yu Zhao
Add a sysfs file /sys/kernel/mm/lru_gen/enabled so users can enable and disable the multigenerational lru at runtime. Add a sysfs file /sys/kernel/mm/lru_gen/spread so users can spread pages out across multiple generations. More generations make the background aging more aggressive. Add a debugfs

[PATCH v2 16/16] mm: multigenerational lru: documentation

2021-04-13 Thread Yu Zhao
Add Documentation/vm/multigen_lru.rst. Signed-off-by: Yu Zhao --- Documentation/vm/index.rst| 1 + Documentation/vm/multigen_lru.rst | 192 ++ 2 files changed, 193 insertions(+) create mode 100644 Documentation/vm/multigen_lru.rst diff --git a/Documentatio

Re: [PATCH 0/7] Restructure the rpmsg char and introduce the rpmsg-raw channel

2021-04-13 Thread Arnaud POULIQUEN
Hello Mathieu, On 4/12/21 10:02 PM, Mathieu Poirier wrote: > On Tue, Mar 23, 2021 at 01:27:30PM +0100, Arnaud Pouliquen wrote: >> This series is the second step in the division of the series [1]: >> "Introducing a Generic IOCTL Interface for RPMsg Channel Management". >> >> The purpose of this pa

Re: [PATCH v2 1/2] perf/core: Share an event with multiple cgroups

2021-04-13 Thread kernel test robot
suggest to use '--base' as documented in https://git-scm.com/docs/git-format-patch] url: https://github.com/0day-ci/linux/commits/Namhyung-Kim/perf-core-Sharing-events-with-multiple-cgroups/20210413-124251 base: https://git.kernel.org/pub/scm/linux/kernel/git/t

Re: [RFC/PATCH] powerpc/smp: Add SD_SHARE_PKG_RESOURCES flag to MC sched-domain

2021-04-13 Thread Vincent Guittot
On Mon, 12 Apr 2021 at 17:24, Mel Gorman wrote: > > On Mon, Apr 12, 2021 at 02:21:47PM +0200, Vincent Guittot wrote: > > > > Peter, Valentin, Vincent, Mel, etal > > > > > > > > On architectures where we have multiple levels of cache access latencies > > > > within a DIE, (For example: one within t

Re: [PATCH net-next 1/2] net: phy: marvell-88x2222: check that link is operational

2021-04-13 Thread Ivan Bornyakov
On Tue, Apr 13, 2021 at 01:32:12AM +0200, Marek Behún wrote: > On Mon, 12 Apr 2021 15:16:59 +0300 > Ivan Bornyakov wrote: > > > Some SFP modules uses RX_LOS for link indication. In such cases link > > will be always up, even without cable connected. RX_LOS changes will > > trigger link_up()/link_

[PATCH 01/12] usb: dwc2: Add device clock gating support functions

2021-04-13 Thread Artur Petrosyan
Added device clock gating support functions according programming guide. Moved "bus_suspended" flag to "dwc2_hsotg" struct because we need to set that flag while entering to clock gating in case when the driver is built in peripheral mode. Added function names: dwc2_gadget_enter_clock_gating() dw

Re: [PATCH v2 bpf-next 0/2] xsk: introduce generic almost-zerocopy xmit

2021-04-13 Thread Magnus Karlsson
On Tue, Apr 13, 2021 at 3:49 AM Xuan Zhuo wrote: > > On Mon, 12 Apr 2021 16:13:12 +0200, Magnus Karlsson > wrote: > > On Wed, Mar 31, 2021 at 2:27 PM Alexander Lobakin wrote: > > > > > > This series is based on the exceptional generic zerocopy xmit logics > > > initially introduced by Xuan Zhuo

[PATCH v2 1/3] context_tracking: Split guest_enter/exit_irqoff

2021-04-13 Thread Wanpeng Li
From: Wanpeng Li Split context_tracking part from guest_enter/exit_irqoff, it will be called separately in later patches. Suggested-by: Thomas Gleixner Cc: Thomas Gleixner Cc: Sean Christopherson Cc: Michael Tokarev Signed-off-by: Wanpeng Li --- include/linux/context_tracking.h | 42 +

[PATCH 02/12] usb: dwc2: Add host clock gating support functions

2021-04-13 Thread Artur Petrosyan
Added host clock gating support functions according programming guide. Added function names: dwc2_host_enter_clock_gating() dwc2_host_exit_clock_gating() Signed-off-by: Artur Petrosyan Acked-by: Minas Harutyunyan --- drivers/usb/dwc2/core.h | 5 +++ drivers/usb/dwc2/hcd.c | 86 ++

[PATCH 03/12] usb: dwc2: Allow entering clock gating from USB_SUSPEND interrupt

2021-04-13 Thread Artur Petrosyan
If core doesn't support hibernation or partial power down power saving options, power can still be saved using clock gating on all the clocks. - Added entering clock gating state from USB_SUSPEND interrupt. Signed-off-by: Artur Petrosyan Acked-by: Minas Harutyunyan --- drivers/usb/dwc2/core_

[PATCH 04/12] usb: dwc2: Add exit clock gating from wakeup interrupt

2021-04-13 Thread Artur Petrosyan
Added exit from clock gating mode when wakeup interrupt is detected. To exit from the clock gating in device mode "dwc2_gadget_exit_clock_gating()" function is used with rem_wakeup parameter 0. To exit clock gating in host mode "dwc2_host_exit_clock_gating()" with rem_wakeup parameter 1. Signed-of

[PATCH 05/12] usb: dwc2: Add exit clock gating from session request interrupt

2021-04-13 Thread Artur Petrosyan
Added clock gating exit flow from session request interrupt handler according programming guide. Signed-off-by: Artur Petrosyan --- drivers/usb/dwc2/core_intr.c | 19 +-- 1 file changed, 13 insertions(+), 6 deletions(-) diff --git a/drivers/usb/dwc2/core_intr.c b/drivers/usb/dwc

[PATCH v2 0/3] KVM: Properly account for guest CPU time

2021-04-13 Thread Wanpeng Li
The bugzilla https://bugzilla.kernel.org/show_bug.cgi?id=209831 reported that the guest time remains 0 when running a while true loop in the guest. The commit 87fa7f3e98a131 ("x86/kvm: Move context tracking where it belongs") moves guest_exit_irqoff() close to vmexit breaks the tick-based time acc

[PATCH v2 2/3] context_tracking: Provide separate vtime accounting functions

2021-04-13 Thread Wanpeng Li
From: Wanpeng Li Provide separate vtime accounting functions, because having proper wrappers for that case would be too consistent and less confusing. Suggested-by: Thomas Gleixner Cc: Thomas Gleixner Cc: Sean Christopherson Cc: Michael Tokarev Signed-off-by: Wanpeng Li --- include/linux/

[PATCH 06/12] usb: dwc2: Add exit clock gating when port reset is asserted

2021-04-13 Thread Artur Petrosyan
Adds clock gating exit flow when set port feature reset is received in suspended state. Signed-off-by: Artur Petrosyan --- drivers/usb/dwc2/hcd.c | 4 1 file changed, 4 insertions(+) diff --git a/drivers/usb/dwc2/hcd.c b/drivers/usb/dwc2/hcd.c index f1c24c15d185..27f030d5de54 100644 --- a/

[PATCH v2 3/3] x86/kvm: Fix vtime accounting

2021-04-13 Thread Wanpeng Li
From: Wanpeng Li The bugzilla https://bugzilla.kernel.org/show_bug.cgi?id=209831 reported that the guest time remains 0 when running a while true loop in the guest. The commit 87fa7f3e98a131 ("x86/kvm: Move context tracking where it belongs") moves guest_exit_irqoff() close to vmexit breaks the

[PATCH 08/12] usb: dwc2: Update exit clock gating when port is resumed

2021-04-13 Thread Artur Petrosyan
Updates the implementation of exiting clock gating mode when core receives port resume. Instead of setting the required bit fields of the registers inline, called the "dwc2_host_exit_clock_gating()" function. Signed-off-by: Artur Petrosyan --- drivers/usb/dwc2/hcd.c | 29

[PATCH 09/12] usb: dwc2: Allow exit clock gating in urb enqueue

2021-04-13 Thread Artur Petrosyan
When core is in clock gating state and an external hub is connected, upper layer sends URB enqueue request, which results in port reset issue. Added exit from clock gating state to avoid port reset issue and process upper layer request properly. Signed-off-by: Artur Petrosyan --- drivers/usb/dw

[PATCH 10/12] usb: dwc2: Add clock gating entering flow by system suspend

2021-04-13 Thread Artur Petrosyan
If not hibernation nor partial power down are supported, clock gating is used to save power. Adds a new flow of entering clock gating when PC is suspended. Signed-off-by: Artur Petrosyan --- drivers/usb/dwc2/hcd.c | 9 + 1 file changed, 9 insertions(+) diff --git a/drivers/usb/dwc2/hcd

[PATCH 11/12] usb: dwc2: Add clock gating exiting flow by system resume

2021-04-13 Thread Artur Petrosyan
If not hibernation nor partial power down are supported, port resume is done using the clock gating programming flow. Adds a new flow of exiting clock gating when PC is resumed. Signed-off-by: Artur Petrosyan --- drivers/usb/dwc2/hcd.c | 22 ++ 1 file changed, 22 insertions(

[PATCH 07/12] usb: dwc2: Update enter clock gating when port is suspended

2021-04-13 Thread Artur Petrosyan
Updates the implementation of entering clock gating mode when core receives port suspend. Instead of setting the required bit fields of the registers inline, called the "dwc2_host_enter_clock_gating()" function. Signed-off-by: Artur Petrosyan --- drivers/usb/dwc2/hcd.c | 19 ---

[PATCH 12/12] usb: dwc2: Add exit clock gating before removing driver

2021-04-13 Thread Artur Petrosyan
When dwc2 core is in clock gating mode loading driver again causes driver fail. Because in that mode registers are not accessible. Added a flow of exiting clock gating mode to avoid the driver reload failure. Signed-off-by: Artur Petrosyan --- drivers/usb/dwc2/platform.c | 9 + 1 file c

Re: [PATCH net-next 1/2] net: phy: marvell-88x2222: check that link is operational

2021-04-13 Thread Ivan Bornyakov
On Tue, Apr 13, 2021 at 01:40:32AM +0200, Andrew Lunn wrote: > On Mon, Apr 12, 2021 at 03:16:59PM +0300, Ivan Bornyakov wrote: > > Some SFP modules uses RX_LOS for link indication. In such cases link > > will be always up, even without cable connected. RX_LOS changes will > > trigger link_up()/link

Re:Re: [PATCH] kernel/module: Use BUG_ON instead of if condition followed by BUG.

2021-04-13 Thread 周传高
>+++ zhouchuangao [30/03/21 05:07 -0700]: >>It can be optimized at compile time. >> >>Signed-off-by: zhouchuangao > >Hi, > >Could you please provide a more descriptive changelog? I.e., Is this >a fix for a cocinelle warning? What are the optimization(s)? > >Thanks, > First, This patch comes from

[PATCH] media: solo6x10: remove useless function

2021-04-13 Thread Jiapeng Chong
Fix the following clang warning: drivers/media/pci/solo6x10/solo6x10-v4l2-enc.c:394:19: warning: unused function 'vop_interlaced' [-Wunused-function]. Reported-by: Abaci Robot Signed-off-by: Jiapeng Chong --- drivers/media/pci/solo6x10/solo6x10-v4l2-enc.c | 5 - 1 file changed, 5 deletions

Re: [PATCH 0/3] scsi: mptfusion: Clear the warnings indicating that the variable is not used

2021-04-13 Thread Leizhen (ThunderTown)
On 2021/4/13 13:07, Martin K. Petersen wrote: > > Zhen, > >> Zhen Lei (3): >> scsi: mptfusion: Remove unused local variable 'time_count' >> scsi: mptfusion: Remove unused local variable 'port' >> scsi: mptfusion: Fix error return code of mptctl_hp_hostinfo() > > I applied patches 1+2. I

Re: Subject: [PATCH v2] staging: media: meson: vdec: declare u32 as static const appropriately

2021-04-13 Thread Hans Verkuil
On 13/04/2021 08:27, Mitali Borkar wrote: > Declared 32 bit unsigned int as static constant inside a function > appropriately. > > Reported-by: kernel test robot > Signed-off-by: Mitali Borkar > --- > > Changes from v1:- Rectified the mistake by declaring u32 as static const > properly. > > d

Re: [PATCH v6] platform/x86: intel_pmc_core: export platform global reset bits via etr3 sysfs file

2021-04-13 Thread Hans de Goede
Hi, On 4/11/21 4:15 PM, Tomas Winkler wrote: > From: Tamar Mashiah > > During PCH (platform/board) manufacturing process a global platform > reset has to be induced in order for the configuration changes take > the effect upon following platform reset. This is an internal platform > state and is

Re: [PATCH 2/4] dt-bindings: Add bindings for aspeed pwm

2021-04-13 Thread Billy Tsai
Hi Rob, Best Regards, Billy Tsai On 2021/4/12, 9:20 PM,Rob Herringwrote: On Mon, 12 Apr 2021 17:54:55 +0800, Billy Tsai wrote: >> This patch adds device bindings for aspeed pwm device which should be >> the sub-node of aspeed,ast2600-pwm-tach. >> >> Signed-off-by: Billy Tsai

Re: [PATCH 1/2] dt-binding: bcm43xx-fmac: add optional brcm,ccode-map

2021-04-13 Thread Shawn Guo
On Mon, Apr 12, 2021 at 02:54:46PM +0300, Kalle Valo wrote: > Shawn Guo writes: > > > On Sun, Apr 11, 2021 at 10:57:54AM +0300, Kalle Valo wrote: > >> Shawn Guo writes: > >> > >> > Add optional brcm,ccode-map property to support translation from ISO3166 > >> > country code to brcmfmac firmware

Re: [PATCH][next] vdpa/mlx5: Fix resource leak of mgtdev due to incorrect kfree

2021-04-13 Thread Stefano Garzarella
On Mon, Apr 12, 2021 at 05:28:04PM +0100, Colin King wrote: From: Colin Ian King Static analysis is reporting a memory leak on mgtdev, it appears that the wrong object is being kfree'd. Fix this by kfree'ing mgtdev rather than mdev. Addresses-Coverity: ("Resource leak") Fixes: c8a2d4c73e70 ("v

Re: [BUG] VAAPI encoder cause kernel panic if encoded video in 4K

2021-04-13 Thread Christian König
Hi Mikhail, the crash is a known issue and should be fixed by: commit f63da9ae7584280582cbc834b20cc18bfb203b14 Author: Philip Yang Date:   Thu Apr 1 00:22:23 2021 -0400     drm/amdgpu: reserve fence slot to update page table But that an userspace application can cause a page fault is perfectl

Re: [PATCH 3/5] ASoC: rt5682: clock driver must use the clock provider API

2021-04-13 Thread Jerome Brunet
On Mon 12 Apr 2021 at 22:27, Stephen Boyd wrote: > Quoting Jerome Brunet (2021-04-10 04:13:54) >> Clock drivers ops should not the clk API but the clock provider (clk_hw) >> instead. >> >> Signed-off-by: Jerome Brunet >> --- >> sound/soc/codecs/rt5682.c | 6 +++--- >> 1 file changed, 3 inser

Re: [PATCH 0/1] Use of /sys/bus/pci/devices/…/index for non-SMBIOS platforms

2021-04-13 Thread Leon Romanovsky
On Tue, Apr 13, 2021 at 08:57:19AM +0200, Niklas Schnelle wrote: > On Tue, 2021-04-13 at 08:39 +0300, Leon Romanovsky wrote: > > On Mon, Apr 12, 2021 at 03:59:04PM +0200, Niklas Schnelle wrote: > > > Hi Narendra, Hi All, > > > > > > According to Documentation/ABI/testing/sysfs-bus-pci you are resp

Re: [PATCH V4 2/2] net: ethernet: ravb: Enable optional refclk

2021-04-13 Thread Geert Uytterhoeven
Hi Adam, On Mon, Apr 12, 2021 at 3:27 PM Adam Ford wrote: > For devices that use a programmable clock for the AVB reference clock, > the driver may need to enable them. Add code to find the optional clock > and enable it when available. > > Signed-off-by: Adam Ford > Reviewed-by: Andrew Lunn >

Re: [PATCH 5.4 v3 1/1] iommu/vt-d: Fix agaw for a supported 48 bit guest address width

2021-04-13 Thread Greg KH
On Mon, Apr 12, 2021 at 01:27:35PM -0700, Saeed Mirzamohammadi wrote: > The IOMMU driver calculates the guest addressability for a DMA request > based on the value of the mgaw reported from the IOMMU. However, this > is a fused value and as mentioned in the spec, the guest width > should be calcu

Re: [PATCH v7 3/3] bio: add limit_bio_size sysfs

2021-04-13 Thread Greg KH
On Tue, Apr 13, 2021 at 11:55:02AM +0900, Changheun Lee wrote: > Add limit_bio_size block sysfs node to limit bio size. > Queue flag QUEUE_FLAG_LIMIT_BIO_SIZE will be set if limit_bio_size is set. > And bio max size will be limited by queue max sectors via > QUEUE_FLAG_LIMIT_BIO_SIZE set. > > Sign

[PATCH v2 02/12] usb: dwc2: Add host clock gating support functions

2021-04-13 Thread Artur Petrosyan
Added host clock gating support functions according programming guide. Added function names: dwc2_host_enter_clock_gating() dwc2_host_exit_clock_gating() Signed-off-by: Artur Petrosyan Acked-by: Minas Harutyunyan --- drivers/usb/dwc2/core.h | 5 +++ drivers/usb/dwc2/hcd.c | 86 ++

[PATCH v2 01/12] usb: dwc2: Add device clock gating support functions

2021-04-13 Thread Artur Petrosyan
Added device clock gating support functions according programming guide. Moved "bus_suspended" flag to "dwc2_hsotg" struct because we need to set that flag while entering to clock gating in case when the driver is built in peripheral mode. Added function names: dwc2_gadget_enter_clock_gating() dw

[PATCH v2 04/12] usb: dwc2: Add exit clock gating from wakeup interrupt

2021-04-13 Thread Artur Petrosyan
Added exit from clock gating mode when wakeup interrupt is detected. To exit from the clock gating in device mode "dwc2_gadget_exit_clock_gating()" function is used with rem_wakeup parameter 0. To exit clock gating in host mode "dwc2_host_exit_clock_gating()" with rem_wakeup parameter 1. Signed-of

[PATCH v2 03/12] usb: dwc2: Allow entering clock gating from USB_SUSPEND interrupt

2021-04-13 Thread Artur Petrosyan
If core doesn't support hibernation or partial power down power saving options, power can still be saved using clock gating on all the clocks. - Added entering clock gating state from USB_SUSPEND interrupt. Signed-off-by: Artur Petrosyan Acked-by: Minas Harutyunyan --- drivers/usb/dwc2/core_

[PATCH v2 06/12] usb: dwc2: Add exit clock gating when port reset is asserted

2021-04-13 Thread Artur Petrosyan
Adds clock gating exit flow when set port feature reset is received in suspended state. Signed-off-by: Artur Petrosyan --- Changes in v2: - None drivers/usb/dwc2/hcd.c | 4 1 file changed, 4 insertions(+) diff --git a/drivers/usb/dwc2/hcd.c b/drivers/usb/dwc2/hcd.c index f1c24c15d185..2

[PATCH v2 07/12] usb: dwc2: Update enter clock gating when port is suspended

2021-04-13 Thread Artur Petrosyan
Updates the implementation of entering clock gating mode when core receives port suspend. Instead of setting the required bit fields of the registers inline, called the "dwc2_host_enter_clock_gating()" function. Signed-off-by: Artur Petrosyan --- Changes in v2: - None drivers/usb/dwc2/hcd.c |

[PATCH v2 05/12] usb: dwc2: Add exit clock gating from session request interrupt

2021-04-13 Thread Artur Petrosyan
Added clock gating exit flow from session request interrupt handler according programming guide. Signed-off-by: Artur Petrosyan --- Changes in v2: - None drivers/usb/dwc2/core_intr.c | 19 +-- 1 file changed, 13 insertions(+), 6 deletions(-) diff --git a/drivers/usb/dwc2/core

[PATCH v2 08/12] usb: dwc2: Update exit clock gating when port is resumed

2021-04-13 Thread Artur Petrosyan
Updates the implementation of exiting clock gating mode when core receives port resume. Instead of setting the required bit fields of the registers inline, called the "dwc2_host_exit_clock_gating()" function. Signed-off-by: Artur Petrosyan --- Changes in v2: - None drivers/usb/dwc2/hcd.c | 29

[PATCH 0/3] rseq: minor optimizations

2021-04-13 Thread Eric Dumazet
From: Eric Dumazet rseq is a heavy user of copy to/from user data in fast paths. This series tries to reduce the cost. Eric Dumazet (3): rseq: optimize rseq_update_cpu_id() rseq: remove redundant access_ok() rseq: optimise for 64bit arches kernel/rseq.c | 26 -- 1

[PATCH 1/3] rseq: optimize rseq_update_cpu_id()

2021-04-13 Thread Eric Dumazet
From: Eric Dumazet Two put_user() in rseq_update_cpu_id() are replaced by a pair of unsafe_put_user() with appropriate surroundings. This removes one stac/clac pair on x86 in fast path. Signed-off-by: Eric Dumazet Cc: Mathieu Desnoyers Cc: Peter Zijlstra Cc: "Paul E. McKenney" Cc: Boqun Fen

Re: [PATCH v2 1/3] context_tracking: Split guest_enter/exit_irqoff

2021-04-13 Thread Christian Borntraeger
On 13.04.21 09:16, Wanpeng Li wrote: [...] @@ -145,6 +155,13 @@ static __always_inline void guest_exit_irqoff(void) } #else +static __always_inline void context_guest_enter_irqoff(void) +{ + instrumentation_begin(); + rcu_virt_note_context_switch(smp_processor_id()); +

[PATCH v2 09/12] usb: dwc2: Allow exit clock gating in urb enqueue

2021-04-13 Thread Artur Petrosyan
When core is in clock gating state and an external hub is connected, upper layer sends URB enqueue request, which results in port reset issue. Added exit from clock gating state to avoid port reset issue and process upper layer request properly. Signed-off-by: Artur Petrosyan --- Changes in v2:

[PATCH v2 11/12] usb: dwc2: Add clock gating exiting flow by system resume

2021-04-13 Thread Artur Petrosyan
If not hibernation nor partial power down are supported, port resume is done using the clock gating programming flow. Adds a new flow of exiting clock gating when PC is resumed. Signed-off-by: Artur Petrosyan --- Changes in v2: - None drivers/usb/dwc2/hcd.c | 22 ++ 1 fil

[PATCH v2 10/12] usb: dwc2: Add clock gating entering flow by system suspend

2021-04-13 Thread Artur Petrosyan
If not hibernation nor partial power down are supported, clock gating is used to save power. Adds a new flow of entering clock gating when PC is suspended. Signed-off-by: Artur Petrosyan --- Changes in v2: - None drivers/usb/dwc2/hcd.c | 9 + 1 file changed, 9 insertions(+) diff --g

[PATCH 2/3] rseq: remove redundant access_ok()

2021-04-13 Thread Eric Dumazet
From: Eric Dumazet After commit 8f2817701492 ("rseq: Use get_user/put_user rather than __get_user/__put_user") we no longer need an access_ok() call from __rseq_handle_notify_resume() Signed-off-by: Eric Dumazet Cc: Mathieu Desnoyers Cc: Peter Zijlstra Cc: "Paul E. McKenney" Cc: Boqun Feng

[PATCH 3/3] rseq: optimise for 64bit arches

2021-04-13 Thread Eric Dumazet
From: Eric Dumazet Commit ec9c82e03a74 ("rseq: uapi: Declare rseq_cs field as union, update includes") added regressions for our servers. Using copy_from_user() and clear_user() for 64bit values on 64bit arches is suboptimal. We might revisit this patch once all 32bit arches support get_user()

Re: [PATCH 4/7] mm: Introduce verify_page_range()

2021-04-13 Thread Peter Zijlstra
On Mon, Apr 12, 2021 at 01:05:09PM -0700, Kees Cook wrote: > On Mon, Apr 12, 2021 at 10:00:16AM +0200, Peter Zijlstra wrote: > > +struct vpr_data { > > + int (*fn)(pte_t pte, unsigned long addr, void *data); > > + void *data; > > +}; > > Eeerg. This is likely to become an attack target itself.

Re: [Outreachy kernel] [PATCH] staging: rtl8723bs: hal: Remove camelcase

2021-04-13 Thread Greg Kroah-Hartman
On Mon, Apr 12, 2021 at 11:02:58PM +0200, Fabio M. De Francesco wrote: > Removed camelcase in (some) symbols. Further work is needed. What symbols did you do this for? What did you change them from and to? Be specific, and try to do only one structure at a time at the most, trying to review 1000

[PATCH v2 12/12] usb: dwc2: Add exit clock gating before removing driver

2021-04-13 Thread Artur Petrosyan
When dwc2 core is in clock gating mode loading driver again causes driver fail. Because in that mode registers are not accessible. Added a flow of exiting clock gating mode to avoid the driver reload failure. Signed-off-by: Artur Petrosyan --- Changes in v2: - None drivers/usb/dwc2/platform.

RE: [PATCH 2/6] staging: media: intel-ipu3: preferred __aligned(size) over __attribute__aligned(size)

2021-04-13 Thread David Laight
From: Mitali Borkar > Sent: 12 April 2021 00:09 > > This patch fixes the warning identified by checkpatch.pl by replacing > __attribute__aligned(size) with __aligned(size) > > Signed-off-by: Mitali Borkar > --- > .../staging/media/ipu3/include/intel-ipu3.h | 74 +-- > 1 file c

Re: [PATCH v2 1/3] context_tracking: Split guest_enter/exit_irqoff

2021-04-13 Thread Wanpeng Li
On Tue, 13 Apr 2021 at 15:35, Christian Borntraeger wrote: > > > > On 13.04.21 09:16, Wanpeng Li wrote: > [...] > > > @@ -145,6 +155,13 @@ static __always_inline void guest_exit_irqoff(void) > > } > > > > #else > > +static __always_inline void context_guest_enter_irqoff(void) > > +{ > > +

Re: [PATCH 1/4] dt-bindings: phy: Add binding for TI TCAN104x CAN transceivers

2021-04-13 Thread Marc Kleine-Budde
On 12.04.2021 12:49:56, Rob Herring wrote: > On Mon, Apr 12, 2021 at 12:19:30PM +0200, Marc Kleine-Budde wrote: > > On 4/9/21 3:40 PM, Aswath Govindraju wrote: > > > Add binding documentation for TI TCAN104x CAN transceivers. > > > > > > Signed-off-by: Aswath Govindraju > > > --- > > > .../bindi

Re: [PATCH 2/2] brcmfmac: support parse country code map from DT

2021-04-13 Thread Shawn Guo
On Mon, Apr 12, 2021 at 10:09:38AM +0200, Arend van Spriel wrote: > On 08-04-2021 13:30, Shawn Guo wrote: > > With any regulatory domain requests coming from either user space or > > 802.11 IE (Information Element), the country is coded in ISO3166 > > standard. It needs to be translated to firmwar

[PATCH v2 2/2] Bluetooth: Support the vendor specific debug events

2021-04-13 Thread Joseph Hwang
This patch allows a user space process to enable/disable the vendor specific (vs) debug events dynamically through the set experimental feature mgmt interface if CONFIG_BT_FEATURE_VS_DBG_EVT is enabled. Since the debug event feature needs to invoke the callback function provided by the driver, i.e

Re: [PATCH 2/2] brcmfmac: support parse country code map from DT

2021-04-13 Thread Shawn Guo
On Mon, Apr 12, 2021 at 10:22:47AM +0200, Arend van Spriel wrote: > On 08-04-2021 13:30, Shawn Guo wrote: > > With any regulatory domain requests coming from either user space or > > 802.11 IE (Information Element), the country is coded in ISO3166 > > standard. It needs to be translated to firmwar

[PATCH v2 1/2] Bluetooth: btusb: support link statistics telemetry events

2021-04-13 Thread Joseph Hwang
From: Chethan T N This patch supports the link statistics telemetry events for Intel controllers To avoid the overhead, this debug feature is disabled by default. Reviewed-by: Miao-chen Chou Signed-off-by: Chethan T N Signed-off-by: Kiran K Signed-off-by: Joseph Hwang --- Changes in v2: -

Re: [PATCH v2 1/3] context_tracking: Split guest_enter/exit_irqoff

2021-04-13 Thread Christian Borntraeger
On 13.04.21 09:38, Wanpeng Li wrote: On Tue, 13 Apr 2021 at 15:35, Christian Borntraeger wrote: On 13.04.21 09:16, Wanpeng Li wrote: [...] @@ -145,6 +155,13 @@ static __always_inline void guest_exit_irqoff(void) } #else THis is the else part +static __always_inline void conte

Re: [PATCH] USB: Don't set USB_PORT_FEAT_SUSPEND on WD19's Realtek Hub

2021-04-13 Thread Chris Chiu
On Mon, Apr 12, 2021 at 11:12 PM Alan Stern wrote: > > On Mon, Apr 12, 2021 at 11:00:06PM +0800, chris.c...@canonical.com wrote: > > From: Chris Chiu > > > > Realtek Hub (0bda:5413) in Dell Dock WD19 sometimes fails to work > > after the system resumes from suspend with remote wakeup enabled > >

Re: [PATCH v5 0/3] staging: rtl8192e: Cleanup patchset for style issues in rtl819x_HTProc.c

2021-04-13 Thread Greg KH
On Tue, Apr 13, 2021 at 08:55:03AM +0530, Mitali Borkar wrote: > Changes from v4:- > [PATCH v4 1/3]:- No changes. > [PATCH v4 2/3]:- No changes. > [PATCH V4 3/3]:- Removed casts and parentheses. This series does not apply cleanly, please rebase and resend. thanks, greg k-h

Re: [PATCH 0/1] Use of /sys/bus/pci/devices/…/index for non-SMBIOS platforms

2021-04-13 Thread Niklas Schnelle
On Tue, 2021-04-13 at 10:32 +0300, Leon Romanovsky wrote: > On Tue, Apr 13, 2021 at 08:57:19AM +0200, Niklas Schnelle wrote: > > On Tue, 2021-04-13 at 08:39 +0300, Leon Romanovsky wrote: > > > On Mon, Apr 12, 2021 at 03:59:04PM +0200, Niklas Schnelle wrote: > > > > Hi Narendra, Hi All, > > > > > >

RE: [PATCH net-next v2 0/3] introduce skb_for_each_frag()

2021-04-13 Thread David Laight
From: Matteo Croce > Sent: 12 April 2021 01:38 > > Introduce skb_for_each_frag, an helper macro to iterate over the SKB frags. The real question is why, the change is: - for (i = 0; i < skb_shinfo(skb)->nr_frags; i++) { + skb_for_each_frag(skb, i) { The existing code isn't complicat

Re: [Outreachy kernel] [PATCH 0/2] Remove spaces and blank lines

2021-04-13 Thread Greg Kroah-Hartman
On Mon, Apr 12, 2021 at 07:59:01PM +0200, Fabio M. De Francesco wrote: > Removed spaces before tabs and multiple blank lines from Hal8723BReg.h > for readability improvement. Issues detected by checkpatch.pl. > > Fabio M. De Francesco (2): > staging: rtl8723bs: hal Remove spaces before tabs >

Re: [PATCH v2 00/16] Multigenerational LRU Framework

2021-04-13 Thread SeongJae Park
From: SeongJae Park Hello, Very interesting work, thank you for sharing this :) On Tue, 13 Apr 2021 00:56:17 -0600 Yu Zhao wrote: > What's new in v2 > > Special thanks to Jens Axboe for reporting a regression in buffered > I/O and helping test the fix. Is the discussion ope

Re: [PATCH v2 1/3] context_tracking: Split guest_enter/exit_irqoff

2021-04-13 Thread Wanpeng Li
On Tue, 13 Apr 2021 at 15:48, Christian Borntraeger wrote: > > > > On 13.04.21 09:38, Wanpeng Li wrote: > > On Tue, 13 Apr 2021 at 15:35, Christian Borntraeger > > wrote: > >> > >> > >> > >> On 13.04.21 09:16, Wanpeng Li wrote: > >> [...] > >> > >>> @@ -145,6 +155,13 @@ static __always_inline voi

Re: [PATCH net v3] net: sched: fix packet stuck problem for lockless qdisc

2021-04-13 Thread Yunsheng Lin
On 2021/4/13 15:12, Hillf Danton wrote: > On Tue, 13 Apr 2021 11:34:27 Yunsheng Lin wrote: >> On 2021/4/13 11:26, Hillf Danton wrote: >>> On Tue, 13 Apr 2021 10:56:42 Yunsheng Lin wrote: On 2021/4/13 10:21, Hillf Danton wrote: > On Mon, 12 Apr 2021 20:00:43 Yunsheng Lin wrote: >>

RE: [PATCH net-next 6/7] net: stmmac: Enable RX via AF_XDP zero-copy

2021-04-13 Thread Ong, Boon Leong
>+ /* synchronize_rcu() needed for pending XDP buffers to drain */ >+ for (queue = 0; queue < rx_queues_cnt; queue++) { >+ rx_q = &priv->rx_queue[queue]; >+ if (rx_q->xsk_pool) { >+ synchronize_rcu(); > >Are you sure this is safe here, especi

Re: [syzbot] WARNING in bpf_test_run

2021-04-13 Thread Dmitry Vyukov
On Fri, Apr 2, 2021 at 2:41 AM 'Yonghong Song' via syzkaller-bugs wrote: > > On 4/1/21 4:29 AM, syzbot wrote: > >> Hello, > >> > >> syzbot found the following issue on: > >> > >> HEAD commit:36e79851 libbpf: Preserve empty DATASEC BTFs during > >> static.. > >> git tree: bpf-next > >> co

Re: [syzbot] BUG: unable to handle kernel paging request in bpf_trace_run2

2021-04-13 Thread Dmitry Vyukov
On Thu, Apr 1, 2021 at 8:01 PM syzbot wrote: > > syzbot suspects this issue was fixed by commit: > > commit befe6d946551d65cddbd32b9cb0170b0249fd5ed > Author: Steven Rostedt (VMware) > Date: Wed Nov 18 14:34:05 2020 + > > tracepoint: Do not fail unregistering a probe due to memory failu

lib/bitfield_kunit.c:93:1: warning: the frame size of 4184 bytes is larger than 2048 bytes

2021-04-13 Thread kernel test robot
months ago config: arm-randconfig-r013-20210413 (attached as .config) compiler: arm-linux-gnueabi-gcc (GCC) 9.3.0 reproduce (this is a W=1 build): wget https://raw.githubusercontent.com/intel/lkp-tests/master/sbin/make.cross -O ~/bin/make.cross chmod +x ~/bin/make.cross

Re: [PATCH v2 00/12] usb: dwc2: Add clock gating support.

2021-04-13 Thread Artur Petrosyan
Hi Greg, On 4/13/2021 11:35, Artur Petrosyan wrote: > This patch set adds clock gating power saving support for > dwc2 core. > It adds support for the following cases described by programming guide. >1. Enter to clock gating from USB_SUSPEND interrupt. >2. Clock gating entering flow by sys

Re: [PATCH] riscv: locks: introduce ticket-based spinlock implementation

2021-04-13 Thread Peter Zijlstra
On Mon, Apr 12, 2021 at 11:54:55PM +0200, Christoph Müllner wrote: > On Mon, Apr 12, 2021 at 7:33 PM Palmer Dabbelt wrote: > > My plan is to add a generic ticket-based lock, which can be selected at > > compile time. It'll have no architecture dependencies (though it'll > > likely have some hook

Re: [RFC v4 net-next 2/4] net: dsa: mt7530: add interrupt support

2021-04-13 Thread Marc Zyngier
On Tue, 13 Apr 2021 01:07:23 +0100, Andrew Lunn wrote: > > > > > +static void > > > > +mt7530_setup_mdio_irq(struct mt7530_priv *priv) > > > > +{ > > > > + struct dsa_switch *ds = priv->ds; > > > > + int p; > > > > + > > > > + for (p = 0; p < MT7530_NUM_PHYS; p++) { > > > > +

Re: [PATCH v2 1/3] context_tracking: Split guest_enter/exit_irqoff

2021-04-13 Thread Christian Borntraeger
On 13.04.21 09:52, Wanpeng Li wrote: Or did I miss anything. I mean the if (!context_tracking_enabled_this_cpu()) part in the function context_guest_enter_irqoff() ifdef CONFIG_VIRT_CPU_ACCOUNTING_GEN. :) Ah I missed that. Thanks.

[syzbot] general protection fault in gadget_setup

2021-04-13 Thread syzbot
Hello, syzbot found the following issue on: HEAD commit:0f4498ce Merge tag 'for-5.12/dm-fixes-2' of git://git.kern.. git tree: upstream console output: https://syzkaller.appspot.com/x/log.txt?x=124adbf6d0 kernel config: https://syzkaller.appspot.com/x/.config?x=daeff30c2474a60f das

Re: [PATCH 2/2] brcmfmac: support parse country code map from DT

2021-04-13 Thread Arend van Spriel
On 13-04-2021 09:45, Shawn Guo wrote: On Mon, Apr 12, 2021 at 10:09:38AM +0200, Arend van Spriel wrote: On 08-04-2021 13:30, Shawn Guo wrote: With any regulatory domain requests coming from either user space or 802.11 IE (Information Element), the country is coded in ISO3166 standard. It ne

Re: [syzbot] general protection fault in gadget_setup

2021-04-13 Thread Dmitry Vyukov
On Tue, Apr 13, 2021 at 10:08 AM syzbot wrote: > > Hello, > > syzbot found the following issue on: > > HEAD commit:0f4498ce Merge tag 'for-5.12/dm-fixes-2' of git://git.kern.. > git tree: upstream > console output: https://syzkaller.appspot.com/x/log.txt?x=124adbf6d0 > kernel config:

Re: [PATCH v5] platform/x86: add Gigabyte WMI temperature driver

2021-04-13 Thread Hans de Goede
Hi, On 4/12/21 2:35 PM, Thomas Weißschuh wrote: > Tested with > * X570 I Aorus Pro Wifi (rev 1.0) > * B550M DS3H > * B550 Gaming X V2 (rev.1.x) > * Z390 I AORUS PRO WIFI (rev. 1.0) > > Those mainboards contain an ITE chips for management and > monitoring. > > They could also be handled by driver

Re: [PATCH v2] platform/x86: pmc_atom: Match all Beckhoff Automation baytrail boards with critclk_systems DMI table

2021-04-13 Thread Hans de Goede
Hi, On 4/12/21 3:30 PM, Steffen Dirkwinkel wrote: > From: Steffen Dirkwinkel > > pmc_plt_clk* clocks are used for ethernet controllers, so need to stay > turned on. This adds the affected board family to critclk_systems DMI > table, so the clocks are marked as CLK_CRITICAL and not turned off. >

Re: [PATCH 7/7 v2] tracing: Do not create tracefs files if tracefs lockdown is in effect

2021-04-13 Thread Ondrej Mosnacek
On Sat, Oct 12, 2019 at 2:59 AM Steven Rostedt wrote: > From: "Steven Rostedt (VMware)" > > If on boot up, lockdown is activated for tracefs, don't even bother creating > the files. This can also prevent instances from being created if lockdown is > in effect. > > Link: > http://lkml.kernel.org/

Re: [PATCH] riscv: locks: introduce ticket-based spinlock implementation

2021-04-13 Thread Peter Zijlstra
On Tue, Apr 13, 2021 at 10:03:01AM +0200, Peter Zijlstra wrote: > For ticket locks you really only needs atomic_fetch_add() and > smp_store_release() and an architectural guarantees that the > atomic_fetch_add() has fwd progress under contention and that a sub-word > store (through smp_store_relea

  1   2   3   4   5   6   7   8   9   10   >