public inbox for pve-devel@lists.proxmox.com
 help / color / mirror / Atom feed
From: Timothy Nicholson <t.nicholson@proxmox.com>
To: pve-devel@lists.proxmox.com
Subject: [pve-devel] [PATCH manager v2] fix #5302: ui: vm cpu affinity displayed in hardware overview
Date: Tue, 15 Oct 2024 11:17:58 +0200	[thread overview]
Message-ID: <20241015091758.48629-1-t.nicholson@proxmox.com> (raw)

Signed-off-by: Timothy Nicholson <t.nicholson@proxmox.com>
---
changes since v1:
* fix javascript indentation

 www/manager6/qemu/HardwareView.js | 9 ++++++++-
 1 file changed, 8 insertions(+), 1 deletion(-)

diff --git a/www/manager6/qemu/HardwareView.js b/www/manager6/qemu/HardwareView.js
index 86d5f4cf..59e670db 100644
--- a/www/manager6/qemu/HardwareView.js
+++ b/www/manager6/qemu/HardwareView.js
@@ -103,7 +103,7 @@ Ext.define('PVE.qemu.HardwareView', {
 		tdCls: 'pve-itype-icon-cpu',
 		group: 3,
 		defaultValue: '1',
-		multiKey: ['sockets', 'cpu', 'cores', 'numa', 'vcpus', 'cpulimit', 'cpuunits'],
+		multiKey: ['sockets', 'cpu', 'cores', 'numa', 'vcpus', 'cpulimit', 'cpuunits', 'affinity'],
 		renderer: function(value, metaData, record, rowIndex, colIndex, store, pending) {
 		    var sockets = me.getObjectValue('sockets', 1, pending);
 		    var model = me.getObjectValue('cpu', undefined, pending);
@@ -112,6 +112,7 @@ Ext.define('PVE.qemu.HardwareView', {
 		    var vcpus = me.getObjectValue('vcpus', undefined, pending);
 		    var cpulimit = me.getObjectValue('cpulimit', undefined, pending);
 		    var cpuunits = me.getObjectValue('cpuunits', undefined, pending);
+		    var cpuaffinity = me.getObjectValue('affinity', undefined, pending);
 
 		    let res = Ext.String.format(
 		        '{0} ({1} sockets, {2} cores)', sockets * cores, sockets, cores);
@@ -131,6 +132,9 @@ Ext.define('PVE.qemu.HardwareView', {
 		    if (cpuunits) {
 			res += ' [cpuunits=' + cpuunits +']';
 		    }
+		    if (cpuaffinity) {
+			res += ' [cpuaffinity=' + cpuaffinity + ']';
+		    }
 
 		    return res;
 		},
@@ -214,6 +218,9 @@ Ext.define('PVE.qemu.HardwareView', {
 	    ostype: {
 		visible: false,
 	    },
+	    affinity: {
+		visible: false,
+	    },
 	};
 
 	PVE.Utils.forEachBus(undefined, function(type, id) {
-- 
2.39.5


_______________________________________________
pve-devel mailing list
pve-devel@lists.proxmox.com
https://lists.proxmox.com/cgi-bin/mailman/listinfo/pve-devel


             reply	other threads:[~2024-10-15  9:17 UTC|newest]

Thread overview: 2+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2024-10-15  9:17 Timothy Nicholson [this message]
2024-10-16 16:41 ` [pve-devel] applied: " Thomas Lamprecht

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=20241015091758.48629-1-t.nicholson@proxmox.com \
    --to=t.nicholson@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