Re: [PATCH] virt: acrn: Use vfs_poll() instead of f_op->poll()

2021-02-20 Thread Shuo A Liu
Thanks for the patch. On Fri 19.Feb'21 at 17:26:12 +0800, Yejune Deng wrote: In acrn_irqfd_assign(), use vfs_poll() is a more advanced function, as the same time, modify the definition of events. Signed-off-by: Yejune Deng --- drivers/virt/acrn/irqfd.c | 4 ++-- 1 file changed, 2

Re: [PATCH v2 3/3] crypto: hisilicon/sec - fixes shash test error

2021-02-20 Thread liulongfang
On 2021/2/18 10:06, Herbert Xu wrote: > On Thu, Feb 18, 2021 at 10:01:58AM +0800, liulongfang wrote: >> diff --git a/drivers/crypto/hisilicon/sec2/sec_crypto.c b/drivers/crypto/hisilicon/sec2/sec_crypto.c index d2c4a2c..988faf7 100644 ---

[PATCH v2] net: phy: add Marvell 88X2222 transceiver support

2021-02-20 Thread Ivan Bornyakov
Add basic support for the Marvell 88X multi-speed ethernet transceiver. This PHY provides data transmission over fiber-optic as well as Twinax copper links. The 88X supports 2 ports of 10GBase-R and 1000Base-X on the line-side interface. The host-side interface supports 4 ports of

[PATCH RFC] f2fs: fix to avoid selecting full segment w/ {AT,}SSR allocator

2021-02-20 Thread Chao Yu
In cp disabling mode, there could be a condition - target segment has 128 ckpt valid blocks - GC migrates 128 valid blocks to other segment (segment is still in dirty list) - GC migrates 384 blocks to target segment (segment has 128 cp_vblocks and 384 vblocks) - If GC selects target segment via

[PATCH] scsi: mpt3sas: Do not use GFP_KERNEL in atomic context

2021-02-20 Thread Christophe JAILLET
'mpt3sas_get_port_by_id()' can be called when a spinlock is hold. So use GFP_ATOMIC instead of GFP_KERNEL when allocating memory. Issue spotted by call_kern.cocci: ./drivers/scsi/mpt3sas/mpt3sas_scsih.c:416:42-52: ERROR: function mpt3sas_get_port_by_id called on line 7125 inside lock on line

Re: [PATCH] scsi: pm80xx: switch from 'pci_' to 'dma_' API

2021-02-20 Thread Christophe JAILLET
Please ignore. This one has already been applied, I'va attached the wrong patch. Sorry for the noise. CJ Le 20/02/2021 à 09:31, Christophe JAILLET a écrit : The wrappers in include/linux/pci-dma-compat.h should go away. The patch has been generated with the coccinelle script below and has

[PATCH 3/3] f2fs: update comments for explicit memory barrier

2021-02-20 Thread Chao Yu
Add more detailed comments for explicit memory barrier used by f2fs, in order to enhance code readability. Signed-off-by: Chao Yu --- fs/f2fs/checkpoint.c | 6 +- fs/f2fs/segment.c| 6 +- 2 files changed, 10 insertions(+), 2 deletions(-) diff --git a/fs/f2fs/checkpoint.c

[PATCH 1/3] f2fs: avoid unused f2fs_show_compress_options()

2021-02-20 Thread Chao Yu
LKP reports: fs/f2fs/super.c:1516:20: warning: unused function 'f2fs_show_compress_options' [-Wunused-function] static inline void f2fs_show_compress_options(struct seq_file *seq, Fix this issue by covering f2fs_show_compress_options() with CONFIG_F2FS_FS_COMPRESSION macro. Fixes:

[PATCH 2/3] f2fs: remove unused FORCE_FG_GC macro

2021-02-20 Thread Chao Yu
FORCE_FG_GC was introduced by commit 6aefd93b0137 ("f2fs: introduce background_gc=sync mount option"), but never be used, remove it. Signed-off-by: Chao Yu --- fs/f2fs/segment.h | 2 -- 1 file changed, 2 deletions(-) diff --git a/fs/f2fs/segment.h b/fs/f2fs/segment.h index

[PATCH 2/2] f2fs: fix panic during f2fs_resize_fs()

2021-02-20 Thread Chao Yu
f2fs_resize_fs() hangs in below callstack with testcase: - mkfs 16GB image & mount image - dd 8GB fileA - dd 8GB fileB - sync - rm fileA - sync - resize filesystem to 8GB kernel BUG at segment.c:2484! Call Trace: allocate_segment_by_default+0x92/0xf0 [f2fs] f2fs_allocate_data_block+0x44b/0x7e0

[PATCH 1/2] f2fs: fix to allow migrating fully valid segment

2021-02-20 Thread Chao Yu
F2FS_IOC_FLUSH_DEVICE/F2FS_IOC_RESIZE_FS needs to migrate all blocks of target segment to other place, no matter the segment has partially or fully valid blocks. However, after commit 803e74be04b3 ("f2fs: stop GC when the victim becomes fully valid"), we may skip migration due to target segment

seccomp: Delay filter activation

2021-02-20 Thread Sargun Dhillon
We've run into a problem where attaching a filter can be quite messy business because the filter itself intercepts sendmsg, and other syscalls related to exfiltrating the listener FD. I believe that this problem set has been brought up before, and although there are "simpler" methods of

[PATCH] fs/locks: print full locks information

2021-02-20 Thread Luo Longjun
Commit fd7732e033e3 ("fs/locks: create a tree of dependent requests.") has put blocked locks into a tree. So, with a for loop, we can't check all locks information. To solve this problem, we should traverse the tree by DFS. Signed-off-by: Luo Longjun --- fs/locks.c | 30

Re: [PATCH v1 0/4] ACPI: PCI: Unify printing of messages

2021-02-20 Thread Hanjun Guo
On 2021/2/20 2:14, Rafael J. Wysocki wrote: Hi All, This series gets rid of ACPICA debugging from non-ACPICA code related to PCI (patches [1-3/4]) and replaces direct printk() usage in pci_link.c with pr_*() or acpi_handle_*(). Please refer to the patch changelogs for details. Looks good to

Re: [PATCH RFC] mm/madvise: introduce MADV_POPULATE to prefault/prealloc memory

2021-02-20 Thread David Hildenbrand
On 17.02.21 16:48, David Hildenbrand wrote: When we manage sparse memory mappings dynamically in user space - also sometimes involving MADV_NORESERVE - we want to dynamically populate/ discard memory inside such a sparse memory region. Example users are hypervisors (especially implementing

[PATCH] libbpf: Remove unnecessary conversion to bool

2021-02-20 Thread Jiapeng Chong
Fix the following coccicheck warnings: ./tools/lib/bpf/libbpf.c:1487:43-48: WARNING: conversion to bool not needed here. Reported-by: Abaci Robot Signed-off-by: Jiapeng Chong --- tools/lib/bpf/libbpf.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/tools/lib/bpf/libbpf.c

[PATCH] nvme-core: Switch to using the new API kobj_to_dev()

2021-02-20 Thread Yang Li
fixed the following coccicheck: ./drivers/nvme/host/core.c:3440:60-61: WARNING opportunity for kobj_to_dev() ./drivers/nvme/host/core.c:3679:60-61: WARNING opportunity for kobj_to_dev() Reported-by: Abaci Robot Signed-off-by: Yang Li --- drivers/nvme/host/core.c | 4 ++-- 1 file changed, 2

[RFC PATCH 3/3] selftests/seccomp: Add test for wait killable notifier

2021-02-20 Thread Sargun Dhillon
This adds a test for the positive case of the wait killable notifier, in testing that when the feature is activated the process acts as expected -- in not terminating on a non-fatal signal, and instead queueing it up. There is already a test case for normal handlers and preemption. Signed-off-by:

[RFC PATCH 1/3] seccomp: Refactor notification handler to prepare for new semantics

2021-02-20 Thread Sargun Dhillon
This refactors the user notification code to have a do / while loop around the completion condition. This has a small change in semantic, in that previously we ignored addfd calls upon wakeup if the notification had been responded to, but instead with the new change we check for an outstanding

[RFC PATCH 2/3] seccomp: Add wait_killable semantic to seccomp user notifier

2021-02-20 Thread Sargun Dhillon
The user notifier feature allows for filtering of seccomp notifications in userspace. While the user notifier is handling the syscall, the notifying process can be preempted, thus ending the notification. This has become a growing problem, as Golang has adopted signal based async preemption[1]. In

Re: [PATCH] rtw88: 8822ce: fix wifi disconnect after S3/S4 on HONOR laptop

2021-02-20 Thread Kalle Valo
Hao Chen writes: > When the laptop HONOR MagicBook 14 sleep to S3/S4, the laptop can't > resume. > The dmesg of kernel report: > "[ 99.990168] pcieport :00:01.2: can't change power state > from D3hot to D0 (config space inaccessible) > [ 99.993334] rtw_pci :01:00.0: can't change

[RFC PATCH 0/3] Seccomp non-preemptible notifier

2021-02-20 Thread Sargun Dhillon
This patchset addresses a race condition we've dealt with recently with seccomp. Specifically programs interrupting syscalls while they're in progress. This was exacerbated by Golang's recent adoption of "async preemption", in which they try to interrupt any syscall that's been running for more

Re: [PATCH 01/20] net: phy: realtek: Fix events detection failure in LPI mode

2021-02-20 Thread Serge Semin
On Thu, Feb 11, 2021 at 10:39:41AM +, Russell King - ARM Linux admin wrote: > On Wed, Feb 10, 2021 at 07:47:20PM +0300, Serge Semin wrote: > > On Tue, Feb 09, 2021 at 10:56:46AM +, Russell King - ARM Linux admin > > wrote: > > > On Tue, Feb 09, 2021 at 11:37:29AM +0100, Heiner Kallweit

Re: [PATCH RFC] mm/madvise: introduce MADV_POPULATE to prefault/prealloc memory

2021-02-20 Thread David Hildenbrand
Sorry, for jumping in late ... hugetlb keyword just hit my mail filters :) Sorry for not realizing to cc you before I sent out the man page update :) Yes, it is true that hugetlb reservations are not numa aware. So, even if pages are reserved at mmap time one could still SIGBUS if a fault

[PATCH] powerpc/sstep: Use bitwise instead of arithmetic operator for flags

2021-02-20 Thread Yang Li
Fix the following coccinelle warnings: ./arch/powerpc/lib/sstep.c:1090:20-21: WARNING: sum of probable bitmasks, consider | ./arch/powerpc/lib/sstep.c:1115:20-21: WARNING: sum of probable bitmasks, consider | ./arch/powerpc/lib/sstep.c:1134:20-21: WARNING: sum of probable bitmasks, consider |

[PATCH] rtw88: 8822ce: fix wifi disconnect after S3/S4 on HONOR laptop

2021-02-20 Thread Hao Chen
When the laptop HONOR MagicBook 14 sleep to S3/S4, the laptop can't resume. The dmesg of kernel report: "[ 99.990168] pcieport :00:01.2: can't change power state from D3hot to D0 (config space inaccessible) [ 99.993334] rtw_pci :01:00.0: can't change power state from D3hot to D0

[PATCH V4 1/2] vdpa: set the virtqueue num during register

2021-02-20 Thread Jason Wang
This patch delay the queue number setting to vDPA device registering. This allows us to probe the virtqueue numbers between device allocation and registering. Signed-off-by: Jason Wang --- drivers/vdpa/ifcvf/ifcvf_main.c | 5 ++--- drivers/vdpa/mlx5/net/mlx5_vnet.c| 4 ++--

[PATCH V4 2/2] vdpa: introduce virtio pci driver

2021-02-20 Thread Jason Wang
This patch introduce a vDPA driver for virtio-pci device. It bridges the virtio-pci control command to the vDPA bus. This will be used for features prototyping and testing. Note that get/restore virtqueue state is not supported which needs extension on the virtio specification. Signed-off-by:

[PATCH V4 0/2] virtio-pci: introduce modern device module

2021-02-20 Thread Jason Wang
Hi all: This series tries to implement a vDPA driver for virtio-pci device which will bridge between vDPA bus and virtio-pci device. This could be used for future feature prototyping and testing. Please review Changes since V3: - rebase to vhost.git Changes since V2: - tweak config prompt -

[PATCH] scsi: pm80xx: switch from 'pci_' to 'dma_' API

2021-02-20 Thread Christophe JAILLET
The wrappers in include/linux/pci-dma-compat.h should go away. The patch has been generated with the coccinelle script below and has been hand modified to replace GFP_ with a correct flag. It has been compile tested. When memory is allocated in 'pm8001_init_ccb_tag()' GFP_KERNEL can be used

[PATCH] drm/amdgpu/sdma5.2: Remove unnecessary conversion to bool

2021-02-20 Thread Jiapeng Chong
Fix the following coccicheck warnings: ./drivers/gpu/drm/amd/amdgpu/sdma_v5_2.c:1621:40-45: WARNING: conversion to bool not needed here. ./drivers/gpu/drm/amd/amdgpu/sdma_v5_2.c:1619:40-45: WARNING: conversion to bool not needed here. Reported-by: Abaci Robot Signed-off-by: Jiapeng Chong ---

[PATCH] KVM: s390: use ARRAY_SIZE instead of division operation

2021-02-20 Thread Yang Li
This eliminates the following coccicheck warning: ./arch/s390/tools/gen_facilities.c:154:37-38: WARNING: Use ARRAY_SIZE ./arch/s390/tools/gen_opcode_table.c:141:39-40: WARNING: Use ARRAY_SIZE Reported-by: Abaci Robot Signed-off-by: Yang Li --- arch/s390/tools/gen_facilities.c | 2 +-

[PATCH] powerpc: use ARRAY_SIZE instead of division operation

2021-02-20 Thread Yang Li
This eliminates the following coccicheck warning: ./arch/powerpc/boot/mktree.c:130:31-32: WARNING: Use ARRAY_SIZE Reported-by: Abaci Robot Signed-off-by: Yang Li --- arch/powerpc/boot/mktree.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/arch/powerpc/boot/mktree.c

Re: [PATCH 1/7] perf cs-etm: Split up etm queue setup function

2021-02-20 Thread Leo Yan
Hi James, On Fri, Feb 12, 2021 at 04:45:07PM +0200, James Clark wrote: > Refactor the function into separate allocation and > timestamp search parts. Later the timestamp search > will be done multiple times. The new introduced function cs_etm__search_first_timestamp() is to search timestamp; if

<    1   2   3