* [PATCH] intel_iommu: Fix two misuse of "0x%u" prints
@ 2020-10-19 17:39 Peter Xu
2020-10-19 18:33 ` Dr. David Alan Gilbert
` (3 more replies)
0 siblings, 4 replies; 6+ messages in thread
From: Peter Xu @ 2020-10-19 17:39 UTC (permalink / raw)
To: qemu-devel
Cc: Jason Wang, Dr . David Alan Gilbert, peterx, Michael S . Tsirkin
Dave magically found this. Fix them with "0x%x".
Reported-by: Dr. David Alan Gilbert <dgilbert@redhat.com>
Signed-off-by: Peter Xu <peterx@redhat.com>
---
hw/i386/intel_iommu.c | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
diff --git a/hw/i386/intel_iommu.c b/hw/i386/intel_iommu.c
index 749eb6ad63..70ac837733 100644
--- a/hw/i386/intel_iommu.c
+++ b/hw/i386/intel_iommu.c
@@ -2665,7 +2665,7 @@ static uint64_t vtd_mem_read(void *opaque, hwaddr addr, unsigned size)
if (addr + size > DMAR_REG_SIZE) {
error_report_once("%s: MMIO over range: addr=0x%" PRIx64
- " size=0x%u", __func__, addr, size);
+ " size=0x%x", __func__, addr, size);
return (uint64_t)-1;
}
@@ -2716,7 +2716,7 @@ static void vtd_mem_write(void *opaque, hwaddr addr,
if (addr + size > DMAR_REG_SIZE) {
error_report_once("%s: MMIO over range: addr=0x%" PRIx64
- " size=0x%u", __func__, addr, size);
+ " size=0x%x", __func__, addr, size);
return;
}
--
2.26.2
^ permalink raw reply related [flat|nested] 6+ messages in thread
* Re: [PATCH] intel_iommu: Fix two misuse of "0x%u" prints
2020-10-19 17:39 [PATCH] intel_iommu: Fix two misuse of "0x%u" prints Peter Xu
@ 2020-10-19 18:33 ` Dr. David Alan Gilbert
2020-10-19 19:00 ` Peter Maydell
` (2 subsequent siblings)
3 siblings, 0 replies; 6+ messages in thread
From: Dr. David Alan Gilbert @ 2020-10-19 18:33 UTC (permalink / raw)
To: Peter Xu; +Cc: Jason Wang, qemu-devel, Michael S . Tsirkin
* Peter Xu (peterx@redhat.com) wrote:
> Dave magically found this. Fix them with "0x%x".
>
> Reported-by: Dr. David Alan Gilbert <dgilbert@redhat.com>
> Signed-off-by: Peter Xu <peterx@redhat.com>
Reviewed-by: Dr. David Alan Gilbert <dgilbert@redhat.com>
> ---
> hw/i386/intel_iommu.c | 4 ++--
> 1 file changed, 2 insertions(+), 2 deletions(-)
>
> diff --git a/hw/i386/intel_iommu.c b/hw/i386/intel_iommu.c
> index 749eb6ad63..70ac837733 100644
> --- a/hw/i386/intel_iommu.c
> +++ b/hw/i386/intel_iommu.c
> @@ -2665,7 +2665,7 @@ static uint64_t vtd_mem_read(void *opaque, hwaddr addr, unsigned size)
>
> if (addr + size > DMAR_REG_SIZE) {
> error_report_once("%s: MMIO over range: addr=0x%" PRIx64
> - " size=0x%u", __func__, addr, size);
> + " size=0x%x", __func__, addr, size);
> return (uint64_t)-1;
> }
>
> @@ -2716,7 +2716,7 @@ static void vtd_mem_write(void *opaque, hwaddr addr,
>
> if (addr + size > DMAR_REG_SIZE) {
> error_report_once("%s: MMIO over range: addr=0x%" PRIx64
> - " size=0x%u", __func__, addr, size);
> + " size=0x%x", __func__, addr, size);
> return;
> }
>
> --
> 2.26.2
>
--
Dr. David Alan Gilbert / dgilbert@redhat.com / Manchester, UK
^ permalink raw reply [flat|nested] 6+ messages in thread
* Re: [PATCH] intel_iommu: Fix two misuse of "0x%u" prints
2020-10-19 17:39 [PATCH] intel_iommu: Fix two misuse of "0x%u" prints Peter Xu
2020-10-19 18:33 ` Dr. David Alan Gilbert
@ 2020-10-19 19:00 ` Peter Maydell
2020-10-19 19:12 ` Dr. David Alan Gilbert
2020-10-19 19:50 ` Philippe Mathieu-Daudé
2020-10-20 5:38 ` Jason Wang
3 siblings, 1 reply; 6+ messages in thread
From: Peter Maydell @ 2020-10-19 19:00 UTC (permalink / raw)
To: Peter Xu
Cc: Jason Wang, Michael S . Tsirkin, QEMU Developers,
Dr . David Alan Gilbert
On Mon, 19 Oct 2020 at 18:43, Peter Xu <peterx@redhat.com> wrote:
>
> Dave magically found this. Fix them with "0x%x".
>
> Reported-by: Dr. David Alan Gilbert <dgilbert@redhat.com>
> Signed-off-by: Peter Xu <peterx@redhat.com>
Hmm, a quick grep finds also some "0x%d" in an arm trace-event file :-)
I'll send a patch...
-- PMM
^ permalink raw reply [flat|nested] 6+ messages in thread
* Re: [PATCH] intel_iommu: Fix two misuse of "0x%u" prints
2020-10-19 19:00 ` Peter Maydell
@ 2020-10-19 19:12 ` Dr. David Alan Gilbert
0 siblings, 0 replies; 6+ messages in thread
From: Dr. David Alan Gilbert @ 2020-10-19 19:12 UTC (permalink / raw)
To: Peter Maydell; +Cc: Jason Wang, QEMU Developers, Peter Xu, Michael S . Tsirkin
* Peter Maydell (peter.maydell@linaro.org) wrote:
> On Mon, 19 Oct 2020 at 18:43, Peter Xu <peterx@redhat.com> wrote:
> >
> > Dave magically found this. Fix them with "0x%x".
> >
> > Reported-by: Dr. David Alan Gilbert <dgilbert@redhat.com>
> > Signed-off-by: Peter Xu <peterx@redhat.com>
>
> Hmm, a quick grep finds also some "0x%d" in an arm trace-event file :-)
> I'll send a patch...
See:
https://lists.gnu.org/archive/html/qemu-devel/2020-10/msg04179.html
Dave
> -- PMM
>
--
Dr. David Alan Gilbert / dgilbert@redhat.com / Manchester, UK
^ permalink raw reply [flat|nested] 6+ messages in thread
* Re: [PATCH] intel_iommu: Fix two misuse of "0x%u" prints
2020-10-19 17:39 [PATCH] intel_iommu: Fix two misuse of "0x%u" prints Peter Xu
2020-10-19 18:33 ` Dr. David Alan Gilbert
2020-10-19 19:00 ` Peter Maydell
@ 2020-10-19 19:50 ` Philippe Mathieu-Daudé
2020-10-20 5:38 ` Jason Wang
3 siblings, 0 replies; 6+ messages in thread
From: Philippe Mathieu-Daudé @ 2020-10-19 19:50 UTC (permalink / raw)
To: Peter Xu, qemu-devel
Cc: Jason Wang, Dr . David Alan Gilbert, Michael S . Tsirkin
On 10/19/20 7:39 PM, Peter Xu wrote:
> Dave magically found this. Fix them with "0x%x".
>
> Reported-by: Dr. David Alan Gilbert <dgilbert@redhat.com>
> Signed-off-by: Peter Xu <peterx@redhat.com>
> ---
> hw/i386/intel_iommu.c | 4 ++--
> 1 file changed, 2 insertions(+), 2 deletions(-)
>
> diff --git a/hw/i386/intel_iommu.c b/hw/i386/intel_iommu.c
> index 749eb6ad63..70ac837733 100644
> --- a/hw/i386/intel_iommu.c
> +++ b/hw/i386/intel_iommu.c
> @@ -2665,7 +2665,7 @@ static uint64_t vtd_mem_read(void *opaque, hwaddr addr, unsigned size)
>
> if (addr + size > DMAR_REG_SIZE) {
> error_report_once("%s: MMIO over range: addr=0x%" PRIx64
> - " size=0x%u", __func__, addr, size);
> + " size=0x%x", __func__, addr, size);
Reviewed-by: Philippe Mathieu-Daudé <philmd@redhat.com>
^ permalink raw reply [flat|nested] 6+ messages in thread
* Re: [PATCH] intel_iommu: Fix two misuse of "0x%u" prints
2020-10-19 17:39 [PATCH] intel_iommu: Fix two misuse of "0x%u" prints Peter Xu
` (2 preceding siblings ...)
2020-10-19 19:50 ` Philippe Mathieu-Daudé
@ 2020-10-20 5:38 ` Jason Wang
3 siblings, 0 replies; 6+ messages in thread
From: Jason Wang @ 2020-10-20 5:38 UTC (permalink / raw)
To: Peter Xu, qemu-devel; +Cc: Dr . David Alan Gilbert, Michael S . Tsirkin
On 2020/10/20 上午1:39, Peter Xu wrote:
> Dave magically found this. Fix them with "0x%x".
>
> Reported-by: Dr. David Alan Gilbert <dgilbert@redhat.com>
> Signed-off-by: Peter Xu <peterx@redhat.com>
> ---
> hw/i386/intel_iommu.c | 4 ++--
> 1 file changed, 2 insertions(+), 2 deletions(-)
>
> diff --git a/hw/i386/intel_iommu.c b/hw/i386/intel_iommu.c
> index 749eb6ad63..70ac837733 100644
> --- a/hw/i386/intel_iommu.c
> +++ b/hw/i386/intel_iommu.c
> @@ -2665,7 +2665,7 @@ static uint64_t vtd_mem_read(void *opaque, hwaddr addr, unsigned size)
>
> if (addr + size > DMAR_REG_SIZE) {
> error_report_once("%s: MMIO over range: addr=0x%" PRIx64
> - " size=0x%u", __func__, addr, size);
> + " size=0x%x", __func__, addr, size);
> return (uint64_t)-1;
> }
>
> @@ -2716,7 +2716,7 @@ static void vtd_mem_write(void *opaque, hwaddr addr,
>
> if (addr + size > DMAR_REG_SIZE) {
> error_report_once("%s: MMIO over range: addr=0x%" PRIx64
> - " size=0x%u", __func__, addr, size);
> + " size=0x%x", __func__, addr, size);
> return;
> }
>
Acked-by: Jason Wang <jasowang@redhat.com>
^ permalink raw reply [flat|nested] 6+ messages in thread
end of thread, other threads:[~2020-10-20 5:40 UTC | newest]
Thread overview: 6+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2020-10-19 17:39 [PATCH] intel_iommu: Fix two misuse of "0x%u" prints Peter Xu
2020-10-19 18:33 ` Dr. David Alan Gilbert
2020-10-19 19:00 ` Peter Maydell
2020-10-19 19:12 ` Dr. David Alan Gilbert
2020-10-19 19:50 ` Philippe Mathieu-Daudé
2020-10-20 5:38 ` Jason Wang
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.