[PATCH v2 12/16] mm: multigenerational lru: eviction

2021-04-12 Thread Yu Zhao
The eviction consumes old generations. Given an lruvec, the eviction scans the pages on the per-zone lists indexed by either of min_seq[2]. It first tries to select a type based on the values of min_seq[2]. When anon and file types are both available from the same generation, it selects the one tha

[PATCH v2 10/16] mm: multigenerational lru: mm_struct list

2021-04-12 Thread Yu Zhao
In order to scan page tables, we add an infrastructure to maintain either a system-wide mm_struct list or per-memcg mm_struct lists. Multiple threads can concurrently work on the same mm_struct list, and each of them will be given a different mm_struct. This infrastructure also tracks whether an m

[PATCH v2 11/16] mm: multigenerational lru: aging

2021-04-12 Thread Yu Zhao
The aging produces young generations. Given an lruvec, the aging walks the mm_struct list associated with this lruvec to scan page tables for referenced pages. Upon finding one, the aging updates the generation number of this page to max_seq. After each round of scan, the aging increments max_seq.

[PATCH v2 08/16] mm: multigenerational lru: groundwork

2021-04-12 Thread Yu Zhao
For each lruvec, evictable pages are divided into multiple generations. The youngest generation number is stored in max_seq for both anon and file types as they are aged on an equal footing. The oldest generation numbers are stored in min_seq[2] separately for anon and file types as clean file page

[PATCH v2 09/16] mm: multigenerational lru: activation

2021-04-12 Thread Yu Zhao
For pages accessed multiple times via file descriptors, instead of activating them upon the second accesses, we activate them based on the refault rates of their tiers. Pages accessed N times via file descriptors belong to tier order_base_2(N). Pages from tier 0, i.e., those read ahead, accessed on

[PATCH v2 01/16] include/linux/memcontrol.h: do not warn in page_memcg_rcu() if !CONFIG_MEMCG

2021-04-12 Thread Yu Zhao
page_memcg_rcu() warns on !rcu_read_lock_held() regardless of CONFIG_MEMCG. The following code is legit, but it triggers the warning when !CONFIG_MEMCG, since lock_page_memcg() and unlock_page_memcg() are empty for this config. memcg = lock_page_memcg(page1) (rcu_read_lock() if CONFIG_MEMCG=

[PATCH v2 04/16] include/linux/cgroup.h: export cgroup_mutex

2021-04-12 Thread Yu Zhao
cgroup_mutex is needed to synchronize with memcg creations. Signed-off-by: Yu Zhao --- include/linux/cgroup.h | 15 ++- 1 file changed, 14 insertions(+), 1 deletion(-) diff --git a/include/linux/cgroup.h b/include/linux/cgroup.h index 4f2f79de083e..bd5744360cfa 100644 --- a/include/

[PATCH v2 06/16] mm, x86: support the access bit on non-leaf PMD entries

2021-04-12 Thread Yu Zhao
Some architectures support the accessed bit on non-leaf PMD entries (parents) in addition to leaf PTE entries (children) where pages are mapped, e.g., x86_64 sets the accessed bit on a parent when using it as part of linear-address translation [1]. Page table walkers who are interested in the acces

[PATCH v2 05/16] mm/swap.c: export activate_page()

2021-04-12 Thread Yu Zhao
activate_page() is needed to activate pages that are already on lru or queued in lru_pvecs.lru_add. The exported function is a merger between the existing activate_page() and __lru_cache_activate_page(). Signed-off-by: Yu Zhao --- include/linux/swap.h | 1 + mm/swap.c| 28 ++

[PATCH v2 03/16] include/linux/huge_mm.h: define is_huge_zero_pmd() if !CONFIG_TRANSPARENT_HUGEPAGE

2021-04-12 Thread Yu Zhao
Currently is_huge_zero_pmd() only exists when CONFIG_TRANSPARENT_HUGEPAGE=y. This patch adds the function for !CONFIG_TRANSPARENT_HUGEPAGE. Signed-off-by: Yu Zhao --- include/linux/huge_mm.h | 5 + 1 file changed, 5 insertions(+) diff --git a/include/linux/huge_mm.h b/include/linux/huge_mm.

[PATCH v2 02/16] include/linux/nodemask.h: define next_memory_node() if !CONFIG_NUMA

2021-04-12 Thread Yu Zhao
Currently next_memory_node only exists when CONFIG_NUMA=y. This patch adds the macro for !CONFIG_NUMA. Signed-off-by: Yu Zhao --- include/linux/nodemask.h | 1 + 1 file changed, 1 insertion(+) diff --git a/include/linux/nodemask.h b/include/linux/nodemask.h index ac398e143c9a..89fe4e3592f9 1006

[PATCH v2 07/16] mm/vmscan.c: refactor shrink_node()

2021-04-12 Thread Yu Zhao
Heuristics that determine scan balance between anon and file LRUs are rather independent. Move them into a separate function to improve readability. Signed-off-by: Yu Zhao --- mm/vmscan.c | 186 +++- 1 file changed, 98 insertions(+), 88 deletions(-

[PATCH v2 00/16] Multigenerational LRU Framework

2021-04-12 Thread Yu Zhao
What's new in v2 Special thanks to Jens Axboe for reporting a regression in buffered I/O and helping test the fix. This version includes the support of tiers, which represent levels of usage from file descriptors only. Pages accessed N times via file descriptors belong to tier ord

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

2021-04-12 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: Re: [PATCH] phy: nxp-c45: add driver for tja1103

2021-04-12 Thread Christian Herber
Hi Andrew, On 4/12/2021 6:52 PM, Andrew Lunn wrote: So what you are say is, you don't care if the IP is completely different, it all goes in one driver. So lets put this driver into nxp-tja11xx.c. And then we avoid all the naming issues. Andrew As this seems to be a key question, let

Re: [PATCH] mm: optimize memory allocation

2021-04-12 Thread Michal Hocko
On Mon 12-04-21 15:49:53, ultrac...@163.com wrote: > From: Chen Xiaoguang > > Check memory cgroup limit before allocating real memory. This may > improve performance especially in slow path when memory allocation > exceeds cgroup limitation. I would be really curious about any actual numbers bec

Re: [PATCH] kunit: add unit test for filtering suites by names

2021-04-12 Thread kernel test robot
Hi Daniel, Thank you for the patch! Perhaps something to improve: [auto build test WARNING on 1678e493d530e7977cce34e59a86bb86f3c5631e] url: https://github.com/0day-ci/linux/commits/Daniel-Latypov/kunit-add-unit-test-for-filtering-suites-by-names/20210413-080913 base: 1678e493d530e7977cce3

Re: [PATCH 6/7] i915: Convert to verify_page_range()

2021-04-12 Thread Peter Zijlstra
On Mon, Apr 12, 2021 at 01:08:38PM -0700, Kees Cook wrote: > On Mon, Apr 12, 2021 at 10:00:18AM +0200, Peter Zijlstra wrote: > > @@ -1249,14 +1249,14 @@ static int check_absent_pte(pte_t *pte, > > > > static int check_present(unsigned long addr, unsigned long len) > > { > > - return apply_to_

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

2021-04-12 Thread Julia Lawall
On Tue, 13 Apr 2021, Mitali Borkar wrote: > Declared 32 bit unsigned int as static constant inside a function > appropriately. I don't think that the description matches what is done. Perhaps all the meaning is intended to be in the word "appropriately", but that is not very clear. The messa

Re: [PATCH 3/3] sched: Use cpu_dying() to fix balance_push vs hotplug-rollback

2021-04-12 Thread Peter Zijlstra
On Mon, Apr 12, 2021 at 06:22:42PM +0100, Valentin Schneider wrote: > On 12/04/21 14:03, Peter Zijlstra wrote: > > On Thu, Mar 11, 2021 at 03:13:04PM +, Valentin Schneider wrote: > >> Peter Zijlstra writes: > >> > @@ -7910,6 +7908,14 @@ int sched_cpu_deactivate(unsigned int cp > >> >} > >>

Re: [PATCH] MIPS: fix memory reservation for non-usermem setups

2021-04-12 Thread Ilya Lipnitskiy
On Mon, Apr 12, 2021 at 11:45 PM Ilya Lipnitskiy wrote: > > Hi Thomas, > > On Tue, Apr 6, 2021 at 6:18 AM Thomas Bogendoerfer > wrote: > > > > On Sat, Apr 03, 2021 at 07:02:13PM -0700, Ilya Lipnitskiy wrote: > > > Hi Mike, > > > > > > On Tue, Mar 16, 2021 at 11:33 PM Mike Rapoport wrote: > > > >

Re: [PATCH] vfio/pci: Add missing range check in vfio_pci_mmap

2021-04-12 Thread Cornelia Huck
On Mon, 12 Apr 2021 23:41:24 +0200 "Christian A. Ehrhardt" wrote: > When mmaping an extra device region verify that the region index > derived from the mmap offset is valid. > > Fixes: a15b1883fee1 ("vfio_pci: Allow mapping extra regions") > Cc: sta...@vger.kernel.org > Signed-off-by: Christian

Re: [PATCH v1 6/7] mfd: lpc_ich: Add support for pinctrl in non-ACPI system

2021-04-12 Thread Henning Schild
Am Mon, 12 Apr 2021 20:34:45 +0300 schrieb Andy Shevchenko : > On Mon, Apr 12, 2021 at 07:16:53PM +0200, Henning Schild wrote: > > Am Mon, 12 Apr 2021 19:59:05 +0300 > > schrieb Andy Shevchenko : > > > On Mon, Apr 12, 2021 at 06:40:01PM +0200, Henning Schild wrote: > > > > Tan or Andy, > > > >

Re: [PATCH] MIPS: fix memory reservation for non-usermem setups

2021-04-12 Thread Ilya Lipnitskiy
Hi Thomas, On Tue, Apr 6, 2021 at 6:18 AM Thomas Bogendoerfer wrote: > > On Sat, Apr 03, 2021 at 07:02:13PM -0700, Ilya Lipnitskiy wrote: > > Hi Mike, > > > > On Tue, Mar 16, 2021 at 11:33 PM Mike Rapoport wrote: > > > > > > Hi Ilya, > > > > > > On Tue, Mar 16, 2021 at 10:10:09PM -0700, Ilya Lip

Re: [PATCH v2 resend] mm/memory_hotplug: Make unpopulated zones PCP structures unreachable during hot remove

2021-04-12 Thread Michal Hocko
On Mon 12-04-21 14:40:18, Vlastimil Babka wrote: > On 4/12/21 2:08 PM, Mel Gorman wrote: > > zone_pcp_reset allegedly protects against a race with drain_pages > > using local_irq_save but this is bogus. local_irq_save only operates > > on the local CPU. If memory hotplug is running on CPU A and dra

Re: [PATCH v5] lib: add basic KUnit test for lib/math

2021-04-12 Thread David Gow
On Tue, Apr 13, 2021 at 3:07 AM Daniel Latypov wrote: > > Add basic test coverage for files that don't require any config options: > * part of math.h (what seem to be the most commonly used macros) > * gcd.c > * lcm.c > * int_sqrt.c > * reciprocal_div.c > (Ignored int_pow.c since it's a simple tex

Re: [PATCH v2 resend] mm/memory_hotplug: Make unpopulated zones PCP structures unreachable during hot remove

2021-04-12 Thread Michal Hocko
On Mon 12-04-21 13:08:42, Mel Gorman wrote: > zone_pcp_reset allegedly protects against a race with drain_pages > using local_irq_save but this is bogus. local_irq_save only operates > on the local CPU. If memory hotplug is running on CPU A and drain_pages > is running on CPU B, disabling IRQs on C

[PATCH] stm class: remove useless function

2021-04-12 Thread Jiapeng Chong
Fix the following clang warning: drivers/hwtracing/stm/policy.c:60:21: warning: unused function 'stp_policy_node_name' [-Wunused-function]. Reported-by: Abaci Robot Signed-off-by: Jiapeng Chong --- drivers/hwtracing/stm/policy.c | 5 - 1 file changed, 5 deletions(-) diff --git a/drivers/h

RE: [PATCH v7 1/2] platform/x86: dell-privacy: Add support for Dell hardware privacy

2021-04-12 Thread Yuan, Perry
Hi , > -Original Message- > From: Amadeusz Sławiński > Sent: 2021年4月12日 18:40 > To: Yuan, Perry; po...@protonmail.com; pierre- > louis.boss...@linux.intel.com; oder_ch...@realtek.com; pe...@perex.cz; > ti...@suse.com; hdego...@redhat.com; mgr...@linux.intel.com > Cc: alsa-de...@alsa-projec

[PATCH v8] RISC-V: enable XIP

2021-04-12 Thread Alexandre Ghiti
From: Vitaly Wool Introduce XIP (eXecute In Place) support for RISC-V platforms. It allows code to be executed directly from non-volatile storage directly addressable by the CPU, such as QSPI NOR flash which can be found on many RISC-V platforms. This makes way for significant optimization of RAM

Re: [PATCH RESEND v1 0/4] powerpc/vdso: Add support for time namespaces

2021-04-12 Thread Michael Ellerman
Thomas Gleixner writes: > On Wed, Mar 31 2021 at 16:48, Christophe Leroy wrote: >> [Sorry, resending with complete destination list, I used the wrong script on >> the first delivery] >> >> This series adds support for time namespaces on powerpc. >> >> All timens selftests are successfull. > > If

Re: [PATCH for-next v3 0/2] Introduce rdma_set_min_rnr_timer() and use it in RDS

2021-04-12 Thread Leon Romanovsky
On Mon, Apr 12, 2021 at 07:58:47PM -0300, Jason Gunthorpe wrote: > On Wed, Mar 31, 2021 at 08:43:12PM +0200, Håkon Bugge wrote: > > ib_modify_qp() is an expensive operation on some HCAs running > > virtualized. This series removes two ib_modify_qp() calls from RDS. > > > > I am sending this as a v

Re: [PATCH 1/4] dt-bindings: Add bindings for aspeed pwm-tach.

2021-04-12 Thread Billy Tsai
Hi, Best Regards, Billy Tsai On 2021/4/12, 8:55 PM,Uwe Kleine-Königwrote: > Hello, On Mon, Apr 12, 2021 at 05:54:54PM +0800, Billy Tsai wrote: > + - Billy Tsai > I object because the MTA at aspeedtech.com doesn't know this email > address. This is typo error, my email ad

arch/mips/n64/init.c:57:38: sparse: sparse: incorrect type in argument 2 (different address spaces)

2021-04-12 Thread kernel test robot
tree: https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git master head: 89698becf06d341a700913c3d89ce2a914af69a2 commit: baec970aa5ba11099ad7a91773350c91fb2113f0 mips: Add N64 machine type date: 3 months ago config: mips-randconfig-s032-20210413 (attached as .config) compiler:

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

2021-04-12 Thread Mitali Borkar
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. drivers/staging/media/meson/vdec/codec_h264.c | 4 ++-- 1 file ch

[PATCH] kernel:irq:manage: request threaded irq with a specified priority

2021-04-12 Thread Song Chen
In general, irq handler thread will be assigned a default priority which is MAX_RT_PRIO/2, as a result, no one can preempt others. Here is the case I found in a real project, an interrupt int_a is coming, wakes up its handler handler_a and handler_a wakes up a userspace RT process task_a. However

[PATCH] x86: Accelerate copy_page with non-temporal in X86

2021-04-12 Thread Kemeng Shi
I'm using AEP with dax_kmem drvier, and AEP is export as a NUMA node in my system. I will move cold pages from DRAM node to AEP node with move_pages system call. With old "rep movsq', it costs 2030ms to move 1 GB pages. With "movnti", it only cost about 890ms to move 1GB pages. I also test move 1GB

[PATCH 5/8] MIPS: pci-legacy: stop using of_pci_range_to_resource

2021-04-12 Thread Ilya Lipnitskiy
Mirror commit aeba3731b150 ("powerpc/pci: Fix IO space breakage after of_pci_range_to_resource() change"). Most MIPS platforms do not define PCI_IOBASE, nor implement pci_address_to_pio(). Moreover, IO_SPACE_LIMIT is 0x for most MIPS platforms. of_pci_range_to_resource passes the _start addres

[PATCH 8/8] MIPS: pci-legacy: use generic pci_enable_resources

2021-04-12 Thread Ilya Lipnitskiy
Follow the reasoning from commit 842de40d93e0 ("PCI: add generic pci_enable_resources()"): The only functional difference from the MIPS version is that the generic one uses "!r->parent" to check for resource collisions instead of "!r->start && r->end". That should have no effect on any pci-

[PATCH 1/8] MIPS: pci-rt2880: fix slot 0 configuration

2021-04-12 Thread Ilya Lipnitskiy
pci_fixup_irqs() used to call pcibios_map_irq on every PCI device, which for RT2880 included bus 0 slot 0. After pci_fixup_irqs() got removed, only slots/funcs with devices attached would be called. While arguably the right thing, that left no chance for this driver to ever initialize slot 0, effec

[PATCH 2/8] MIPS: pci-rt2880: remove unneeded locks

2021-04-12 Thread Ilya Lipnitskiy
Mirror pci-rt3883 fix from commit e5067c718b3a ("MIPS: pci-rt3883: Remove odd locking in PCI config space access code"). pci-rt2880 shares the driver layout with pci-rt3883 and the same reasons apply. Caller (generic PCI code) already does proper locking, so no need to add another one here. Local

Re: linux-next: Tree for Apr 9 (x86 boot problem)

2021-04-12 Thread Randy Dunlap
On 4/12/21 11:06 PM, Mike Rapoport wrote: > Hi Randy, > > On Mon, Apr 12, 2021 at 01:53:34PM -0700, Randy Dunlap wrote: >> On 4/12/21 10:01 AM, Mike Rapoport wrote: >>> On Mon, Apr 12, 2021 at 08:49:49AM -0700, Randy Dunlap wrote: >>> >>> I thought about adding some prints to see what's causing

[PATCH 3/8] MIPS: pci-rt3883: trivial: remove unused variable

2021-04-12 Thread Ilya Lipnitskiy
Fixes the following compiler warning: warning: unused variable 'flags' [-Wunused-variable] Fixes: e5067c718b3a ("MIPS: pci-rt3883: Remove odd locking in PCI config space access code") Signed-off-by: Ilya Lipnitskiy Cc: Sergey Ryazanov Cc: triv...@kernel.org --- arch/mips/pci/pci-rt3883.c | 4

[PATCH 4/8] MIPS: pci-rt3883: more accurate DT error messages

2021-04-12 Thread Ilya Lipnitskiy
Existing strings do not make sense: one is always NULL and the other refers to the wrong parent node. Signed-off-by: Ilya Lipnitskiy --- arch/mips/pci/pci-rt3883.c | 6 ++ 1 file changed, 2 insertions(+), 4 deletions(-) diff --git a/arch/mips/pci/pci-rt3883.c b/arch/mips/pci/pci-rt3883.c in

[PATCH 7/8] MIPS: pci-legacy: remove busn_resource field

2021-04-12 Thread Ilya Lipnitskiy
No drivers set the busn_resource field in the pci_controller struct. Commit 7ee214b540d9 ("MIPS: PCI: Remove unused busn_offset") almost removed it over 3 years ago. Remove it for good to free up memory and eliminate messages like: pci_bus :00: root bus resource [??? 0x flags 0x0] Si

[PATCH 6/8] MIPS: pci-legacy: remove redundant info messages

2021-04-12 Thread Ilya Lipnitskiy
Remove the following pci-legacy message: PCI host bridge /pci@44/host-bridge ranges: MEM 0x2000..0x2fff IO 0x0046..0x0046 It is followed shortly by the same data from pci_register_host_bridge: PCI host bridge to bus :00 pci_bus 0

[PATCH 0/8] MIPS: Fixes for PCI legacy drivers (rt2880, rt3883)

2021-04-12 Thread Ilya Lipnitskiy
One major fix for rt2880-pci in the first patch - fixes breakage that existed since v4.14. Other more minor fixes, cleanups, and improvements that either free up memory, make dmesg messages clearer, or remove redundant dmesg output. Ilya Lipnitskiy (8): MIPS: pci-rt2880: fix slot 0 configuratio

Re: [PATCH 1/1] arm: topology: parse the topology from the dt

2021-04-12 Thread Ruifeng Zhang
Dietmar Eggemann 于2021年4月12日周一 下午8:40写道: > > On 12/04/2021 14:20, Ruifeng Zhang wrote: > > Valentin Schneider 于2021年4月12日周一 下午7:32写道: > >> > >> > >> Hi, > >> > >> On 12/04/21 15:08, Ruifeng Zhang wrote: > >>> From: Ruifeng Zhang > >>> > >>> The arm topology still parse from the MPIDR, but it is

[PATCH] ASoC: ak5558: correct reset polarity

2021-04-12 Thread Shengjiu Wang
Reset (aka power off) happens when the reset gpio is made active. Change function name to ak5558_reset to match devicetree property "reset-gpios". Signed-off-by: Shengjiu Wang --- sound/soc/codecs/ak5558.c | 30 ++ 1 file changed, 10 insertions(+), 20 deletions(-) di

[PATCH] drm/i915/gvt: remove useless function

2021-04-12 Thread Jiapeng Chong
Fix the following clang warning: drivers/gpu/drm/i915/gvt/gtt.c:590:20: warning: unused function 'ppgtt_set_guest_root_entry' [-Wunused-function]. Reported-by: Abaci Robot Signed-off-by: Jiapeng Chong --- drivers/gpu/drm/i915/gvt/gtt.c | 6 -- 1 file changed, 6 deletions(-) diff --git a/d

[PATCH] irq: Fix missing IRQF_ONESHOT as only threaded handler

2021-04-12 Thread zhuguangqing83
From: Guangqing Zhu Coccinelle noticed: kernel/irq/manage.c:2199:8-28: ERROR: Threaded IRQ with no primary handler requested without IRQF_ONESHOT. Signed-off-by: Guangqing Zhu --- kernel/irq/manage.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/kernel/irq/manage.c b/ke

Re: [PATCH 5.10 000/188] 5.10.30-rc1 review

2021-04-12 Thread Samuel Zou
On 2021/4/12 16:38, Greg Kroah-Hartman wrote: This is the start of the stable review cycle for the 5.10.30 release. There are 188 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 should be m

[RFC PATCH] delayacct: delayacct_stats[] can be static

2021-04-12 Thread kernel test robot
Reported-by: kernel test robot Signed-off-by: kernel test robot --- delayacct.c |2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/kernel/delayacct.c b/kernel/delayacct.c index b8d719fbfc404..2505aa9f87f61 100644 --- a/kernel/delayacct.c +++ b/kernel/delayacct.c @@ -32,7 +3

Re: [RESEND PATCH 2/2] delayacct: Add a proc file to dump the delay info

2021-04-12 Thread kernel test robot
Hi brookxu, Thank you for the patch! Perhaps something to improve: [auto build test WARNING on linus/master] [also build test WARNING on v5.12-rc7 next-20210412] [If your patch is applied to the wrong git tree, kindly drop us a note. And when submitting patch, we suggest to use '--bas

[tip:x86/sgx] BUILD SUCCESS 523caed9efbb049339706b124185c9358c1b6477

2021-04-12 Thread kernel test robot
allyesconfig powerpc allmodconfig powerpc allnoconfig i386 randconfig-a003-20210412 i386 randconfig-a001-20210412 i386 randconfig-a006-20210412 i386 randconfig

[tip:x86/platform] BUILD SUCCESS 8f2aca40dd077f74e62982cd2669845f41ed0ac6

2021-04-12 Thread kernel test robot
-a005-20210413 x86_64 randconfig-a006-20210413 x86_64 randconfig-a004-20210413 i386 randconfig-a003-20210412 i386 randconfig-a001-20210412 i386 randconfig-a006-20210412 i386 randconfig-a005-20210412 i386

Re: [PATCH 1/1] arm: topology: parse the topology from the dt

2021-04-12 Thread Ruifeng Zhang
Valentin Schneider 于2021年4月12日周一 下午11:33写道: > > On 12/04/21 20:20, Ruifeng Zhang wrote: > > There is a armv8.3 cpu which should work normally both on aarch64 and > > aarch32. > > The MPIDR has been written to the chip register in armv8.3 format. > > For example, > > core0: 8000 > > co

Re: [syzbot] KASAN: slab-out-of-bounds Read in reiserfs_xattr_get

2021-04-12 Thread Dmitry Vyukov
On Tue, Apr 13, 2021 at 7:55 AM syzbot wrote: > > Hello, > > syzbot found the following issue on: > > HEAD commit:3a229812 Merge tag 'arm-fixes-5.11-2' of git://git.kernel... > git tree: upstream > console output: https://syzkaller.appspot.com/x/log.txt?x=16b4d196d0 > kernel config:

Re: [PATCH v14 4/6] locking/qspinlock: Introduce starvation avoidance into CNA

2021-04-12 Thread Andi Kleen
Andi Kleen writes: > Alex Kogan writes: >> >> +numa_spinlock_threshold=[NUMA, PV_OPS] >> +Set the time threshold in milliseconds for the >> +number of intra-node lock hand-offs before the >> +NUMA-aware spinlock is forced

/usr/bin/ld: ll_temac_main.c:undefined reference to `devm_of_iomap'

2021-04-12 Thread kernel test robot
Hi Andre, FYI, the error/warning still remains. tree: https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git master head: 89698becf06d341a700913c3d89ce2a914af69a2 commit: e8b6c54f6d57822e228027d41a1edb317034a08c net: xilinx: temac: Relax Kconfig dependencies date: 1 year, 1 mo

Re: [PATCH][next] scsi: aacraid: Replace one-element array with flexible-array member

2021-04-12 Thread Gustavo A. R. Silva
Hi Martin, On 4/12/21 23:52, Martin K. Petersen wrote: > Silencing analyzer warnings shouldn't be done at the expense of human > readers. If it is imperative to switch to flex_array_size() to quiesce > checker warnings, please add a comment in the code explaining that the > size evaluates to nseg

Re: [PATCH] KVM: arm/arm64: Fix KVM_VGIC_V3_ADDR_TYPE_REDIST read

2021-04-12 Thread Keqian Zhu
On 2021/4/12 23:00, Eric Auger wrote: > When reading the base address of the a REDIST region > through KVM_VGIC_V3_ADDR_TYPE_REDIST we expect the > redistributor region list to be populated with a single > element. > > However list_first_entry() expects the list to be non empty. Indeed, list_fir

Re: [PATCH v5 04/16] memory: mtk-smi: Add device-link between smi-larb and smi-common

2021-04-12 Thread Yong Wu
On Sat, 2021-04-10 at 14:40 +0200, Krzysztof Kozlowski wrote: > On 10/04/2021 11:11, Yong Wu wrote: > > Normally, If the smi-larb HW need work, we should enable the smi-common > > HW power and clock firstly. > > This patch adds device-link between the smi-larb dev and the smi-common > > dev. then I

Re: linux-next: Tree for Apr 9 (x86 boot problem)

2021-04-12 Thread Mike Rapoport
Hi Randy, On Mon, Apr 12, 2021 at 01:53:34PM -0700, Randy Dunlap wrote: > On 4/12/21 10:01 AM, Mike Rapoport wrote: > > On Mon, Apr 12, 2021 at 08:49:49AM -0700, Randy Dunlap wrote: > > > > I thought about adding some prints to see what's causing the hang, the > > reservations or their absence.

[PATCH] hwmon: (nct6683) remove useless function

2021-04-12 Thread Jiapeng Chong
Fix the following clang warning: drivers/hwmon/nct6683.c:491:19: warning: unused function 'in_to_reg' [-Wunused-function]. Reported-by: Abaci Robot Signed-off-by: Jiapeng Chong --- drivers/hwmon/nct6683.c | 11 --- 1 file changed, 11 deletions(-) diff --git a/drivers/hwmon/nct6683.c b

Re: [PATCH v14 4/6] locking/qspinlock: Introduce starvation avoidance into CNA

2021-04-12 Thread Andi Kleen
Alex Kogan writes: > > + numa_spinlock_threshold=[NUMA, PV_OPS] > + Set the time threshold in milliseconds for the > + number of intra-node lock hand-offs before the > + NUMA-aware spinlock is forced to be passed to > +

[syzbot] KASAN: null-ptr-deref Write in rhashtable_free_and_destroy (2)

2021-04-12 Thread syzbot
Hello, syzbot found the following issue on: HEAD commit:d93a0d43 Merge tag 'block-5.12-2021-04-02' of git://git.ke.. git tree: upstream console output: https://syzkaller.appspot.com/x/log.txt?x=12d81cfcd0 kernel config: https://syzkaller.appspot.com/x/.config?x=71a75beb62b62a34 das

[PATCH v4 3/4] pinctrl: add drive for I2C related pins on MT8195

2021-04-12 Thread Zhiyong Tao
This patch provides the advanced drive raw data setting version for I2C used pins on MT8195. Signed-off-by: Zhiyong Tao --- drivers/pinctrl/mediatek/pinctrl-mt8195.c | 22 +++ .../pinctrl/mediatek/pinctrl-mtk-common-v2.c | 14 .../pinctrl/mediatek/pinctrl-mtk-co

[syzbot] KASAN: slab-out-of-bounds Read in __xfrm_decode_session (2)

2021-04-12 Thread syzbot
Hello, syzbot found the following issue on: HEAD commit:1678e493 Merge tag 'lto-v5.12-rc6' of git://git.kernel.org.. git tree: upstream console output: https://syzkaller.appspot.com/x/log.txt?x=1565bf7cd0 kernel config: https://syzkaller.appspot.com/x/.config?x=71a75beb62b62a34 das

[PATCH v4 2/4] pinctrl: add pinctrl driver on mt8195

2021-04-12 Thread Zhiyong Tao
This commit includes pinctrl driver for mt8195. Signed-off-by: Zhiyong Tao --- drivers/pinctrl/mediatek/Kconfig |6 + drivers/pinctrl/mediatek/Makefile |1 + drivers/pinctrl/mediatek/pinctrl-mt8195.c | 828 drivers/pinctrl/mediatek/pinctrl-mtk-mt819

[PATCH v4 4/4] pinctrl: add rsel setting on MT8195

2021-04-12 Thread Zhiyong Tao
This patch provides rsel setting on MT8195. Signed-off-by: Zhiyong Tao --- drivers/pinctrl/mediatek/pinctrl-mt8195.c | 22 +++ .../pinctrl/mediatek/pinctrl-mtk-common-v2.c | 14 .../pinctrl/mediatek/pinctrl-mtk-common-v2.h | 10 + drivers/pinctrl/mediat

[PATCH v4 1/4] dt-bindings: pinctrl: mt8195: add pinctrl file and binding document

2021-04-12 Thread Zhiyong Tao
1. This patch adds pinctrl file for mt8195. 2. This patch adds mt8195 compatible node in binding document. Signed-off-by: Zhiyong Tao --- .../bindings/pinctrl/pinctrl-mt8195.yaml | 151 +++ include/dt-bindings/pinctrl/mt8195-pinfunc.h | 962 ++ 2 files changed, 1113 inserti

[PATCH v4 0/4] Mediatek pinctrl patch on mt8195

2021-04-12 Thread Zhiyong Tao
This series includes 4 patches: 1.add pinctrl file and inding document on mt8195. 2.add pinctrl driver on MT8195. 3.add pinctrl drive for I2C related pins on MT8195. 4.add pinctrl rsel setting on MT8195. Changes in patch v4: 1)fix pinctrl-mt8195.yaml warning error. 2)remove pinctrl device node pat

[syzbot] BUG: unable to handle kernel NULL pointer dereference in __lookup_slow (2)

2021-04-12 Thread syzbot
Hello, syzbot found the following issue on: HEAD commit:d93a0d43 Merge tag 'block-5.12-2021-04-02' of git://git.ke.. git tree: upstream console output: https://syzkaller.appspot.com/x/log.txt?x=16519431d0 kernel config: https://syzkaller.appspot.com/x/.config?x=71a75beb62b62a34 das

[syzbot] KASAN: slab-out-of-bounds Read in reiserfs_xattr_get

2021-04-12 Thread syzbot
Hello, syzbot found the following issue on: HEAD commit:3a229812 Merge tag 'arm-fixes-5.11-2' of git://git.kernel... git tree: upstream console output: https://syzkaller.appspot.com/x/log.txt?x=16b4d196d0 kernel config: https://syzkaller.appspot.com/x/.config?x=f91155ccddaf919c das

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

2021-04-12 Thread Martin K. Petersen
On Tue, 30 Mar 2021 05:46:01 -0700, zhouchuangao wrote: > BUG_ON() uses unlikely in if(), which can be optimized at compile time. Applied to 5.13/scsi-queue, thanks! [1/1] message/fusion: Use BUG_ON instead of if condition followed by BUG. https://git.kernel.org/mkp/scsi/c/4dec8004de29 --

Re: [PATCH] scsi: bfa: Remove unnecessary struct declaration

2021-04-12 Thread Martin K. Petersen
On Thu, 1 Apr 2021 14:35:34 +0800, Wan Jiabing wrote: > struct bfa_fcs_s is declared twice. One is declared > at 50th line. Remove the duplicate. > struct bfa_fcs_fabric_s is defined at 175th line. > Remove unnecessary declaration. Applied to 5.13/scsi-queue, thanks! [1/1] scsi: bfa: Remove unne

Re: [PATCH][next] scsi: ufs: Fix out-of-bounds warnings in ufshcd_exec_raw_upiu_cmd

2021-04-12 Thread Martin K. Petersen
On Wed, 31 Mar 2021 17:43:38 -0500, Gustavo A. R. Silva wrote: > Fix the following out-of-bounds warnings by enclosing > some structure members into new structure objects upiu_req > and upiu_rsp: > > include/linux/fortify-string.h:20:29: warning: '__builtin_memcpy' offset [29, > 48] from the obj

Re: [PATCH -next] scsi: fnic: remove unnecessary spin_lock_init() and INIT_LIST_HEAD()

2021-04-12 Thread Martin K. Petersen
On Tue, 30 Mar 2021 20:59:11 +0800, Yang Yingliang wrote: > The spinlock and list head of fnic_list is initialized statically. > It is unnecessary to initialize by spin_lock_init() and INIT_LIST_HEAD(). Applied to 5.13/scsi-queue, thanks! [1/1] scsi: fnic: remove unnecessary spin_lock_init() and

Re: [PATCH v7 3/4] spmi: mediatek: Add support for MT6873/8192

2021-04-12 Thread Hsin-hsiung Wang
Hi Maintainers, Gentle pin for this patch. Thanks. On Sun, 2021-03-14 at 02:00 +0800, Hsin-Hsiung Wang wrote: > Add spmi support for MT6873/8192. > > Signed-off-by: Hsin-Hsiung Wang > --- > changes since v6: > - remove unused spinlock. > - remove redundant check for slave id. > --- > drivers/s

[PATCH RFC v2 0/4] virtio net: spurious interrupt related fixes

2021-04-12 Thread Michael S. Tsirkin
With the implementation of napi-tx in virtio driver, we clean tx descriptors from rx napi handler, for the purpose of reducing tx complete interrupts. But this introduces a race where tx complete interrupt has been raised, but the handler finds there is no work to do because we have done the work i

Re: [PATCH v1 0/2] scsi: libsas: few clean up patches

2021-04-12 Thread Martin K. Petersen
On Thu, 25 Mar 2021 20:29:54 +0800, Luo Jiaxing wrote: > Two types of errors are detected by the checkpatch. > 1. Alignment between switches and cases > 2. Improper use of some spaces > > Here are the clean up patches. > > Luo Jiaxing (2): > scsi: libsas: make switch and case at the same inden

Re: [PATCH v2] scsi: libsas: Reset num_scatter if libata mark qc as NODATA

2021-04-12 Thread Martin K. Petersen
On Thu, 18 Mar 2021 15:56:32 -0700, Jolly Shah wrote: > When the cache_type for the scsi device is changed, the scsi layer > issues a MODE_SELECT command. The caching mode details are communicated > via a request buffer associated with the scsi command with data > direction set as DMA_TO_DEVICE (s

[PATCH RFC v2 4/4] virtio_net: move txq wakeups under tx q lock

2021-04-12 Thread Michael S. Tsirkin
We currently check num_free outside tx q lock which is unsafe: new packets can arrive meanwhile and there won't be space in the queue. Thus a spurious queue wakeup causing overhead and even packet drops. Move the check under the lock to fix that. Signed-off-by: Michael S. Tsirkin --- drivers/ne

[PATCH RFC v2 3/4] virtio_net: move tx vq operation under tx queue lock

2021-04-12 Thread Michael S. Tsirkin
It's unsafe to operate a vq from multiple threads. Unfortunately this is exactly what we do when invoking clean tx poll from rx napi. As a fix move everything that deals with the vq to under tx lock. Signed-off-by: Michael S. Tsirkin --- drivers/net/virtio_net.c | 22 +- 1 fi

[PATCH RFC v2 2/4] virtio_net: disable cb aggressively

2021-04-12 Thread Michael S. Tsirkin
There are currently two cases where we poll TX vq not in response to a callback: start xmit and rx napi. We currently do this with callbacks enabled which can cause extra interrupts from the card. Used not to be a big issue as we run with interrupts disabled but that is no longer the case, and in

[PATCH RFC v2 1/4] virtio: fix up virtio_disable_cb

2021-04-12 Thread Michael S. Tsirkin
virtio_disable_cb is currently a nop for split ring with event index. This is because it used to be always called from a callback when we know device won't trigger more events until we update the index. However, now that we run with interrupts enabled a lot we also poll without a callback so that

[syzbot] KASAN: use-after-free Read in skcipher_walk_next

2021-04-12 Thread syzbot
Hello, syzbot found the following issue on: HEAD commit:4fa56ad0 Merge tag 'for-linus' of git://git.kernel.org/pub.. git tree: upstream console output: https://syzkaller.appspot.com/x/log.txt?x=17dbd09ad0 kernel config: https://syzkaller.appspot.com/x/.config?x=9320464bf47598bd das

linux-next: manual merge of the kvm-arm tree with the arm64 tree

2021-04-12 Thread Stephen Rothwell
Hi all, Today's linux-next merge of the kvm-arm tree got a conflict in: arch/arm64/include/asm/assembler.h between commits: 27248fe1abb2 ("arm64: assembler: remove conditional NEON yield macros") 13150149aa6d ("arm64: fpsimd: run kernel mode NEON with softirqs disabled") from the arm64 t

Re: [RFC] mm: activate access-more-than-once page via NUMA balancing

2021-04-12 Thread Huang, Ying
Yu Zhao writes: > On Fri, Mar 26, 2021 at 12:21 AM Huang, Ying wrote: >> >> Mel Gorman writes: >> >> > On Thu, Mar 25, 2021 at 12:33:45PM +0800, Huang, Ying wrote: >> >> > I caution against this patch. >> >> > >> >> > It's non-deterministic for a number of reasons. As it requires NUMA >> >> > b

Re: [PATCH 4.19 00/66] 4.19.187-rc1 review

2021-04-12 Thread Naresh Kamboju
On Mon, 12 Apr 2021 at 14:13, Greg Kroah-Hartman wrote: > > This is the start of the stable review cycle for the 4.19.187 release. > There are 66 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. > > Re

Re: [PATCH][next] KEYS: trusted: Fix missing null return from kzalloc call

2021-04-12 Thread Sumit Garg
On Mon, 12 Apr 2021 at 22:34, Colin Ian King wrote: > > On 12/04/2021 17:48, James Bottomley wrote: > > On Mon, 2021-04-12 at 17:01 +0100, Colin King wrote: > >> From: Colin Ian King > >> > >> The kzalloc call can return null with the GFP_KERNEL flag so > >> add a null check and exit via a new er

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

2021-04-12 Thread Leon Romanovsky
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 create network > interface names. > > Now we would like to reuse this at

[PATCH v2][next] scsi: aacraid: Replace one-element array with flexible-array member

2021-04-12 Thread Gustavo A. R. Silva
There is a regular need in the kernel to provide a way to declare having a dynamically sized set of trailing elements in a structure. Kernel code should always use “flexible array members”[1] for these cases. The older style of one-element or zero-length arrays should no longer be used[2]. Refacto

Re: [RESEND,v5,1/2] bio: limit bio max size

2021-04-12 Thread Christoph Hellwig
And more importantly please test with a file system that uses the iomap direct I/O code (btrfs, gfs2, ext4, xfs, zonefs) as we should never just work aroudn a legacy codebase that should go away in the block layer.

[PATCH v2 2/2] x86/tsc: skip tsc watchdog checking for qualified platforms

2021-04-12 Thread Feng Tang
There are cases that tsc clocksources are wrongly judged as unstable by clocksource watchdogs like hpet, acpi_pm or 'refined-jiffies'. While there is hardly a general reliable way to check the validity of a watchdog, and to protect the innocent tsc, Thomas Gleixner proposed [1]: "I'm inclined to l

[PATCH v2 1/2] x86/tsc: add a timer to make sure tsc_adjust is always checked

2021-04-12 Thread Feng Tang
Normally the tsc_sync will get checked every time system enters idle state, but Thomas Gleixner mentioned there is still a caveat that a system won't enter idle [1], either because it's too busy or configured purposely to not enter idle. Setup a periodic timer to make sure the check is always on.

Re: [PATCH][next] KEYS: trusted: Fix missing null return from kzalloc call

2021-04-12 Thread Sumit Garg
On Mon, 12 Apr 2021 at 21:31, Colin King wrote: > > From: Colin Ian King > > The kzalloc call can return null with the GFP_KERNEL flag so > add a null check and exit via a new error exit label. Use the > same exit error label for another error path too. > > Addresses-Coverity: ("Dereference null

Re: [PATCH] ibmvfc: Fix invalid state machine BUG_ON

2021-04-12 Thread Martin K. Petersen
Tyrel, > This fixes an issue hitting the BUG_ON in ibmvfc_do_work. When going > through a host action of IBMVFC_HOST_ACTION_RESET, we change the > action to IBMVFC_HOST_ACTION_TGT_DEL, then drop the host lock, and > reset the CRQ, which changes the host state to IBMVFC_NO_CRQ. [...] Applied to

[PATCH v2 6/9] userfaultfd/selftests: create alias mappings in the shmem test

2021-04-12 Thread Axel Rasmussen
Previously, we just allocated two shm areas: area_src and area_dst. With this commit, change this so we also allocate area_src_alias, and area_dst_alias. area_*_alias and area_* (respectively) point to the same underlying physical pages, but are different VMAs. In a future commit in this series, w

  1   2   3   4   5   6   7   8   9   10   >