Re: [PATCH 1/2] mm/madvise: allow process_madvise operations on entire memory range

2020-12-22 Thread Christoph Hellwig
On Tue, Dec 22, 2020 at 09:48:43AM -0800, Suren Baghdasaryan wrote: > Thanks for the feedback! The use case is userspace memory reaping > similar to oom-reaper. Detailed justification is here: > https://lore.kernel.org/linux-mm/20201124053943.1684874-1-sur...@google.com Given that this new

Re: [PATCH v5 07/12] media: uvcvideo: Implement UVC_EXT_GPIO_UNIT

2020-12-22 Thread Laurent Pinchart
Hi Ricardo, On Tue, Dec 22, 2020 at 07:36:52PM +0100, Ricardo Ribalda wrote: > On Tue, Dec 22, 2020 at 9:34 AM Laurent Pinchart wrote: > > On Mon, Dec 21, 2020 at 05:48:14PM +0100, Ricardo Ribalda wrote: > > > Some devices can implement a physical switch to disable the input of the > > > camera

Re: Does uaccess_kernel() work for detecting kernel thread?

2020-12-22 Thread Christoph Hellwig
On Tue, Dec 22, 2020 at 11:39:08PM +0900, Tetsuo Handa wrote: > For example, if uaccess_kernel() is "false" due to CONFIG_SET_FS=n, > isn't sg_check_file_access() failing to detect kernel context? sg_check_file_access does exactly the right thing - fail for all kernel threads as those can't

Re: [PATCH] vdpa_sim: use iova module to allocate IOVA addresses

2020-12-22 Thread Stefano Garzarella
On Wed, Dec 23, 2020 at 11:43:40AM +0800, Jason Wang wrote: On 2020/12/23 上午1:45, Stefano Garzarella wrote: The identical mapping used until now created issues when mapping different virtual pages with the same physical address. To solve this issue, we can use the iova module, to handle the

Re: [PATCH] crypto: keembay-ocs-aes - Add dependency on HAS_IOMEM

2020-12-22 Thread Herbert Xu
On Thu, Dec 17, 2020 at 04:35:10PM +, Daniele Alessandrelli wrote: > From: Daniele Alessandrelli > > Add dependency for CRYPTO_DEV_KEEMBAY_OCS_AES_SM4 on HAS_IOMEM to > prevent build failures. > > Fixes: 88574332451380f4 ("crypto: keembay - Add support for Keem Bay OCS > AES/SM4") >

Re: [PATCH bpf-next 1/2] bpf: Add a bpf_kallsyms_lookup helper

2020-12-22 Thread Christoph Hellwig
On Tue, Dec 22, 2020 at 09:17:41PM +0100, Florent Revest wrote: > On Tue, Dec 22, 2020 at 3:18 PM Christoph Hellwig wrote: > > > > FYI, there is a reason why kallsyms_lookup is not exported any more. > > I don't think adding that back through a backdoor is a good idea. > > Did you maybe mean

Re: [PATCH] crypto: CRYPTO_DEV_KEEMBAY_OCS_AES_SM4 should depend on ARCH_KEEMBAY

2020-12-22 Thread Herbert Xu
On Wed, Dec 16, 2020 at 02:14:59PM +0100, Geert Uytterhoeven wrote: > The Intel Keem Bay Offload and Crypto Subsystem (OCS) is only present on > Intel Keem Bay SoCs. Hence add a dependency on ARCH_KEEMBAY, to prevent > asking the user about this driver when configuring a kernel without > Intel

[PATCH] arm64: dts: mt8192: add thermal zones, cooling map and trips

2020-12-22 Thread Michael Kao
Add thermal zone node to support mt8192 read temperature. Thermal throttle will start at 68C and the target temperature is 85C. This patch depends on [1]. [1]https://patchwork.kernel.org/project/linux-mediatek/patch/20201221061018.18503-3-yz...@mediatek.com/ Signed-off-by: Michael Kao ---

Re: [PATCH v1 0/5] dm: dm-user: New target that proxies BIOs to userspace

2020-12-22 Thread Christoph Hellwig
FYI, a few years ago I spent some time helping a customer to prepare their block device in userspace using fuse code for upstreaming, but at some point they abandoned the project. But if for some reason we don't want to use nbd I think a driver using the fuse infrastructure would be the next

[PATCH] thermal: cpufreq_cooling: fix slab OOB issue

2020-12-22 Thread Michael Kao
From: brian-sy yang Slab OOB issue is scanned by KASAN in cpu_power_to_freq(). If power is limited below the power of OPP0 in EM table, it will cause slab out-of-bound issue with negative array index. Return the lowest frequency if limited power cannot found a suitable OPP in EM table to fix

RE: [PATCH v1] scsi: ufs-mediatek: Enable UFSHCI_QUIRK_SKIP_MANUAL_WB_FLUSH_CTRL

2020-12-22 Thread Avri Altman
> > On 2020-12-23 12:19, Stanley Chu wrote: > > Hi Can, > > > > On Tue, 2020-12-22 at 19:34 +0800, Can Guo wrote: > >> On 2020-12-22 15:29, Stanley Chu wrote: > >> > Flush during hibern8 is sufficient on MediaTek platforms, thus > >> > enable UFSHCI_QUIRK_SKIP_MANUAL_WB_FLUSH_CTRL to skip >

Der Betrag von 500.000,00 Euro wurde Ihnen gespendet. Kontakt: manuelfranco4l...@gmail.com

2020-12-22 Thread Samaila Sali
Manuel Franco hat Ihnen 500.000,00 Euro gespendet. Er hat am 23. April 2019 den Powerball-Jackpot in Höhe von 758,7 Millionen US-Dollar gewonnen. Weitere Informationen erhalten Sie per E-Mail unter: manuelfranco4l...@gmail.com

Re: [PATCH] erofs: support direct IO for uncompressed file

2020-12-22 Thread Christoph Hellwig
On Wed, Dec 23, 2020 at 03:39:01AM +0800, Gao Xiang wrote: > Hi Christoph, > > On Tue, Dec 22, 2020 at 02:22:34PM +, Christoph Hellwig wrote: > > Please do not add new callers of __blockdev_direct_IO and use the modern > > iomap variant instead. > > We've talked about this topic before. The

Re: [LKP] [locking/rwsem] 617f3ef951: unixbench.score -21.2% regression

2020-12-22 Thread Xing Zhengjun
Hi Waiman, Do you have time to look at this? Thanks. As you describe in commit: 617f3ef95177840c77f59c2aec1029d27d5547d6 ("locking/rwsem: Remove reader optimistic spinning"), The patch that disables reader optimistic spinning shows reduced performance at lightly loaded cases, so for

Re: [PATCH v6 1/2] lib/string.c: add __sysfs_match_string_with_gaps() helper

2020-12-22 Thread Alexandru Ardelean
On Tue, Dec 22, 2020 at 3:43 PM Andy Shevchenko wrote: > > On Tue, Dec 22, 2020 at 3:09 PM Alexandru Ardelean > wrote: > > > > The original docstring of the __sysfs_match_string() and match_string() > > helper, implied that -1 could be used to search through NULL terminated > > arrays, and

Re: [PATCH AUTOSEL 5.4 008/130] staging: wimax: depends on NET

2020-12-22 Thread Greg Kroah-Hartman
On Tue, Dec 22, 2020 at 09:16:11PM -0500, Sasha Levin wrote: > From: Randy Dunlap > > [ Upstream commit 9364a2cf567187c0a075942c22d1f434c758de5d ] > > Fix build errors when CONFIG_NET is not enabled. E.g. (trimmed): > > ld: drivers/staging/wimax/op-msg.o: in function `wimax_msg_alloc': >

Re: [PATCH] mm/uaccess: Use 'unsigned long' to placate UBSAN warnings, again

2020-12-22 Thread Randy Dunlap
On 12/22/20 9:04 PM, Josh Poimboeuf wrote: > GCC 7 has a known bug where UBSAN ignores '-fwrapv' and generates false > signed-overflow-UB warnings. The type mismatch between 'i' and > 'nr_segs' in copy_compat_iovec_from_user() is causing such a warning, > which also happens to violate uaccess

[PATCH v2 2/2] arm64: dts: mt6779: Support ufshci and ufsphy

2020-12-22 Thread Stanley Chu
Support UFS on MT6779 platforms by adding ufshci and ufsphy nodes in dts file. Reviewed-by: Hanks Chen Signed-off-by: Stanley Chu --- arch/arm64/boot/dts/mediatek/mt6779.dtsi | 36 +++- 1 file changed, 35 insertions(+), 1 deletion(-) diff --git

[PATCH v2 0/2] arm64: Support Universal Flash Storage on MediaTek MT6779 platform

2020-12-22 Thread Stanley Chu
Hi, This series adds UFS (Universal Flash Storage) support on MediaTek MT6779 SoC platform. Changes since v1: - Fix irq attribute in dts in patch [2/2] Stanley Chu (2): arm64: configs: Support Universal Flash Storage on MediaTek platforms arm64: dts: mt6779: Support ufshci and ufsphy

[PATCH v2 1/2] arm64: configs: Support Universal Flash Storage on MediaTek platforms

2020-12-22 Thread Stanley Chu
Support UFS on MediaTek platforms by enabling CONFIG_SCSI_UFS_MEDIATEK. Reviewed-by: Hanks Chen Signed-off-by: Stanley Chu --- arch/arm64/configs/defconfig | 1 + 1 file changed, 1 insertion(+) diff --git a/arch/arm64/configs/defconfig b/arch/arm64/configs/defconfig index

Re: [PATCHSET] saner elf compat

2020-12-22 Thread Al Viro
On Wed, Dec 23, 2020 at 07:03:20AM +, Al Viro wrote: Argh Wrong commit blamed - the parent of the correct one. It's actually 2aa362c49c31 ("coredump: extend core dump note section to contain file names of mapped files"). My apologies - fat-fingered cut'n'paste...

Re: [PATCH AUTOSEL 5.4 057/130] ALSA: usb-audio: Check valid altsetting at parsing rates for UAC2/3

2020-12-22 Thread Takashi Iwai
On Wed, 23 Dec 2020 03:17:00 +0100, Sasha Levin wrote: > > From: Takashi Iwai > > [ Upstream commit 93db51d06b32227319dae2ac289029ccf1b33181 ] > > The current driver code assumes blindly that all found sample rates for > the same endpoint from the UAC2 and UAC3 descriptors can be used no >

RE: [v2 1/2] rtc: pcf2127: properly set flag WD_CD for rtc chips(pcf2129, pca2129)

2020-12-22 Thread Biwen Li
Hi Alexandre, Any comments? Regards, Biwen Li > -Original Message- > From: Biwen Li > Sent: 2020年12月2日 11:19 > To: Leo Li ; alexandre.bell...@bootlin.com; Anson > Huang ; Aisheng Dong > Cc: linux-kernel@vger.kernel.org; Jiafei Pan ; > linux-...@vger.kernel.org; Biwen Li > Subject: [v2

Re: [PATCHSET] saner elf compat

2020-12-22 Thread Al Viro
[Denys Vlasenko cc'd] On Wed, Dec 16, 2020 at 09:44:53AM +, Maciej W. Rozycki wrote: > On Wed, 16 Dec 2020, Al Viro wrote: > > > > It may be worth pushing through GDB's gdb.threads/tls-core.exp test > > > case, > > > making sure no UNSUPPORTED results have been produced due to resource >

Re: [PATCH] ubifs: Fix read out-of-bounds in ubifs_jnl_write_inode()

2020-12-22 Thread Zhihao Cheng
在 2020/12/23 14:28, Chengsong Ke 写道: Reviewed-by: Zhihao Cheng From: kechengsong ubifs_jnl_write_inode() probably cause read out-of-bounds in some situation. There is kasan stack: [ 336.432159] BUG: KASAN: slab-out-of-bounds in ecc_sw_hamming_calculate+0x1dc/0x7d0 [ 336.433634] Read of

Re: [PATCH v3 3/4] x86/signal: Prevent an alternate stack overflow before a signal delivery

2020-12-22 Thread Jann Horn
On Wed, Dec 23, 2020 at 2:57 AM Chang S. Bae wrote: > The kernel pushes data on the userspace stack when entering a signal. If > using a sigaltstack(), the kernel precisely knows the user stack size. > > When the kernel knows that the user stack is too small, avoid the overflow > and do an

Re: [PATCH] powerpc/32s: Fix RTAS machine check with VMAP stack

2020-12-22 Thread Christophe Leroy
Le 22/12/2020 à 08:11, Christophe Leroy a écrit : When we have VMAP stack, exception prolog 1 sets r1, not r11. But exception prolog 1 uses r1 to setup r1 when machine check happens in kernel. So r1 must be restored when the branch is not taken. See subsequent patch I just sent out.

Re: [v2] i2c: mediatek: Move suspend and resume handling to NOIRQ phase

2020-12-22 Thread Qii Wang
Hi sirs: If there is no new comment, I will resent it in 5.11.

[PATCH v1 2/2] perf arm64: Add argument support for SDT

2020-12-22 Thread Leo Yan
Now the two OP formats are used for SDT marker argument in Arm64 ELF, one format is genreal register xNUM (e.g. x1, x2, etc), another is for using stack pointer to access local variables (e.g. [sp], [sp, 8]). This patch adds support SDT marker argument for Arm64, it parses OP and converts to

[PATCH] powerpc/32s: Fix RTAS machine check with VMAP stack - again

2020-12-22 Thread Christophe Leroy
When it is not a RTAS machine check, don't trash r1 because it is needed by prolog 1. Fixes: 9c7422b92cb2 ("powerpc/32s: Fix RTAS machine check with VMAP stack") Cc: sta...@vger.kernel.org Signed-off-by: Christophe Leroy --- Sorry Michael for this last minute fix of the fix.

[PATCH v1 1/2] perf probe: Fixup Arm64 SDT arguments

2020-12-22 Thread Leo Yan
Arm64 ELF section '.note.stapsdt' uses string format "-4@[sp, NUM]" if the probe is to access data in stack, e.g. below is an example for dumping Arm64 ELF file and shows the argument format: Arguments: -4@[sp, 12] -4@[sp, 8] -4@[sp, 4] Comparing against other archs' argument format, Arm64's

[PATCH v1 0/2] perf arm64: Support SDT

2020-12-22 Thread Leo Yan
This patch is to enable SDT on Arm64. Since Arm64 SDT marker in ELF file is different from other archs, especially for using stack pointer (sp) to retrieve data for local variables, patch 01 is used to fixup the arguments for this special case. Patch 02 is to add argument support for Arm64 SDT.

[PATCH] kconfig: remove 'kvmconfig' and 'xenconfig' shorthands

2020-12-22 Thread Masahiro Yamada
Linux 5.10 is out. Remove the 'kvmconfig' and 'xenconfig' shorthands as previously announced. Signed-off-by: Masahiro Yamada --- scripts/kconfig/Makefile | 10 -- 1 file changed, 10 deletions(-) diff --git a/scripts/kconfig/Makefile b/scripts/kconfig/Makefile index

Re: [PATCH] sh: check return code of request_irq

2020-12-22 Thread Masahiro Yamada
On Wed, Dec 23, 2020 at 5:54 AM Nick Desaulniers wrote: > > request_irq is marked __must_check, but the call in shx3_prepare_cpus > has a void return type, so it can't propagate failure to the caller. > Follow cues from hexagon and just print an error. > > Fixes: c7936b9abcf5 ("sh: smp: Hook in

Re: linux-next: Tree for Dec 21 (objtool warning)

2020-12-22 Thread Randy Dunlap
On 12/22/20 9:09 PM, Josh Poimboeuf wrote: > On Mon, Dec 21, 2020 at 08:03:17AM -0800, Randy Dunlap wrote: >> On 12/20/20 7:18 PM, Stephen Rothwell wrote: >>> Hi all, >>> >>> News: there will be no linux-next releases between Dec 24 and Jan >>> 3 inclusive. >>> >>> Please do not add any v5.12

[PATCH] mm/buffer.c: remove the macro check in check_irqs_on()

2020-12-22 Thread Hui Su
The macro irqs_disabled is always defined in include/linux/irqflags.h, so we don't need the macro check. Signed-off-by: Hui Su --- fs/buffer.c | 2 -- 1 file changed, 2 deletions(-) diff --git a/fs/buffer.c b/fs/buffer.c index 32647d2011df..34b505542d96 100644 --- a/fs/buffer.c +++

[PATCH v2 1/3] iommu/vt-d: Move intel_iommu info from struct intel_svm to struct intel_svm_dev

2020-12-22 Thread Liu Yi L
Current struct intel_svm has a field to record the struct intel_iommu pointer for a PASID bind. And struct intel_svm will be shared by all the devices bind to the same process. The devices may be behind different DMAR units. As the iommu driver code uses the intel_iommu pointer stored in intel_svm

[PATCH] ubifs: Fix read out-of-bounds in ubifs_jnl_write_inode()

2020-12-22 Thread Chengsong Ke
From: kechengsong ubifs_jnl_write_inode() probably cause read out-of-bounds in some situation. There is kasan stack: [ 336.432159] BUG: KASAN: slab-out-of-bounds in ecc_sw_hamming_calculate+0x1dc/0x7d0 [ 336.433634] Read of size 4 at addr 888019612ff8 by task kworker/u8:4/135 [

[PATCH v2 3/3] iommu/vt-d: Fix ineffective devTLB invalidation for subdevices

2020-12-22 Thread Liu Yi L
iommu_flush_dev_iotlb() is called to invalidate caches on device. It only loops the devices which are full-attached to the domain. For sub-devices, this is ineffective. This results in invalid caching entries left on the device. Fix it by adding loop for subdevices as well. Also, the domain->

[PATCH v2 2/3] iommu/vt-d: Track device aux-attach with subdevice_domain_info

2020-12-22 Thread Liu Yi L
In the existing code, loop all devices attached to a domain does not include sub-devices attached via iommu_aux_attach_device(). This was found by when I'm working on the belwo patch, There is no device in the domain->devices list, thus unable to get the cap and ecap of iommu unit. But this

[PATCH v2 0/3] iommu/vt-d: Misc fixes on scalable mode

2020-12-22 Thread Liu Yi L
This patchset aims to fix a bug regards to native SVM usage, and also several bugs around subdevice (attached to device via auxiliary manner) tracking and ineffective device_tlb flush. Liu Yi L (3): iommu/vt-d: Move intel_iommu info from struct intel_svm to struct intel_svm_dev

[PATCH] x86/iommu: Fix two minimal issues in check_iommu_entries()

2020-12-22 Thread Zhenzhong Duan
check_iommu_entries() checks for cyclic dependency in iommu entries and fixes the cyclic dependency by setting x->depend to NULL. But this repairing isn't correct if q is in front of p, there will be "EXECUTION ORDER INVALID!" report following. Fix it by NULLing whichever in the front. The second

Re: [PATCH] Bluetooth: btrtl: Add null check in setup

2020-12-22 Thread Marcel Holtmann
Hi Abhishek, > btrtl_dev->ic_info is only available from the controller on cold boot > (the lmp subversion matches the device model and this is used to look up > the ic_info). On warm boots (firmware already loaded), > btrtl_dev->ic_info is null. > > Fixes: 05672a2c14a4 (Bluetooth: btrtl: Enable

Re: [PATCH v4] ovl: fix dentry leak in ovl_get_redirect

2020-12-22 Thread Liangyan
Thanks Viro. @Miklos, can you please advise? On 20/12/22 上午11:26, Al Viro wrote: On Tue, Dec 22, 2020 at 11:06:26AM +0800, Liangyan wrote: Cc: Fixes: a6c606551141 ("ovl: redirect on rename-dir") Signed-off-by: Liangyan Reviewed-by: Joseph Qi Suggested-by: Al Viro Fine by me... I can

Re: [PATCH] Revert "kbuild: avoid static_assert for genksyms"

2020-12-22 Thread Masahiro Yamada
On Sun, Dec 20, 2020 at 3:40 AM Masahiro Yamada wrote: > > This reverts commit 14dc3983b5dff513a90bd5a8cc90acaf7867c3d0. > > Macro Elver had sent a fix proper fix earlier, and also pointed out > corner cases: > > "I guess what you propose is simpler, but might still have corner cases > where we

drivers/acpi/x86/s2idle.c:395:13: sparse: sparse: restricted suspend_state_t degrades to integer

2020-12-22 Thread kernel test robot
tree: https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git master head: 614cb5894306cfa2c7d9b6168182876ff5948735 commit: fef98671194be005853cbbf51b164a3927589b64 ACPI: PM: s2idle: Move x86-specific code to the x86 directory date: 5 days ago config:

[PATCH] blokc/blk-merge: remove the next_bvec label in __blk_bios_map_sg()linux-bl...@vger.kernel.org (open list:BLOCK LAYER)

2020-12-22 Thread sh
remove the next_bvec label in __blk_bios_map_sg(), simplify the logic of traversal bvec. Signed-off-by: sh --- block/blk-merge.c | 8 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/block/blk-merge.c b/block/blk-merge.c index 808768f6b174..aa113cbc0f35 100644 ---

Re: [PATCH v2 15/48] opp: Support set_opp() customization without requiring to use regulators

2020-12-22 Thread Viresh Kumar
On 17-12-20, 21:06, Dmitry Osipenko wrote: > Support set_opp() customization without requiring to use regulators. This > is needed by drivers which want to use dev_pm_opp_set_rate() for changing > rates of a multiple clocks and don't need to touch regulator. > > One example is NVIDIA Tegra30/114

RE: [PATCH 2/3] aspeed-video: clear spurious interrupt bits unconditionally

2020-12-22 Thread Ryan Chen
> -Original Message- > From: Zev Weiss > Sent: Wednesday, December 23, 2020 11:54 AM > To: Ryan Chen > Cc: Joel Stanley ; Eddie James ; > Mauro Carvalho Chehab ; Andrew Jeffery > ; linux-me...@vger.kernel.org; OpenBMC Maillist > ; Linux ARM > ; linux-aspeed > ; Linux Kernel Mailing List

[PATCH v2] HID: Add Wireless Radio Control feature for Chicony devices

2020-12-22 Thread Jian-Hong Pan
Some Chicony's keyboards support airplane mode hotkey (Fn+F2) with "Wireless Radio Control" feature. For example, the wireless keyboard [04f2:1236] shipped with ASUS all-in-one desktop. After consulting Chicony for this hotkey, learned the device will send with 0x11 as the report ID and 0x1 as

Re: [PATCH v2 28/48] soc/tegra: Introduce core power domain driver

2020-12-22 Thread Viresh Kumar
On 22-12-20, 22:39, Dmitry Osipenko wrote: > 22.12.2020 22:21, Dmitry Osipenko пишет: > >>> + if (IS_ERR(opp)) { > >>> + dev_err(>dev, "failed to find OPP for level %u: %pe\n", > >>> + level, opp); > >>> + return PTR_ERR(opp); > >>> + } > >>> + > >>> + err =

[PATCH v2] net/ncsi: Use real net-device for response handler

2020-12-22 Thread John Wang
When aggregating ncsi interfaces and dedicated interfaces to bond interfaces, the ncsi response handler will use the wrong net device to find ncsi_dev, so that the ncsi interface will not work properly. Here, we use the original net device to fix it. Fixes: 138635cc27c9 ("net/ncsi: NCSI response

[PATCH] drm/hisilicon: Add load and unload callback functions

2020-12-22 Thread Tian Tao
Add the callback functions of drm_driver structure member functions load and unload, no need to call load in the hibmc_pci_probe function and unload in the hibmc_pci_remove function. Signed-off-by: Tian Tao --- drivers/gpu/drm/hisilicon/hibmc/hibmc_drm_drv.c | 17 +++-- 1 file

[PATCH v13 1/6] locking/qspinlock: Rename mcs lock/unlock macros and make them more generic

2020-12-22 Thread Alex Kogan
The mcs unlock macro (arch_mcs_lock_handoff) should accept the value to be stored into the lock argument as another argument. This allows using the same macro in cases where the value to be stored when passing the lock is different from 1. Signed-off-by: Alex Kogan Reviewed-by: Steve Sistare

[PATCH v13 3/6] locking/qspinlock: Introduce CNA into the slow path of qspinlock

2020-12-22 Thread Alex Kogan
In CNA, spinning threads are organized in two queues, a primary queue for threads running on the same node as the current lock holder, and a secondary queue for threads running on other nodes. After acquiring the MCS lock and before acquiring the spinlock, the MCS lock holder checks whether the

[PATCH v13 5/6] locking/qspinlock: Avoid moving certain threads between waiting queues in CNA

2020-12-22 Thread Alex Kogan
Prohibit moving certain threads (e.g., in irq and nmi contexts) to the secondary queue. Those prioritized threads will always stay in the primary queue, and so will have a shorter wait time for the lock. Signed-off-by: Alex Kogan Reviewed-by: Steve Sistare Reviewed-by: Waiman Long ---

[PATCH v13 2/6] locking/qspinlock: Refactor the qspinlock slow path

2020-12-22 Thread Alex Kogan
Move some of the code manipulating the spin lock into separate functions. This would allow easier integration of alternative ways to manipulate that lock. Signed-off-by: Alex Kogan Reviewed-by: Steve Sistare Reviewed-by: Waiman Long --- kernel/locking/qspinlock.c | 38

[PATCH v13 6/6] locking/qspinlock: Introduce the shuffle reduction optimization into CNA

2020-12-22 Thread Alex Kogan
This performance optimization chooses probabilistically to avoid moving threads from the main queue into the secondary one when the secondary queue is empty. It is helpful when the lock is only lightly contended. In particular, it makes CNA less eager to create a secondary queue, but does not

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

2020-12-22 Thread Alex Kogan
Keep track of the time the thread at the head of the secondary queue has been waiting, and force inter-node handoff once this time passes a preset threshold. The default value for the threshold (10ms) can be overridden with the new kernel boot command-line option "numa_spinlock_threshold". The ms

[PATCH v13 0/6] Add NUMA-awareness to qspinlock

2020-12-22 Thread Alex Kogan
Change from v12: Added a shuffle reduction optimization (SRO, last patch in the series) in order to address the regression in unixbench. Reported-by: kernel test robot I note that despite my initial experiments, a more thorough testing on our system did not reproduce the

Re: [External] Re: [PATCH] net/ncsi: Use real net-device for response handler

2020-12-22 Thread John Wang
On Wed, Dec 23, 2020 at 10:25 AM Jakub Kicinski wrote: > > On Tue, 22 Dec 2020 10:38:21 -0800 Samuel Mendoza-Jonas wrote: > > On Tue, 2020-12-22 at 06:13 +, Joel Stanley wrote: > > > On Sun, 20 Dec 2020 at 12:40, John Wang wrote: > > > > When aggregating ncsi interfaces and dedicated

Re: [PATCH v3 09/24] wfx: add hwio.c/hwio.h

2020-12-22 Thread Kalle Valo
Jérôme Pouiller writes: > On Tuesday 22 December 2020 16:27:01 CET Greg Kroah-Hartman wrote: >> >> On Tue, Dec 22, 2020 at 05:10:11PM +0200, Kalle Valo wrote: >> > Jerome Pouiller writes: >> > >> > > +/* >> > > + * Internal helpers. >> > > + * >> > > + * About CONFIG_VMAP_STACK: >> > > + *

[PATCH 1/3] objtool: Refactor ORC section generation

2020-12-22 Thread Josh Poimboeuf
Decouple ORC entries from instructions. This simplifies the control/data flow, and is going to make it easier to support alternative instructions which change the stack layout. Signed-off-by: Josh Poimboeuf --- tools/objtool/Makefile | 4 - tools/objtool/arch.h| 4 -

[PATCH 2/3] objtool: Add 'alt_group' struct

2020-12-22 Thread Josh Poimboeuf
Create a new struct associated with each group of alternatives instructions. This will help with the removal of fake jumps, and more importantly with adding support for stack layout changes in alternatives. Signed-off-by: Josh Poimboeuf --- tools/objtool/check.c | 29

[PATCH 3/3] objtool: Support stack layout changes in alternatives

2020-12-22 Thread Josh Poimboeuf
The ORC unwinder showed a warning [1] which revealed the stack layout didn't match what was expected. The problem was that paravirt patching had replaced "CALL *pv_ops.irq.save_fl" with "PUSHF;POP". That changed the stack layout between the PUSHF and the POP, so unwinding from an interrupt which

[PATCH 0/3] Alternatives vs ORC, a slightly easier way

2020-12-22 Thread Josh Poimboeuf
These patches replace Peter's "Alternatives vs ORC, the hard way". The end result should be the same (support for paravirt patching's using of alternatives which modify the stack). Josh Poimboeuf (3): objtool: Refactor ORC section generation objtool: Add 'alt_group' struct objtool: Support

Re: [PATCH v3 03/24] wfx: add Makefile/Kconfig

2020-12-22 Thread Kalle Valo
Jérôme Pouiller writes: > On Tuesday 22 December 2020 16:02:38 CET Kalle Valo wrote: >> Jerome Pouiller writes: >> >> > From: Jérôme Pouiller >> > >> > Signed-off-by: Jérôme Pouiller >> >> [...] >> >> > +wfx-$(CONFIG_SPI) += bus_spi.o >> > +wfx-$(subst m,y,$(CONFIG_MMC)) += bus_sdio.o >>

Re: linux-next: Tree for Dec 21 (objtool warning)

2020-12-22 Thread Josh Poimboeuf
On Mon, Dec 21, 2020 at 08:03:17AM -0800, Randy Dunlap wrote: > On 12/20/20 7:18 PM, Stephen Rothwell wrote: > > Hi all, > > > > News: there will be no linux-next releases between Dec 24 and Jan > > 3 inclusive. > > > > Please do not add any v5.12 destined code to your linux-next included > >

Re: [PATCH v13 4/6] powerpc: Delete unused function delete_fdt_mem_rsv()

2020-12-22 Thread Lakshmi Ramasubramanian
On 12/22/20 5:08 PM, Thiago Jung Bauermann wrote: Lakshmi Ramasubramanian writes: delete_fdt_mem_rsv() defined in "arch/powerpc/kexec/file_load.c" has been renamed to fdt_find_and_del_mem_rsv(), and moved to "drivers/of/kexec.c". Remove delete_fdt_mem_rsv() in

[PATCH] mm/uaccess: Use 'unsigned long' to placate UBSAN warnings, again

2020-12-22 Thread Josh Poimboeuf
GCC 7 has a known bug where UBSAN ignores '-fwrapv' and generates false signed-overflow-UB warnings. The type mismatch between 'i' and 'nr_segs' in copy_compat_iovec_from_user() is causing such a warning, which also happens to violate uaccess rules: lib/iov_iter.o: warning: objtool:

Re: [PATCH v13 2/6] powerpc: Move arch independent ima kexec functions to drivers/of/kexec.c

2020-12-22 Thread Lakshmi Ramasubramanian
On 12/22/20 4:40 PM, Thiago Jung Bauermann wrote: Lakshmi Ramasubramanian writes: On 12/22/20 11:45 AM, Mimi Zohar wrote: On Tue, 2020-12-22 at 10:53 -0800, Lakshmi Ramasubramanian wrote: On 12/22/20 6:26 AM, Mimi Zohar wrote: Hi Mimi, On Sat, 2020-12-19 at 09:57 -0800, Lakshmi

Re: [PATCH v13 2/6] powerpc: Move arch independent ima kexec functions to drivers/of/kexec.c

2020-12-22 Thread Lakshmi Ramasubramanian
On 12/22/20 4:19 PM, Thiago Jung Bauermann wrote: Lakshmi Ramasubramanian writes: The functions defined in "arch/powerpc/kexec/ima.c" handle setting up and freeing the resources required to carry over the IMA measurement list from the current kernel to the next kernel across kexec system

Re: [PATCH v13 2/6] powerpc: Move arch independent ima kexec functions to drivers/of/kexec.c

2020-12-22 Thread Lakshmi Ramasubramanian
On 12/22/20 4:48 PM, Thiago Jung Bauermann wrote: Actually, I have one more comment on this patch: Lakshmi Ramasubramanian writes: diff --git a/arch/powerpc/kexec/file_load.c b/arch/powerpc/kexec/file_load.c index 956bcb2d1ec2..9f3ec0b239ef 100644 --- a/arch/powerpc/kexec/file_load.c +++

UBSAN: shift-out-of-bounds in vhci_hub_control

2020-12-22 Thread syzbot
Hello, syzbot found the following issue on: HEAD commit:a409ed15 Merge tag 'gpio-v5.11-1' of git://git.kernel.org/.. git tree: upstream console output: https://syzkaller.appspot.com/x/log.txt?x=1053b62350 kernel config: https://syzkaller.appspot.com/x/.config?x=f7c39e7211134bc0

linux-next: Tree for Dec 23

2020-12-22 Thread Stephen Rothwell
Hi all, News: there will be no linux-next releases between Dec 24 and Jan 3 inclusive. Please do not add any v5.12 destined code to your linux-next included branches until after v5.11-rc1 has been released. Changes since 20201222: Non-merge commits (relative to Linus' tree): 923 941 files

Re: [PATCH v1] scsi: ufs-mediatek: Enable UFSHCI_QUIRK_SKIP_MANUAL_WB_FLUSH_CTRL

2020-12-22 Thread Can Guo
On 2020-12-23 12:19, Stanley Chu wrote: Hi Can, On Tue, 2020-12-22 at 19:34 +0800, Can Guo wrote: On 2020-12-22 15:29, Stanley Chu wrote: > Flush during hibern8 is sufficient on MediaTek platforms, thus > enable UFSHCI_QUIRK_SKIP_MANUAL_WB_FLUSH_CTRL to skip enabling > fWriteBoosterBufferFlush

Re: [PATCH v2 19/48] opp: Fix adding OPP entries in a wrong order if rate is unavailable

2020-12-22 Thread Viresh Kumar
On 22-12-20, 22:19, Dmitry Osipenko wrote: > 22.12.2020 12:12, Viresh Kumar пишет: > > On 17-12-20, 21:06, Dmitry Osipenko wrote: > >> Fix adding OPP entries in a wrong (opposite) order if OPP rate is > >> unavailable. The OPP comparison is erroneously skipped if OPP rate is > >> missing, thus

Re: [PATCH] perf stat: Create '--add-default' option to append default list

2020-12-22 Thread Jin, Yao
On 12/23/2020 8:56 AM, Jin, Yao wrote: Hi Arnaldo, On 12/23/2020 12:15 AM, Arnaldo Carvalho de Melo wrote: Em Tue, Dec 22, 2020 at 09:11:31AM +0800, Jin Yao escreveu: The event default list includes the most common events which are widely used by users. But with -e option, the current perf

Re: [PATCH phy] PHY: Ingenic: fix unconditional build of phy-ingenic-usb

2020-12-22 Thread Vinod Koul
On 22-12-20, 13:10, Alexander Lobakin wrote: > Currently drivers/phy/ingenic/Makefile adds phy-ingenic-usb to targets > not depending on actual Kconfig symbol CONFIG_PHY_INGENIC_USB, so this > driver always gets built[-in] on every system. > Add missing dependency. Applied, thanks -- ~Vinod

[PATCH v2] arm64: dts: mt8192: add nor_flash device node

2020-12-22 Thread Bayi Cheng
From: bayi cheng add nor_flash device node Change-Id: I79f0228529bd8a33e5f354b7a861a4ec8d92e9ba Signed-off-by: bayi cheng --- Change in v2: 1: add dependent patch of arm soc 2: change compatible name Depends on: https://patchwork.kernel.org/patch/11713559/ [v4,1/3] arm64: dts: Add Mediatek

Re: [PATCH v2 14/48] opp: Filter out OPPs based on availability of a required-OPP

2020-12-22 Thread Viresh Kumar
On 22-12-20, 22:17, Dmitry Osipenko wrote: > 22.12.2020 11:59, Viresh Kumar пишет: > > On 17-12-20, 21:06, Dmitry Osipenko wrote: > >> A required OPP may not be available, and thus, all OPPs which are using > >> this required OPP should be unavailable too. > >> > >> Signed-off-by: Dmitry Osipenko

Re: [PATCH v1] scsi: ufs-mediatek: Enable UFSHCI_QUIRK_SKIP_MANUAL_WB_FLUSH_CTRL

2020-12-22 Thread Stanley Chu
Hi Can, On Tue, 2020-12-22 at 19:34 +0800, Can Guo wrote: > On 2020-12-22 15:29, Stanley Chu wrote: > > Flush during hibern8 is sufficient on MediaTek platforms, thus > > enable UFSHCI_QUIRK_SKIP_MANUAL_WB_FLUSH_CTRL to skip enabling > > fWriteBoosterBufferFlush during WriteBooster

Re: [PATCH v2 11/48] opp: Add dev_pm_opp_find_level_ceil()

2020-12-22 Thread Viresh Kumar
On 22-12-20, 22:15, Dmitry Osipenko wrote: > 22.12.2020 09:42, Viresh Kumar пишет: > > On 17-12-20, 21:06, Dmitry Osipenko wrote: > >> Add a ceil version of the dev_pm_opp_find_level(). It's handy to have if > >> levels don't start from 0 in OPP table and zero usually means a minimal > >> level. >

Re: [PATCH v3 3/5] RISC-V: Align the .init.text section

2020-12-22 Thread Palmer Dabbelt
On Fri, 18 Dec 2020 00:19:09 PST (-0800), ati...@atishpatra.org wrote: On Thu, Dec 17, 2020 at 12:33 AM Atish Patra wrote: On Wed, Dec 16, 2020 at 10:51 PM Palmer Dabbelt wrote: > > On Tue, 15 Dec 2020 22:02:54 PST (-0800), Palmer Dabbelt wrote: > > On Wed, 04 Nov 2020 16:04:37 PST (-0800),

[PATCH v1 2/2] arm64: dts: mt6779: Support ufshci and ufsphy

2020-12-22 Thread Stanley Chu
Support UFS on MT6779 platforms by adding ufshci and ufsphy nodes in dts file. Reviewed-by: Hanks Chen Signed-off-by: Stanley Chu --- arch/arm64/boot/dts/mediatek/mt6779.dtsi | 36 +++- 1 file changed, 35 insertions(+), 1 deletion(-) diff --git

[PATCH v1 1/2] arm64: configs: Support Universal Flash Storage on MediaTek platforms

2020-12-22 Thread Stanley Chu
Support UFS on MediaTek platforms by enabling CONFIG_SCSI_UFS_MEDIATEK. Reviewed-by: Hanks Chen Signed-off-by: Stanley Chu --- arch/arm64/configs/defconfig | 1 + 1 file changed, 1 insertion(+) diff --git a/arch/arm64/configs/defconfig b/arch/arm64/configs/defconfig index

[PATCH v1 0/2] arm64: Support Universal Flash Storage on MediaTek MT6779 platform

2020-12-22 Thread Stanley Chu
Hi, This series adds UFS (Universal Flash Storage) support on MediaTek MT6779 SoC platform. Stanley Chu (2): arm64: configs: Support Universal Flash Storage on MediaTek platforms arm64: dts: mt6779: Support ufshci and ufsphy arch/arm64/boot/dts/mediatek/mt6779.dtsi | 36

Re: [PATCH 1/2] mm/madvise: allow process_madvise operations on entire memory range

2020-12-22 Thread Suren Baghdasaryan
On Tue, Dec 22, 2020 at 9:48 AM Suren Baghdasaryan wrote: > > On Tue, Dec 22, 2020 at 5:44 AM Christoph Hellwig wrote: > > > > On Fri, Dec 11, 2020 at 09:27:46PM +0100, Jann Horn wrote: > > > > Can we just use one element in iovec to indicate entire address rather > > > > than using up the

mmotm 2020-12-22-20-07 uploaded

2020-12-22 Thread akpm
The mm-of-the-moment snapshot 2020-12-22-20-07 has been uploaded to https://www.ozlabs.org/~akpm/mmotm/ mmotm-readme.txt says README for mm-of-the-moment: https://www.ozlabs.org/~akpm/mmotm/ This is a snapshot of my -mm patch queue. Uploaded at random hopefully more than once a week. You

Re: [PATCH v2 1/2] mm: cma: allocate cma areas bottom-up

2020-12-22 Thread Andrew Morton
On Mon, 21 Dec 2020 09:05:51 -0800 Roman Gushchin wrote: > Subject: [PATCH v3 1/2] mm: cma: allocate cma areas bottom-up i386 allmodconfig: In file included from ./include/vdso/const.h:5, from ./include/linux/const.h:4, from ./include/linux/bits.h:5,

Re: [PATCH] riscv: return -ENOSYS for syscall -1

2020-12-22 Thread Palmer Dabbelt
On Tue, 22 Dec 2020 08:22:19 PST (-0800), tycho@tycho.pizza wrote: On Mon, Dec 21, 2020 at 11:52:00PM +0100, Andreas Schwab wrote: Properly return -ENOSYS for syscall -1 instead of leaving the return value uninitialized. This fixes the strace teststuite. Fixes: 5340627e3fe0 ("riscv: add

Re: [PATCH] HID: Add Wireless Radio Control feature for Chicony devices

2020-12-22 Thread Jian-Hong Pan
Chris Chiu 於 2020年12月23日 週三 上午12:41寫道: > > On Tue, Dec 22, 2020 at 3:41 PM Jian-Hong Pan wrote: > > > > Some Chicony's keyboards support airplane mode hotkey (Fn+F2) with > > "Wireless Radio Control" feature. For example, the wireless keyboard > > [04f2:1236] shipped with ASUS all-in-one

Re: [RFC PATCH 1/3] mm: support hugetlb free page reporting

2020-12-22 Thread Liang Li
> On 12/21/20 11:46 PM, Liang Li wrote: > > Free page reporting only supports buddy pages, it can't report the > > free pages reserved for hugetlbfs case. On the other hand, hugetlbfs > > is a good choice for a system with a huge amount of RAM, because it > > can help to reduce the memory

Re: [PATCH 2/3] aspeed-video: clear spurious interrupt bits unconditionally

2020-12-22 Thread Zev Weiss
On Tue, Dec 22, 2020 at 08:53:33PM CST, Ryan Chen wrote: -Original Message- From: Joel Stanley Sent: Wednesday, December 23, 2020 9:07 AM To: Zev Weiss ; Ryan Chen Cc: Eddie James ; Mauro Carvalho Chehab ; Andrew Jeffery ; linux-me...@vger.kernel.org; OpenBMC Maillist ; Linux ARM ;

[PATCH] checkpatch: Prefer strscpy to strlcpy

2020-12-22 Thread Joe Perches
Prefer strscpy over the deprecated strlcpy function. Requested-by: Andrew Morton Signed-off-by: Joe Perches --- scripts/checkpatch.pl | 6 ++ 1 file changed, 6 insertions(+) diff --git a/scripts/checkpatch.pl b/scripts/checkpatch.pl index 00085308ed9d..27679cc0ec17 100755 ---

Re: [PATCH] vdpa_sim: use iova module to allocate IOVA addresses

2020-12-22 Thread Jason Wang
On 2020/12/23 上午1:45, Stefano Garzarella wrote: The identical mapping used until now created issues when mapping different virtual pages with the same physical address. To solve this issue, we can use the iova module, to handle the IOVA allocation. For semplicity we use an IOVA allocator with

Re: [RFC PATCH 1/3] mm: support hugetlb free page reporting

2020-12-22 Thread Liang Li
> On 12/22/20 11:59 AM, Alexander Duyck wrote: > > On Mon, Dec 21, 2020 at 11:47 PM Liang Li > > wrote: > >> + > >> + if (huge_page_order(h) > MAX_ORDER) > >> + budget = HUGEPAGE_REPORTING_CAPACITY; > >> + else > >> + budget = HUGEPAGE_REPORTING_CAPACITY *

Re: [RFC PATCH 1/3] mm: support hugetlb free page reporting

2020-12-22 Thread Liang Li
> > +hugepage_reporting_cycle(struct page_reporting_dev_info *prdev, > > +struct hstate *h, unsigned int nid, > > +struct scatterlist *sgl, unsigned int *offset) > > +{ > > + struct list_head *list = >hugepage_freelists[nid]; > > +

Re: [PATCH v4 2/2] firmware: arm_scmi: Augment SMC/HVC to allow optional interrupt

2020-12-22 Thread Florian Fainelli
On 12/22/2020 6:56 AM, Jim Quinlan wrote: > The SMC/HVC SCMI transport is modified to allow the completion of an SCMI > message to be indicated by an interrupt rather than the return of the smc > call. This accommodates the existing behavior of the BrcmSTB SCMI > "platform" whose SW is already

Re: [PATCH] mm/userfaultfd: fix memory corruption due to writeprotect

2020-12-22 Thread Yu Zhao
On Tue, Dec 22, 2020 at 09:56:11PM -0500, Andrea Arcangeli wrote: > On Tue, Dec 22, 2020 at 04:39:46PM -0700, Yu Zhao wrote: > > We are talking about non-COW anon pages here -- they can't be mapped > > more than once. So why not just identify them by checking > > page_mapcount == 1 and then

  1   2   3   4   5   6   7   8   9   10   >