On 25.09.23 01:58, Gavin Shan wrote:
Hi David and Michael,
On 8/31/23 11:10, Gavin Shan wrote:
The deflation request to the target, which isn't unaligned to the
guest page size causes endless deflation and inflation actions. For
example, we receive the flooding QMP events for the changes on mem
x27;s size can be stablizied to 0x3ffe soon
after the deflation request is sent.
{ "execute" : "balloon", "arguments": { "value" : 1073672192 } }
{"return": {}}
{"timestamp": {"seconds": 1693273328, "microseconds": 79307
On 29.08.23 03:54, Gavin Shan wrote:
The deflation request to the target, which isn't unaligned to the
guest page size causes endless deflation and inflation actions. For
example, we receive the flooding QMP events for the changes on memory
balloon's size after a deflation request to the unaligne
On 22.08.23 15:40, Stefan Hajnoczi wrote:
On Mon, Aug 21, 2023 at 03:18:50PM -0700, Daniel Verkamp wrote:
Hello virtio folks,
Hi Daniel,
I have CCed those involved in the free page hint and page reporting
features.
Stefan
I noticed a mismatch between the way the specification defines
devic
age, struct page *page, enum migrate_mode mode)
Reviewed-by: David Hildenbrand
--
Cheers,
David / dhildenb
___
Virtualization mailing list
Virtualization@lists.linux-foundation.org
https://lists.linuxfoundation.org/mailman/listinfo/virtualization
On 13.07.23 17:03, Michael S. Tsirkin wrote:
On Thu, Jul 13, 2023 at 04:55:47PM +0200, David Hildenbrand wrote:
Some cleanups+optimizations primarily around offline_and_remove_memory().
Patch #1 drops the "unsafe unplug" feature where we might get stuck in
offline_and_remove_memory
y and we're not supposed to unplug memory
anymore. For example, the hypervisor might detect a low-memory situation
while unplugging memory and decide to replug some memory. Continuing
trying to unplug memory in that case can be problematic.
So let's check on a more regular basis.
Signe
Just like we do with alloc_contig_range(), let's convert all unknown
errors to -EBUSY, but WARN so we can look into the issue. For example,
offline_pages() could fail with -EINTR, which would be unexpected in our
case.
Signed-off-by: David Hildenbrand
---
drivers/virtio/virtio_mem.c
ntig_range() user, if allocating temporary memory fails,
or if some memory notifier rejected the offlining request.
Let's handle that case better, by simple retrying to offline and remove
such memory.
Tested using CONFIG_MEMORY_NOTIFIER_ERROR_INJECT.
Signed-off-by: David Hildenbrand
---
S. Tsirkin"
Cc: Jason Wang
Cc: Xuan Zhuo
David Hildenbrand (4):
virtio-mem: remove unsafe unplug in Big Block Mode (BBM)
virtio-mem: convert most offline_and_remove_memory() errors to -EBUSY
virtio-mem: keep retrying on offline_and_remove_memory() errors in Sub
Block Mode (SBM)
virt
ed
mechanism; and (b) this mode is not the default and as far as I know,
it's unused either way.
So let's simply get rid of it.
Signed-off-by: David Hildenbrand
---
drivers/virtio/virtio_mem.c | 51 +++--
1 file changed, 20 insertions(+), 31 deletions(-
On 27.06.23 16:17, Michal Hocko wrote:
On Tue 27-06-23 15:14:11, David Hildenbrand wrote:
On 27.06.23 14:40, Michal Hocko wrote:
On Tue 27-06-23 13:22:18, David Hildenbrand wrote:
John Hubbard writes [1]:
Some device drivers add memory to the system via memory hotplug
On 27.06.23 14:34, Michal Hocko wrote:
On Tue 27-06-23 13:22:16, David Hildenbrand wrote:
Let's check for fatal signals only. That looks cleaner and still keeps
the documented use case for manual user-space triggered memory offlining
working. From Documentation/admin-guide/mm/memory-hotplu
On 27.06.23 14:40, Michal Hocko wrote:
On Tue 27-06-23 13:22:18, David Hildenbrand wrote:
John Hubbard writes [1]:
Some device drivers add memory to the system via memory hotplug.
When the driver is unloaded, that memory is hot-unplugged.
However, memory hot unplug
https://lkml.kernel.org/r/20230620011719.155379-1-jhubb...@nvidia.com
Signed-off-by: David Hildenbrand
---
drivers/virtio/virtio_mem.c| 2 +-
include/linux/memory_hotplug.h | 2 +-
mm/memory_hotplug.c| 50 --
3 files changed, 50 insertions(+), 4 d
parameter description and the relationship to
unmovable pages.
Signed-off-by: David Hildenbrand
---
drivers/virtio/virtio_mem.c | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
diff --git a/drivers/virtio/virtio_mem.c b/drivers/virtio/virtio_mem.c
index f8792223f1db..7468b4a907e3 10
we're not supposed to unplug memory
anymore.
Let's optimize for that case, identified while testing the
offline_and_remove() memory timeout and simulating it repeatedly running
into the timeout.
Signed-off-by: David Hildenbrand
---
drivers/virtio/virtio_mem.c | 8
1 file change
Let's prepare for offline_and_remove_memory() to return other error
codes that effectively translate to -EBUSY, such as -ETIMEDOUT.
Signed-off-by: David Hildenbrand
---
drivers/virtio/virtio_mem.c | 10 +-
1 file changed, 9 insertions(+), 1 deletion(-)
diff --git a/drivers/v
0230620011719.155379-1-jhubb...@nvidia.com
David Hildenbrand (5):
mm/memory_hotplug: check for fatal signals only in offline_pages()
virtio-mem: convert most offline_and_remove_memory() errors to -EBUSY
mm/memory_hotplug: make offline_and_remove_memory() timeout instead of
failing on fa
ument there: "the offlining context can be terminated
by sending a fatal signal".
Signed-off-by: David Hildenbrand
---
mm/memory_hotplug.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/mm/memory_hotplug.c b/mm/memory_hotplug.c
index 8e0fa209d533..0d2151df4ee1
* C2,...)
|
alloc(
- (E1) * (E2)
+ array_size(E1, E2)
,...)
)
//
Signed-off-by: Julia Lawall
---
drivers/virtio/virtio_mem.c |6 +++---
1 file changed, 3 insertions(+), 3 deletions(-)
Reviewed-by: David Hildenbrand
--
Cheers,
David / dhildenb
On 21.05.23 11:15, Björn Töpel wrote:
Hi David and Anshuman!
Björn Töpel writes:
David Hildenbrand writes:
On 12.05.23 16:57, Björn Töpel wrote:
From: Björn Töpel
Memory Hot(Un)Plug support for the RISC-V port
==
[...]
Cool stuff! I
io-mem-pci"), and can be found here
https://github.com/bjoto/qemu/tree/riscv-virtio-mem
I will try to upstream that work in parallel with this.
Thanks to David Hildenbrand for valuable input for the Qemu side of
things.
The series is based on the RISC-V fixes tree
https://git.kernel.org/
-by: Lorenzo Stoakes
---
Ideally, we'd avoid FOLL_SAME_FILE as well
Acked-by: David Hildenbrand
--
Thanks,
David / dhildenb
___
Virtualization mailing list
Virtualization@lists.linux-foundation.org
https://lists.linuxfoundation.org/mailman/lis
On 24.01.23 06:42, Alistair Popple wrote:
Kernel drivers that pin pages should account these pages against
either user->locked_vm or mm->pinned_vm and fail the pinning if
RLIMIT_MEMLOCK is exceeded and CAP_IPC_LOCK isn't held.
Currently drivers open-code this accounting and use various methods t
On 24.01.23 00:04, Sudarshan Rajagopalan wrote:
[...]
One problematic thing is that adding memory to Linux by virtio-mem
eventually consumes memory (e.g., the memmap), especially when having
to to add a completely new memory block to Linux.
Yes we have thought about this issue as well where-in
1. This will be a native userspace daemon that will be running only in
the Linux VM which will use virtio-mem driver that uses memory hotplug
to add/remove memory. The VM (aka Secondary VM, SVM) will request for
memory from the host which is Primary VM, PVM via the backend hypervisor
which takes
On 15.01.23 04:57, Sudarshan Rajagopalan wrote:
Hello all,
Hi,
I'll focus on the virtio-mem side of things :)
We’re from the Linux memory team here at Qualcomm. We are currently
devising a VM memory resizing feature where we dynamically inflate or
deflate the Linux VM based on ongoing memor
On 29.12.22 06:31, Soichiro Ueda wrote:
Hi David.
How does this affect page migration / balloon compaction etc?
I guess this patch doesn't affect balloon compaction. When allocating
pages using alloc_pages(), it skips compaction by masking out
__GFP_RECLAIM if the order is larger than 0.
As
On 23.12.22 10:35, Soichiro Ueda wrote:
At present, the VirtIO balloon device driver allocates pages
one by one using alloc_page(), and frees them using put_page().
This changes it so that the driver allocates high order pages
by using alloc_pages(), and frees them using __free_pages() if possib
/drivers/virtio/virtio_mem.c
+++ b/drivers/virtio/virtio_mem.c
@@ -2793,6 +2793,7 @@ static int virtio_mem_probe(struct virtio_device *vdev)
return 0;
out_del_vq:
+ virtio_reset_device(vdev);
vdev->config->del_vqs(vdev);
out_free_vm:
kfree(vm);
Apart from that
Review
Other problem is that there are drivers that do not use
adjust_managed_page_count().
Which ones? Do we care?
VMWare and Virtio balloon drivers. I recently proposed to unify them and
the objection was that it would break existing users - which is valid so
we must care i guess.
I'm confused,
On 14.10.22 14:50, Alexander Atanasov wrote:
Hello,
On 11.10.22 12:23, David Hildenbrand wrote:
Sounds to me that all you want is some notifier to be called from
adjust_managed_page_count(). What am I missing?
Notifier will act as an accumulator to report size of change and it
will make
Sounds to me that all you want is some notifier to be called from
adjust_managed_page_count(). What am I missing?
Notifier will act as an accumulator to report size of change and it will make
things easier for the drivers and users wrt locking.
Notifier is similar to the memory hotplug notifier
On 09.08.22 11:36, Alexander Atanasov wrote:
> Hello,
>
> On 2.08.22 16:48, David Hildenbrand wrote:
>>>>
>>>> In case of Hyper-V I remember a customer BUG report that requested that
>>>> exact behavior, however, I'm not a
>>
>> In case of Hyper-V I remember a customer BUG report that requested that
>> exact behavior, however, I'm not able to locate the BZ quickly.
>> [1]
>> https://lists.linuxfoundation.org/pipermail/virtualization/2021-November/057767.html
>> (note that I can't easily find the original mail in the
>>> +
>>> + if (!virtio_has_feature(vb->vdev, VIRTIO_BALLOON_F_DEFLATE_ON_OOM))
>>> + num_pages = -num_pages;
>> With VIRTIO_BALLOON_F_DEFLATE_ON_OOM this will now always report "0".
>>
>> which would be the same as "num_pages = 0;" and would deserve a comment
>> explaining why we don't
On 26.07.22 16:08, Alexander Atanasov wrote:
> Allow the guest to know how much it is ballooned by the host
> and how that memory is accounted.
>
> It is useful when debugging out of memory conditions,
> as well for userspace processes that monitor the memory pressure
> and for nested virtualizati
On 26.07.22 16:10, Alexander Atanasov wrote:
> Always account inflated memory as used for both cases - with and
> without deflate on oom. Do not change total ram which can confuse
> userspace and users.
Sorry, but NAK.
This would affect existing users / user space / balloon stats. For example
HV
On 25.07.22 13:27, Alexander Atanasov wrote:
> Hi,
>
> On 18/07/2022 14:35, David Hildenbrand wrote:
>> On 14.07.22 15:20, Alexander Atanasov wrote:
>>> Allow the guest to know how much it is ballooned by the host.
>>> It is useful when debugging out of memory c
On 14.07.22 15:20, Alexander Atanasov wrote:
> Allow the guest to know how much it is ballooned by the host.
> It is useful when debugging out of memory conditions.
>
> When host gets back memory from the guest it is accounted
> as used memory in the guest but the guest have no way to know
> how m
On 14.07.22 15:20, Alexander Atanasov wrote:
> Hello,
>
> On 14/07/2022 14:35, David Hildenbrand wrote:
>> On 05.07.22 10:36, Alexander Atanasov wrote:
>>> Allow the guest to know how much it is ballooned by the host.
>>> It is useful when debugging out of mem
On 05.07.22 10:36, Alexander Atanasov wrote:
> Allow the guest to know how much it is ballooned by the host.
> It is useful when debugging out of memory conditions.
>
> When host gets back memory from the guest it is accounted
> as used memory in the guest but the guest have no way to know
> how m
On 20.06.22 20:49, Ben Hutchings wrote:
> I've tested a 5.19-rc3 kernel on top of QEMU/KVM with machine type
> pc-q35-5.2. It has a virtio balloon device defined in libvirt as:
>
>
>function="0x0"/>
>
>
> but the virtio_balloon driver fails to bind to it:
>
> virtio_balloo
On 09.06.22 16:35, Matthew Wilcox wrote:
> On Thu, Jun 09, 2022 at 02:50:20PM +0200, David Hildenbrand wrote:
>> On 08.06.22 17:02, Matthew Wilcox (Oracle) wrote:
>>> diff --git a/Documentation/filesystems/locking.rst
>>> b/Documentation/filesystems/locking
Let's make it clearer that simply unlocking CONFIG_VIRTIO_MEM on an
architecture is most probably not sufficient to have it working as
expected.
Cc: "Michael S. Tsirkin"
Cc: Jason Wang
Cc: Gavin Shan
Signed-off-by: David Hildenbrand
---
drivers/virtio/Kconfig | 8 +---
1
On 08.06.22 17:02, Matthew Wilcox (Oracle) wrote:
> Provide a folio-based replacement for aops->migratepage. Update the
> documentation to document migrate_folio instead of migratepage.
>
> Signed-off-by: Matthew Wilcox (Oracle)
> Reviewed-by: Christoph Hellwig
> ---
> Documentation/filesystem
secretmem_isolate_page,
> };
>
> static int secretmem_setattr(struct user_namespace *mnt_userns,
Reviewed-by: David Hildenbrand
--
Thanks,
David / dhildenb
___
Virtualization mailing list
Virtualization@lists.linux-foundation.org
https://lists.linuxfoundation.org/mailman/listinfo/virtualization
| 102 ++-
> 14 files changed, 94 insertions(+), 365 deletions(-)
You probably should have cc'ed the relevant maintainers (including me :P ).
For everything except z3fold.c and zsmalloc.c,
Reviewed-by: David Hildenbrand
--
Thanks,
David / dhildenb
__
On 07.06.22 21:21, Matthew Wilcox wrote:
> On Tue, Jun 07, 2022 at 03:24:15PM +0100, Matthew Wilcox wrote:
>> On Tue, Jun 07, 2022 at 09:36:21AM +0200, David Hildenbrand wrote:
>>> On 06.06.22 22:40, Matthew Wilcox (Oracle) wrote:
>>>> const struct address
On 06.06.22 22:40, Matthew Wilcox (Oracle) wrote:
> This is little more than changing the types over; there's no real work
> being done in this function.
>
> Signed-off-by: Matthew Wilcox (Oracle)
> ---
> mm/balloon_compaction.c | 15 +++
> 1 file changed, 7 insertions(+), 8 deletion
On 02.06.22 11:28, zhenwei pi wrote:
> On 6/1/22 15:59, David Hildenbrand wrote:
>> On 01.06.22 04:17, zhenwei pi wrote:
>>> On 5/31/22 12:08, Jue Wang wrote:
>>>> On Mon, May 30, 2022 at 8:49 AM Peter Xu wrote:
>>>>>
>>>>> On Mon, May
On 01.06.22 04:17, zhenwei pi wrote:
> On 5/31/22 12:08, Jue Wang wrote:
>> On Mon, May 30, 2022 at 8:49 AM Peter Xu wrote:
>>>
>>> On Mon, May 30, 2022 at 07:33:35PM +0800, zhenwei pi wrote:
A VM uses RAM of 2M huge page. Once a MCE(@HVAy in [HVAx,HVAz)) occurs, the
2M([HVAx,HVAz)) of h
On 25.05.22 01:32, zhenwei pi wrote:
>
>
> On 5/25/22 03:35, Sean Christopherson wrote:
>> On Fri, May 20, 2022, zhenwei pi wrote:
>>> @@ -59,6 +60,12 @@ enum virtio_balloon_config_read {
>>> VIRTIO_BALLOON_CONFIG_READ_CMD_ID = 0,
>>> };
>>>
>>> +/* the request body to commucate with hos
> +
> struct virtio_balloon {
> struct virtio_device *vdev;
> struct virtqueue *inflate_vq, *deflate_vq, *stats_vq, *free_page_vq;
> @@ -126,6 +133,16 @@ struct virtio_balloon {
> /* Free page reporting device */
> struct virtqueue *reporting_vq;
> struct page_repor
On 27.05.22 08:32, zhenwei pi wrote:
> On 5/27/22 02:37, Peter Xu wrote:
>> On Wed, May 25, 2022 at 01:16:34PM -0700, Jue Wang wrote:
>>> The hypervisor _must_ emulate poisons identified in guest physical
>>> address space (could be transported from the source VM), this is to
>>> prevent silent dat
On 30.05.22 04:16, Bo Liu (刘波)-浪潮信息 wrote:
> Adding this patch can avoid unnecessary VM exits and reduce the number of VM
> exits
>
... in corner cases where virtqueue_add_outbuf() fails? Why do we care
about that corner case?
Looks like unnecessary code churn to me, unless I am missing somethi
On 20.05.22 09:06, zhenwei pi wrote:
> Origianlly, unpoison_memory() is only used by hwpoison-inject, and
> unpoisons a page which is poisoned by hwpoison-inject too. The kernel PTE
> entry has no change during software poison/unpoison.
>
> On a virtualization platform, it's possible to fix hardwa
On 20.05.22 09:06, zhenwei pi wrote:
> Hi,
>
> I'm trying to recover hardware corrupted page by virtio balloon, the
> workflow of this feature like this:
>
> Guest 5.MF -> 6.RVQ FE10.Unpoison page
> / \/
> ---+
On 06.05.22 15:38, zhenwei pi wrote:
>
>
> On 5/6/22 16:59, Naoya Horiguchi wrote:
>> On Fri, Apr 29, 2022 at 10:22:05PM +0800, zhenwei pi wrote:
>>> In the memory failure procedure, hwpoison_filter has higher priority,
>>> if memory_filter() filters the error event, there is no need to do
>>> th
On 12.04.22 17:01, Zi Yan wrote:
> On 12 Apr 2022, at 10:49, David Hildenbrand wrote:
>
>> On 12.04.22 16:07, Zi Yan wrote:
>>> On 12 Apr 2022, at 9:10, David Hildenbrand wrote:
>>>
>>>> On 06.04.22 17:18, Zi Yan wrote:
>>>>> From: Zi Y
On 12.04.22 16:07, Zi Yan wrote:
> On 12 Apr 2022, at 9:10, David Hildenbrand wrote:
>
>> On 06.04.22 17:18, Zi Yan wrote:
>>> From: Zi Yan
>>>
>>> Enable set_migratetype_isolate() to check specified sub-range for
>>> unmovable pages
On 06.04.22 17:18, Zi Yan wrote:
> From: Zi Yan
>
> Enable set_migratetype_isolate() to check specified sub-range for
> unmovable pages during isolation. Page isolation is done
> at MAX_ORDER_NR_PAEGS granularity, but not all pages within that
> granularity are intended to be isolated. For exampl
On 06.04.22 17:18, Zi Yan wrote:
> From: Zi Yan
>
> Hi David,
Hi!
>
> This patchset tries to remove the MAX_ORDER-1 alignment requirement for CMA
> and alloc_contig_range(). It prepares for my upcoming changes to make
> MAX_ORDER adjustable at boot time[1]. It is on top of mmotm-2022-04-05-15-
On 21.03.22 19:23, Zi Yan wrote:
> On 21 Mar 2022, at 13:30, David Hildenbrand wrote:
>
>> On 17.03.22 16:37, Zi Yan wrote:
>>> From: Zi Yan
>>>
>>> Enable set_migratetype_isolate() to check specified sub-range for
>>> unmovable pages dur
On 17.03.22 16:37, Zi Yan wrote:
> From: Zi Yan
>
> Enable set_migratetype_isolate() to check specified sub-range for
> unmovable pages during isolation. Page isolation is done
> at max(MAX_ORDER_NR_PAEGS, pageblock_nr_pages) granularity, but not all
> pages within that granularity are intended t
On 11.03.22 19:36, Zi Yan wrote:
> From: Zi Yan
>
> Enable set_migratetype_isolate() to check specified sub-range for
> unmovable pages during isolation. Page isolation is done
> at max(MAX_ORDER_NR_PAEGS, pageblock_nr_pages) granularity, but not all
> pages within that granularity are intended t
On 11.03.22 19:36, Zi Yan wrote:
> From: Zi Yan
>
> has_unmovable_pages() is only used in mm/page_isolation.c. Move it from
> mm/page_alloc.c and make it static.
>
> Signed-off-by: Zi Yan
> Reviewed-by: Oscar Salvador
> Reviewed-by: Mike Rapoport
Acked-by: David H
> tristate "Virtio mem driver"
> - default m
> depends on X86_64
> depends on VIRTIO
> depends on MEMORY_HOTPLUG
Yeah, why not
Acked-by: David Hildenbrand
--
Thanks,
David / dhildenb
___
On 14.02.22 20:59, Kameron Lutes wrote:
> This new linux API will allow user space applications to directly
> control the size of the virtio-balloon. This is useful in
> situations where the guest must quickly respond to drastically
> increased memory pressure and cannot wait for the host to adjust
yprowski
Cc: Robin Murphy
Cc: Minchan Kim
Cc: Vlastimil Babka
Cc: linuxppc-...@lists.ozlabs.org
Cc: devicet...@vger.kernel.org
Cc: virtualization@lists.linux-foundation.org
Cc: io...@lists.linux-foundation.org
Cc: linux...@kvack.org
David Hildenbrand (2):
cma: factor out minimum alignment requirement
Let's factor out determining the minimum alignment requirement for CMA
and add a helpful comment.
No functional change intended.
Signed-off-by: David Hildenbrand
---
arch/powerpc/include/asm/fadump-internal.h | 5 -
arch/powerpc/kernel/fadump.c | 2 +-
drive
ffected setups
should be using CMA or boottime allocations instead.
So let's make sure that pageblock_order < MAX_ORDER and simplify.
[1] https://lkml.kernel.org/r/87r189a2ks@linux.ibm.com
Signed-off-by: David Hildenbrand
---
drivers/virtio/virtio_mem.c | 9 +++--
include/li
On 04.02.22 15:04, Michael S. Tsirkin wrote:
> On Fri, Feb 04, 2022 at 02:29:39PM +0100, David Hildenbrand wrote:
>> On 04.02.22 14:24, Michael S. Tsirkin wrote:
>>> On Wed, Jan 19, 2022 at 09:35:05AM +0100, David Hildenbrand wrote:
>>>> On 19.01.22 08:46, Gavi
On 04.02.22 14:24, Michael S. Tsirkin wrote:
> On Wed, Jan 19, 2022 at 09:35:05AM +0100, David Hildenbrand wrote:
>> On 19.01.22 08:46, Gavin Shan wrote:
>>> Hi Michael,
>>>
>>> On 1/19/22 3:39 PM, Michael S. Tsirkin wrote:
>>>> On Wed, Ja
On 02.02.22 13:18, Oscar Salvador wrote:
> On Wed, Jan 19, 2022 at 02:06:19PM -0500, Zi Yan wrote:
>> From: Zi Yan
>>
>> Enable set_migratetype_isolate() to check specified sub-range for
>> unmovable pages during isolation. Page isolation is done
>> at max(MAX_ORDER_NR_PAEGS, pageblock_nr_pages) g
relevant code.
>
> Signed-off-by: Miaohe Lin
Reviewed-by: David Hildenbrand
--
Thanks,
David / dhildenb
___
Virtualization mailing list
Virtualization@lists.linux-foundation.org
https://lists.linuxfoundation.org/mailman/listinfo/virtualization
fig option (CONFIG_VIRTIO_MEM) on the
>>> architecture.
>>>
>>> Signed-off-by: Gavin Shan
>>> Acked-by: David Hildenbrand
>>> Acked-by: Jonathan Cameron
>>> Acked-by: Michael S. Tsirkin
>>> ---
>>> v3: Pick ack-by tags from
On 18.01.22 11:43, Michael S. Tsirkin wrote:
> On Tue, Jan 18, 2022 at 09:38:21AM +0100, David Hildenbrand wrote:
>> On 18.01.22 02:34, Gavin Shan wrote:
>>> This enables virtio-mem device support by allowing to enable the
>>> corresponding kernel config option
64, but should
+theoretically work on all architectures that support memory hotplug and
+ hotremove.
If unsure, say M.
Acked-by: David Hildenbrand
--
Thanks,
David / dhildenb
___
Virtualization mailing list
Virtualization@l
On 17.01.22 09:40, Michael S. Tsirkin wrote:
> On Mon, Jan 17, 2022 at 09:31:56AM +0100, David Hildenbrand wrote:
>> On 17.01.22 08:55, Michael S. Tsirkin wrote:
>>> On Mon, Jan 17, 2022 at 02:40:11PM +0800, Jason Wang wrote:
>>>>
>>>> 在 2022/1/15 上午5
On 17.01.22 08:55, Michael S. Tsirkin wrote:
> On Mon, Jan 17, 2022 at 02:40:11PM +0800, Jason Wang wrote:
>>
>> 在 2022/1/15 上午5:43, Michael S. Tsirkin 写道:
>>> A common pattern for device reset is currently:
>>> vdev->config->reset(vdev);
>>> .. cleanup ..
>>>
>>> reset prevents new interrupts from
On 05.01.22 22:47, Zi Yan wrote:
> From: Zi Yan
>
> alloc_contig_range() now only needs to be aligned to pageblock_order,
> drop virtio_mem size requirement that it needs to be the max of
> pageblock_order and MAX_ORDER.
>
> Signed-off-by: Zi Yan
> ---
> drivers/virtio/virtio_mem.c | 3 +--
>
On 05.01.22 22:47, Zi Yan wrote:
> From: Zi Yan
>
> Enable set_migratetype_isolate() to check specified sub-range for
> unmovable pages during isolation. Page isolation is done
> at max(MAX_ORDER_NR_PAEGS, pageblock_nr_pages) granularity, but not all
> pages within that granularity are intended t
On 13.01.22 16:46, Zi Yan wrote:
> On 12 Jan 2022, at 6:04, David Hildenbrand wrote:
>
>> On 05.01.22 22:47, Zi Yan wrote:
>>> From: Zi Yan
>>>
>>> alloc_migration_target() is used by alloc_contig_range() and non-LRU
>>> movable compound pages can
On 13.01.22 12:36, Mike Rapoport wrote:
> On Wed, Jan 12, 2022 at 11:54:49AM +0100, David Hildenbrand wrote:
>> On 05.01.22 22:47, Zi Yan wrote:
>>> From: Zi Yan
>>>
>>> This is done in addition to MIGRATE_ISOLATE pageblock merge avoidance.
>>>
On 05.01.22 22:47, Zi Yan wrote:
> From: Zi Yan
>
> alloc_migration_target() is used by alloc_contig_range() and non-LRU
> movable compound pages can be migrated. Current code does not allocate the
> right page size for such pages. Check THP precisely using
> is_transparent_huge() and add allocat
On 05.01.22 22:47, Zi Yan wrote:
> From: Zi Yan
>
> In isolate_migratepages_block(), a !PageLRU tail page can be encountered
> when the page is larger than a pageblock. Use compound head page for the
> checks inside and skip the entire compound page when isolation succeeds.
>
This will currentl
On 05.01.22 22:47, Zi Yan wrote:
> From: Zi Yan
>
> This is done in addition to MIGRATE_ISOLATE pageblock merge avoidance.
> It prepares for the upcoming removal of the MAX_ORDER-1 alignment
> requirement for CMA and alloc_contig_range().
>
> MIGRARTE_HIGHATOMIC should not merge with other migra
On 10.12.21 00:04, Zi Yan wrote:
> From: Zi Yan
>
> Hi all,
Hi,
thanks for working on that!
>
> This patchset tries to remove the MAX_ORDER - 1 alignment requirement for CMA
> and alloc_contig_range(). It prepares for my upcoming changes to make
> MAX_ORDER
> adjustable at boot time[1].
>
>
Hi Eric,
thanks for the review!
>> if (PageDirty(page)) {
>> -virtio_mem_clear_fake_offline(pfn + i, max_nr_pages,
>> - false);
>> -generic_online_page(page, MAX_ORDER - 1);
>> +
On 01.12.21 00:56, Michael S. Tsirkin wrote:
> On Fri, Nov 26, 2021 at 02:42:07PM +0100, David Hildenbrand wrote:
>> The virtio-mem driver currently supports logical hot(un)plug in
>> MAX_ORDER - 1 granularity (4MiB on x86-64) or bigger. We want to support
>> pageblock granul
On 29.11.21 17:47, Zi Yan wrote:
> On 26 Nov 2021, at 8:42, David Hildenbrand wrote:
>
>> The virtio-mem driver currently supports logical hot(un)plug in
>> MAX_ORDER - 1 granularity (4MiB on x86-64) or bigger. We want to support
>> pageblock granularity (2MiB on x86-64),
Let's prepare our fake page onlining code for subblock size smaller than
MAX_ORDER - 1: we might get called for ranges not covering properly
aligned MAX_ORDER - 1 pages. We have to detect the order to use
dynamically.
Signed-off-by: David Hildenbrand
---
drivers/virtio/virtio_mem.c
the buddy.
Signed-off-by: David Hildenbrand
---
drivers/virtio/virtio_mem.c | 86 ++---
1 file changed, 62 insertions(+), 24 deletions(-)
diff --git a/drivers/virtio/virtio_mem.c b/drivers/virtio/virtio_mem.c
index 96e5a8782769..03e1c5743699 100644
--- a/driv
https://lkml.kernel.org/r/2025193725.737539-1-zi@sent.com
Cc: "Michael S. Tsirkin"
Cc: Jason Wang
Cc: Zi Yan
Cc: Gavin Shan
Cc: Hui Zhu
Cc: Eric Ren
Cc: Sebastien Boeuf
Cc: Pankaj Gupta
Cc: Wei Yang
Cc: virtualization@lists.linux-foundation.org
Cc: linux...@kvack.org
David
On 26.11.21 03:30, Sasha Levin wrote:
> From: David Hildenbrand
>
> [ Upstream commit 61082ad6a6e1f999eef7e7e90046486c87933b1e ]
>
> The initial virtio-mem spec states that while unplugged memory should not
> be read, the device still has to allow for reading unplugged m
On 26.11.21 03:30, Sasha Levin wrote:
> From: David Hildenbrand
>
> [ Upstream commit 61082ad6a6e1f999eef7e7e90046486c87933b1e ]
>
> The initial virtio-mem spec states that while unplugged memory should not
> be read, the device still has to allow for reading unplugged m
I'd appreciate a more generic approach for user space to figure out the
"initial memory size" in a virtualized environment than adding
some module parameter to virtio-balloon -- if that makes sense.
MemTotal as is expresses how much memory the buddy currently manages,
On 17.11.21 04:04, Zi Yan wrote:
> On 16 Nov 2021, at 3:58, David Hildenbrand wrote:
>
>> On 15.11.21 20:37, Zi Yan wrote:
>>> From: Zi Yan
>>>
>>> Hi David,
>>
>> Hi,
>>
>> thanks for looking into this.
>>
Hi,
sorry for t
1 - 100 of 833 matches
Mail list logo