qemu-devel.nongnu.org archive mirror
 help / color / mirror / Atom feed
* [Qemu-devel] [PATCH] hw/net: Remove unnecessary header includes
@ 2018-02-22  9:58 Thomas Huth
  2018-03-02  7:04 ` Jason Wang
  0 siblings, 1 reply; 2+ messages in thread
From: Thomas Huth @ 2018-02-22  9:58 UTC (permalink / raw)
  To: qemu-devel, Jason Wang

Headers like "hw/loader.h" and "qemu/sockets.h" are not needed in
the hw/net/*.c files. And Some other headers are included via other
headers already, so we can drop them, too.

Signed-off-by: Thomas Huth <thuth@redhat.com>
---
 hw/net/e1000.c     | 1 -
 hw/net/lance.c     | 3 ---
 hw/net/ne2000.c    | 2 --
 hw/net/pcnet-pci.c | 1 -
 hw/net/pcnet.c     | 1 -
 hw/net/rtl8139.c   | 2 --
 hw/net/xgmac.c     | 1 -
 7 files changed, 11 deletions(-)

diff --git a/hw/net/e1000.c b/hw/net/e1000.c
index 804ec08..c7f1695 100644
--- a/hw/net/e1000.c
+++ b/hw/net/e1000.c
@@ -30,7 +30,6 @@
 #include "hw/pci/pci.h"
 #include "net/net.h"
 #include "net/checksum.h"
-#include "hw/loader.h"
 #include "sysemu/sysemu.h"
 #include "sysemu/dma.h"
 #include "qemu/iov.h"
diff --git a/hw/net/lance.c b/hw/net/lance.c
index 0028bc5..a08d5ac 100644
--- a/hw/net/lance.c
+++ b/hw/net/lance.c
@@ -36,10 +36,7 @@
  */
 
 #include "qemu/osdep.h"
-#include "hw/sysbus.h"
-#include "net/net.h"
 #include "qemu/timer.h"
-#include "qemu/sockets.h"
 #include "hw/sparc/sparc32_dma.h"
 #include "hw/net/lance.h"
 #include "trace.h"
diff --git a/hw/net/ne2000.c b/hw/net/ne2000.c
index 687ef84..3a9fc89 100644
--- a/hw/net/ne2000.c
+++ b/hw/net/ne2000.c
@@ -23,10 +23,8 @@
  */
 #include "qemu/osdep.h"
 #include "hw/pci/pci.h"
-#include "net/net.h"
 #include "net/eth.h"
 #include "ne2000.h"
-#include "hw/loader.h"
 #include "sysemu/sysemu.h"
 
 /* debug NE2000 card */
diff --git a/hw/net/pcnet-pci.c b/hw/net/pcnet-pci.c
index 0ae5ca4..70dc8b3 100644
--- a/hw/net/pcnet-pci.c
+++ b/hw/net/pcnet-pci.c
@@ -30,7 +30,6 @@
 #include "qemu/osdep.h"
 #include "hw/pci/pci.h"
 #include "net/net.h"
-#include "hw/loader.h"
 #include "qemu/timer.h"
 #include "sysemu/dma.h"
 #include "sysemu/sysemu.h"
diff --git a/hw/net/pcnet.c b/hw/net/pcnet.c
index 606b05c..0c44554 100644
--- a/hw/net/pcnet.c
+++ b/hw/net/pcnet.c
@@ -40,7 +40,6 @@
 #include "net/net.h"
 #include "net/eth.h"
 #include "qemu/timer.h"
-#include "qemu/sockets.h"
 #include "sysemu/sysemu.h"
 #include "trace.h"
 
diff --git a/hw/net/rtl8139.c b/hw/net/rtl8139.c
index 1cc95b8..46daa16 100644
--- a/hw/net/rtl8139.c
+++ b/hw/net/rtl8139.c
@@ -58,9 +58,7 @@
 #include "qemu/timer.h"
 #include "net/net.h"
 #include "net/eth.h"
-#include "hw/loader.h"
 #include "sysemu/sysemu.h"
-#include "qemu/iov.h"
 
 /* debug RTL8139 card */
 //#define DEBUG_RTL8139 1
diff --git a/hw/net/xgmac.c b/hw/net/xgmac.c
index 0843bf1..fa00156 100644
--- a/hw/net/xgmac.c
+++ b/hw/net/xgmac.c
@@ -28,7 +28,6 @@
 #include "hw/sysbus.h"
 #include "qemu/log.h"
 #include "net/net.h"
-#include "net/checksum.h"
 
 #ifdef DEBUG_XGMAC
 #define DEBUGF_BRK(message, args...) do { \
-- 
1.8.3.1

^ permalink raw reply related	[flat|nested] 2+ messages in thread

* Re: [Qemu-devel] [PATCH] hw/net: Remove unnecessary header includes
  2018-02-22  9:58 [Qemu-devel] [PATCH] hw/net: Remove unnecessary header includes Thomas Huth
@ 2018-03-02  7:04 ` Jason Wang
  0 siblings, 0 replies; 2+ messages in thread
From: Jason Wang @ 2018-03-02  7:04 UTC (permalink / raw)
  To: Thomas Huth, qemu-devel



On 2018年02月22日 17:58, Thomas Huth wrote:
> Headers like "hw/loader.h" and "qemu/sockets.h" are not needed in
> the hw/net/*.c files. And Some other headers are included via other
> headers already, so we can drop them, too.
>
> Signed-off-by: Thomas Huth <thuth@redhat.com>
> ---
>   hw/net/e1000.c     | 1 -
>   hw/net/lance.c     | 3 ---
>   hw/net/ne2000.c    | 2 --
>   hw/net/pcnet-pci.c | 1 -
>   hw/net/pcnet.c     | 1 -
>   hw/net/rtl8139.c   | 2 --
>   hw/net/xgmac.c     | 1 -
>   7 files changed, 11 deletions(-)
>
> diff --git a/hw/net/e1000.c b/hw/net/e1000.c
> index 804ec08..c7f1695 100644
> --- a/hw/net/e1000.c
> +++ b/hw/net/e1000.c
> @@ -30,7 +30,6 @@
>   #include "hw/pci/pci.h"
>   #include "net/net.h"
>   #include "net/checksum.h"
> -#include "hw/loader.h"
>   #include "sysemu/sysemu.h"
>   #include "sysemu/dma.h"
>   #include "qemu/iov.h"
> diff --git a/hw/net/lance.c b/hw/net/lance.c
> index 0028bc5..a08d5ac 100644
> --- a/hw/net/lance.c
> +++ b/hw/net/lance.c
> @@ -36,10 +36,7 @@
>    */
>   
>   #include "qemu/osdep.h"
> -#include "hw/sysbus.h"
> -#include "net/net.h"
>   #include "qemu/timer.h"
> -#include "qemu/sockets.h"
>   #include "hw/sparc/sparc32_dma.h"
>   #include "hw/net/lance.h"
>   #include "trace.h"
> diff --git a/hw/net/ne2000.c b/hw/net/ne2000.c
> index 687ef84..3a9fc89 100644
> --- a/hw/net/ne2000.c
> +++ b/hw/net/ne2000.c
> @@ -23,10 +23,8 @@
>    */
>   #include "qemu/osdep.h"
>   #include "hw/pci/pci.h"
> -#include "net/net.h"
>   #include "net/eth.h"
>   #include "ne2000.h"
> -#include "hw/loader.h"
>   #include "sysemu/sysemu.h"
>   
>   /* debug NE2000 card */
> diff --git a/hw/net/pcnet-pci.c b/hw/net/pcnet-pci.c
> index 0ae5ca4..70dc8b3 100644
> --- a/hw/net/pcnet-pci.c
> +++ b/hw/net/pcnet-pci.c
> @@ -30,7 +30,6 @@
>   #include "qemu/osdep.h"
>   #include "hw/pci/pci.h"
>   #include "net/net.h"
> -#include "hw/loader.h"
>   #include "qemu/timer.h"
>   #include "sysemu/dma.h"
>   #include "sysemu/sysemu.h"
> diff --git a/hw/net/pcnet.c b/hw/net/pcnet.c
> index 606b05c..0c44554 100644
> --- a/hw/net/pcnet.c
> +++ b/hw/net/pcnet.c
> @@ -40,7 +40,6 @@
>   #include "net/net.h"
>   #include "net/eth.h"
>   #include "qemu/timer.h"
> -#include "qemu/sockets.h"
>   #include "sysemu/sysemu.h"
>   #include "trace.h"
>   
> diff --git a/hw/net/rtl8139.c b/hw/net/rtl8139.c
> index 1cc95b8..46daa16 100644
> --- a/hw/net/rtl8139.c
> +++ b/hw/net/rtl8139.c
> @@ -58,9 +58,7 @@
>   #include "qemu/timer.h"
>   #include "net/net.h"
>   #include "net/eth.h"
> -#include "hw/loader.h"
>   #include "sysemu/sysemu.h"
> -#include "qemu/iov.h"
>   
>   /* debug RTL8139 card */
>   //#define DEBUG_RTL8139 1
> diff --git a/hw/net/xgmac.c b/hw/net/xgmac.c
> index 0843bf1..fa00156 100644
> --- a/hw/net/xgmac.c
> +++ b/hw/net/xgmac.c
> @@ -28,7 +28,6 @@
>   #include "hw/sysbus.h"
>   #include "qemu/log.h"
>   #include "net/net.h"
> -#include "net/checksum.h"
>   
>   #ifdef DEBUG_XGMAC
>   #define DEBUGF_BRK(message, args...) do { \

Applied.

Thanks

^ permalink raw reply	[flat|nested] 2+ messages in thread

end of thread, other threads:[~2018-03-02  7:04 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2018-02-22  9:58 [Qemu-devel] [PATCH] hw/net: Remove unnecessary header includes Thomas Huth
2018-03-02  7:04 ` Jason Wang

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).