[PATCH] driver/virtio: Add Memory Balloon Support for SEV/SEV-ES

2024-01-09 Thread Zheyun Shen
For now, SEV pins guest's memory to avoid swapping or moving ciphertext, but leading to the inhibition of Memory Ballooning. In Memory Ballooning, only guest's free pages will be relocated in balloon inflation and deflation, so the difference of plaintext doesn't matter to guest. Memory

Re: [v5.15] WARNING in kvm_arch_vcpu_ioctl_run

2024-01-09 Thread Muhammad Usama Anjum
On 1/9/24 11:18 PM, syzbot wrote: > This bug is marked as fixed by commit: > KVM: x86: Remove WARN sanity check on hypervisor timer vs. UNINITIALIZED vCPU > > But I can't find it in the tested trees[1] for more than 90 days. Just found out that the fix hasn't been back ported to this kernel. The

Re: [PATCH v7 3/3] vduse: enable Virtio-net device type

2024-01-09 Thread Yongji Xie
On Tue, Jan 9, 2024 at 7:10 PM Maxime Coquelin wrote: > > This patch adds Virtio-net device type to the supported > devices types. > > Initialization fails if the device does not support > VIRTIO_F_VERSION_1 feature, in order to guarantee the > configuration space is read-only. It also fails with

Re: [PATCH v7 2/3] vduse: Temporarily fail if control queue feature requested

2024-01-09 Thread Yongji Xie
On Tue, Jan 9, 2024 at 7:10 PM Maxime Coquelin wrote: > > Virtio-net driver control queue implementation is not safe > when used with VDUSE. If the VDUSE application does not > reply to control queue messages, it currently ends up > hanging the kernel thread sending this command. > > Some work is

RE: [PATCH] vfio: fix virtio-pci dependency

2024-01-09 Thread Tian, Kevin
> From: Arnd Bergmann > Sent: Tuesday, January 9, 2024 3:57 PM > > From: Arnd Bergmann > > The new vfio-virtio driver already has a dependency on > VIRTIO_PCI_ADMIN_LEGACY, > but that is a bool symbol and allows vfio-virtio to be built-in even if > virtio-pci itself is a loadable module. This

[PATCH v3] ring-buffer: Have mmapped ring buffer keep track of missed events

2024-01-09 Thread Steven Rostedt
From: "Steven Rostedt (Google)" While testing libtracefs on the mmapped ring buffer, the test that checks if missed events are accounted for failed when using the mapped buffer. This is because the mapped page does not update the missed events that were dropped because the writer filled up the

[PATCH v3] virtio_balloon: stay awake while adjusting balloon

2024-01-09 Thread David Stevens
From: David Stevens A virtio_balloon's parent device may be configured so that a configuration change interrupt is a wakeup event. Extend the processing of such a wakeup event until the balloon finishes inflating or deflating by calling pm_stay_awake/pm_relax in the virtio_balloon driver. Note

Re: [PATCH] virtiofs: limit the length of ITER_KVEC dio by max_nopage_rw

2024-01-09 Thread Hou Tao
Hi, On 1/9/2024 9:11 PM, Bernd Schubert wrote: > > > On 1/3/24 11:59, Hou Tao wrote: >> From: Hou Tao >> >> When trying to insert a 10MB kernel module kept in a virtiofs with cache >> disabled, the following warning was reported: >> >>    [ cut here ] >>    WARNING: CPU:

[PATCH] ftrace: Fix DIRECT_CALLS to use SAVE_REGS by default

2024-01-09 Thread Masami Hiramatsu (Google)
From: Masami Hiramatsu (Google) The commit 60c8971899f3 ("ftrace: Make DIRECT_CALLS work WITH_ARGS and !WITH_REGS") changed DIRECT_CALLS to use SAVE_ARGS when there are multiple ftrace_ops at the same function, but since the x86 only support to jump to direct_call from ftrace_regs_caller, when

Re: [PATCH v10 1/2] ring-buffer: Introducing ring-buffer mapping functions

2024-01-09 Thread Steven Rostedt
On Wed, 10 Jan 2024 08:42:05 +0900 Masami Hiramatsu (Google) wrote: > On Tue, 9 Jan 2024 15:13:51 + > Vincent Donnefort wrote: > > > > > @@ -388,6 +389,7 @@ struct rb_irq_work { > > > > boolwaiters_pending; > > > > bool

Re: [PATCH v10 1/2] ring-buffer: Introducing ring-buffer mapping functions

2024-01-09 Thread Google
On Tue, 9 Jan 2024 15:13:51 + Vincent Donnefort wrote: > > > @@ -388,6 +389,7 @@ struct rb_irq_work { > > > boolwaiters_pending; > > > boolfull_waiters_pending; > > > boolwakeup_full; > > > + bool

Re: REGRESSION: lockdep warning triggered by 15b9ce7ecd: virtio_balloon: stay awake while adjusting balloon

2024-01-09 Thread Michael S. Tsirkin
On Tue, Jan 09, 2024 at 02:50:20PM +0900, David Stevens wrote: > On Tue, Jan 9, 2024 at 6:50 AM Theodore Ts'o wrote: > > > > Hi, while doing final testing before sending a pull request, I merged > > in linux-next, and commit 5b9ce7ecd7: virtio_balloon: stay awake while > > adjusting balloon seems

Re: Re: Re: EEVDF/vhost regression (bisected to 86bfbb7ce4f6 sched/fair: Add lag based placement)

2024-01-09 Thread Michael S. Tsirkin
On Mon, Jan 08, 2024 at 02:13:25PM +0100, Tobias Huschle wrote: > On Thu, Dec 14, 2023 at 02:14:59AM -0500, Michael S. Tsirkin wrote: > > > > Peter, would appreciate feedback on this. When is cond_resched() > > insufficient to give up the CPU? Should > > Documentation/kernel-hacking/hacking.rst

[PATCH v2] ring-buffer: Have mmapped ring buffer keep track of missed events

2024-01-09 Thread Steven Rostedt
From: "Steven Rostedt (Google)" While testing libtracefs on the mmapped ring buffer, the test that checks if missed events are accounted for failed when using the mapped buffer. This is because the mapped page does not update the missed events that were dropped because the writer filled up the

[PATCH] ring-buffer: Have mmapped ring buffer keep track of missed events

2024-01-09 Thread Steven Rostedt
From: "Steven Rostedt (Google)" While testing libtracefs on the mmapped ring buffer, the test that checks if missed events are accounted for failed when using the mapped buffer. This is because the mapped page does not update the missed events that were dropped because the writer filled up the

[syzbot] [modules?] INFO: task hung in _vm_unmap_aliases (3)

2024-01-09 Thread syzbot
Hello, syzbot found the following issue on: HEAD commit:610a9b8f49fb Linux 6.7-rc8 git tree: upstream console output: https://syzkaller.appspot.com/x/log.txt?x=137c4981e8 kernel config: https://syzkaller.appspot.com/x/.config?x=c1d9baf5d2241e14 dashboard link:

Re: [v5.15] WARNING in kvm_arch_vcpu_ioctl_run

2024-01-09 Thread syzbot
This bug is marked as fixed by commit: KVM: x86: Remove WARN sanity check on hypervisor timer vs. UNINITIALIZED vCPU But I can't find it in the tested trees[1] for more than 90 days. Is it a correct commit? Please update it by replying: #syz fix: exact-commit-title Until then the bug is still

Re: [PATCH v10 1/2] ring-buffer: Introducing ring-buffer mapping functions

2024-01-09 Thread Steven Rostedt
On Tue, 9 Jan 2024 15:13:51 + Vincent Donnefort wrote: > > > @@ -388,6 +389,7 @@ struct rb_irq_work { > > > boolwaiters_pending; > > > boolfull_waiters_pending; > > > boolwakeup_full; > > > + bool

Re: [PATCH v10 1/2] ring-buffer: Introducing ring-buffer mapping functions

2024-01-09 Thread Vincent Donnefort
On Tue, Jan 09, 2024 at 11:42:30PM +0900, Masami Hiramatsu wrote: > On Fri, 5 Jan 2024 09:47:28 + > Vincent Donnefort wrote: > > > In preparation for allowing the user-space to map a ring-buffer, add > > a set of mapping functions: > > > > ring_buffer_{map,unmap}() > >

[GIT PULL] Modules changes for v6.8-rc1

2024-01-09 Thread Luis Chamberlain
The following changes since commit ceb6a6f023fd3e8b07761ed900352ef574010bcb: Linux 6.7-rc6 (2023-12-17 15:19:28 -0800) are available in the Git repository at: git://git.kernel.org/pub/scm/linux/kernel/git/mcgrof/linux.git/ tags/modules-6.8-rc1 for you to fetch changes up to

Re: [PATCH v10 1/2] ring-buffer: Introducing ring-buffer mapping functions

2024-01-09 Thread Google
On Fri, 5 Jan 2024 09:47:28 + Vincent Donnefort wrote: > In preparation for allowing the user-space to map a ring-buffer, add > a set of mapping functions: > > ring_buffer_{map,unmap}() > ring_buffer_map_fault() > > And controls on the ring-buffer: > > ring_buffer_map_get_reader()

Re: [PATCH v10 0/2] Introducing trace buffer mapping by user-space

2024-01-09 Thread Vincent Donnefort
On Tue, Jan 09, 2024 at 08:20:57AM -0500, Steven Rostedt wrote: > > Hi Masami, thanks for looking at this. > > On Tue, 9 Jan 2024 22:04:45 +0900 > Masami Hiramatsu (Google) wrote: > > > > The tracing ring-buffers can be stored on disk or sent to network > > > without any copy via splice.

Re: [PATCH v10 0/2] Introducing trace buffer mapping by user-space

2024-01-09 Thread Steven Rostedt
Hi Masami, thanks for looking at this. On Tue, 9 Jan 2024 22:04:45 +0900 Masami Hiramatsu (Google) wrote: > > The tracing ring-buffers can be stored on disk or sent to network > > without any copy via splice. However the later doesn't allow real time > > processing of the traces. A solution

Re: [PATCH] virtiofs: limit the length of ITER_KVEC dio by max_nopage_rw

2024-01-09 Thread Bernd Schubert
On 1/3/24 11:59, Hou Tao wrote: From: Hou Tao When trying to insert a 10MB kernel module kept in a virtiofs with cache disabled, the following warning was reported: [ cut here ] WARNING: CPU: 2 PID: 439 at mm/page_alloc.c:4544 .. Modules linked in:

Re: [PATCH v10 0/2] Introducing trace buffer mapping by user-space

2024-01-09 Thread Google
Hi Vincent, On Fri, 5 Jan 2024 09:47:27 + Vincent Donnefort wrote: > The tracing ring-buffers can be stored on disk or sent to network > without any copy via splice. However the later doesn't allow real time > processing of the traces. A solution is to give userspace direct access > to the

Re: REGRESSION: lockdep warning triggered by 15b9ce7ecd: virtio_balloon: stay awake while adjusting balloon

2024-01-09 Thread David Hildenbrand
On 09.01.24 06:50, David Stevens wrote: On Tue, Jan 9, 2024 at 6:50 AM Theodore Ts'o wrote: Hi, while doing final testing before sending a pull request, I merged in linux-next, and commit 5b9ce7ecd7: virtio_balloon: stay awake while adjusting balloon seems to be causing a lockdep warning (see

Re: [PATCH] virtiofs: limit the length of ITER_KVEC dio by max_nopage_rw

2024-01-09 Thread Michael S. Tsirkin
On Wed, Jan 03, 2024 at 06:59:29PM +0800, Hou Tao wrote: > From: Hou Tao > > When trying to insert a 10MB kernel module kept in a virtiofs with cache > disabled, the following warning was reported: > > [ cut here ] > WARNING: CPU: 2 PID: 439 at mm/page_alloc.c:4544

Re: [PATCH v7 2/3] vduse: Temporarily fail if control queue feature requested

2024-01-09 Thread Eugenio Perez Martin
On Tue, Jan 9, 2024 at 12:11 PM Maxime Coquelin wrote: > > Virtio-net driver control queue implementation is not safe > when used with VDUSE. If the VDUSE application does not > reply to control queue messages, it currently ends up > hanging the kernel thread sending this command. > > Some work

Re: [RFC PATCH] kprobes: Use synchronize_rcu_tasks_rude in kprobe_optimizer

2024-01-09 Thread Yang Jihong
Hello, PING. I had a similar problem. Is this solution feasible? Thanks, Yang On 2024/1/2 11:40, Chen Zhongjin wrote: There is a deadlock scenario in kprobe_optimizer(): pid A pid B pid C kprobe_optimizer() do_exit()

Re: [PATCH 2/2] arm64: dts: qcom: sm7225-fairphone-fp4: Add PM6150L thermals

2024-01-09 Thread Luca Weiss
On Tue Jan 9, 2024 at 11:09 AM CET, Konrad Dybcio wrote: > > > On 1/5/24 15:54, Luca Weiss wrote: > > Configure the thermals for the PA_THERM1, MSM_THERM, PA_THERM0, > > RFC_CAM_THERM, CAM_FLASH_THERM and QUIET_THERM thermistors connected to > > PM6150L. > > > > Due to hardware constraints we can

[PATCH v7 3/3] vduse: enable Virtio-net device type

2024-01-09 Thread Maxime Coquelin
This patch adds Virtio-net device type to the supported devices types. Initialization fails if the device does not support VIRTIO_F_VERSION_1 feature, in order to guarantee the configuration space is read-only. It also fails with -EPERM if the CAP_NET_ADMIN is missing. Acked-by: Jason Wang

[PATCH v7 2/3] vduse: Temporarily fail if control queue feature requested

2024-01-09 Thread Maxime Coquelin
Virtio-net driver control queue implementation is not safe when used with VDUSE. If the VDUSE application does not reply to control queue messages, it currently ends up hanging the kernel thread sending this command. Some work is on-going to make the control queue implementation robust with

[PATCH v7 1/3] vduse: validate block features only with block devices

2024-01-09 Thread Maxime Coquelin
This patch is preliminary work to enable network device type support to VDUSE. As VIRTIO_BLK_F_CONFIG_WCE shares the same value as VIRTIO_NET_F_HOST_TSO4, we need to restrict its check to Virtio-blk device type. Acked-by: Jason Wang Reviewed-by: Xie Yongji Reviewed-by: Eugenio Pérez

[PATCH v7 0/3] vduse: add support for networking devices

2024-01-09 Thread Maxime Coquelin
This small series enables virtio-net device type in VDUSE. With it, basic operation have been tested, both with virtio-vdpa and vhost-vdpa using DPDK Vhost library series adding VDUSE support using split rings layout (merged in DPDK v23.07-rc1). Control queue support (and so multiqueue) has also

Re: [PATCH V3] remoteproc: virtio: Fix wdg cannot recovery remote processor

2024-01-09 Thread Arnaud POULIQUEN
On 12/17/23 06:36, joakim.zh...@cixtech.com wrote: > From: Joakim Zhang > > Recovery remote processor failed when wdg irq received: > [0.842574] remoteproc remoteproc0: crash detected in cix-dsp-rproc: type > watchdog > [0.842750] remoteproc remoteproc0: handling crash #1 in

Re: [PATCH 2/2] arm64: dts: qcom: sm7225-fairphone-fp4: Add PM6150L thermals

2024-01-09 Thread Dmitry Baryshkov
On Tue, 9 Jan 2024 at 12:10, Konrad Dybcio wrote: > > > > On 1/5/24 15:54, Luca Weiss wrote: > > Configure the thermals for the PA_THERM1, MSM_THERM, PA_THERM0, > > RFC_CAM_THERM, CAM_FLASH_THERM and QUIET_THERM thermistors connected to > > PM6150L. > > > > Due to hardware constraints we can only

Re: [PATCH 2/2] arm64: dts: qcom: sm7225-fairphone-fp4: Add PM6150L thermals

2024-01-09 Thread Konrad Dybcio
On 1/5/24 15:54, Luca Weiss wrote: Configure the thermals for the PA_THERM1, MSM_THERM, PA_THERM0, RFC_CAM_THERM, CAM_FLASH_THERM and QUIET_THERM thermistors connected to PM6150L. Due to hardware constraints we can only register 4 zones with pm6150l_adc_tm, the other 2 we can register via

RE: [PATCH V3] remoteproc: virtio: Fix wdg cannot recovery remote processor

2024-01-09 Thread Joakim Zhang
Kindly Ping... On Sunday, December 17, 2023 1:37 PM, Joakim Zhang wrote: > Recovery remote processor failed when wdg irq received: > [0.842574] remoteproc remoteproc0: crash detected in cix-dsp-rproc: type > watchdog > [0.842750] remoteproc remoteproc0: handling crash #1 in