* [PATCH] vfio/ccw: Replace warn_once_pfch() with warn_report_once()
@ 2025-02-14 16:19 Cédric Le Goater
2025-02-24 8:23 ` Cédric Le Goater
2025-02-24 17:07 ` Eric Farman
0 siblings, 2 replies; 3+ messages in thread
From: Cédric Le Goater @ 2025-02-14 16:19 UTC (permalink / raw)
To: qemu-devel
Cc: Alex Williamson, Matthew Rosato, Cédric Le Goater,
Eric Farman
Use the common helper warn_report_once() instead of implementing its
own.
Cc: Eric Farman <farman@linux.ibm.com>
Signed-off-by: Cédric Le Goater <clg@redhat.com>
---
hw/vfio/ccw.c | 12 ++----------
1 file changed, 2 insertions(+), 10 deletions(-)
diff --git a/hw/vfio/ccw.c b/hw/vfio/ccw.c
index ea766ae26c744c05515e1cc80a486a3462d82834..e5e0d9e3e7ed124f242b3eda345bc973e418a64c 100644
--- a/hw/vfio/ccw.c
+++ b/hw/vfio/ccw.c
@@ -51,17 +51,8 @@ struct VFIOCCWDevice {
EventNotifier crw_notifier;
EventNotifier req_notifier;
bool force_orb_pfch;
- bool warned_orb_pfch;
};
-static inline void warn_once_pfch(VFIOCCWDevice *vcdev, SubchDev *sch,
- const char *msg)
-{
- warn_report_once_cond(&vcdev->warned_orb_pfch,
- "vfio-ccw (devno %x.%x.%04x): %s",
- sch->cssid, sch->ssid, sch->devno, msg);
-}
-
static void vfio_ccw_compute_needs_reset(VFIODevice *vdev)
{
vdev->needs_reset = false;
@@ -83,7 +74,8 @@ static IOInstEnding vfio_ccw_handle_request(SubchDev *sch)
if (!(sch->orb.ctrl0 & ORB_CTRL0_MASK_PFCH) && vcdev->force_orb_pfch) {
sch->orb.ctrl0 |= ORB_CTRL0_MASK_PFCH;
- warn_once_pfch(vcdev, sch, "PFCH flag forced");
+ warn_report_once("vfio-ccw (devno %x.%x.%04x): PFCH flag forced",
+ sch->cssid, sch->ssid, sch->devno);
}
QEMU_BUILD_BUG_ON(sizeof(region->orb_area) != sizeof(ORB));
--
2.48.1
^ permalink raw reply related [flat|nested] 3+ messages in thread
* Re: [PATCH] vfio/ccw: Replace warn_once_pfch() with warn_report_once()
2025-02-14 16:19 [PATCH] vfio/ccw: Replace warn_once_pfch() with warn_report_once() Cédric Le Goater
@ 2025-02-24 8:23 ` Cédric Le Goater
2025-02-24 17:07 ` Eric Farman
1 sibling, 0 replies; 3+ messages in thread
From: Cédric Le Goater @ 2025-02-24 8:23 UTC (permalink / raw)
To: qemu-devel; +Cc: Alex Williamson, Matthew Rosato, Eric Farman, Thomas Huth
On 2/14/25 17:19, Cédric Le Goater wrote:
> Use the common helper warn_report_once() instead of implementing its
> own.
>
> Cc: Eric Farman <farman@linux.ibm.com>
> Signed-off-by: Cédric Le Goater <clg@redhat.com>
> ---
> hw/vfio/ccw.c | 12 ++----------
> 1 file changed, 2 insertions(+), 10 deletions(-)
>
I can update the trailers before sending a PR. For now, since it is
simple enough :
Applied to vfio-next.
Thanks,
C.
^ permalink raw reply [flat|nested] 3+ messages in thread
* Re: [PATCH] vfio/ccw: Replace warn_once_pfch() with warn_report_once()
2025-02-14 16:19 [PATCH] vfio/ccw: Replace warn_once_pfch() with warn_report_once() Cédric Le Goater
2025-02-24 8:23 ` Cédric Le Goater
@ 2025-02-24 17:07 ` Eric Farman
1 sibling, 0 replies; 3+ messages in thread
From: Eric Farman @ 2025-02-24 17:07 UTC (permalink / raw)
To: Cédric Le Goater, qemu-devel; +Cc: Alex Williamson, Matthew Rosato
On Fri, 2025-02-14 at 17:19 +0100, Cédric Le Goater wrote:
> Use the common helper warn_report_once() instead of implementing its
> own.
>
> Cc: Eric Farman <farman@linux.ibm.com>
> Signed-off-by: Cédric Le Goater <clg@redhat.com>
> ---
> hw/vfio/ccw.c | 12 ++----------
> 1 file changed, 2 insertions(+), 10 deletions(-)
Reviewed-by: Eric Farman <farman@linux.ibm.com>
^ permalink raw reply [flat|nested] 3+ messages in thread
end of thread, other threads:[~2025-02-24 17:08 UTC | newest]
Thread overview: 3+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2025-02-14 16:19 [PATCH] vfio/ccw: Replace warn_once_pfch() with warn_report_once() Cédric Le Goater
2025-02-24 8:23 ` Cédric Le Goater
2025-02-24 17:07 ` Eric Farman
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).