qemu-devel
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [RFC PATCH] hw/net/can: clean-up unnecessary includes


From: Pierrick Bouvier
Subject: Re: [RFC PATCH] hw/net/can: clean-up unnecessary includes
Date: Mon, 9 Dec 2024 10:58:07 -0800
User-agent: Mozilla Thunderbird

On 12/9/24 02:06, Alex Bennée wrote:
The event_notifier, thread and socket includes look like copy and
paste of standard headers. None of the canbus devices use chardev
although some relied on chardev to bring in bitops and byte swapping
headers. In this case include them directly.

Signed-off-by: Alex Bennée <alex.bennee@linaro.org>
---
  hw/net/can/can_kvaser_pci.c   | 4 ----
  hw/net/can/can_mioe3680_pci.c | 4 ----
  hw/net/can/can_pcm3680_pci.c  | 4 ----
  hw/net/can/can_sja1000.c      | 2 +-
  hw/net/can/ctucan_core.c      | 3 ++-
  hw/net/can/ctucan_pci.c       | 4 ----
  6 files changed, 3 insertions(+), 18 deletions(-)

diff --git a/hw/net/can/can_kvaser_pci.c b/hw/net/can/can_kvaser_pci.c
index 38434d3a04..9e363d532f 100644
--- a/hw/net/can/can_kvaser_pci.c
+++ b/hw/net/can/can_kvaser_pci.c
@@ -30,12 +30,8 @@
   */
#include "qemu/osdep.h"
-#include "qemu/event_notifier.h"
  #include "qemu/module.h"
-#include "qemu/thread.h"
-#include "qemu/sockets.h"
  #include "qapi/error.h"
-#include "chardev/char.h"
  #include "hw/irq.h"
  #include "hw/pci/pci_device.h"
  #include "hw/qdev-properties.h"
diff --git a/hw/net/can/can_mioe3680_pci.c b/hw/net/can/can_mioe3680_pci.c
index 21659b7afb..580f099e00 100644
--- a/hw/net/can/can_mioe3680_pci.c
+++ b/hw/net/can/can_mioe3680_pci.c
@@ -26,12 +26,8 @@
   */
#include "qemu/osdep.h"
-#include "qemu/event_notifier.h"
  #include "qemu/module.h"
-#include "qemu/thread.h"
-#include "qemu/sockets.h"
  #include "qapi/error.h"
-#include "chardev/char.h"
  #include "hw/irq.h"
  #include "hw/pci/pci_device.h"
  #include "hw/qdev-properties.h"
diff --git a/hw/net/can/can_pcm3680_pci.c b/hw/net/can/can_pcm3680_pci.c
index af21dc6855..3195b79954 100644
--- a/hw/net/can/can_pcm3680_pci.c
+++ b/hw/net/can/can_pcm3680_pci.c
@@ -26,12 +26,8 @@
   */
#include "qemu/osdep.h"
-#include "qemu/event_notifier.h"
  #include "qemu/module.h"
-#include "qemu/thread.h"
-#include "qemu/sockets.h"
  #include "qapi/error.h"
-#include "chardev/char.h"
  #include "hw/irq.h"
  #include "hw/pci/pci_device.h"
  #include "hw/qdev-properties.h"
diff --git a/hw/net/can/can_sja1000.c b/hw/net/can/can_sja1000.c
index 6694d7bfd8..5b6ba9df6c 100644
--- a/hw/net/can/can_sja1000.c
+++ b/hw/net/can/can_sja1000.c
@@ -27,7 +27,7 @@
#include "qemu/osdep.h"
  #include "qemu/log.h"
-#include "chardev/char.h"
+#include "qemu/bitops.h"
  #include "hw/irq.h"
  #include "migration/vmstate.h"
  #include "net/can_emu.h"
diff --git a/hw/net/can/ctucan_core.c b/hw/net/can/ctucan_core.c
index 812b83e93e..4402d4cb1f 100644
--- a/hw/net/can/ctucan_core.c
+++ b/hw/net/can/ctucan_core.c
@@ -28,7 +28,8 @@
#include "qemu/osdep.h"
  #include "qemu/log.h"
-#include "chardev/char.h"
+#include "qemu/bswap.h"
+#include "qemu/bitops.h"
  #include "hw/irq.h"
  #include "migration/vmstate.h"
  #include "net/can_emu.h"
diff --git a/hw/net/can/ctucan_pci.c b/hw/net/can/ctucan_pci.c
index 65f1f82303..a8c77b9194 100644
--- a/hw/net/can/ctucan_pci.c
+++ b/hw/net/can/ctucan_pci.c
@@ -27,12 +27,8 @@
   */
#include "qemu/osdep.h"
-#include "qemu/event_notifier.h"
  #include "qemu/module.h"
-#include "qemu/thread.h"
-#include "qemu/sockets.h"
  #include "qapi/error.h"
-#include "chardev/char.h"
  #include "hw/irq.h"
  #include "hw/pci/pci_device.h"
  #include "hw/qdev-properties.h"

Reviewed-by: Pierrick Bouvier <pierrick.bouvier@linaro.org>


reply via email to

[Prev in Thread] Current Thread [Next in Thread]