argo: few log fixes
v5 cover argo: few log fixes
This series corrects Argo module tracing.
Patch 1 lowers the verbosity of a spammy log message.
Patch 2 corrects the debug logline.
Patch 3 cleans up existing loglines by dropping duplicate prefixes. Patch 4 re-wires argo_dprintk() to gprintk() to include mode debugging
context.
Patch 5 adds new Kconfig for short-circuiting extra verbose Argo traces. Patch 6 enables extra verbose Argo traces in CI for ease of catching
potential issues.
CI: https://gitlab.com/xen-project/people/dmukhin/xen/-/pipelines/2574255630
Link to v4: https://lore.kernel.org/xen-devel/[email protected]/
Denis Mukhin (6):
argo: lower level of noisy connection-refused log
argo: correct logline in ring_unmap()
argo: drop argo prefix from argo_dprintk() calls
argo: fixup argo_dprintk()
argo: introduce CONFIG_ARGO_DEBUG
automation: enable Argo debugging in CI
automation/gitlab-ci/analyze.yaml | 2 ++ automation/gitlab-ci/build.yaml | 1 + xen/common/Kconfig | 6 ++++++ xen/common/argo.c | 22 ++++++++++------------ 4 files changed, 19 insertions(+), 12 deletions(-)
Signature · 1 line
2.54.0
PATCH v5 1/6 argo: lower level of noisy connection-refused log
Switch the log line to argo_dprintk() so it is enabled only in debug environments, as it can spam the logs when a dom0 service using the Argo hypercall tries to communicate with a domain that is still starting up.
Note that this also lowers the log level to debug when the argo_dprintk() facility is enabled.
---
Changes since v4:
- n/a
--- xen/common/argo.c | 7 +++---- 1 file changed, 3 insertions(+), 4 deletions(-)
xen/common/argo.c +3 -4
@@ -2034,10 +2034,9 @@ sendv(struct domain *src_d, xen_argo_addr_t *src_addr, src_id.domain_id);if ( !ring_info ) { -gprintk (XENLOG_ERR , -"argo: vm%u connection refused, src (vm%u:%x) dst (vm%u:%x)\n" , - current->domain->domain_id, src_id.domain_id, src_id.aport, - dst_addr->domain_id, dst_addr->aport); +argo_dprintk ("vm%u connection refused, src (vm%u:%x) dst (vm%u:%x)\n" , + current->domain->domain_id, src_id.domain_id, src_id.aport, + dst_addr->domain_id, dst_addr->aport); ret = -ECONNREFUSED ; }
Signature · 1 line
2.54.0
PATCH v5 2/6 argo: correct logline in ring_unmap()
In reply to [email protected]Drop XENLOG_ERR from the logline since argo_dprintk() already injects the proper log level indicator.
Also, drop "argo: " prefix, since it is also injected by argo_dprintk()
---
Changes since v4:
- n/a
--- xen/common/argo.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-)
xen/common/argo.c +1 -1
@@ -474,7 +474,7 @@ ring_unmap(const struct domain *d, struct argo_ring_info *ring_info)continue ;ASSERT (!mfn_eq (ring_info->mfns[i],INVALID_MFN )); -argo_dprintk (XENLOG_ERR "argo: unmapping page %" PRI_mfn" from %p\n" , +argo_dprintk ("unmapping page %" PRI_mfn" from %p\n" ,mfn_x (ring_info->mfns[i]), ring_info->mfn_mapping[i]);unmap_domain_page_global (ring_info->mfn_mapping[i]);
Signature · 1 line
2.54.0
PATCH v5 3/6 argo: drop argo prefix from argo_dprintk() calls
In reply to [email protected]argo_dprintk() prefixes all log lines with "argo: " automatically.
Remove duplicate prefixes from log messages in the Argo module where applicable.
---
Changes since v4:
- n/a
--- xen/common/argo.c | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-)
xen/common/argo.c +4 -4
@@ -1467,7 +1467,7 @@ find_ring_mfns(struct domain *d, struct argo_ring_info *ring_info,if ( ring_info->mfns ) {/* Ring already existed: drop the previous mapping. */ -argo_dprintk ("argo: vm%u re-register existing ring " +argo_dprintk ("vm%u re-register existing ring " "(vm%u:%x vm%u) clears mapping\n" , d->domain_id, ring_info->id.domain_id, ring_info->id.aport, ring_info->id.partner_id);
@@ -1527,7 +1527,7 @@ find_ring_mfns(struct domain *d, struct argo_ring_info *ring_info, {ASSERT (ring_info->nmfns ==NPAGES_RING (len)); - argo_dprintk("argo: vm%u ring (vm%u:%x vm%u) %p " + argo_dprintk("vm%u ring (vm%u:%x vm%u) %p " "mfn_mapping %p len %u nmfns %u\n", d->domain_id, ring_info->id.domain_id, ring_info->id.aport, ring_info->id.partner_id, ring_info,
@@ -1741,7 +1741,7 @@ register_ring(struct domain *currd,list_add (&ring_info->node, &currd->argo->ring_hash[hash_index (&ring_info->id)]); -argo_dprintk ("argo: vm%u registering ring (vm%u:%x vm%u)\n" , +argo_dprintk ("vm%u registering ring (vm%u:%x vm%u)\n" , currd->domain_id, ring_id.domain_id, ring_id.aport, ring_id.partner_id); }
@@ -1781,7 +1781,7 @@ register_ring(struct domain *currd, goto out_unlock2; } -argo_dprintk ("argo: vm%u re-registering existing ring (vm%u:%x vm%u)\n" , +argo_dprintk ("vm%u re-registering existing ring (vm%u:%x vm%u)\n" , currd->domain_id, ring_id.domain_id, ring_id.aport, ring_id.partner_id); }
Signature · 1 line
2.54.0
PATCH v5 4/6 argo: fixup argo_dprintk()
In reply to [email protected]Current argo_dprintk() implementation is a wrapper around raw printk().
Rewire it through gprintk() to allow for better debugging context (such as domain ID).
---
Changes since v4:
- n/a
--- xen/common/argo.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-)
xen/common/argo.c +1 -1
@@ -322,7 +322,7 @@ static DEFINE_RWLOCK(L1_global_argo_rwlock); /* L1 */ #define argo_dprintk(fmt, args...) \ do { \ if ( ARGO_DEBUG ) \ - printk(XENLOG_DEBUG "argo: " fmt, ##args); \ + gprintk(XENLOG_DEBUG, "argo: " fmt, ##args);\ } while ( 0 )/*
Signature · 1 line
2.54.0
Re: [PATCH v5 4/6] argo: fixup argo_dprintk()
Quoted 7 lines · On 2026-06-03 15:41, [email protected] wrote:
Current
argo_dprintk()implementation is a wrapper around rawprintk().Rewire it through
gprintk()to allow for better debugging context (such as domain ID).Signed-off-by Denis Mukhin <[email protected]>Reviewed-by Stefano Stabellini <[email protected]>
Quoted 1 line
Changes since v4:
Oops, sorry for replying to the v4 patches. I'm in the correct thread now. All the patches are unchanged, so the R-b stands.
Regards,
Jason
Re: [PATCH v5 4/6] argo: fixup argo_dprintk()
Quoted 9 lines · Jason Andryuk
Quoted 7 lines · On 2026-06-03 15:41, [email protected] wrote:
Current
argo_dprintk()implementation is a wrapper around rawprintk().Rewire it through
gprintk()to allow for better debugging context (such as domain ID).Signed-off-by Denis Mukhin <[email protected]>Reviewed-by Stefano Stabellini <[email protected]>
Quoted 6 lines
Reviewed-by Jason Andryuk <[email protected]>Quoted 1 line
Changes since v4:
Oops, sorry for replying to the v4 patches. I'm in the correct thread now. All the patches are unchanged, so the R-b stands.
Thanks for taking a look!
PATCH v5 5/6 argo: introduce CONFIG_ARGO_DEBUG
In reply to [email protected]Add Kconfig knob to enable traces for Argo debugging.
---
Changes since v4:
- fixed dependency on a new Kconfig knob on ARGO
Changes since v3:
- dropped uneeded "If unsure, say N." from new Kconfig description
--- xen/common/Kconfig | 6 ++++++ xen/common/argo.c | 3 +-- 2 files changed, 7 insertions(+), 2 deletions(-)
xen/common/Kconfig +6 -0
@@ -491,6 +491,12 @@ config ARGO If unsure, say N. +config ARGO_DEBUG + bool "Argo: enable debug traces (UNSUPPORTED)" if ARGO + depends on ARGO + help + Enables extra debug traces for Argo debugging. + source "common/sched/Kconfig" config CRYPTO
xen/common/argo.c +1 -2
@@ -318,10 +318,9 @@ static DEFINE_RWLOCK(L1_global_argo_rwlock); /* L1 */ ((LOCKING_Read_L1 &&spin_is_locked (&(d)->argo->send_L2_lock)) || \ LOCKING_Write_L1) -#define ARGO_DEBUG 0 #define argo_dprintk(fmt, args...) \ do { \ - if ( ARGO_DEBUG ) \ + if ( IS_ENABLED(CONFIG_ARGO_DEBUG) ) \ gprintk(XENLOG_DEBUG, "argo: " fmt, ##args);\ } while ( 0 )
Signature · 1 line
2.54.0
Re: [PATCH v5 5/6] argo: introduce CONFIG_ARGO_DEBUG
Quoted 19 lines · On 03.06.2026 21:41, [email protected] wrote:
Add
Kconfigknob to enable traces for Argo debugging.Signed-off-by Denis Mukhin <[email protected]>---
Changes since v4:
- fixed dependency on a newKconfigknob on ARGOChanges since v3:
- dropped uneeded "If unsure, say N." from newKconfigdescription--- xen/common/Kconfig | 6 ++++++ xen/common/argo.c | 3 +-- 2 files changed, 7 insertions(+), 2 deletions(-)xen/common/Kconfig +0
-0
xen/common/Kconfig config ARGO · line 495
Quoted 5 lines
xen/common/Kconfig +2
-0@@ -491,6 +491,12 @@ config ARGO If unsure, say N. +config ARGO_DEBUG + bool "Argo: enable debug traces (UNSUPPORTED)" if ARGO
Why is the "if ARGO" still there? That's fully redundant with ...
xen/common/Kconfig config ARGO · line 496
Quoted 1 line
xen/common/Kconfig +1
-0+ depends on ARGO
... this. I said the v4 issue could be fixed while committing. Now you've posted another version (adding to overall mail volume) and an adjustment still needs doing.
Jan
Jason Andryuk
Reviewed-byRe: [PATCH v5 5/6] argo: introduce CONFIG_ARGO_DEBUG
Quoted 28 lines · Jan Beulich
Quoted 19 lines · On 03.06.2026 21:41, [email protected] wrote:
Add
Kconfigknob to enable traces for Argo debugging.Signed-off-by Denis Mukhin <[email protected]>---
Changes since v4:
- fixed dependency on a newKconfigknob on ARGOChanges since v3:
- dropped uneeded "If unsure, say N." from newKconfigdescription--- xen/common/Kconfig | 6 ++++++ xen/common/argo.c | 3 +-- 2 files changed, 7 insertions(+), 2 deletions(-)xen/common/Kconfig +0
-0xen/common/Kconfig config ARGO · line 495
Quoted 5 lines
xen/common/Kconfig +2
-0@@ -491,6 +491,12 @@ config ARGO If unsure, say N. +config ARGO_DEBUG + bool "Argo: enable debug traces (UNSUPPORTED)" if ARGOWhy is the "if ARGO" still there? That's fully redundant with ...
Quoted 5 lines
xen/common/Kconfig config ARGO · line 496
Quoted 1 line
xen/common/Kconfig +1
-0+ depends on ARGO... this. I said the v4 issue could be fixed while committing. Now you've posted another version (adding to overall mail volume) and an adjustment still needs doing.
With the if ARGO removed:
-Jason
Re: [PATCH v5 5/6] argo: introduce CONFIG_ARGO_DEBUG
Quoted 33 lines · Jason Andryuk
Quoted 26 lines · Jan Beulich
Quoted 19 lines · On 03.06.2026 21:41, [email protected] wrote:
Add
Kconfigknob to enable traces for Argo debugging.Signed-off-by Denis Mukhin <[email protected]>---
Changes since v4:
- fixed dependency on a newKconfigknob on ARGOChanges since v3:
- dropped uneeded "If unsure, say N." from newKconfigdescription--- xen/common/Kconfig | 6 ++++++ xen/common/argo.c | 3 +-- 2 files changed, 7 insertions(+), 2 deletions(-)xen/common/Kconfig +0
-0xen/common/Kconfig config ARGO · line 493
Quoted 3 lines
xen/common/Kconfig +2
-0@@ -491,6 +491,12 @@ config ARGO If unsure, say N. +config ARGO_DEBUG + bool "Argo: enable debug traces (UNSUPPORTED)" if ARGOWhy is the "if ARGO" still there? That's fully redundant with ...
Quoted 5 lines
xen/common/Kconfig config ARGO · line 496
Quoted 1 line
xen/common/Kconfig +1
-0+ depends on ARGO... this. I said the v4 issue could be fixed while committing. Now you've posted another version (adding to overall mail volume) and an adjustment still needs doing.
Quoted 3 lines
With the if ARGO removed:
Reviewed-by Jason Andryuk <[email protected]>
Thank you!
Re: [PATCH v5 5/6] argo: introduce CONFIG_ARGO_DEBUG
In reply to Jan BeulichQuoted 28 lines · Jan Beulich
Quoted 19 lines · On 03.06.2026 21:41, [email protected] wrote:
Add
Kconfigknob to enable traces for Argo debugging.Signed-off-by Denis Mukhin <[email protected]>---
Changes since v4:
- fixed dependency on a newKconfigknob on ARGOChanges since v3:
- dropped uneeded "If unsure, say N." from newKconfigdescription--- xen/common/Kconfig | 6 ++++++ xen/common/argo.c | 3 +-- 2 files changed, 7 insertions(+), 2 deletions(-)xen/common/Kconfig +0
-0xen/common/Kconfig config ARGO · line 495
Quoted 5 lines
xen/common/Kconfig +2
-0@@ -491,6 +491,12 @@ config ARGO If unsure, say N. +config ARGO_DEBUG + bool "Argo: enable debug traces (UNSUPPORTED)" if ARGOWhy is the "if ARGO" still there? That's fully redundant with ...
Quoted 5 lines
xen/common/Kconfig config ARGO · line 496
Quoted 1 line
xen/common/Kconfig +1
-0+ depends on ARGO... this. I said the v4 issue could be fixed while committing. Now you've posted another version (adding to overall mail volume) and an adjustment still needs doing.
I was not expecting this series to be approved for 4.22, so decided to send an update, supposedly so no adjustments are needed in the future.
Let me fix that.
--
Denis
PATCH v5 6/6 automation: enable Argo debugging in CI
In reply to [email protected]Enable extra Argo traces in CI to help analyze any potential Argo issues.
That covers eclair-*-allcode and alpine-3.18-gcc-debug jobs.
---
Changes since v4:
- n/a
- elcair-x86_64-allcode is green:
https://gitlab.com/xen-project/people/dmukhin/xen/-/jobs/14680426572
Changes since v3:
- enabled CONFIG_ARGO_DEBUG for eclair-*-allcode jobs Note, eclair-x86_64-allcode is failing on staging (known):
https://gitlab.com/xen-project/hardware/xen/-/pipelines/2567857238
- example of extra argo traces in CI:
https://gitlab.com/xen-project/people/dmukhin/xen/-/jobs/14661834468
--- automation/gitlab-ci/analyze.yaml | 2 ++ automation/gitlab-ci/build.yaml | 1 + 2 files changed, 3 insertions(+)
automation/gitlab-ci/analyze.yaml +2 -0
@@ -47,6 +47,7 @@ eclair-x86_64-allcode: RULESET: "monitored" EXTRA_XEN_CONFIG: | CONFIG_ARGO=y + CONFIG_ARGO_DEBUG=y CONFIG_DEBUG_INFO=n CONFIG_DEBUG_LOCK_PROFILE=y CONFIG_DEBUG_TRACE=y
@@ -127,6 +128,7 @@ eclair-ARM64-allcode: EXTRA_XEN_CONFIG: | CONFIG_ACPI=y CONFIG_ARGO=y + CONFIG_ARGO_DEBUG=y CONFIG_ARM64_SVE=y CONFIG_ARM_SMMU_V3=y CONFIG_BOOT_TIME_CPUPOOLS=y
automation/gitlab-ci/build.yaml +1 -0
@@ -286,6 +286,7 @@ alpine-3.18-gcc-debug: CONFIG_EXPERT=y CONFIG_UNSUPPORTED=y CONFIG_ARGO=y + CONFIG_ARGO_DEBUG=y CONFIG_UBSAN=y CONFIG_UBSAN_FATAL=y CONFIG_MICROCODE_SCAN_DEFAULT=y
Signature · 1 line
2.54.0
Re: [PATCH v5 6/6] automation: enable Argo debugging in CI
Quoted 5 lines · On 2026-06-03 15:41, [email protected] wrote:
Enable extra Argo traces in CI to help analyze any potential Argo issues.
That covers eclair-*-allcode and alpine-3.18-gcc-debug jobs.
Signed-off-by Denis Mukhin <[email protected]>
Quoted 22 lines · On 6/3/26 9:41 PM, [email protected] wrote:
This series corrects Argo module tracing.
Patch 1 lowers the verbosity of a spammy log message.
Patch 2 corrects the debug logline.
Patch 3 cleans up existing loglines by dropping duplicate prefixes. Patch 4 re-wiresargo_dprintk()togprintk()to include mode debugging
context.
Patch 5 adds newKconfigfor short-circuiting extra verbose Argo traces. Patch 6 enables extra verbose Argo traces in CI for ease of catching
potential issues.CI: https://gitlab.com/xen-project/people/dmukhin/xen/-/pipelines/2574255630
Link to v4: https://lore.kernel.org/xen-devel/[email protected]/Denis Mukhin (6):
argo: lower level of noisy connection-refused log
argo: correct logline inring_unmap()
argo: drop argo prefix fromargo_dprintk()calls
argo: fixupargo_dprintk()
argo: introduceCONFIG_ARGO_DEBUG
automation: enable Argo debugging in CI
Quoted 6 lines
automation/gitlab-ci/analyze.yaml | 2 ++ automation/gitlab-ci/build.yaml | 1 + xen/common/Kconfig | 6 ++++++ xen/common/argo.c | 22 ++++++++++------------ 4 files changed, 19 insertions(+), 12 deletions(-)
Considering that changes affect only the way how ARGO messages are printed I will be comfortable to have this in 4.22 as it is low-risk fixes:
Thasnks.
~ Oleksii