public inbox for pve-devel@lists.proxmox.com
 help / color / mirror / Atom feed
From: "DERUMIER, Alexandre" <alexandre.derumier@groupe-cyllene.com>
To: "pve-devel@lists.proxmox.com" <pve-devel@lists.proxmox.com>,
	"aderumier@odiso.com" <aderumier@odiso.com>,
	"f.ebner@proxmox.com" <f.ebner@proxmox.com>
Subject: Re: [pve-devel] applied: [PATCH v5 qemu-server 02/12] memory: don't use foreach_reversedimm for unplug
Date: Fri, 17 Mar 2023 16:23:14 +0000	[thread overview]
Message-ID: <d087fea8c3236b0c721f2e8beb379614d2712e75.camel@groupe-cyllene.com> (raw)
In-Reply-To: <6f83e5f1-dcc1-772f-c5db-1e7e66b67317@proxmox.com>

Hi Fiona,

I don't have checked yet, but does I need to rebase the other virtio-
mem patches ?


Le vendredi 17 mars 2023 à 14:39 +0100, Fiona Ebner a écrit :
> Am 24.02.23 um 13:09 schrieb Alexandre Derumier:
> > simple use dimm_list() returned by qemu
> > 
> > Signed-off-by: Alexandre Derumier <aderumier@odiso.com>
> 
> Thanks! Applied with this follow-up:
> 
> >     memory: hotplug: sort by numerical ID rather than slot when
> > unplugging
> >     
> >     While, usually, the slot should match the ID, it's not
> > explicitly
> >     guaranteed and relies on QEMU internals. Using the numerical ID
> > is
> >     more future-proof and more consistent with plugging, where no
> > slot
> >     information (except the maximum limit) is relied upon.
> >     
> >     Signed-off-by: Fiona Ebner <f.ebner@proxmox.com>
> > ---
> >  PVE/QemuServer/Memory.pm | 2 +-
> >  1 file changed, 1 insertion(+), 1 deletion(-)
> > 
> > diff --git a/PVE/QemuServer/Memory.pm b/PVE/QemuServer/Memory.pm
> > index 0f4229c5..0601dd6c 100644
> > --- a/PVE/QemuServer/Memory.pm
> > +++ b/PVE/QemuServer/Memory.pm
> > @@ -201,7 +201,7 @@ sub qemu_memory_hotplug {
> >         my $dimms = qemu_memdevices_list($vmid, 'dimm');
> >  
> >         my $current_size = $memory;
> > -       for my $name (sort { $dimms->{$b}->{slot} <=> $dimms->{$a}-
> > >{slot} } keys %$dimms) {
> > +       for my $name (sort { ($b =~ /^dimm(\d+)$/)[0] <=> ($a =~
> > /^dimm(\d+)$/)[0] } keys %$dimms) {
> >  
> >             my $dimm_size = $dimms->{$name}->{size} / 1024 / 1024;
> >  
> 


  reply	other threads:[~2023-03-17 16:23 UTC|newest]

Thread overview: 18+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2023-02-24 12:09 [pve-devel] [PATCH v5 qemu-server 00/12] rework memory hotplug + virtiomem Alexandre Derumier
2023-02-24 12:09 ` [pve-devel] [PATCH v5 qemu-server 01/12] memory: rename qemu_dimm_list to qemu_memdevices_list Alexandre Derumier
2023-03-17 13:38   ` [pve-devel] applied: " Fiona Ebner
2023-02-24 12:09 ` [pve-devel] [PATCH v5 qemu-server 02/12] memory: don't use foreach_reversedimm for unplug Alexandre Derumier
2023-03-17 13:39   ` [pve-devel] applied: " Fiona Ebner
2023-03-17 16:23     ` DERUMIER, Alexandre [this message]
2023-03-20  8:36       ` Fiona Ebner
2023-03-20  8:49         ` DERUMIER, Alexandre
2023-02-24 12:09 ` [pve-devel] [PATCH v5 qemu-server 03/12] add memory parser Alexandre Derumier
2023-02-24 12:09 ` [pve-devel] [PATCH v5 qemu-server 04/12] memory: add get_static_mem Alexandre Derumier
2023-02-24 12:09 ` [pve-devel] [PATCH v5 qemu-server 05/12] memory: use static_memory in foreach_dimm Alexandre Derumier
2023-02-24 12:09 ` [pve-devel] [PATCH v5 qemu-server 06/12] config: memory: add 'max' option Alexandre Derumier
2023-02-24 12:09 ` [pve-devel] [PATCH v5 qemu-server 07/12] memory: get_max_mem: use config memory max Alexandre Derumier
2023-02-24 12:09 ` [pve-devel] [PATCH v5 qemu-server 08/12] memory: use 64 slots && static dimm size when max is defined Alexandre Derumier
2023-02-24 12:09 ` [pve-devel] [PATCH v5 qemu-server 09/12] test: add memory-max tests Alexandre Derumier
2023-02-24 12:09 ` [pve-devel] [PATCH v5 qemu-server 10/12] memory: add virtio-mem support Alexandre Derumier
2023-02-24 12:09 ` [pve-devel] [PATCH v5 qemu-server 11/12] memory: virtio-mem : implement redispatch retry Alexandre Derumier
2023-02-24 12:09 ` [pve-devel] [PATCH v5 qemu-server 12/12] tests: add virtio-mem tests Alexandre Derumier

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=d087fea8c3236b0c721f2e8beb379614d2712e75.camel@groupe-cyllene.com \
    --to=alexandre.derumier@groupe-cyllene.com \
    --cc=aderumier@odiso.com \
    --cc=f.ebner@proxmox.com \
    --cc=pve-devel@lists.proxmox.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox
Service provided by Proxmox Server Solutions GmbH | Privacy | Legal