Include qemu/module.h where needed, drop it from qemu-common.h

Signed-off-by: Markus Armbruster <armbru@redhat.com>
Message-Id: <20190523143508.25387-4-armbru@redhat.com>
[Rebased with conflicts resolved automatically, except for
hw/usb/dev-hub.c hw/misc/exynos4210_rng.c hw/misc/bcm2835_rng.c
hw/misc/aspeed_scu.c hw/display/virtio-vga.c hw/arm/stm32f205_soc.c;
ui/cocoa.m fixed up]
diff --git a/ui/cocoa.m b/ui/cocoa.m
index 420b241..89b16e0 100644
--- a/ui/cocoa.m
+++ b/ui/cocoa.m
@@ -36,6 +36,7 @@
 #include "qapi/qapi-commands-misc.h"
 #include "sysemu/blockdev.h"
 #include "qemu-version.h"
+#include "qemu/module.h"
 #include <Carbon/Carbon.h>
 #include "qom/cpu.h"
 
diff --git a/ui/console.c b/ui/console.c
index 6d2282d..eb7e7e0 100644
--- a/ui/console.c
+++ b/ui/console.c
@@ -27,6 +27,7 @@
 #include "hw/qdev-core.h"
 #include "qapi/error.h"
 #include "qapi/qapi-commands-ui.h"
+#include "qemu/module.h"
 #include "qemu/option.h"
 #include "qemu/timer.h"
 #include "chardev/char-fe.h"
diff --git a/ui/curses.c b/ui/curses.c
index e9319eb..a6e260e 100644
--- a/ui/curses.c
+++ b/ui/curses.c
@@ -21,6 +21,7 @@
  * OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
  * THE SOFTWARE.
  */
+
 #include "qemu/osdep.h"
 
 #ifndef _WIN32
@@ -33,7 +34,7 @@
 #include <iconv.h>
 
 #include "qapi/error.h"
-#include "qemu-common.h"
+#include "qemu/module.h"
 #include "ui/console.h"
 #include "ui/input.h"
 #include "sysemu/sysemu.h"
diff --git a/ui/egl-headless.c b/ui/egl-headless.c
index e67b47a..05b2e7d 100644
--- a/ui/egl-headless.c
+++ b/ui/egl-headless.c
@@ -1,5 +1,5 @@
 #include "qemu/osdep.h"
-#include "qemu-common.h"
+#include "qemu/module.h"
 #include "sysemu/sysemu.h"
 #include "ui/console.h"
 #include "ui/egl-helpers.h"
diff --git a/ui/input-linux.c b/ui/input-linux.c
index ba550dd..c8d22f9 100644
--- a/ui/input-linux.c
+++ b/ui/input-linux.c
@@ -6,8 +6,8 @@
 
 #include "qemu/osdep.h"
 #include "qapi/error.h"
-#include "qemu-common.h"
 #include "qemu/config-file.h"
+#include "qemu/module.h"
 #include "qemu/sockets.h"
 #include "sysemu/sysemu.h"
 #include "ui/input.h"
diff --git a/ui/sdl2.c b/ui/sdl2.c
index 1277cf2..b8a3119 100644
--- a/ui/sdl2.c
+++ b/ui/sdl2.c
@@ -24,7 +24,7 @@
 /* Ported SDL 1.2 code to 2.0 by Dave Airlie. */
 
 #include "qemu/osdep.h"
-#include "qemu-common.h"
+#include "qemu/module.h"
 #include "ui/console.h"
 #include "ui/input.h"
 #include "ui/sdl2.h"
diff --git a/ui/spice-app.c b/ui/spice-app.c
index 30541b1..40fb2ef 100644
--- a/ui/spice-app.c
+++ b/ui/spice-app.c
@@ -21,15 +21,16 @@
  * OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
  * THE SOFTWARE.
  */
+
 #include "qemu/osdep.h"
 
 #include <gio/gio.h>
 
-#include "qemu-common.h"
 #include "ui/console.h"
 #include "qemu/config-file.h"
 #include "qemu/option.h"
 #include "qemu/cutils.h"
+#include "qemu/module.h"
 #include "qapi/error.h"
 #include "io/channel-command.h"
 #include "chardev/spice.h"
diff --git a/ui/spice-core.c b/ui/spice-core.c
index 0632c74..2ffc333 100644
--- a/ui/spice-core.c
+++ b/ui/spice-core.c
@@ -22,6 +22,7 @@
 
 #include "ui/qemu-spice.h"
 #include "qemu/error-report.h"
+#include "qemu/module.h"
 #include "qemu/thread.h"
 #include "qemu/timer.h"
 #include "qemu/queue.h"
diff --git a/ui/vnc.c b/ui/vnc.c
index d83f4a6..38f92bf 100644
--- a/ui/vnc.c
+++ b/ui/vnc.c
@@ -30,6 +30,7 @@
 #include "trace.h"
 #include "sysemu/sysemu.h"
 #include "qemu/error-report.h"
+#include "qemu/module.h"
 #include "qemu/option.h"
 #include "qemu/sockets.h"
 #include "qemu/timer.h"