All of lore.kernel.org
 help / color / mirror / Atom feed
From: Jan Beulich <jbeulich@suse.com>
To: "xen-devel@lists.xenproject.org" <xen-devel@lists.xenproject.org>
Cc: Kevin Tian <kevin.tian@intel.com>
Subject: [PATCH 3/6] VT-d: bring print_qi_regs() in line with print_iommu_regs()
Date: Thu, 1 Apr 2021 10:44:55 +0200	[thread overview]
Message-ID: <c3401f8c-35b5-17d7-ae14-8c58e43b5cb9@suse.com> (raw)
In-Reply-To: <157e4a65-6d0b-7ea8-1c23-cd393c8c0d7f@suse.com>

Shorten the names printed. There's also no need to go through a local
variable.

While at it also constify the function's parameter.

Signed-off-by: Jan Beulich <jbeulich@suse.com>

--- a/xen/drivers/passthrough/vtd/qinval.c
+++ b/xen/drivers/passthrough/vtd/qinval.c
@@ -33,18 +33,11 @@
 
 static int __must_check invalidate_sync(struct vtd_iommu *iommu);
 
-static void print_qi_regs(struct vtd_iommu *iommu)
+static void print_qi_regs(const struct vtd_iommu *iommu)
 {
-    u64 val;
-
-    val = dmar_readq(iommu->reg, DMAR_IQA_REG);
-    printk("DMAR_IQA_REG = %"PRIx64"\n", val);
-
-    val = dmar_readq(iommu->reg, DMAR_IQH_REG);
-    printk("DMAR_IQH_REG = %"PRIx64"\n", val);
-
-    val = dmar_readq(iommu->reg, DMAR_IQT_REG);
-    printk("DMAR_IQT_REG = %"PRIx64"\n", val);
+    printk(" IQA = %"PRIx64"\n", dmar_readq(iommu->reg, DMAR_IQA_REG));
+    printk(" IQH = %"PRIx64"\n", dmar_readq(iommu->reg, DMAR_IQH_REG));
+    printk(" IQT = %"PRIx64"\n", dmar_readq(iommu->reg, DMAR_IQT_REG));
 }
 
 static unsigned int qinval_next_index(struct vtd_iommu *iommu)



  parent reply	other threads:[~2021-04-01  8:45 UTC|newest]

Thread overview: 8+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2021-04-01  8:42 [PATCH 0/6] VT-d: assorted cleanup Jan Beulich
2021-04-01  8:44 ` [PATCH 1/6] VT-d: improve save/restore of registers across S3 Jan Beulich
2021-04-01  8:44 ` [PATCH 2/6] VT-d: don't open-code dmar_readl() Jan Beulich
2021-04-01  8:44 ` Jan Beulich [this message]
2021-04-01  8:45 ` [PATCH 4/6] VT-d: qinval indexes are only up to 19 bits wide Jan Beulich
2021-04-01  8:45 ` [PATCH 5/6] VT-d: avoid pointless use of 64-bit constants Jan Beulich
2021-04-01  8:45 ` [PATCH 6/6] VT-d: drop unused #define-s Jan Beulich
2021-04-13  2:50 ` [PATCH 0/6] VT-d: assorted cleanup Tian, Kevin

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=c3401f8c-35b5-17d7-ae14-8c58e43b5cb9@suse.com \
    --to=jbeulich@suse.com \
    --cc=kevin.tian@intel.com \
    --cc=xen-devel@lists.xenproject.org \
    /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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.